-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Some test files failed to build due to "error: 'namespace arg = boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol" #45
Comments
Thank you for your input. Much appreciated. Would you mind to clarify under what circumstances it fails to build... because 1) it builds on my machine (ubuntu); 2) it builds and runs in Boorst regression (https://www.boost.org/development/tests/develop/developer/convert.html). From what I understand the "arg" you reference is, in fact, in the std namspace, i.e. std::arg declared in ... which I do not see even included in the mentioned cpp files. SO, again, would you mind shedding some light on how the problem pops up? Thanks. |
Thanks for your quick response. I build the tests on gcc-8.1.0 & C++14. If it cannot be reproduced in your environment, it would be probably due to arg is not declared in your complex.h on the C++/toolchain version you are using. ../libs/convert/test/performance.cpp: At global scope: |
Indeed, I use g++-7.4.0 and it does not have "arg" defined in ccomplex.
I'll look into fixing it. Still, I am really curious why that does not fail
in regression tests.
https://www.boost.org/development/tests/develop/developer/convert.html
shows that all compiled on gcc- 8~c++11, gcc- 8~c++14, etc.
Any idea why that might be? Tnx.
…On Wed, May 29, 2019 at 12:28 PM BinCaoWR ***@***.***> wrote:
Thanks for your quick response. I build the tests on gcc-8.1.0 & C++14. If
it cannot be reproduced in your environment, it would be probably due to
arg is not declared in your complex.h on the C++/toolchain version you are
using.
Here is the info about how complex can be included in the boost cpp files.
../libs/convert/test/performance.cpp: At global scope:
../libs/convert/test/performance.cpp:31:38: error: 'namespace arg =
boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol
namespace arg = boost::cnv::parameter;
^
In file included from ccomplex:16,
from complex:5,
from boost_1_70_0/boost/type_traits/is_complex.hpp:12,
from boost_1_70_0/boost/type_traits.hpp:96,
from boost_1_70_0/boost/convert/detail/is_fun.hpp:11,
from boost_1_70_0/boost/convert.hpp:28,
from ../libs/convert/test/performance.cpp:13:
complex.h:664:20: note: previous declaration 'long double arg(_Lcomplex)'
inline long double arg(_Lcomplex _Left)
^~~
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#45?email_source=notifications&email_token=AANTAIDV2VOP2EPGEEPIHR3PXXS6DA5CNFSM4HQARZAKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGODWN7DNA#issuecomment-496759220>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AANTAIBAMRMEYBHO2Q6O5GTPXXS6DANCNFSM4HQARZAA>
.
|
I'm not sure why the boost regression can pass. Perhaps need to confirm if is_complex.hpp is included and how arg(the conditionals, etc) is defined in complex. |
I have no forgotten about the issue. Just recently upgraded to gcc-8.3. Will be trying to see why tat might be failing... because IMO it should not. :-) |
Can't reproduce. Closing. |
The following files failed to build:
../libs/convert/test/performance.cpp:31:38: error: 'namespace arg = boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol
../libs/convert/test/spirit_converter.cpp:22:38: error: 'namespace arg = boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol
../libs/convert/test/stream_converter.cpp:26:38: error: 'namespace arg = boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol
../libs/convert/test/printf_converter.cpp:19:38: error: 'namespace arg = boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol
../libs/convert/test/strtol_converter.cpp:166:38: error: 'namespace arg = boost::cnv::boost::cnv::parameter;' redeclared as different kind of symbol
According to http://www.cplusplus.com/reference/complex/arg/, arg should be declared in complex as below:
complex (1) | template T arg (const complex& x);
arithmetic type (2) | double arg (ArithmeticType x); // additional overloads
As a result, the arg declared in boost test files should be renamed.
The text was updated successfully, but these errors were encountered: