mirror of
https://git.savannah.gnu.org/git/guile.git
synced 2025-06-24 12:20:20 +02:00
no keyword arguments in GHIL / GLIL, just optional args -- faster compiles
* module/system/base/syntax.scm (define-record): So, in the generated constructors, allow optional arguments, but not keyword arguments. Conses much less in the constructors. (define-record/keywords): And the old define-record is here. * module/language/ghil.scm (parse-ghil): * module/language/ghil/compile-glil.scm (codegen): * module/language/scheme/compile-ghil.scm (translate-1, quote) (quasiquote): Don't use keywords in this compiler hotpath. * module/system/base/language.scm (<language>): * module/system/repl/common.scm (<repl>): * module/system/vm/debug.scm (<debugger>): Use define-record/keywords.
This commit is contained in:
parent
df8cd091f9
commit
d9d671f76e
7 changed files with 52 additions and 18 deletions
|
@ -150,7 +150,7 @@
|
|||
|
||||
;; fixme: non-self-quoting objects like #<foo>
|
||||
(else
|
||||
(make-ghil-quote e l #:obj x)))))
|
||||
(make-ghil-quote e l x)))))
|
||||
|
||||
(define (valid-bindings? bindings . it-is-for-do)
|
||||
(define (valid-binding? b)
|
||||
|
@ -179,11 +179,11 @@
|
|||
|
||||
(define-scheme-translator quote
|
||||
;; (quote OBJ)
|
||||
((,obj) (make-ghil-quote e l #:obj obj)))
|
||||
((,obj) (make-ghil-quote e l obj)))
|
||||
|
||||
(define-scheme-translator quasiquote
|
||||
;; (quasiquote OBJ)
|
||||
((,obj) (make-ghil-quasiquote e l #:exp (trans-quasiquote e l obj 0))))
|
||||
((,obj) (make-ghil-quasiquote e l (trans-quasiquote e l obj 0))))
|
||||
|
||||
(define-scheme-translator define
|
||||
;; (define NAME VAL)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue