25 Mai
2011
25 Mai
'11
08:58
Hello, I can't understand why compiiler fails if "make-obj" function is re-defined (for example, using "(include-adt "_gvmadt.scm")"). A minimal example to reproduce: $ export GAMBIT_SOURCE=....my local copy.... $ $GAMBIT_SOURCE/gsc/gsc -:~~lib=/home/olpa/p/scheme/gambit/lib Gambit v4.6.0 > (define std-scm (string-append (getenv "GAMBIT_SOURCE") "/lib /_std.scm")) > (compile-file-to-c std-scm) "/home/olpa/p/scheme/gambit/lib/_std.c" > (pp c#make-obj) (##lambda (val) (+ (* (enter-opnd val #f) 8) 5)) > (define c#make-obj (##lambda (val) (+ (* (c#enter-opnd val #f) 8) 5))) > (pp c#make-obj) (lambda (val) (+ (* (c#enter-opnd val #f) 8) 5)) > (compile-file-to-c std-scm) *** ERROR IN c#schedule-gen-proc, "p/scheme/gambit/gsc/_front.sc m"@1215.19 -- Wrong number of arguments passed to procedure (c#make-obj) 1> An obvious solution is not to re-define the function, but I'm curious: what happens? Why using an identical function leads to the error? -- Oleg Parashchenko olpa@ http://uucode.com/ http://uucode.com/blog/ XML, TeX, Python, Mac, Chess