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

Nate Rosenblum updated THRIFT-1458:
-----------------------------------

    Attachment: 0001-Use-compatibility-c-namespace-in-generated-code.patch

The attached patch produces generated cpp code that will compile cleanly with 
{{-std=c++11}} and {{-stdlib=libc++}}. As discussed in THRIFT-1753
                
> use the C++ standard (c++0x or later c++11) to improve code quality and cross 
> platform capability
> -------------------------------------------------------------------------------------------------
>
>                 Key: THRIFT-1458
>                 URL: https://issues.apache.org/jira/browse/THRIFT-1458
>             Project: Thrift
>          Issue Type: Improvement
>          Components: C++ - Compiler, C++ - Library
>         Environment: gcc, llvm, visualstudio
>            Reporter: Roger Meier
>            Assignee: Roger Meier
>         Attachments: 
> 0001-Use-compatibility-c-namespace-in-generated-code.patch
>
>
> The goal is improvment of code quality and cross platform capability.
> I did several test on Debian Squeeze with default packages of gcc(4.4.5) and 
> clang(2.7)
> *Thrift Compiler only*
> sh bootstrap.sh ; ./configure --without-cpp --without-csharp --without-java  
> --without-erlang --without-python  --without-perl --without-php  
> --without-php_extension  --without-ruby --without-haskell 
> CXX=g++
> => ok
> CXX=g++ CXXFLAGS='-std=c++0x'
> => ok
> CXX=clang++
> => ok
> CXX=clang++ CXXFLAGS='-std=c++0x'
> => fail
> *Thrift C++ Library*
> sh bootstrap.sh ; ./configure --without-csharp --without-java  
> --without-erlang --without-python  --without-perl --without-php  
> --without-php_extension  --without-ruby --without-haskell 
> CXX=clang++
> => fail
> CXX=clang++ CXXFLAGS='-std=c++0x'
> => fail
> CXX=g++
> => ok
> CXX=g++ CXXFLAGS='-std=c++0x'
> => ok (since THRIFT-1459)
> further info on supported features
>  * http://gcc.gnu.org/projects/cxx0x.html
>  * http://clang.llvm.org/cxx_status.html
>  * 
> http://blogs.msdn.com/b/vcblog/archive/2010/04/06/c-0x-core-language-features-in-vc10-the-table.aspx

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