Re: mixing lush with clush
"Yury Sulsky" <[email protected]> Fri, 17 Mar 2006 02:33:49 -0500
| Newsgroups | gmane.lisp.lush.devel |
|---|---|
| Message-ID | <[email protected]> |
On 3/17/06, Ralf Juengling <[email protected]> wrote: > The DX wrappers are all hand-coded. They essentially do runtime > type-checking and then call the wrapped C function (if it exits). > When you say "the compiler should produce marshalling code" for > C API functions, I guess you mean it should do the type checking > at compile time if possible, perhaps emit C code for runtime type > checking where it doesn't have enough information at compile time, > and finally emit the C function call. It currently cannot do compile > time type-checking because the DXs do not carry information about > the C functions they wrap. DHs do carry that information. Well, by marshalling I meant that when the compiler comes across a form that it can't translate into C, it emits code that does the following: - box up any local variables that the form refers to and add them to the lisp environment - call the interpreter to evaluate the form - insert run time type checks when assigning the return value to a local variable of a specific type (otherwise leave the return value boxed up) > I hope that makes sense. Yes, thank you for the primer! Yury ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid0944&bid$1720&dat1642