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

Ilya Maykov commented on THRIFT-911:
------------------------------------

I'll add some non-primitive constants to ThriftTest.thrift later this week, and 
write associated tests.

> (JavaScript compiler) Const structs, maps, sets, and lists generate a 
> trailing comma
> ------------------------------------------------------------------------------------
>
>                 Key: THRIFT-911
>                 URL: https://issues.apache.org/jira/browse/THRIFT-911
>             Project: Thrift
>          Issue Type: Bug
>          Components: JavaScript - Compiler
>    Affects Versions: 0.4
>            Reporter: Ilya Maykov
>         Attachments: THRIFT-911.patch
>
>
> The JavaScript compiler generates a trailing comma when compiling 
> non-primitive constants. For example, this thrift code:
> namespace js Toy
> const map<byte,string> TOY_MAP = {
>   1 : "ONE",
>   2 : "TWO",
>   3 : "THREE"
> }
> generates this JavaScript code:
> Toy.TOY_MAP = {1 : 'ONE',
> 2 : 'TWO',
> 3 : 'THREE',
> }
> According to Google's Closure compiler, this will breaks in some versions of 
> IE. We have a patch available and would like to submit it to trunk.
> The bug is present in at least 0.4.0 and in trunk as of revision r999487.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to