[
https://issues.apache.org/jira/browse/THRIFT-632?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12791095#action_12791095
]
Dave Engberg commented on THRIFT-632:
-------------------------------------
Actually, it's not specific to i16 ... the patch (applied on 0.2.0) doesn't
permit any named constants for parameter defaults:
/tmp $ cat TestConst.thrift
const i32 CONST1 = 1
service TestConst {
void foo(1: i32 p1 = CONST1)
}
/tmp $ thrift -gen java TestConst.thrift
[FAILURE:/tmp/TestConst.thrift:3] type error: const "p1" was declared as i32
> Constants of enum types don't behave well
> -----------------------------------------
>
> Key: THRIFT-632
> URL: https://issues.apache.org/jira/browse/THRIFT-632
> Project: Thrift
> Issue Type: Bug
> Components: Compiler (Java)
> Affects Versions: 0.2
> Reporter: Bryan Duxbury
> Assignee: Bryan Duxbury
> Fix For: 0.3
>
> Attachments: thrift-632-v2.patch, thrift-632-v3.patch,
> thrift-632-v4.patch, thrift-632-v5.patch, thrift-632-v6.patch,
> thrift-632-v7.patch, thrift-632.patch
>
>
> It turns out that THRIFT-551 missed the case of constants defined of enum
> types.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.