[
https://issues.apache.org/jira/browse/THRIFT-2315?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Jens Geyer updated THRIFT-2315:
-------------------------------
Fix Version/s: 1.0
> Defaults applied to service method arguments not working as expected
> --------------------------------------------------------------------
>
> Key: THRIFT-2315
> URL: https://issues.apache.org/jira/browse/THRIFT-2315
> Project: Thrift
> Issue Type: Bug
> Components: Compiler (General)
> Reporter: Jens Geyer
> Labels: default
> Fix For: 1.0
>
>
> h3. Problem
> {code}
> service Foobar {
> void Test( 1: i32 someValue = 42)
> }
> {code}
> The default of 42 is set into the Test_Args structure in most languages, but
> later overwritten because the generated calls do completely ignore these
> defaults. One has always to call:
> {code}
> client.Test( 1);
> client.Test( 42);
> client.Test( 4711);
> {code}
> instead of
> {code}
> client.Test( 1);
> client.Test( ); // 42 is the default
> client.Test( 4711);
> {code}
> h3. Applies to
> Most (all?) languages.
> h3. Todo
> Create a sub-task for your particular language and add the patch. :-)
--
This message was sent by Atlassian JIRA
(v6.1.5#6160)