[
https://issues.apache.org/jira/browse/DRILL-362?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13898088#comment-13898088
]
Timothy Chen commented on DRILL-362:
------------------------------------
The joy of enums in C++... I think it's fine but it does touches lots of places
so the refactor will probably require some testing to make sure things still
work, especially the generate code templates as they might not be able to get
refactored automatically by any IDE.
> Some protobuf enum values generates problematic C++/Windows code
> ----------------------------------------------------------------
>
> Key: DRILL-362
> URL: https://issues.apache.org/jira/browse/DRILL-362
> Project: Apache Drill
> Issue Type: Bug
> Reporter: George Chow
> Priority: Minor
>
> The enums DataMode and MinorType (in Types.proto) each contain a value
> (OPTIONAL and NULL respectively) that generate into problematic C++ code on
> Windows under Visual Studio.
> I propose to add a prefix to the enum values to uniquify them. For example:
> enum DataMode {
> DM_OPTIONAL = 0,
> DM_REQUIRED = 1,
> DM_REPEATED = 2
> }
> This is slightly ugly but is ultimately safe. Unfortunately, this change will
> trigger a lot of little changes throughout the codebase.
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)