[Reland][Runtimes] Merge 'compile_commands.json' files from runtimes build (#116303)
[llvm-project.git] / clang / test / CodeGenCXX / scoped-enums.cpp
blob218013a4c58b7ef08fc7517d9ec5ff61b07b7bd0
1 // RUN: %clang_cc1 -std=c++11 -triple %itanium_abi_triple -emit-llvm -o - %s | FileCheck %s
3 // PR9923
4 enum class Color { red, blue, green };
6 void f(Color);
7 void g() {
8 f(Color::red);
11 // See that struct is handled equally.
12 enum struct Colour { grey };
14 void h(Colour);
15 void i() {
16 h(Colour::grey);
19 enum struct PR17103 : int { a = -1, b = 1 };
20 bool cmp(PR17103 x, PR17103 y) { return x < y; }
22 // CHECK-LABEL: @_Z3cmp7PR17103S_(
23 // CHECK-NOT: }
24 // CHECK: icmp slt