Skip to content
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

Fix a compilation error with clang-cl (VS2022) #6489

Merged
merged 1 commit into from
Dec 12, 2022

Conversation

mrexodia
Copy link
Contributor

D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\util/vector.h(741,35): error: reference to 'vector' is ambiguous
    svector(SZ s, T const & elem):vector<T, false, SZ>(s, elem) {}
                                  ^
D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\util/vector.h(163,7): note: candidate found by name lookup is 'vector'
class vector {
      ^
c:\Program Files\Microsoft Visual Studio\2022\Community\VC\Tools\MSVC\14.34.31933\include\vector(494,7): note: candidate found by name lookup is 'std::vector'
class vector { // varying size array of values
      ^
In file included from D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\math\polynomial\upolynomial_factorization.cpp:27:
In file included from D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\math/polynomial/upolynomial_factorization_int.h:28:
In file included from D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\math/polynomial/upolynomial_factorization.h:27:
In file included from D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\math/polynomial/upolynomial.h:26:
In file included from D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\util/mpzzp.h:28:
In file included from D:\CodeBlocks\cxx-common-cmake\build\z3-prefix\src\z3\src\util/mpz.h:27:

I'm not exactly sure why this is erroring (the using is after the headers after all), but using namespace std; is bad practice regardless and this seems to be almost the only place that has it.

@nunoplopes nunoplopes merged commit e82c8e7 into Z3Prover:master Dec 12, 2022
hgvk94 pushed a commit to hgvk94/z3 that referenced this pull request Mar 27, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants