Akash Kava
Akash Kava

Reputation: 39956

What can be used for parser/lexer in silverlight, M Programming or ANTLR?

I am trying to create a simple parser/lexer, my problem is I have to use this in silverlight, so I need a parser/lexer that requires no runtime, it needs to have pure C# code without any dependency on any runtime. I know there used to be lex/yacc tool, but cant find it anymore for C#, I did study Sql Modelling M language, but to my understanding, it will not work inside silverlight as it needs Sql modelling runtime or some dependent components that may not be available on silverlight on non microsoft platform.

So M Programming looks like out, can ANTLR be used in silverlight or is there any other parser which generates all the code without any runtime dependencies?

Upvotes: 1

Views: 293

Answers (3)

cdiggins
cdiggins

Reputation: 18243

The Jigsaw library would meet your requirements. It has a PackRat parsing library (a recursive descent parser with memoization) that recognizes PEG grammars. Unlike Irony it requires no separate scanning phase.

Upvotes: 0

Akash Kava
Akash Kava

Reputation: 39956

http://irony.codeplex.com/ provides a good Parser/Lexer for expression parsing and it is straight forward to use it.

Upvotes: 1

leppie
leppie

Reputation: 117330

gppg and gplex should work without issue.

Upvotes: 0

Related Questions