reimplementation (oupsi)
This commit is contained in:
parent
0572264f76
commit
1aec6085d9
27 changed files with 1213 additions and 21 deletions
23
main.c
23
main.c
|
|
@ -1,23 +0,0 @@
|
|||
#include <stdio.h>
|
||||
|
||||
#include "wscm.h"
|
||||
|
||||
int main(void) {
|
||||
gcinit();
|
||||
|
||||
O env = NIL;
|
||||
addroot(&env);
|
||||
setupenv(&env);
|
||||
|
||||
// IF
|
||||
O code = cons(SYM("if"), cons(NIL, cons(NUM(100), cons(NUM(200), NIL))));
|
||||
addroot(&code);
|
||||
|
||||
// collect();
|
||||
println(code);
|
||||
printf("=> ");
|
||||
println(eval(code, env));
|
||||
|
||||
gcfinalize();
|
||||
return 0;
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue