I\'m looking for a customizable parser and/or lexer that can allow me to build a custom syntax checker in C#. Essentially the user will enter code a line of code (custom), and t
If what the user is entering is a line of code corresponding to traditional expressions, you can hand-code a recursive descent parser for this in a few hours max and be done with it.
If your input is a fragment of a complex language (e.g., you want to accept a line of C# code) you'll need a much strong parser and a parser generator is recommended.
However, you'll find that most parser generators do not offer you a good way to parse a piece of the language that you define, but you can hack you way around that by defining the root grammar rule to mention the nonterminals that correspond to the "lines" that you are willing to accept.