aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-family/c-lex.c
diff options
context:
space:
mode:
Diffstat (limited to 'gcc/c-family/c-lex.c')
-rw-r--r--gcc/c-family/c-lex.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/gcc/c-family/c-lex.c b/gcc/c-family/c-lex.c
index e3c602f..fb05b5f 100644
--- a/gcc/c-family/c-lex.c
+++ b/gcc/c-family/c-lex.c
@@ -353,13 +353,14 @@ c_common_has_attribute (cpp_reader *pfile)
else if (is_attribute_p ("deprecated", attr_name))
result = 201309;
else if (is_attribute_p ("maybe_unused", attr_name)
- || is_attribute_p ("nodiscard", attr_name)
|| is_attribute_p ("fallthrough", attr_name))
result = 201603;
else if (is_attribute_p ("no_unique_address", attr_name)
|| is_attribute_p ("likely", attr_name)
|| is_attribute_p ("unlikely", attr_name))
result = 201803;
+ else if (is_attribute_p ("nodiscard", attr_name))
+ result = 201907;
if (result)
attr_name = NULL_TREE;
}