Comments (18)
Hi Peter,
Last I checked, it did not compile, but that was a few months back. The last known problem is fixed to the extent that you can tell the compiler to ignore a faulty error message:
By adding #pragma warning(disable: 4579) at the top of your file, you might get around this constexpr issue. I suspect that there are more, but I don't have a windows machine to test.
I'd appreciate compiler output from the latest RTM.
Best,
Roland
from sqlpp11.
FYI - I've just tried compiling the sqlpp11 examples with Visual Studio 2015 Update 1(which was released on Monday) and they don't compile, raising the following errors:
-
In column.h (it doesn't like the partial specialisation of
serializer_t
forcolumn_t
, complaining thatcolumn_t<...>
has too few template arguments - it doesn't appear to like the use of variadic template parameters here) -
As far as I can tell, every definition of the form
static constexpr const char _literal[] = "concat_";
-
In table.h, compiling
table_t
, it's unable to specializemember_t
. Again, an issue with variadic template parameters, I think...
Oh - and compiling any of the source files causes an internal compiler error while compiling table.h.
However - this version of Visual Studio also ships with 'clang/C2', which is a hybrid clang/msvc with a clang 3.7 frontend and an MSVC code generator, and that compiles the sample code fine (apart from sample.cpp
, which I'm guessing is there to illustrate compile-time detection of incorrect use of the database?).
from sqlpp11.
Thanks for the report!
- Can you send me sample output?
- Sigh, now that error is a bit annoying.
- They planned to fix this in Update 1, see here: https://connect.microsoft.com/VisualStudio/feedback/details/1290476/static-constexpr-const-char-literal-delta-not-working-inside-struct
- Maybe you can add a comment there?
- Also, have you tried to use "#pragma warning(disable: 4579)" at the top of an example? Not exactly a reassuring technique, but it could help to isolate the remaining issues.
- Again, some sample output might help. If the pragma thing works, maybe you could just attach the compiler output to your reply?
Internal compiler error does not sound too promising, but who knows? One fine day...
The clang news is great!
sample.cpp has to fail to compile (although I have to admit that that is a result of negligence rather than intention).
Best regards,
Roland
from sqlpp11.
- Here you go - this is the compiler output for
examples/*.cpp
andtests/*.cpp
with warning 4579 disabled (at the command-line, with-wd4579
. - If you look at the Connect issue again, someone's already reported that it's only partially fixed in Update 1 :-(
from sqlpp11.
I saw the report at MS Connect this morning, I thought that was you :-)
Thanks for the compiler output. I'll try to figure something out (no promises though).
from sqlpp11.
Hello! I've found another bug while trying to build sqlpp with msvc https://connect.microsoft.com/VisualStudio/Feedback/Details/2086629
from sqlpp11.
@isliser Thanks. That looks so basic...
from sqlpp11.
Another bug in msvs compiler https://connect.microsoft.com/VisualStudio/Feedback/Details/2087449
from sqlpp11.
Nice, thanks again :-)
Replacing the variadic template arguments of the serializer with Table and ColumnSpec should fix the issue in column.h. Could you prepare a pull request for the develop branch (I currently have no way of testing with MSCV)?
from sqlpp11.
Sure I'll do it tomorrow.
from sqlpp11.
One more bug https://connect.microsoft.com/VisualStudio/feedback/details/2091069
from sqlpp11.
Yikes! That's awful...
from sqlpp11.
Could someone test this with Clang inside of VS 2015? http://blogs.msdn.com/b/vcblog/archive/2015/12/04/introducing-clang-with-microsoft-codegen-in-vs-2015-update-1.aspx
from sqlpp11.
@studoot tested clang in MSVC successfully about three weeks ago.
BTW: How can I convince cmake to use the clang frontend in MSVC? I would like to add an apveyor instance for that, too.
from sqlpp11.
Wow it works now!!! Thank you!
from sqlpp11.
Just finished the appveyor branch (everything compiles and all tests work).
Many thanks to @isliser for the great effort in finding most of the workarounds.
from sqlpp11.
The above is meant to say: sqlpp11 develop branch now compiles with MSVC 2015 Update 1.
Yay!
I'll add badges and create a new release, soon.
from sqlpp11.
Release 0.35 can be compiled using MSVC 2015 Update 1.
Closing this issue, thanking @isliser again for the effort to find the workarounds!
from sqlpp11.
Related Issues (20)
- mingw64, vcpkg, CMake, Project installation cannot find mariadb ? HOT 5
- sqlite connector: execute() silently ignores statements after the first one HOT 7
- how to use binary equal in where HOT 2
- Is there any opentracing support in sqlpp,like jaeger?Will it be supported in the future? HOT 1
- how to fix update exception? HOT 23
- How to retrieve the row count of a query result? HOT 6
- mysql does not seem to support the TIME type HOT 4
- Multiple table query error HOT 3
- Mysql prepared_statement.h missing _bind_time_of_day_parameter function HOT 3
- How do I get record with count of references from one to many? HOT 4
- Handling of `::sqlpp::tag::enforce_null_result_treatment` does not seem to be implemented, NULL documentation is erroneous HOT 11
- scripts/sqlite2cpp.py requires insert of nullable column HOT 6
- [Feedback Requested] Results returning optional, string_view, and span HOT 22
- [requesting assistance] Can the same parameter be used in multiple places in the same prepared statement? HOT 13
- [Need assistance] Common Table Expressions with update HOT 2
- Can't find how to use count(1) HOT 3
- head file include question HOT 3
- how to predict const struct sqlpp::result_row_t is or not NULL? HOT 3
- Supporting the BETWEEN operator? HOT 2
- SQLite: Is order by rowid possible? HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from sqlpp11.