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

Visual Studio 2019 compilation error ('SQLite::Database::Database': delegating constructor calls itself) #317

Closed
chronoxor opened this issue Jan 6, 2021 · 5 comments
Assignees
Labels

Comments

@chronoxor
Copy link
Contributor

SQLiteCpp\include\SQLiteCpp/Database.h(182,17): error C7535: 'SQLite::Database::Database': delegating constructor calls itself
@chronoxor
Copy link
Contributor Author

chronoxor commented Jan 6, 2021

The problem related to std::filesystem::path which returns const wchar_t* c_str() const noexcept and confits with const char* apFilename

@chronoxor
Copy link
Contributor Author

Send a PR with a fix

@SRombauts
Copy link
Owner

Thanks for reporting!
I'll see what to do...

I'll also have to check why it is not catched by continuous integration (Travis CI and / or Github Actions)

@chronoxor
Copy link
Contributor Author

Filesystem is also issues with MinGW-w64:

[ 22%] Building CXX object modules/SQLiteCpp/CMakeFiles/SQLiteCpp.dir/src/Database.cpp.obj
In file included from C:/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/c++/filesystem:37,
                 from C:/projects/primetrader/modules/SQLiteCpp/include/SQLiteCpp/Database.h:16,
                 from C:/projects/primetrader/modules/SQLiteCpp/include/SQLiteCpp/Backup.h:14,
                 from C:\projects\primetrader\modules\SQLiteCpp\src\Backup.cpp:12:
C:/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/c++/bits/fs_path.h: In member function 'std::filesystem::__cxx11::path& std::filesystem::__cxx11::path::operator/=(const std::filesystem::__cxx11::path&)':
C:/mingw64/lib/gcc/x86_64-w64-mingw32/8.1.0/include/c++/bits/fs_path.h:237:47: error: no match for 'operator!=' (operand types are 'std::filesystem::__cxx11::path' and 'std::filesystem::__cxx11::path')
    || (__p.has_root_name() && __p.root_name() != root_name()))
                               ~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~

@Chronial
Copy link

Chronial commented Jan 8, 2021

@SRombauts The default cmake build does not build with c++17, so the problematic code is disabled via #ifdef: https://github.com/SRombauts/SQLiteCpp/blob/master/CMakeLists.txt#L11

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants