mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-05-20 11:40:18 +02:00
heap/literal fixes for repl-default-options
* module/system/repl/common.scm (repl-default-options): Heap-allocate the repl-default-options, to avoid mutating a literal. (make-repl): Copy repl-default-options.
This commit is contained in:
parent
a38dd31ffc
commit
2b12193df2
1 changed files with 5 additions and 4 deletions
|
@ -104,14 +104,15 @@ See <http://www.gnu.org/licenses/lgpl.html>, for more details.")
|
|||
language options tm-stats gc-stats inport outport debug)
|
||||
|
||||
(define repl-default-options
|
||||
'((compile-options . (#:warnings (unbound-variable arity-mismatch)))
|
||||
(trace . #f)
|
||||
(interp . #f)))
|
||||
(copy-tree
|
||||
'((compile-options . (#:warnings (unbound-variable arity-mismatch)))
|
||||
(trace . #f)
|
||||
(interp . #f))))
|
||||
|
||||
(define %make-repl make-repl)
|
||||
(define* (make-repl lang #:optional debug)
|
||||
(%make-repl #:language (lookup-language lang)
|
||||
#:options repl-default-options
|
||||
#:options (copy-tree repl-default-options)
|
||||
#:tm-stats (times)
|
||||
#:gc-stats (gc-stats)
|
||||
#:inport (current-input-port)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue