nitra
nitra copied to clipboard
support vs 2017
is there a installer for vs 2017?
What do you mean? To build language projects, you need to build Nitra on a computer (https://github.com/rsdn/nitra/wiki/Nitra-Build-process).
ValdD2, thanks, I've followed the instructions and build the tools successfully. However, as a newbie, I don't know what to do next to get this integrated in the VS 2007? Is there any documentation or tutorial for beginners? thanks much.
Hello @jianyunli,
I would suggest you start with one of the samples and go from there.
Full Nitra parser has four major parts:
- Language definition: https://github.com/rsdn/Nitra-Mini-C/blob/master/Nitra-Mini-C/MiniC-Language.nitra
- Syntax parser: https://github.com/rsdn/Nitra-Mini-C/blob/master/Nitra-Mini-C/MiniC-syntax.nitra
- Language AST: https://github.com/rsdn/Nitra-Mini-C/blob/master/Nitra-Mini-C/MiniC-ast.nitra
- The mapping between syntax and AST: https://github.com/rsdn/Nitra-Mini-C/blob/master/Nitra-Mini-C/MiniC-Mapping.nitra
Also, you need to implement IProjectSupport interface on your top-most AST type: https://github.com/rsdn/Nitra-Mini-C/blob/master/Nitra-Mini-C/CompilationUnit.n
Hi @ionoy, thanks much, I'll get started. It says it can generate a parser for the IDE, actually that is what I need. Is it possible for my DSL, that I can put a squiggle for "incorrect" part , for example squiggle
var x = "123" - 1 // string minus integer does not make sense
Yes, of course. This is an example from Mini-C: https://github.com/rsdn/Nitra-Mini-C/blob/master/Nitra-Mini-C/MiniC-ast.nitra#L203