llvm-for-llvmta/tools/clang/test/Sema/enum-increment.c

14 lines
189 B
C
Raw Normal View History

2022-04-25 13:02:35 +02:00
// RUN: %clang_cc1 -fsyntax-only %s -verify
// expected-no-diagnostics
enum A { A1, A2, A3 };
typedef enum A A;
void test() {
A a;
a++;
a--;
++a;
--a;
a = a + 1;
a = a - 1;
}