Discussion: [Sdl-developers] ABNF Grammar
[Sdl-developers] ABNF Grammar
Daniel LeuckMon Jan 8 14:54:21 HST 2007
- Previous message: [Sdl-developers] ABNF Grammar
- Next message: [Sdl-developers] ABNF Grammar
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ top page ]
Hi Jesse, I would just write a method to consume the multiline comments during the tokenization phase. At this point, I don't think SDL's grammar is complex enough to require use of a parser generator. I considered using JJTree as we do for BeanShell (https://javacc.dev.java.net/doc/JJTree.html), but I discovered writing it by hand wasn't too hard, and the Java and C# implementations are very fast. Dan _____ From: sdl-developers-bounces at ikayzo.org [mailto:sdl-developers-bounces at ikayzo.org] On Behalf Of Jesse Weaver Sent: Monday, January 08, 2007 2:29 PM To: sdl-developers at ikayzo.org:Information relating to SDL development Subject: Re: [Sdl-developers] ABNF Grammar Just in case it makes a difference, I'm writing a completely handcoded recursive descent parser for the C++ version (Boost::Spirit is a lot of library overhead). Right now, the parsing functions for each part of the grammar will look at the text stream directly. Should I add a lexer-type class, and implement the multiline comments in there, or simply write in multiline comments as a fallback when nothing else can be matched? -- Jesse ----------- There is a theory which states that if anybody ever discovers exactly what the Universe is for and why it is here, it will instantly disappear and be replaced by something even more bizarre and inexplicable. There is another theory which states that this has already happened. - Douglas Adams, author of Hitchhiker's Guide to the Galaxy -------------- next part -------------- An HTML attachment was scrubbed... URL: http://ml.ikayzo.org/pipermail/sdl-developers/attachments/20070108/6814a174/attachment.htm
- Previous message: [Sdl-developers] ABNF Grammar
- Next message: [Sdl-developers] ABNF Grammar
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ] [ top page ]










