| how to extract STRING content? [message #780819] |
Thu, 19 January 2012 09:03  |
Mauro Condarelli Messages: 365 Registered: September 2009 |
Senior Member |
|
|
Hi,
the built-in terminal STRING, when used in grammar rules, returns the
literal string complete with escape sequence and bracketing quotes.
This is unsurprising.
I want to extract the supposed "value" of the string literal and I'm a
bit surprised I didn't find a standard way to do it.
If I understand correctly I should define a grammar rule like:
StringValue returns ecore::EString: value=STRING;
and then implement my own value converter.
Is this true?
I would be more than a bit surprised this very basic functionality isn't
included in the standard framework.
Am I missing something?
TiA
Mauro
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.01801 seconds