[stringtemplate-interest] global boolean

Terence Parr parrt at cs.usfca.edu
Thu Apr 21 10:39:54 PDT 2011


* Made STGroup.iterateAcrossValues an instance variable not static.
  That needed a change to convertAnythingIteratableToIterator, etc..
  to non-static.
* Removed STDump as unneeded; Use STViz.


ter
On Apr 11, 2011, at 8:59 AM, Sam Harwell wrote:

> I made it an instance variable from the start for just this reason. :)
> 
> Set it to true for the STGroup created in CodeGenerator (in the Tool).
> 
> Change the signature of convertAnythingIteratableToIterator to
> convertAnythingIteratableToIterator(InstanceScope, object). That will reveal
> a number of other methods that need the exact same.
> 
> Test the value with
> (scope.st.groupThatCreatedThisInstance.iterateAcrossValues). (I believe this
> is correct - for the C# port it's frame.Template.Group.IterateAcrossValues).
> 
> Sam
> 
> -----Original Message-----
> From: stringtemplate-interest-bounces at antlr.org
> [mailto:stringtemplate-interest-bounces at antlr.org] On Behalf Of Terence Parr
> Sent: Monday, April 11, 2011 10:19 AM
> To: stringtemplate-interest List
> Subject: [stringtemplate-interest] global boolean
> 
> ooops. the intro of STGroup.iterateAcrossValues to make maps iterate across
> values ala v3 not keys like v4 could be a problem if someone uses ANTLR's
> Tool object in their VM *and* ST v4.  ANTLR sets this for v3 compat but if,
> say, eclipse calls antlr but a plugin uses ST v4 "properly"...bang!
> 
> maybe put it on STGroup instances and force antlr to set it all over in
> code.  i guess that is better. grr...I was stupido this weekend.
> 
> Ter
> _______________________________________________
> stringtemplate-interest mailing list
> stringtemplate-interest at antlr.org
> http://www.antlr.org/mailman/listinfo/stringtemplate-interest
> 



More information about the stringtemplate-interest mailing list