1 // RUN: %clang_cc1 -std=c++1z %s -verify 2 // RUN: %clang_cc1 -std=c++1z %s -verify -ftrigraphs -DENABLED_TRIGRAPHS=1 3 // RUN: %clang_cc1 -std=c++1z %s -verify -fno-trigraphs -DENABLED_TRIGRAPHS=0 4 5 #ifdef __MVS__ 6 #ifndef ENABLED_TRIGRAPHS 7 #define ENABLED_TRIGRAPHS 1 8 #endif 9 #endif 10 11 ??= define foo ; 12 13 static_assert("??="[0] == '#', ""); 14 15 // ??/ 16 error here; 17 18 // Note, there is intentionally trailing whitespace one line below. 19 // ??/ 20 error here; 21 22 #if !ENABLED_TRIGRAPHS 23 // expected-error@11 {{}} expected-warning@11 {{trigraph ignored}} 24 // expected-error@13 {{failed}} expected-warning@13 {{trigraph ignored}} 25 // expected-error@16 {{}} 26 // expected-error@20 {{}} 27 #else 28 // expected-warning@11 {{trigraph converted}} 29 // expected-warning@13 {{trigraph converted}} 30 // expected-warning@19 {{backslash and newline separated by space}} 31 #endif 32