[ 
https://issues.apache.org/jira/browse/THRIFT-3640?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Jens Geyer updated THRIFT-3640:
-------------------------------
    Description: 
Try this IDL 
========

{code}
namespace csharp whatever

exception DataServiceException {
    1: optional string message;
}

service SomeDataService {
    string Version() throws (1:DataServiceException e1);
}
{code}

========

And run 0.9.3 compiler for csharp

{code}
thrift -r -gen csharp aaa.thrift

[ERROR:....../aaa.thrift:10] (last token was 'e1')
syntax error
[FAILURE:...../aaa.thrift:10] Parser error during include pass.
{code}


If you change the exception name from e1 to e, then it would compile no problem.



  was:
Try this IDL 
========

namespace csharp whatever

exception DataServiceException {
    1: optional string message;
}

service SomeDataService {
    string Version() throws (1:DataServiceException e1);
}

========

And run 0.9.3 compiler for csharp

thrift -r -gen csharp aaa.thrift

[ERROR:....../aaa.thrift:10] (last token was 'e1')
syntax error
[FAILURE:...../aaa.thrift:10] Parser error during include pass.


If you change the exception name from e1 to e, then it would compile no problem.




> Cannot define service exception with argument name having numerical values
> --------------------------------------------------------------------------
>
>                 Key: THRIFT-3640
>                 URL: https://issues.apache.org/jira/browse/THRIFT-3640
>             Project: Thrift
>          Issue Type: Bug
>          Components: Compiler (General)
>    Affects Versions: 0.9.3
>            Reporter: Paul
>            Priority: Minor
>
> Try this IDL 
> ========
> {code}
> namespace csharp whatever
> exception DataServiceException {
>     1: optional string message;
> }
> service SomeDataService {
>     string Version() throws (1:DataServiceException e1);
> }
> {code}
> ========
> And run 0.9.3 compiler for csharp
> {code}
> thrift -r -gen csharp aaa.thrift
> [ERROR:....../aaa.thrift:10] (last token was 'e1')
> syntax error
> [FAILURE:...../aaa.thrift:10] Parser error during include pass.
> {code}
> If you change the exception name from e1 to e, then it would compile no 
> problem.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to