Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

about 7 years ago

Language

Compiler

Options

Author

anonymous

about 7 years ago

$
prog.cc: In function 'int main()':
prog.cc:14:32:   in constexpr expansion of 'nonnegative(-1)'
prog.cc:9:29: error: call to non-constexpr function 'nonnegative(int)::<lambda()>'
         []{ assert(false); }()), i;
         ~~~~~~~~~~~~~~~~~~~~^~
prog.cc:9:10: note: 'nonnegative(int)::<lambda()>' is not usable as a constexpr function because:
         []{ assert(false); }()), i;
          ^
In file included from /opt/wandbox/gcc-7.2.0/include/c++/7.2.0/cassert:44:0,
                 from prog.cc:2:
prog.cc:9:13: error: call to non-constexpr function 'void __assert_fail(const char*, const char*, unsigned int, const char*)'
         []{ assert(false); }()), i;
             ^
Exit Code:
1