add (picrin base macro) primitives
This commit is contained in:
parent
6b01f36914
commit
f70b6c5240
|
@ -1,7 +1,7 @@
|
|||
(define-library (picrin base)
|
||||
(import (rename (picrin base core) (define define*))
|
||||
(scheme base)
|
||||
(picrin macro))
|
||||
(picrin base macro)
|
||||
(scheme base))
|
||||
|
||||
(define-syntax define
|
||||
(lambda (form use-env mac-env)
|
||||
|
|
|
@ -2,6 +2,7 @@
|
|||
|
||||
(define-library (picrin macro)
|
||||
(import (picrin base)
|
||||
(picrin base macro)
|
||||
(scheme base)
|
||||
(picrin dictionary))
|
||||
|
||||
|
@ -128,7 +129,9 @@
|
|||
(cons (cdr formal)
|
||||
body)))))))
|
||||
|
||||
(export identifier=?
|
||||
(export identifier?
|
||||
identifier=?
|
||||
make-identifier
|
||||
make-syntactic-closure
|
||||
close-syntax
|
||||
capture-syntactic-environment
|
||||
|
|
|
@ -479,12 +479,15 @@ pic_macro_make_identifier(pic_state *pic)
|
|||
void
|
||||
pic_init_macro(pic_state *pic)
|
||||
{
|
||||
pic_deflibrary (pic, "(picrin base macro)") {
|
||||
pic_defun(pic, "identifier?", pic_macro_identifier_p);
|
||||
pic_defun(pic, "make-identifier", pic_macro_make_identifier);
|
||||
}
|
||||
|
||||
pic_deflibrary (pic, "(picrin macro)") {
|
||||
pic_defun(pic, "gensym", pic_macro_gensym);
|
||||
pic_defun(pic, "ungensym", pic_macro_ungensym);
|
||||
pic_defun(pic, "macroexpand", pic_macro_macroexpand);
|
||||
pic_defun(pic, "macroexpand-1", pic_macro_macroexpand_1);
|
||||
pic_defun(pic, "identifier?", pic_macro_identifier_p);
|
||||
pic_defun(pic, "make-identifier", pic_macro_make_identifier);
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue