antlr / stringtemplate4

StringTemplate 4
http://www.stringtemplate.org
Other
955 stars 231 forks source link

Equals fails if there's a field with name o #163

Closed fpompermaier closed 6 years ago

fpompermaier commented 8 years ago

I have a thrift structure with a field named o. In that case, the generated equals name the incoming object o hiding the field value.

Thus, the generated equals method should use this.fieldName instead of simply fieldName

sharwell commented 8 years ago

I think this bug might have been filed with the wrong project. StringTemplate 4 (this repository) is a template engine. Other projects often use StringTemplate for code generation, but the actual templates where code like fieldName or this.fieldName is emitted is part of those other projects.