aboutsummaryrefslogtreecommitdiff
path: root/gcc/c-family/c-lex.c
diff options
context:
space:
mode:
authorNicola Pero <nicola.pero@meta-innovation.com>2010-09-30 08:23:37 +0000
committerNicola Pero <nicola@gcc.gnu.org>2010-09-30 08:23:37 +0000
commit49b91f055dbcf33c0230356a6ff41916c7cac917 (patch)
treefebeddb29ba321d8891cab7a7b66a19df3e27ea9 /gcc/c-family/c-lex.c
parent10ad386ac38c8c9de3e7eb4fcdfaf597c8e1d591 (diff)
downloadgcc-49b91f055dbcf33c0230356a6ff41916c7cac917.zip
gcc-49b91f055dbcf33c0230356a6ff41916c7cac917.tar.gz
gcc-49b91f055dbcf33c0230356a6ff41916c7cac917.tar.bz2
In gcc/c-family/: 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com>
In gcc/c-family/: 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com> * c-lex.c (c_lex_with_flags): Updated comments for CPP_AT_NAME Objective-C/Objective-C++ keywords. In gcc/cp/: 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com> * parser.c (cp_lexer_get_preprocessor_token): Tidied up comments and indentation when finding an Objective-C++ CPP_AT_NAME token. In gcc/: 2010-09-30 Nicola Pero <nicola.pero@meta-innovation.com> * c-parser.c (c_lex_one_token): When finding a CPP_AT_NAME Objective-C token, map RID_CLASS to RID_AT_CLASS and similar. (c_parser_external_declaration): Use RID_AT_CLASS instead of RID_CLASS. (c_parser_objc_class_declaration): Same change. (c_parser_objc_try_catch_statement): Use RID_AT_TRY instead of RID_TRY and RID_AT_CATCH instead of RID_CATCH. (c_parser_objc_class_instance_variables): Use RID_AT_PRIVATE instead of RID_PRIVATE, RID_AT_PROTECTED instead of RID_PROTECTED and RID_AT_PUBLIC instead of RID_PUBLIC. (c_parser_statement_after_labels): Use RID_AT_TRY instead of RID_TRY and RID_AT_CATCH instead of RID_CATCH. From-SVN: r164744
Diffstat (limited to 'gcc/c-family/c-lex.c')
-rw-r--r--gcc/c-family/c-lex.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/gcc/c-family/c-lex.c b/gcc/c-family/c-lex.c
index 8c65b8b..851449f 100644
--- a/gcc/c-family/c-lex.c
+++ b/gcc/c-family/c-lex.c
@@ -370,6 +370,12 @@ c_lex_with_flags (tree *value, location_t *loc, unsigned char *cpp_flags,
|| OBJC_IS_CXX_KEYWORD (C_RID_CODE (*value)))
{
type = CPP_AT_NAME;
+ /* Note the complication: if we found an OBJC_CXX
+ keyword, for example, 'class', we will be
+ returning a token of type CPP_AT_NAME and rid
+ code RID_CLASS (not RID_AT_CLASS). The language
+ parser needs to convert that to RID_AT_CLASS.
+ */
break;
}
/* FALLTHROUGH */