Dechenjm / crack-language

Automatically exported from code.google.com/p/crack-language
Other
0 stars 0 forks source link

Enrich the code generated for an interpolated string #25

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
interpolates strings currently translate like this:
   cout `a$(b)c`; --> if (cout) { cout.format('a'); cout.format(b); cout.format('c') }

Make them more like this:

cout ? (cout.enter(); cout.format('a'); cout.format(b); cout.format('c');
        cout.leave()) : 0;

So in other words, provide enter() and leave() hooks, if the leave() hook 
returns non-void let it be used as the value of the expression.

Original issue reported on code.google.com by mind...@gmail.com on 12 Aug 2010 at 11:30

GoogleCodeExporter commented 9 years ago
Implemented correctly as of rev 966960b96c2c

Original comment by mind...@gmail.com on 17 Apr 2011 at 5:36