Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

about 5 years ago

Language

C++

Compiler

gcc HEAD 10.0.1 20200407 (experimental)

Options
Warnings
Boost 1.72.0
C++2a(GNU)
no pedantic

Author

anonymous

about 5 years ago

Foo.hpp
Bar.hpp

$ g++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.72.0/gcc-head/include -std=gnu++2a
prog.cc:11:17: error: cannot declare a parameter with 'decltype(auto)'
   11 | void f3(HasSize decltype(auto)) {} // ok
      |                 ^~~~~~~~~~~~~~
prog.cc: In function 'int main()':
prog.cc:23:13: error: cannot convert 'std::string' {aka 'std::__cxx11::basic_string<char>'} to 'int'
   23 |     f3(std::string{});
      |             ^~~~~~~~
      |             |
      |             std::string {aka std::__cxx11::basic_string<char>}
prog.cc:11:9: note:   initializing argument 1 of 'void f3(int)'
   11 | void f3(HasSize decltype(auto)) {} // ok
      |         ^~~~~~~~~~~~~~~~~~~~~~
Exit Code:
1