Subj : Re: Need a few hints on JS_CompileFunction To : netscape.public.mozilla.jseng From : Sterling Bates Date : Wed May 19 2004 01:00 pm Brendan Eich wrote: > The docs need to be fixed to say that obj and name may be null (both, > one or the other, or neither -- they're independent). Non-null obj with > null name means the function is anonymous, but scoped by obj. Non-null > obj with non-null name is a function-valued property of obj, where the > function object is scoped by obj. Null obj with non-null name is a > named function object with no scope parent. Null obj and name make an > anonymous function with no scope parent. Here's an updated description for JS_CompileFunction (sans markup): --- JS_CompileFunction compiles a function from a text string, bytes, and associates it with a JS object, obj. If obj is NULL, the function is created without a scope parent. name is the name to assign to the newly created function. If name is NULL, an anonymous function is created. [...] --- I also added "May be null." to the parameter descriptions for obj and name. Let me know if that works. Sterling .