Wandbox
SettingsLog
SettingsLog
Language
GitHubLogin
Ran/Viewed Log

Author

anonymous

almost 5 years ago

Language

C++

Compiler

gcc HEAD 12.0.0 20210721 (experimental)

Options
Warnings
Boost 1.73.0
C++2b(GNU)
no pedantic

Author

anonymous

almost 5 years ago

$ g++ prog.cc -Wall -Wextra -I/opt/wandbox/boost-1.73.0/gcc-head/include -std=gnu++2b
prog.cc: In instantiation of 'T identity(T, number) [with T = int; number = int]':
prog.cc:74:46:   required from here
prog.cc:63:49: warning: unused parameter 'i' [-Wunused-parameter]
   63 | template <typename T> auto identity(T x, number i) -> T
      |                                          ~~~~~~~^
prog.cc: In instantiation of 'number binarySearchKey(const std::vector<T>&, U, std::function<U(T, int)>, Comparer<U>, number) [with T = int; U = int; number = int; Comparer<U> = std::function<Comparison(int, int)>]':
prog.cc:60:33:   required from 'number binarySearch(const std::vector<T>&, T, std::function<U(T, int)>, Comparer<U>, number) [with T = int; U = int; number = int; Comparer<U> = std::function<Comparison(int, int)>]'
prog.cc:74:46:   required from here
prog.cc:36:16: warning: comparison of integer expressions of different signedness: 'int' and 'long unsigned int' [-Wsign-compare]
   36 |     while (low <= high)
      |            ~~~~^~~~~~~
-2
Exit Code:
0