[
https://issues.apache.org/jira/browse/THRIFT-1835?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jens Geyer updated THRIFT-1835:
-------------------------------
Attachment: (was:
THRIFT-1835_Compiler_should_fail_when_duplicate_field_names_are_present.patch)
> Compiler should fail when duplicate field names are present
> -----------------------------------------------------------
>
> Key: THRIFT-1835
> URL: https://issues.apache.org/jira/browse/THRIFT-1835
> Project: Thrift
> Issue Type: Bug
> Components: Compiler (General)
> Affects Versions: 0.9
> Reporter: Nicolas Trésegnie
> Attachments: Test Thrift-1835 duplicate fields.thrift
>
>
> Thrift accept structs with a duplicate field name if the IDs are different.
> However, the generated java code does not compile.
> {code}
> struct duplicate {
> 1: i32 field,
> 2: i32 field
> }
> {code}
> {code}
> private static final org.apache.thrift.protocol.TField FIELD_FIELD_DESC = ...
> private static final org.apache.thrift.protocol.TField FIELD_FIELD_DESC = ...
> {code}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira