The following code contains a fold expression, which afaiu is a c++17 feature:
template static bool variable_length_or(const T ... v) {
If you don't add something as -ansi -pedantic
, to impose a strict conformance to the standard, the compilers are free to adopt some extensions or, in this case, elements of the following standard.
-ansi -pedantic
are the options I add for g++ and clang++; other compilers can use different options, obviously.
-- EDIT --
As pointed by Barry (thanks!), -ansi
is no more useful and is enough -pedantic
.
As pointed by Passer By (thanks!), can be useful the use of -pedantic-error
to impose an error, and non only a warning, in case of not strictly conformance.