mirror of
https://github.com/justinethier/cyclone.git
synced 2025-05-21 22:59:16 +02:00
Fix to cyc_display
Print ellipsis with a lambda received from interpreter, as an inidication there is more that is not being displayed
This commit is contained in:
parent
13a0a368ad
commit
917c6c00b3
1 changed files with 6 additions and 4 deletions
10
runtime.h
10
runtime.h
|
@ -575,7 +575,7 @@ static object Cyc_display(x) object x;
|
||||||
if (equal(quote_Cyc_191procedure, car(x))) {
|
if (equal(quote_Cyc_191procedure, car(x))) {
|
||||||
printf(" ");
|
printf(" ");
|
||||||
Cyc_display(cadr(x));
|
Cyc_display(cadr(x));
|
||||||
printf(")");
|
printf(" ...)"); /* skip body and env for now */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1447,9 +1447,9 @@ static void dispatch_va(int argc, function_type_va func, object clo, object cont
|
||||||
static object apply(object cont, object func, object args){
|
static object apply(object cont, object func, object args){
|
||||||
common_type buf;
|
common_type buf;
|
||||||
|
|
||||||
printf("DEBUG apply: ");
|
//printf("DEBUG apply: ");
|
||||||
Cyc_display(args);
|
//Cyc_display(args);
|
||||||
printf("\n");
|
//printf("\n");
|
||||||
if (!is_object_type(func)) {
|
if (!is_object_type(func)) {
|
||||||
printf("Call of non-procedure: ");
|
printf("Call of non-procedure: ");
|
||||||
Cyc_display(func);
|
Cyc_display(func);
|
||||||
|
@ -1486,11 +1486,13 @@ printf("\n");
|
||||||
case cons_tag:
|
case cons_tag:
|
||||||
if (!nullp(func) && eq(quote_Cyc_191procedure, car(func))) {
|
if (!nullp(func) && eq(quote_Cyc_191procedure, car(func))) {
|
||||||
make_cons(c, func, args);
|
make_cons(c, func, args);
|
||||||
|
/*
|
||||||
printf("DEBUG apply cons: ");
|
printf("DEBUG apply cons: ");
|
||||||
Cyc_display(&c);
|
Cyc_display(&c);
|
||||||
printf("\n");
|
printf("\n");
|
||||||
//printf("TODO: apply compound proc\n");
|
//printf("TODO: apply compound proc\n");
|
||||||
//exit(1);
|
//exit(1);
|
||||||
|
*/
|
||||||
((closure)__glo_eval)->fn(3, __glo_eval, cont, &c, nil);
|
((closure)__glo_eval)->fn(3, __glo_eval, cont, &c, nil);
|
||||||
} else {
|
} else {
|
||||||
printf("Unable to evaluate list\n");
|
printf("Unable to evaluate list\n");
|
||||||
|
|
Loading…
Add table
Reference in a new issue