Are Elipses in case statements standard C/C++

That is the case range extension of the GNU C compiler, it is not standard C or C++.


That's an extension. Compiling your program with -pedantic gives:

example.cpp: In function ‘int main()’:
example.cpp:9: error: range expressions in switch statements are non-standard
example.cpp:12: error: range expressions in switch statements are non-standard

clang gives even better warnings:

example.cpp:9:12: warning: use of GNU case range extension [-Wgnu]
    case 0 ... 10:
           ^
example.cpp:12:13: warning: use of GNU case range extension [-Wgnu]
    case 11 ... 100:
            ^

Tags:

C++

C