[antlr-interest] book, online doc discrepancy?
    Mathew Yeates 
    myeates at jpl.nasa.gov
       
    Mon Jan  7 10:58:31 PST 2008
    
    
  
Using StringTemplate the book says to do (using Python)
hello=stringtemplate.StringTemplate("Hello, <name>")
hello.setAttribute("name","World")
print hello.toString() #is an error :AttributeError: 'StringTemplate' 
object has no attribute 'toString'
if I do
print str(hello) I get Hello, <name>
But the online docs say to use $name$ and hello["name"] = "World"
and this works.
????
Mathew
    
    
More information about the antlr-interest
mailing list