llvm-for-llvmta/tools/clang/test/PCH/cli-macro.c

13 lines
417 B
C
Raw Normal View History

2022-04-25 13:02:35 +02:00
// Test this without pch.
// RUN: %clang_cc1 -Wunused-macros -Dunused=1 -fsyntax-only -verify %s
// Test with pch.
// RUN: %clang_cc1 -Wunused-macros -emit-pch -o %t %s
// RUN: %clang_cc1 -Wunused-macros -Dunused=1 -include-pch %t -fsyntax-only -verify %s
// expected-no-diagnostics
// -Dunused=1 is intentionally not set for the pch.
// There still should be no unused warning for a macro from the command line.