From patchwork Fri Oct 11 22:23:16 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Joseph Myers X-Patchwork-Id: 1175599 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (mailfrom) smtp.mailfrom=gcc.gnu.org (client-ip=209.132.180.131; helo=sourceware.org; envelope-from=gcc-patches-return-510817-incoming=patchwork.ozlabs.org@gcc.gnu.org; receiver=) Authentication-Results: ozlabs.org; dmarc=none (p=none dis=none) header.from=codesourcery.com Authentication-Results: ozlabs.org; dkim=pass (1024-bit key; unprotected) header.d=gcc.gnu.org header.i=@gcc.gnu.org header.b="sTE7b9fa"; dkim-atps=neutral Received: from sourceware.org (server1.sourceware.org [209.132.180.131]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 46qjCY31Qyz9sP4 for ; Sat, 12 Oct 2019 09:23:34 +1100 (AEDT) DomainKey-Signature: a=rsa-sha1; c=nofws; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; q=dns; s= default; b=rfpvxw3LBKpdgF68zWZvqOoNpoeQq1YwNgjdo8+1rHG+cYlop1eeM RCLD6wjKr7OBnMjC56Fh/dzO/xUqX89HSEiTc3gcvgzl5dWeXuiYg86rcnUSE+UL pSHfcdGK0IRjLr+RFVKez/ZGPIR4e6U3bsx6ep+lpmaybVBY7KPEgY= DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=gcc.gnu.org; h=list-id :list-unsubscribe:list-archive:list-post:list-help:sender:date :from:to:subject:message-id:mime-version:content-type; s= default; bh=m7trLQqp0gHhZw/tLPCzKwEUeBc=; b=sTE7b9fah9SV7o9lqukC jW+up4PZjHVKwKIV2FCLhdzK44VjkaGgdnk7QRqqVj7egQGTunlI8LAltdow2yxC MrjlwcXC+Abh0CypUUoy65ROUhcSLjs6IpLTrhMHxNVBZ9xRokvm9PfheNUFDlz9 whJ7h4v7GAEZhda/H0dsXHk= Received: (qmail 33365 invoked by alias); 11 Oct 2019 22:23:26 -0000 Mailing-List: contact gcc-patches-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Archive: List-Post: List-Help: Sender: gcc-patches-owner@gcc.gnu.org Delivered-To: mailing list gcc-patches@gcc.gnu.org Received: (qmail 33356 invoked by uid 89); 11 Oct 2019 22:23:26 -0000 Authentication-Results: sourceware.org; auth=none X-Spam-SWARE-Status: No, score=-7.3 required=5.0 tests=AWL, BAYES_00, GIT_PATCH_2, GIT_PATCH_3, KAM_ASCII_DIVIDERS autolearn=ham version=3.3.1 spammy=sk:interpr, c90, Mention, 69 X-HELO: esa3.mentor.iphmx.com Received: from esa3.mentor.iphmx.com (HELO esa3.mentor.iphmx.com) (68.232.137.180) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with ESMTP; Fri, 11 Oct 2019 22:23:24 +0000 IronPort-SDR: GF/fMUuXlR8r534qN9q6fENpWSoSGz9yxrqzxQAYN+XD0tI7G25r/lHNNRKoQDy4N4Gl98ckqL VfI/f48pkERjHJ9ejvRG+krUbIIfYUvWA7scVWS4x4ZVnqlxYTZeWmLu5aup23rNhiX/pXZCCQ dJMBUTKicNu9q+4zyu//Rr/4lY1tyHYAfMIXxpCjLZnH9gwU4/A54A2TFjQVrsVKmJPIv//zu6 EVVW8GVFUEKBvklQjlgq0wKjSkYNkmvCe5AjW+HE40rrjABB6MqZ9H41i0utrELIPqc+ZMT8bE EEI= Received: from orw-gwy-01-in.mentorg.com ([192.94.38.165]) by esa3.mentor.iphmx.com with ESMTP; 11 Oct 2019 14:23:21 -0800 IronPort-SDR: cMmpNcB8sonAmC04bYOi/A1eTVIjZjrPMgHxCRm+1ZcmubrsrUmwEHeN5DCevnZjjF9WPVbWPr 8gtDDIYXZX0WNF5EasgFWRywTXrjYCvJRJNa6Qu+q4fl9eLjsUkuhnkDzqaLWsX4gvadLTpgq6 0MFdRAUpzoIkr51Ey1WZLm4aWJpdO3Vs0fX7epseX7wa7tJi/xmuvOOkeezhL56Aywe1UoTdbv wdlnd88IA407vYV1d75x3zZTukDj9UypaCvlz5m+BQ4VrOYcoZD1whCpGWCL5J61cYVc7p0evr L48= Date: Fri, 11 Oct 2019 22:23:16 +0000 From: Joseph Myers To: Subject: Support decimal floating-point constants in C2x Message-ID: User-Agent: Alpine 2.21 (DEB 202 2017-01-01) MIME-Version: 1.0 ISO C2x adds decimal floating point as an optional standard feature. This patch accordingly makes GCC accept DFP constants (DF, DD, DL, df, dd, dl suffixes) in strict C2X mode, with a pedwarn-if-pedantic for older standards and a warning with -Wc11-c2x-compat even in C2x mode (which in turn requires -Wc11-c2x-compat to be newly passed through to libcpp). Bootstrapped with no regressions on x86_64-pc-linux-gnu. Applied to mainline. gcc/c-family: 2019-10-11 Joseph Myers * c.opt (Wc11-c2x-compat): Add CPP(cpp_warn_c11_c2x_compat) CppReason(CPP_W_C11_C2X_COMPAT). gcc/testsuite: 2019-10-11 Joseph Myers * gcc.dg/dfp/c11-constants-1.c, gcc.dg/dfp/c11-constants-2.c, gcc.dg/dfp/c2x-constants-1.c, gcc.dg/dfp/c2x-constants-2.c: New tests. * gcc.dg/dfp/constants-pedantic.c: Use -std=gnu17 explicitly. Update expected diagnostics. libcpp: 2019-10-11 Joseph Myers * include/cpplib.h (struct cpp_options): Add dfp_constants and cpp_warn_c11_c2x_compat. (enum cpp_warning_reason): Add CPP_W_C11_C2X_COMPAT. * init.c (struct lang_flags): Add dfp_constants. (lang_defaults): Set dfp_constants to 1 for GNUC2X and STDC2X and 0 for other languages. (cpp_set_lang): Set dfp_constants from language. (cpp_create_reader): Set cpp_warn_c11_c2x_compat to -1. * expr.c (interpret_float_suffix): Mention DFP constants as C2X in comment. (cpp_classify_number): Do not diagnose DFP constants for languages setting dfp_constants, unless cpp_warn_c11_c2x_compat. Index: gcc/c-family/c.opt =================================================================== --- gcc/c-family/c.opt (revision 276896) +++ gcc/c-family/c.opt (working copy) @@ -367,7 +367,7 @@ C ObjC C++ ObjC++ CPP(warn_builtin_macro_redefined Warn when a built-in preprocessor macro is undefined or redefined. Wc11-c2x-compat -C ObjC Var(warn_c11_c2x_compat) Init(-1) Warning +C ObjC CPP(cpp_warn_c11_c2x_compat) CppReason(CPP_W_C11_C2X_COMPAT) Var(warn_c11_c2x_compat) Init(-1) Warning Warn about features not present in ISO C11, but present in ISO C2X. Wc90-c99-compat Index: gcc/testsuite/gcc.dg/dfp/c11-constants-1.c =================================================================== --- gcc/testsuite/gcc.dg/dfp/c11-constants-1.c (nonexistent) +++ gcc/testsuite/gcc.dg/dfp/c11-constants-1.c (working copy) @@ -0,0 +1,13 @@ +/* Test that DFP constants are diagnosed in C11 mode: -pedantic. */ +/* { dg-do compile } */ +/* { dg-options "-std=c11 -pedantic" } */ + +int a = (int) 1.1DF; /* { dg-warning "C2X feature" } */ +int b = (int) 2.df; /* { dg-warning "C2X feature" } */ +int c = (int) .33DD; /* { dg-warning "C2X feature" } */ +int d = (int) 2e1dd; /* { dg-warning "C2X feature" } */ +int e = (int) .3e2DL; /* { dg-warning "C2X feature" } */ +int f = (int) 4.5e3dl; /* { dg-warning "C2X feature" } */ +int g = (int) 5.e0DF; /* { dg-warning "C2X feature" } */ +int h = (int) 1e+2df; /* { dg-warning "C2X feature" } */ +int i = (int) 1000e-3DL; /* { dg-warning "C2X feature" } */ Index: gcc/testsuite/gcc.dg/dfp/c11-constants-2.c =================================================================== --- gcc/testsuite/gcc.dg/dfp/c11-constants-2.c (nonexistent) +++ gcc/testsuite/gcc.dg/dfp/c11-constants-2.c (working copy) @@ -0,0 +1,13 @@ +/* Test that DFP constants are diagnosed in C11 mode: -pedantic-errors. */ +/* { dg-do compile } */ +/* { dg-options "-std=c11 -pedantic-errors" } */ + +int a = (int) 1.1DF; /* { dg-error "C2X feature" } */ +int b = (int) 2.df; /* { dg-error "C2X feature" } */ +int c = (int) .33DD; /* { dg-error "C2X feature" } */ +int d = (int) 2e1dd; /* { dg-error "C2X feature" } */ +int e = (int) .3e2DL; /* { dg-error "C2X feature" } */ +int f = (int) 4.5e3dl; /* { dg-error "C2X feature" } */ +int g = (int) 5.e0DF; /* { dg-error "C2X feature" } */ +int h = (int) 1e+2df; /* { dg-error "C2X feature" } */ +int i = (int) 1000e-3DL; /* { dg-error "C2X feature" } */ Index: gcc/testsuite/gcc.dg/dfp/c2x-constants-1.c =================================================================== --- gcc/testsuite/gcc.dg/dfp/c2x-constants-1.c (nonexistent) +++ gcc/testsuite/gcc.dg/dfp/c2x-constants-1.c (working copy) @@ -0,0 +1,13 @@ +/* Test that DFP constants are accepted in C2X mode. */ +/* { dg-do compile } */ +/* { dg-options "-std=c2x -pedantic-errors" } */ + +int a = (int) 1.1DF; +int b = (int) 2.df; +int c = (int) .33DD; +int d = (int) 2e1dd; +int e = (int) .3e2DL; +int f = (int) 4.5e3dl; +int g = (int) 5.e0DF; +int h = (int) 1e+2df; +int i = (int) 1000e-3DL; Index: gcc/testsuite/gcc.dg/dfp/c2x-constants-2.c =================================================================== --- gcc/testsuite/gcc.dg/dfp/c2x-constants-2.c (nonexistent) +++ gcc/testsuite/gcc.dg/dfp/c2x-constants-2.c (working copy) @@ -0,0 +1,13 @@ +/* Test that DFP constants are accepted in C2X mode: compat warnings. */ +/* { dg-do compile } */ +/* { dg-options "-std=c2x -Wc11-c2x-compat" } */ + +int a = (int) 1.1DF; /* { dg-warning "C2X feature" } */ +int b = (int) 2.df; /* { dg-warning "C2X feature" } */ +int c = (int) .33DD; /* { dg-warning "C2X feature" } */ +int d = (int) 2e1dd; /* { dg-warning "C2X feature" } */ +int e = (int) .3e2DL; /* { dg-warning "C2X feature" } */ +int f = (int) 4.5e3dl; /* { dg-warning "C2X feature" } */ +int g = (int) 5.e0DF; /* { dg-warning "C2X feature" } */ +int h = (int) 1e+2df; /* { dg-warning "C2X feature" } */ +int i = (int) 1000e-3DL; /* { dg-warning "C2X feature" } */ Index: gcc/testsuite/gcc.dg/dfp/constants-pedantic.c =================================================================== --- gcc/testsuite/gcc.dg/dfp/constants-pedantic.c (revision 276896) +++ gcc/testsuite/gcc.dg/dfp/constants-pedantic.c (working copy) @@ -1,5 +1,5 @@ /* { dg-do compile } */ -/* { dg-options "-pedantic" } */ +/* { dg-options "-std=gnu17 -pedantic" } */ /* N1150 6: Constants. C99 6.4.4.2: Floating constants. */ @@ -6,9 +6,9 @@ #include "dfp-dbg.h" -_Decimal32 a = 1.1df; /* { dg-warning "GCC extension|ISO C" } */ -_Decimal32 b = -.003DF; /* { dg-warning "GCC extension|ISO C" } */ -_Decimal64 c = 11e-1dl; /* { dg-warning "GCC extension|ISO C" } */ -_Decimal64 d = -.3DL; /* { dg-warning "GCC extension|ISO C" } */ -_Decimal128 e = 000.3e0dl; /* { dg-warning "GCC extension|ISO C" } */ -_Decimal128 f = 3000300030003e0DL; /* { dg-warning "GCC extension|ISO C" } */ +_Decimal32 a = 1.1df; /* { dg-warning "C2X feature|ISO C" } */ +_Decimal32 b = -.003DF; /* { dg-warning "C2X feature|ISO C" } */ +_Decimal64 c = 11e-1dl; /* { dg-warning "C2X feature|ISO C" } */ +_Decimal64 d = -.3DL; /* { dg-warning "C2X feature|ISO C" } */ +_Decimal128 e = 000.3e0dl; /* { dg-warning "C2X feature|ISO C" } */ +_Decimal128 f = 3000300030003e0DL; /* { dg-warning "C2X feature|ISO C" } */ Index: libcpp/expr.c =================================================================== --- libcpp/expr.c (revision 276896) +++ libcpp/expr.c (working copy) @@ -98,8 +98,8 @@ interpret_float_suffix (cpp_reader *pfile, const u flags = 0; f = d = l = w = q = i = fn = fnx = fn_bits = 0; - /* The following decimal float suffixes, from TR 24732:2009 and TS - 18661-2:2015, are supported: + /* The following decimal float suffixes, from TR 24732:2009, TS + 18661-2:2015 and C2X, are supported: df, DF - _Decimal32. dd, DD - _Decimal64. @@ -744,9 +744,16 @@ cpp_classify_number (cpp_reader *pfile, const cpp_ cpp_error_with_line (pfile, CPP_DL_PEDWARN, virtual_location, 0, "fixed-point constants are a GCC extension"); - if ((result & CPP_N_DFLOAT) && CPP_PEDANTIC (pfile)) - cpp_error_with_line (pfile, CPP_DL_PEDWARN, virtual_location, 0, - "decimal float constants are a GCC extension"); + if (result & CPP_N_DFLOAT) + { + if (CPP_PEDANTIC (pfile) && !CPP_OPTION (pfile, dfp_constants)) + cpp_error_with_line (pfile, CPP_DL_PEDWARN, virtual_location, 0, + "decimal float constants are a C2X feature"); + else if (CPP_OPTION (pfile, cpp_warn_c11_c2x_compat) > 0) + cpp_warning_with_line (pfile, CPP_W_C11_C2X_COMPAT, + virtual_location, 0, + "decimal float constants are a C2X feature"); + } result |= CPP_N_FLOATING; } Index: libcpp/include/cpplib.h =================================================================== --- libcpp/include/cpplib.h (revision 276896) +++ libcpp/include/cpplib.h (working copy) @@ -480,6 +480,9 @@ struct cpp_options /* Nonzero for C++ 2014 Standard digit separators. */ unsigned char digit_separators; + /* Nonzero for C2X decimal floating-point constants. */ + unsigned char dfp_constants; + /* Nonzero for C++2a __VA_OPT__ feature. */ unsigned char va_opt; @@ -508,6 +511,9 @@ struct cpp_options /* True if warn about differences between C90 and C99. */ signed char cpp_warn_c90_c99_compat; + /* True if warn about differences between C11 and C2X. */ + signed char cpp_warn_c11_c2x_compat; + /* True if warn about differences between C++98 and C++11. */ bool cpp_warn_cxx11_compat; @@ -607,6 +613,7 @@ enum cpp_warning_reason { CPP_W_DATE_TIME, CPP_W_PEDANTIC, CPP_W_C90_C99_COMPAT, + CPP_W_C11_C2X_COMPAT, CPP_W_CXX11_COMPAT, CPP_W_EXPANSION_TO_DEFINED }; Index: libcpp/init.c =================================================================== --- libcpp/init.c (revision 276896) +++ libcpp/init.c (working copy) @@ -93,32 +93,33 @@ struct lang_flags char utf8_char_literals; char va_opt; char scope; + char dfp_constants; }; static const struct lang_flags lang_defaults[] = -{ /* c99 c++ xnum xid c11 std digr ulit rlit udlit bincst digsep trig u8chlit vaopt scope*/ - /* GNUC89 */ { 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1 }, - /* GNUC99 */ { 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1 }, - /* GNUC11 */ { 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1 }, - /* GNUC17 */ { 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1 }, - /* GNUC2X */ { 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1 }, - /* STDC89 */ { 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0 }, - /* STDC94 */ { 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0 }, - /* STDC99 */ { 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0 }, - /* STDC11 */ { 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0 }, - /* STDC17 */ { 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0 }, - /* STDC2X */ { 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 1 }, - /* GNUCXX */ { 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1 }, - /* CXX98 */ { 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1 }, - /* GNUCXX11 */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1 }, - /* CXX11 */ { 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1 }, - /* GNUCXX14 */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1 }, - /* CXX14 */ { 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1 }, - /* GNUCXX17 */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1 }, - /* CXX17 */ { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1 }, - /* GNUCXX2A */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1 }, - /* CXX2A */ { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1 }, - /* ASM */ { 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } +{ /* c99 c++ xnum xid c11 std digr ulit rlit udlit bincst digsep trig u8chlit vaopt scope dfp */ + /* GNUC89 */ { 0, 0, 1, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0 }, + /* GNUC99 */ { 1, 0, 1, 1, 0, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 0 }, + /* GNUC11 */ { 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 0 }, + /* GNUC17 */ { 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 0 }, + /* GNUC2X */ { 1, 0, 1, 1, 1, 0, 1, 1, 1, 0, 0, 0, 0, 0, 1, 1, 1 }, + /* STDC89 */ { 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 }, + /* STDC94 */ { 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 }, + /* STDC99 */ { 1, 0, 1, 1, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0 }, + /* STDC11 */ { 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0 }, + /* STDC17 */ { 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 0, 0 }, + /* STDC2X */ { 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 0, 0, 1, 0, 0, 1, 1 }, + /* GNUCXX */ { 0, 1, 1, 1, 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0 }, + /* CXX98 */ { 0, 1, 0, 1, 0, 1, 1, 0, 0, 0, 0, 0, 1, 0, 0, 1, 0 }, + /* GNUCXX11 */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 0, 0, 0, 0, 1, 1, 0 }, + /* CXX11 */ { 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 0, 1, 0 }, + /* GNUCXX14 */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 0, 1, 1, 0 }, + /* CXX14 */ { 1, 1, 0, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0 }, + /* GNUCXX17 */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0 }, + /* CXX17 */ { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 0, 1, 0 }, + /* GNUCXX2A */ { 1, 1, 1, 1, 1, 0, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0 }, + /* CXX2A */ { 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 0, 1, 1, 1, 0 }, + /* ASM */ { 0, 0, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 } }; /* Sets internal flags correctly for a given language. */ @@ -145,6 +146,7 @@ cpp_set_lang (cpp_reader *pfile, enum c_lang lang) CPP_OPTION (pfile, utf8_char_literals) = l->utf8_char_literals; CPP_OPTION (pfile, va_opt) = l->va_opt; CPP_OPTION (pfile, scope) = l->scope; + CPP_OPTION (pfile, dfp_constants) = l->dfp_constants; } /* Initialize library global state. */ @@ -193,6 +195,7 @@ cpp_create_reader (enum c_lang lang, cpp_hash_tabl CPP_OPTION (pfile, warn_trigraphs) = 2; CPP_OPTION (pfile, warn_endif_labels) = 1; CPP_OPTION (pfile, cpp_warn_c90_c99_compat) = -1; + CPP_OPTION (pfile, cpp_warn_c11_c2x_compat) = -1; CPP_OPTION (pfile, cpp_warn_cxx11_compat) = 0; CPP_OPTION (pfile, cpp_warn_deprecated) = 1; CPP_OPTION (pfile, cpp_warn_long_long) = 0;