1*f4a2713aSLionel Sambuc // "System header" for testing that -Wunused-value is properly suppressed in 2*f4a2713aSLionel Sambuc // certain cases. 3*f4a2713aSLionel Sambuc 4*f4a2713aSLionel Sambuc #define POSSIBLY_BAD_MACRO(x) \ 5*f4a2713aSLionel Sambuc { int i = x; \ 6*f4a2713aSLionel Sambuc i; } 7*f4a2713aSLionel Sambuc 8*f4a2713aSLionel Sambuc #define STATEMENT_EXPR_MACRO(x) \ 9*f4a2713aSLionel Sambuc (__extension__ \ 10*f4a2713aSLionel Sambuc ({int i = x; \ 11*f4a2713aSLionel Sambuc i;})) 12*f4a2713aSLionel Sambuc 13*f4a2713aSLionel Sambuc #define COMMA_MACRO_1(x, y) \ 14*f4a2713aSLionel Sambuc {x, y;} 15*f4a2713aSLionel Sambuc 16*f4a2713aSLionel Sambuc #define COMMA_MACRO_2(x, y) \ 17*f4a2713aSLionel Sambuc if (x) { 1 == 2, y; } 18*f4a2713aSLionel Sambuc 19*f4a2713aSLionel Sambuc #define COMMA_MACRO_3(x, y) \ 20*f4a2713aSLionel Sambuc (x, y) 21*f4a2713aSLionel Sambuc 22*f4a2713aSLionel Sambuc #define COMMA_MACRO_4(x, y) \ 23*f4a2713aSLionel Sambuc ( 1 == 2, y ) 24