From: Jason Merrill Date: Tue, 17 Jan 1995 21:43:40 +0000 (+0000) Subject: (pedantic_non_lvalue): Check pedantic_lvalues instead of pedantic. X-Git-Url: https://git.libre-soc.org/?a=commitdiff_plain;h=e9866da310c2a1d3aefe79367553d91de16802e2;p=gcc.git (pedantic_non_lvalue): Check pedantic_lvalues instead of pedantic. From-SVN: r8765 --- diff --git a/gcc/fold-const.c b/gcc/fold-const.c index 9d40401ffa6..c17c1d70a5e 100644 --- a/gcc/fold-const.c +++ b/gcc/fold-const.c @@ -1562,6 +1562,11 @@ non_lvalue (x) return result; } +/* Nonzero means lvalues are limited to those valid in pedantic ANSI C. + Zero means allow extended lvalues. */ + +int pedantic_lvalues; + /* When pedantic, return an expr equal to X but certainly not valid as a pedantic lvalue. Otherwise, return X. */ @@ -1569,7 +1574,7 @@ tree pedantic_non_lvalue (x) tree x; { - if (pedantic) + if (pedantic_lvalues) return non_lvalue (x); else return x;