I'm confused. This is a self-interpreter, but in what sense is it metacircular? It's an implementation of JavaScript in JavaScript; it does not appear to rely on the host's evaluation semantics, which is necessary to qualify as a metacircular evaluator: http://en.wikipedia.org/wiki/Meta-circular_evaluator
Mozilla also has a Firefox addon called Zaphod which will allow you to force scripts in web-pages to be executed with your (customized) Narcissus interpreter, instead of executing scripts with SpiderMonkey directly:
Unfortunately, it does not seem to create Emacs-style tags at the moment. I had meant to add that to it--I even have some half-baked code lying around somewhere--but never got around to finishing it :(
Still, it's a cool project anybody working with JavaScript should check out.
This is interesting, but doesn't appear to be self-hosting. That is, you can't use Narcissus to compile Narcissus, you have to use SpiderMonkey to run the Narcissus code (that is the impression I get from reading the wiki, anyway, someone correct me if I'm wrong). Still, it is cool that the objects that Narcissus parses in the "user" code are stored exactly the same way in the "host" code.
Funny enough, I just started using this the other day to write a little async callback JS pre-processor. I wanted to just tokenize but then I found out that JS's regexp literals make JS ambiguous to parse. This project turned out to be a huge boon--really easy to patch to find particular token boundaries.
[+] [-] lubutu|14 years ago|reply
[+] [-] stralep|14 years ago|reply
[+] [-] comex|14 years ago|reply
[+] [-] thristian|14 years ago|reply
https://mozillalabs.com/zaphod/
[+] [-] tikhonj|14 years ago|reply
[1]: http://doctorjs.org/ [2]: https://github.com/mozilla/doctorjs
Unfortunately, it does not seem to create Emacs-style tags at the moment. I had meant to add that to it--I even have some half-baked code lying around somewhere--but never got around to finishing it :(
Still, it's a cool project anybody working with JavaScript should check out.
[+] [-] mcmire|14 years ago|reply
[+] [-] lalc|14 years ago|reply
[+] [-] ldayley|14 years ago|reply