mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-23 20:15:05 +02:00
Setting stage for eval interpreted func from compiled code
This commit is contained in:
parent
14855cef41
commit
2109ea1483
1 changed files with 14 additions and 0 deletions
14
runtime.h
14
runtime.h
|
@ -1476,6 +1476,20 @@ static object apply(object cont, object func, object args){
|
|||
}
|
||||
|
||||
break;
|
||||
// TODO: if #define CYC_EVAL
|
||||
// TODO: also, this only works if the generated code knows to call apply, want to do this,
|
||||
// but again only if CYC_EVAL is defined:
|
||||
//#define funcall2(cfn,a1,a2) if (type_of(cfn) == cons_tag || prim(cfn)) { Cyc_apply(1, (closure)a1, cfn,a2); } else { ((cfn)->fn)(2,cfn,a1,a2);}
|
||||
case cons_tag:
|
||||
if (!nullp(func) && eq(quote_Cyc_191procedure, car(func))) {
|
||||
printf("TODO: apply compound proc\n");
|
||||
exit(1);
|
||||
} else {
|
||||
printf("Unable to evaluate list\n");
|
||||
exit(1);
|
||||
}
|
||||
// TODO: #endif
|
||||
|
||||
default:
|
||||
printf("Invalid object type %ld\n", type_of(func));
|
||||
exit(1);
|
||||
|
|
Loading…
Add table
Reference in a new issue