This project has moved and is read-only. For the latest updates, please go here.

Intext macros

Nov 2, 2009 at 6:43 PM

Hi i want to create in text macros languge using irony. Like:

Some text $macros$ text lalala. 
$another macros$ etc.

So i have written

var sql = new NonTerminal("sql");
MakeStarRule(sql,  Empty|new FreeTextLiteral("text", "$") +"$"+ macros + "$");

Root = sql;u


Saying "1,1|Syntax error, expected: text, 



Nov 3, 2009 at 12:48 AM
Edited Nov 3, 2009 at 12:53 AM


I didn't quite understand what and how you try to do, but in general, Macro capabilities are not supported by Irony - yet, I hope to add it in the future. I doubt you can mock it using non-terminals. At least you would need a special custom terminal plus some supporting code in the core parser and scanner - which does not exist  yet.


Nov 3, 2009 at 7:12 AM
Edited Nov 3, 2009 at 7:26 AM


Thanks for the explanation.


PS. Great project!