Kris, I started porting Brendan Eich's Narcissus over to Narwhal
before finding that you already started it:
http://github.com/kriskowal/narcissus
Are you using this anywhere or was it just started? I ran into these issues:
ReferenceError: "snarf" is not defined.
org.mozilla.javascript.EcmaError: ReferenceError: "snarf" is not
defined. (/home/andy/git/narwhal2/packages/narcissus/lib/narcissus/exec.js#56)
That was on Rhino -- in the code it says:
// Extensions to ECMA.
snarf: snarf, evaluate: evaluate,
The other one is that he uses "catch if" syntax, which is a
Rhino-specific extension to ECMAScript:
undefined:321: SyntaxError: Unexpected token if
} catch (e if e == BREAK && x.target == n) {
^^
so that doesn't work on v8.
Andy
--
You received this message because you are subscribed to the Google Groups "Narwhal and Jack" group.
To post to this group, send email to narw...@googlegroups.com.
To unsubscribe from this group, send email to narwhaljs+...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/narwhaljs?hl=en.
So I'm basically done with the Jekyll-like static doc generator, but I
have to use it to document itself and such before I "release". I
thought about also writing a "docstring" parser for jsdoc-like docs,
but I would rather not if it already exists.
Can jsdoc-toolkit take a .js file and output a JSON file of the
docstrings? Something like:
{filename: "foo.js",
items: [
{name: "myFunction"
args: [
{name: "a", type: "int", desc: "An integer a"}
...
]
}
....
]
}
If so I think it would make sense to loosely integrate the 2 things.
The Narcissus parser doesn't retain comments though (probably not too
hard to add). It will output line/column numbers of every token
(which I haven't enabled yet, but that's easy).
Is this it? http://code.google.com/p/jsdoc-toolkit/ Or are you
porting it to Narwhal?
>
> BTW: just wondering why don't you use narwhal itself for building
> narcissus.js instead of python??
Yeah that could have been done. I guess just that Python is more
stable so I just chose it for this non-essential part.
thanks,
Andy