aboutsummaryrefslogtreecommitdiff
path: root/libcpp/include/cpplib.h
diff options
context:
space:
mode:
authorIan Lance Taylor <iant@golang.org>2023-03-29 09:01:23 -0700
committerIan Lance Taylor <iant@golang.org>2023-03-29 09:01:23 -0700
commit6612f4f8cb9b0d5af18ec69ad04e56debc3e6ced (patch)
tree1deecdcfbf185c7044bc861d0ace51285c96cb62 /libcpp/include/cpplib.h
parent795cffe109e28b248a54b8ee583cbae48368c2a7 (diff)
parentaa8f4242efc99f24de73c59d53996f28db28c13f (diff)
downloadgcc-6612f4f8cb9b0d5af18ec69ad04e56debc3e6ced.zip
gcc-6612f4f8cb9b0d5af18ec69ad04e56debc3e6ced.tar.gz
gcc-6612f4f8cb9b0d5af18ec69ad04e56debc3e6ced.tar.bz2
Merge from trunk revision aa8f4242efc99f24de73c59d53996f28db28c13f.
Diffstat (limited to 'libcpp/include/cpplib.h')
-rw-r--r--libcpp/include/cpplib.h14
1 files changed, 12 insertions, 2 deletions
diff --git a/libcpp/include/cpplib.h b/libcpp/include/cpplib.h
index 2db1e9c..a6f0abd 100644
--- a/libcpp/include/cpplib.h
+++ b/libcpp/include/cpplib.h
@@ -1,5 +1,5 @@
/* Definitions for CPP library.
- Copyright (C) 1995-2022 Free Software Foundation, Inc.
+ Copyright (C) 1995-2023 Free Software Foundation, Inc.
Written by Per Bothner, 1994-95.
This program is free software; you can redistribute it and/or modify it
@@ -179,7 +179,11 @@ enum c_lang {CLK_GNUC89 = 0, CLK_GNUC99, CLK_GNUC11, CLK_GNUC17, CLK_GNUC2X,
/* Payload of a NUMBER, STRING, CHAR or COMMENT token. */
struct GTY(()) cpp_string {
unsigned int len;
- const unsigned char *text;
+
+ /* TEXT is always null terminated (terminator not included in len); but this
+ GTY markup arranges that PCH streaming works properly even if there is a
+ null byte in the middle of the string. */
+ const unsigned char * GTY((string_length ("1 + %h.len"))) text;
};
/* Flags for the cpp_token structure. */
@@ -496,6 +500,10 @@ struct cpp_options
in C11. */
unsigned char c11_identifiers;
+ /* Nonzero means extended identifiers allow the characters specified
+ by Unicode XID_Start and XID_Continue properties. */
+ unsigned char xid_identifiers;
+
/* Nonzero for C++ 2014 Standard binary constants. */
unsigned char binary_constants;
@@ -1275,6 +1283,7 @@ struct cpp_num
#define CPP_N_USERDEF 0x1000000 /* C++11 user-defined literal. */
#define CPP_N_SIZE_T 0x2000000 /* C++23 size_t literal. */
+#define CPP_N_BFLOAT16 0x4000000 /* std::bfloat16_t type. */
#define CPP_N_WIDTH_FLOATN_NX 0xF0000000 /* _FloatN / _FloatNx value
of N, divided by 16. */
@@ -1591,5 +1600,6 @@ int cpp_wcwidth (cppchar_t c);
bool cpp_input_conversion_is_trivial (const char *input_charset);
int cpp_check_utf8_bom (const char *data, size_t data_length);
+bool cpp_valid_utf8_p (const char *data, size_t num_bytes);
#endif /* ! LIBCPP_CPPLIB_H */