forked from alex-eg/sex
implement closures
This commit is contained in:
25
sexc.scm
25
sexc.scm
@@ -175,17 +175,22 @@ status, which is ours to pass on."
|
||||
(semen-process raw-forms))))
|
||||
|
||||
(define prelude
|
||||
'((include inttypes.h)
|
||||
(include stdbool.h)
|
||||
(append
|
||||
'((include inttypes.h)
|
||||
(include stdbool.h)
|
||||
(include stddef.h) ; max_align_t, for closure environments
|
||||
(typedef u8 uint8-t)
|
||||
(typedef i8 int8-t)
|
||||
(typedef u16 uint16-t)
|
||||
(typedef i16 int16-t)
|
||||
(typedef u32 uint32-t)
|
||||
(typedef i32 int32-t)
|
||||
(typedef u64 uint64-t)
|
||||
(typedef i64 int64-t))
|
||||
|
||||
(typedef u8 uint8-t)
|
||||
(typedef i8 int8-t)
|
||||
(typedef u16 uint16-t)
|
||||
(typedef i16 int16-t)
|
||||
(typedef u32 uint32-t)
|
||||
(typedef i32 int32-t)
|
||||
(typedef u64 uint64-t)
|
||||
(typedef i64 int64-t)))
|
||||
;; The closure environment is the part of the ABI, so include it in
|
||||
;; every module
|
||||
(list (closure-env-declaration))))
|
||||
|
||||
(define (main)
|
||||
(let* ((argv (command-line-arguments))
|
||||
|
||||
Reference in New Issue
Block a user