ginac-1.8.8/cln-1.3.7/gcc-15.1.0 test failures
Hello *, I've compiled cln-1.3.7 and ginac-1.8.8 by gcc-15.1.0 on Gentoo linux (I'm the maintainer of the ginal package in this distro). Everything's fine. But when I run ginac tests, I get x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I../config -I./../ginac -I../ginac -DIN_GINAC -O2 -march=alderlake -mabm -mno-cldemote -mno-kl -mno-pconfig -mno-sgx -mno-widekl -mshstk --param=l1-cache-line-size=64 --param=l1-cache-size=32 --param=l2-cache-size=24576 -pipe -c -o exam_archive.o exam_archive.cpp exam_archive.cpp: In function ‘unsigned int numeric_complex_bug()’: exam_archive.cpp:104:17: error: reference to ‘complex’ is ambiguous 104 | complex(one, one), | ^~~~~~~ In file included from /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/tuple:40, from /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/functional:55, from ./../ginac/ptr.h:29, from ./../ginac/basic.h:27, from ./../ginac/ginac.h:28, from exam_archive.cpp:23: /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: note: candidates are: ‘template<class _Tp> class std::complex’ 105 | class complex; | ^~~~~~~ In file included from ./../ginac/numeric.h:30, from ./../ginac/ginac.h:40: /usr/include/cln/complex.h:22:19: note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | ^~~~~~~ exam_archive.cpp:105:17: error: reference to ‘complex’ is ambiguous 105 | complex(one, three_fp), | ^~~~~~~ /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: note: candidates are: ‘template<class _Tp> class std::complex’ 105 | class complex; | ^~~~~~~ /usr/include/cln/complex.h:22:19: note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | ^~~~~~~ exam_archive.cpp:106:17: error: reference to ‘complex’ is ambiguous 106 | complex(three_fp, one), | ^~~~~~~ /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: note: candidates are: ‘template<class _Tp> class std::complex’ 105 | class complex; | ^~~~~~~ /usr/include/cln/complex.h:22:19: note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | ^~~~~~~ exam_archive.cpp:107:17: error: reference to ‘complex’ is ambiguous 107 | complex(three_fp, three_fp) | ^~~~~~~ /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: note: candidates are: ‘template<class _Tp> class std::complex’ 105 | class complex; | ^~~~~~~ /usr/include/cln/complex.h:22:19: note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | ^~~~~~~ exam_archive.cpp:108:9: error: could not convert ‘{<expression error>, <expression error>, <expression error>, <expression error>}’ from ‘<brace-enclosed initializer list>’ to ‘std::vector<cln::cl_N>’ 108 | }; | ^ | | | <brace-enclosed initializer list> Any ideas? Andrey
Hello, Andrey! It seems the new version of GCC introduces the class complex, which was not there before. Now the compiler is confused which one to use: the previously existing cln::complex or std::complex. The attached simple patch shall resolve that. Best wishes, Vladimir -- Vladimir V. Kisil http://v-v-kisil.scienceontheweb.net Book: Geometry of Mobius Maps https://doi.org/10.1142/p835 Soft: Geometry of cycles http://moebinv.sourceforge.net/ Jupyter notebooks: https://github.com/vvkisil?tab=repositories
On Tue, 29 Apr 2025 19:27:40 +0700 (+07), "Andrey G. Grozin via GiNaC-devel" <ginac-devel@ginac.de> said:
AG> Hello *, AG> I've compiled cln-1.3.7 and ginac-1.8.8 by gcc-15.1.0 on Gentoo AG> linux (I'm the maintainer of the ginal package in this AG> distro). Everything's fine. But when I run ginac tests, I get AG> x86_64-pc-linux-gnu-g++ -DHAVE_CONFIG_H -I. -I../config AG> -I./../ginac -I../ginac -DIN_GINAC -O2 -march=alderlake -mabm AG> -mno-cldemote -mno-kl -mno-pconfig -mno-sgx -mno-widekl -mshstk AG> --param=l1-cache-line-size=64 --param=l1-cache-size=32 AG> --param=l2-cache-size=24576 -pipe -c -o exam_archive.o AG> exam_archive.cpp exam_archive.cpp: In function ‘unsigned int AG> numeric_complex_bug()’: exam_archive.cpp:104:17: error: AG> reference to ‘complex’ is ambiguous 104 | complex(one, one), | AG> ^~~~~~~ In file included from AG> /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/tuple:40, AG> from AG> /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/functional:55, AG> from ./../ginac/ptr.h:29, from ./../ginac/basic.h:27, from AG> ./../ginac/ginac.h:28, from exam_archive.cpp:23: AG> /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: AG> note: candidates are: ‘template<class _Tp> class std::complex’ AG> 105 | class complex; | ^~~~~~~ In file included from AG> ./../ginac/numeric.h:30, from ./../ginac/ginac.h:40: AG> /usr/include/cln/complex.h:22:19: note: ‘const cln::cl_N AG> cln::complex(const cl_R&, const cl_R&)’ 22 | extern const cl_N AG> complex (const cl_R& a, const cl_R& b); | ^~~~~~~ AG> exam_archive.cpp:105:17: error: reference to ‘complex’ is AG> ambiguous 105 | complex(one, three_fp), | ^~~~~~~ AG> /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: AG> note: candidates are: ‘template<class _Tp> class std::complex’ AG> 105 | class complex; | ^~~~~~~ /usr/include/cln/complex.h:22:19: AG> note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ AG> 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | AG> ^~~~~~~ exam_archive.cpp:106:17: error: reference to ‘complex’ AG> is ambiguous 106 | complex(three_fp, one), | ^~~~~~~ AG> /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: AG> note: candidates are: ‘template<class _Tp> class std::complex’ AG> 105 | class complex; | ^~~~~~~ /usr/include/cln/complex.h:22:19: AG> note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ AG> 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | AG> ^~~~~~~ exam_archive.cpp:107:17: error: reference to ‘complex’ AG> is ambiguous 107 | complex(three_fp, three_fp) | ^~~~~~~ AG> /usr/lib/gcc/x86_64-pc-linux-gnu/15/include/g++-v15/bits/stl_pair.h:105:11: AG> note: candidates are: ‘template<class _Tp> class std::complex’ AG> 105 | class complex; | ^~~~~~~ /usr/include/cln/complex.h:22:19: AG> note: ‘const cln::cl_N cln::complex(const cl_R&, const cl_R&)’ AG> 22 | extern const cl_N complex (const cl_R& a, const cl_R& b); | AG> ^~~~~~~ exam_archive.cpp:108:9: error: could not convert AG> ‘{<expression error>, <expression error>, <expression error>, AG> <expression error>}’ from ‘<brace-enclosed initializer list>’ to AG> ‘std::vector<cln::cl_N>’ 108 | }; | ^ | | | <brace-enclosed AG> initializer list> AG> Any ideas? AG> Andrey _______________________________________________ AG> GiNaC-devel mailing list GiNaC-devel@ginac.de AG> https://www.ginac.de/mailman/listinfo/ginac-devel
On Tue, 29 Apr 2025, Vladimir V. Kisil wrote:
It seems the new version of GCC introduces the class complex, which was not there before. Now the compiler is confused which one to use: the previously existing cln::complex or std::complex. The attached simple patch shall resolve that. Yes, this is what I thought. Thank you very much for the quick fix. Committed to Gentoo.
Andrey
participants (2)
-
Andrey G. Grozin
-
Vladimir V. Kisil