Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

over 4 years ago

Language

C++

Compiler

gcc 11.1.0

Options
Warnings
Optimization
Don't Use Boost
C++2a
-pedantic-errors

Author

anonymous

over 4 years ago

$ g++ prog.cc -Wall -Wextra -O2 -march=native -std=c++2a -pedantic-errors
prog.cc: In function 'int main()':
prog.cc:18:15: error: no matching function for call to 'frombulate(SmartPtr<int>&)'
   18 |     frombulate(spi);
      |     ~~~~~~~~~~^~~~~
prog.cc:14:6: note: candidate: 'template<class U> void frombulate(SmartPtr<const T>)'
   14 | void frombulate(SmartPtr<const U>) {}
      |      ^~~~~~~~~~
prog.cc:14:6: note:   template argument deduction/substitution failed:
prog.cc:18:15: note:   types 'const T' and 'int' have incompatible cv-qualifiers
   18 |     frombulate(spi);
      |     ~~~~~~~~~~^~~~~
Exit Code:
1