Author
anonymous
almost 3 years ago
Language
C++
Compiler
gcc 12.1.0
Options
Warnings
Optimization
Boost 1.79.0
C++2a
-pedantic
Author
anonymous
almost 3 years ago
$ g++ prog.cc -Wall -Wextra -O2 -march=native -I/opt/wandbox/boost-1.79.0-gcc-12.1.0/include -std=c++2a -pedantic
In file included from prog.cc:3:
Header.h: In function 'std::optional<int> temp::noexcept_stoi(const T&, std::size_t*, int) [with T = std::__cxx11::basic_string<wchar_t>; std::size_t = long unsigned int]':
Header.h:13:91: warning: unused parameter 'str' [-Wunused-parameter]
13 | template<> inline std::optional<int> noexcept_stoi<std::wstring>( const std::wstring& str, std::size_t* pos, int base ){return 4;}
| ~~~~~~~~~~~~~~~~~~~~^~~
Header.h:13:109: warning: unused parameter 'pos' [-Wunused-parameter]
13 | template<> inline std::optional<int> noexcept_stoi<std::wstring>( const std::wstring& str, std::size_t* pos, int base ){return 4;}
| ~~~~~~~~~~~~~^~~
Header.h:13:118: warning: unused parameter 'base' [-Wunused-parameter]
13 | template<> inline std::optional<int> noexcept_stoi<std::wstring>( const std::wstring& str, std::size_t* pos, int base ){return 4;}
| ~~~~^~~~
Header.h: In function 'std::optional<int> temp::noexcept_stoi(const T&, std::size_t*, int) [with T = std::__cxx11::basic_string<char>; std::size_t = long unsigned int]':
Header.h:14:89: warning: unused parameter 'str' [-Wunused-parameter]
14 | template<> inline std::optional<int> noexcept_stoi<std::string>( const std::string& str, std::size_t* pos, int base ){return 4;}
| ~~~~~~~~~~~~~~~~~~~^~~
Header.h:14:107: warning: unused parameter 'pos' [-Wunused-parameter]
14 | template<> inline std::optional<int> noexcept_stoi<std::string>( const std::string& str, std::size_t* pos, int base ){return 4;}
| ~~~~~~~~~~~~~^~~
Header.h:14:116: warning: unused parameter 'base' [-Wunused-parameter]
14 | template<> inline std::optional<int> noexcept_stoi<std::string>( const std::string& str, std::size_t* pos, int base ){return 4;}
| ~~~~^~~~
prog.cc: In function 'int main()':
prog.cc:7:8: warning: variable 'result' set but not used [-Wunused-but-set-variable]
7 | auto result = temp::noexcept_stoi(input);
| ^~~~~~
Exit Code:
0