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

Compilation failure when using the Visual Studio 2017 15.8 #248

Closed
dirkvdb opened this issue Aug 16, 2018 · 5 comments
Closed

Compilation failure when using the Visual Studio 2017 15.8 #248

dirkvdb opened this issue Aug 16, 2018 · 5 comments

Comments

@dirkvdb
Copy link
Contributor

dirkvdb commented Aug 16, 2018

The latest release of Visual Studio fails to compile sqlpp11
The problem seems to be in the alias provider:

------ Build started: Project: repro, Configuration: Debug x64 ------
geodb.cpp
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(99): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(99): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[2]'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(99): note: Reason: cannot convert from 'int' to 'const char [2]'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(99): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(99): note: see reference to alias template instantiation 'make_char_sequence<2,0>' being compiled
c:\build\date\include\date\date.h(150): note: see reference to class template instantiation 'std::chrono::duration<int,std::ratio<86400,1>>' being compiled
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(99): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2762: 'sqlpp::make_char_sequence_impl': invalid expression as a template argument for 's'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(58): note: see declaration of 'sqlpp::make_char_sequence_impl'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[2]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [2]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2973: 'sqlpp::make_char_sequence_impl<N,s,sqlpp::detail::index_sequence<i...>>': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(61): note: see declaration of 'sqlpp::make_char_sequence_impl<N,s,sqlpp::detail::index_sequence<i...>>'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(63): error C2109: subscript requires array or pointer type
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(100): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(101): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(102): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(103): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(104): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(105): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(106): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(107): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(108): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(109): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(110): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(111): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(112): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(113): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(114): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(115): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(116): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(117): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(118): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(119): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(120): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(121): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(122): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(123): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(124): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(125): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(125): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[5]'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(125): note: Reason: cannot convert from 'int' to 'const char [5]'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(125): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(125): note: see reference to alias template instantiation 'make_char_sequence<5,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(125): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[5]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [5]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(126): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(126): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[6]'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(126): note: Reason: cannot convert from 'int' to 'const char [6]'
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(126): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(126): note: see reference to alias template instantiation 'make_char_sequence<6,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\alias_provider.h(126): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[6]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [6]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\data_types\text\concat.h(47): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\data_types\text\concat.h(47): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[8]'
c:\build\sqlpp11\include\sqlpp11\data_types\text\concat.h(47): note: Reason: cannot convert from 'int' to 'const char [8]'
c:\build\sqlpp11\include\sqlpp11\data_types\text\concat.h(47): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\data_types\text\concat.h(47): note: see reference to alias template instantiation 'make_char_sequence<8,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\data_types\text\concat.h(47): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[8]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [8]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(20): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(20): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[7]'
c:\build\geoscheme.h(20): note: Reason: cannot convert from 'int' to 'const char [7]'
c:\build\geoscheme.h(20): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(20): note: see reference to alias template instantiation 'make_char_sequence<7,0>' being compiled
c:\build\geoscheme.h(20): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[7]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [7]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(36): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(52): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(73): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(73): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[31]'
c:\build\geoscheme.h(73): note: Reason: cannot convert from 'int' to 'const char [31]'
c:\build\geoscheme.h(73): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(73): note: see reference to alias template instantiation 'make_char_sequence<31,0>' being compiled
c:\build\geoscheme.h(73): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[31]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [31]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(90): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(106): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(122): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(143): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(143): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[36]'
c:\build\geoscheme.h(143): note: Reason: cannot convert from 'int' to 'const char [36]'
c:\build\geoscheme.h(143): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(143): note: see reference to alias template instantiation 'make_char_sequence<36,0>' being compiled
c:\build\geoscheme.h(143): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[36]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [36]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(160): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(176): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(192): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(213): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(213): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[22]'
c:\build\geoscheme.h(213): note: Reason: cannot convert from 'int' to 'const char [22]'
c:\build\geoscheme.h(213): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(213): note: see reference to alias template instantiation 'make_char_sequence<22,0>' being compiled
c:\build\geoscheme.h(213): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[22]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [22]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(230): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(246): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(262): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(283): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\geoscheme.h(283): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[27]'
c:\build\geoscheme.h(283): note: Reason: cannot convert from 'int' to 'const char [27]'
c:\build\geoscheme.h(283): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\geoscheme.h(283): note: see reference to alias template instantiation 'make_char_sequence<27,0>' being compiled
c:\build\geoscheme.h(283): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[27]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [27]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\aggregate_functions\count.h(41): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\aggregate_functions\min.h(40): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\aggregate_functions\max.h(40): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\aggregate_functions\avg.h(40): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\aggregate_functions\sum.h(40): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\trim.h(42): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\in.h(43): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\in.h(43): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[4]'
c:\build\sqlpp11\include\sqlpp11\in.h(43): note: Reason: cannot convert from 'int' to 'const char [4]'
c:\build\sqlpp11\include\sqlpp11\in.h(43): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\in.h(43): note: see reference to alias template instantiation 'make_char_sequence<4,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\in.h(43): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[4]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [4]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\not_in.h(43): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\is_null.h(42): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\is_null.h(42): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[9]'
c:\build\sqlpp11\include\sqlpp11\is_null.h(42): note: Reason: cannot convert from 'int' to 'const char [9]'
c:\build\sqlpp11\include\sqlpp11\is_null.h(42): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\is_null.h(42): note: see reference to alias template instantiation 'make_char_sequence<9,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\is_null.h(42): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[9]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [9]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\is_not_null.h(42): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\is_not_null.h(42): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[13]'
c:\build\sqlpp11\include\sqlpp11\is_not_null.h(42): note: Reason: cannot convert from 'int' to 'const char [13]'
c:\build\sqlpp11\include\sqlpp11\is_not_null.h(42): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\is_not_null.h(42): note: see reference to alias template instantiation 'make_char_sequence<13,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\is_not_null.h(42): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[13]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [13]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\exists.h(40): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(45): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(45): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[14]'
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(45): note: Reason: cannot convert from 'int' to 'const char [14]'
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(45): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(45): note: see reference to alias template instantiation 'make_char_sequence<14,0>' being compiled
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(45): error C2973: 'sqlpp::make_char_sequence': invalid template argument 'int'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[14]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: Reason: cannot convert from 'int' to 'const char [14]'
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: There are no conversions to array types, although there are conversions to references or pointers to arrays
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(62): error C2975: 'sqlpp::make_char_sequence': invalid template argument for 'Input', expected compile-time constant expression
c:\build\sqlpp11\include\sqlpp11\char_sequence.h(68): note: see declaration of 'sqlpp::make_char_sequence'
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(62): error C2440: 'specialization': cannot convert from 'int' to 'const char (&)[15]'
c:\build\sqlpp11\include\sqlpp11\verbatim_table.h(62): fatal error C1003: error count exceeds 100; stopping compilation
Done building project "repro.vcxproj" -- FAILED.
------ Skipped Build: Project: ALL_BUILD, Configuration: Debug x64 ------
Project not selected to build for this solution configuration 
========== Build: 0 succeeded, 1 failed, 1 up-to-date, 1 skipped ==========

Is this a compiler issue or something that needs to be fixed in the library?

@egorpugin
Copy link
Contributor

egorpugin commented Aug 16, 2018

https://developercommunity.visualstudio.com/content/problem/310933/clexe-vs158-c-regression-with-templates.html

One solution is in the ticket, but I use another one.

  1. Replace in include/sqlpp11/char_sequence.h all Input with s.
  2. Replace in include/sqlpp11/char_sequence.h (&s)[N] with *s.
s/Input/s/g
s/\(&s\)\[N\]/*s/g

@dirkvdb
Copy link
Contributor Author

dirkvdb commented Aug 16, 2018

Thanks for the info. It solves the compilation errors.
But as soon as you use prepared statements it results in internal compiler errors.

I reported this issue a few months ago: https://developercommunity.visualstudio.com/content/problem/256471/internal-compiler-error-in-vs157.html

It was supposed to be fixed in the 15.8 release...

SSE4 added a commit to bincrafters/conan-sqlpp11 that referenced this issue Nov 19, 2018
@juandent
Copy link

juandent commented Dec 24, 2018

The problem persists in VS v 15.9.4... any solution to it? --- it does seem to be very much concentrated in char_sequence.h

@RavenX8
Copy link

RavenX8 commented Dec 25, 2018

The only solution is to wait for the VS team to actually release the fix, which they have yet to do. as @dirkvdb posted the link to the issue report, it's still pending release and I have been asking on the thread when it will be release with no answer.

EDIT: The only other thing you could do is install VS v15.6 and use that instead of the latest

@rbock
Copy link
Owner

rbock commented Aug 20, 2019

My understanding (I have no Windows myself and rely on Appveyor) is that this is fixed.
Closing.
Please open a new ticket, if you are still experiencing compilation issues with current master and current Visual Studio.

@rbock rbock closed this as completed Aug 20, 2019
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

No branches or pull requests

5 participants