aboutsummaryrefslogtreecommitdiff
path: root/libcpp/include/cpplib.h
diff options
context:
space:
mode:
authorIain Buclaw <ibuclaw@gdcproject.org>2022-09-24 16:23:43 +0200
committerIain Buclaw <ibuclaw@gdcproject.org>2022-09-24 16:23:43 +0200
commit13de60fb8e26a874dd58089286a0ea99a90972c8 (patch)
tree9460ec898d5cedf1ab0ac06073b358cc3b928648 /libcpp/include/cpplib.h
parent6da3cab7b0acf5dc363c85069bef716923ddf90c (diff)
parentad2aab5c816a6fd56b46210c0a4a4c6243da1de9 (diff)
downloadgcc-13de60fb8e26a874dd58089286a0ea99a90972c8.zip
gcc-13de60fb8e26a874dd58089286a0ea99a90972c8.tar.gz
gcc-13de60fb8e26a874dd58089286a0ea99a90972c8.tar.bz2
Merge remote-tracking branch 'mainline/master' into ibuclaw/targetrustm
Diffstat (limited to 'libcpp/include/cpplib.h')
-rw-r--r--libcpp/include/cpplib.h21
1 files changed, 19 insertions, 2 deletions
diff --git a/libcpp/include/cpplib.h b/libcpp/include/cpplib.h
index 810203d..2db1e9c 100644
--- a/libcpp/include/cpplib.h
+++ b/libcpp/include/cpplib.h
@@ -190,7 +190,7 @@ struct GTY(()) cpp_string {
#define NAMED_OP (1 << 4) /* C++ named operators. */
#define PREV_FALLTHROUGH (1 << 5) /* On a token preceeded by FALLTHROUGH
comment. */
-#define BOL (1 << 6) /* Token at beginning of line. */
+#define DECIMAL_INT (1 << 6) /* Decimal integer, set in c-lex.cc. */
#define PURE_ZERO (1 << 7) /* Single 0 digit, used by the C++ frontend,
set in c-lex.cc. */
#define SP_DIGRAPH (1 << 8) /* # or ## token was a digraph. */
@@ -199,6 +199,7 @@ struct GTY(()) cpp_string {
after a # operator. */
#define NO_EXPAND (1 << 10) /* Do not macro-expand this token. */
#define PRAGMA_OP (1 << 11) /* _Pragma token. */
+#define BOL (1 << 12) /* Token at beginning of line. */
/* Specify which field, if any, of the cpp_token union is used. */
@@ -525,6 +526,9 @@ struct cpp_options
/* Nonzero for C++23 delimited escape sequences. */
unsigned char delimited_escape_seqs;
+ /* Nonzero for 'true' and 'false' in #if expressions. */
+ unsigned char true_false;
+
/* Holds the name of the target (execution) character set. */
const char *narrow_charset;
@@ -560,6 +564,17 @@ struct cpp_options
cpp_bidirectional_level. */
unsigned char cpp_warn_bidirectional;
+ /* True if libcpp should warn about invalid UTF-8 characters in comments.
+ 2 if it should be a pedwarn. */
+ unsigned char cpp_warn_invalid_utf8;
+
+ /* True if libcpp should warn about invalid forms of delimited or named
+ escape sequences. */
+ bool cpp_warn_unicode;
+
+ /* True if -finput-charset= option has been used explicitly. */
+ bool cpp_input_charset_explicit;
+
/* Dependency generation. */
struct
{
@@ -666,7 +681,9 @@ enum cpp_warning_reason {
CPP_W_CXX11_COMPAT,
CPP_W_CXX20_COMPAT,
CPP_W_EXPANSION_TO_DEFINED,
- CPP_W_BIDIRECTIONAL
+ CPP_W_BIDIRECTIONAL,
+ CPP_W_INVALID_UTF8,
+ CPP_W_UNICODE
};
/* Callback for header lookup for HEADER, which is the name of a