aboutsummaryrefslogtreecommitdiffstats
path: root/tests/query/highlights/cpp/enums-as-constants.cpp
blob: d6b93d5ec431026740bdd40151c72c2dd2ff6ea9 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
enum class Foo{
    a,
//  ^ @constant
    aa,
//  ^ @constant
    C,
//  ^ @constant
};

void foo(Foo f){
    switch ( f ) {
        case Foo::a:
         //  ^ @type
         //   ^ @module
         //       ^ @constant
            break;
        case Foo::aa:
         //        ^ @constant
            break;
        case Foo::C:
         //       ^ @constant
            break;
        default:
    }
}