Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

about 5 years ago

Language

C++

Compiler

gcc 10.1.0

Options
Warnings
Boost 1.73.0
C++14
no pedantic

Author

anonymous

about 5 years ago

$ g++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.73.0/gcc-10.1.0/include -std=c++14
prog.cc: In function 'int main()':
prog.cc:11:17: error: type/value mismatch at argument 2 in template parameter list for 'template<class T, template<class> class C> struct Foo'
   11 |     Foo<int, Bar> test;
      |                 ^
prog.cc:11:17: note:   expected a template of type 'template<class> class C', got 'template<class ...> struct Bar'
prog.cc:12:10: error: request for member 'x' in 'test', which is of non-class type 'int'
   12 |     test.x = 5;
      |          ^
prog.cc:13:17: error: request for member 'x' in 'test', which is of non-class type 'int'
   13 |     return test.x;
      |                 ^
Exit Code:
1