[ 
https://issues.apache.org/jira/browse/THRIFT-1780?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13531608#comment-13531608
 ] 

Jens Geyer commented on THRIFT-1780:
------------------------------------

+1
Looks good so far, I just modified one line slightly for the non-nullable case:

{code}
string postfix = (nullable_ && ttype->is_enum()) ? "?" : "";
{code}

The nullable_ check was missing, this caused enums to be nullable even when 
they shouldn't be. Mono test follows.
                
> Add option to generate nullable values
> --------------------------------------
>
>                 Key: THRIFT-1780
>                 URL: https://issues.apache.org/jira/browse/THRIFT-1780
>             Project: Thrift
>          Issue Type: New Feature
>          Components: C# - Compiler
>            Reporter: Carl Yeksigian
>            Priority: Minor
>         Attachments: 1780.patch, 1780-v2.patch, 1780-v3.patch, 1780-v4.patch
>
>
> There should be an option to generate nullable value types for C#.
> If a value is not set, then it would return as null rather than default 
> value. If a value is updated to null, then it would become unset.

--
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

Reply via email to