This is the mail archive of the gcc-patches@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

add cp_parser_nonclass_name


This patch adds the optimization discussed here:
http://gcc.gnu.org/ml/gcc-patches/2008-02/msg00460.html

Basically, factor-out the code to handle non-class names, so we don't
need to call cp_parser_class_name if we know that a class cannot
appear in our current context.

Bootstrapped and regression tested on x86_64-unknown-linux-gnu.

OK for 4.4?

2008-02-26  Manuel Lopez-Ibanez  <manu@gcc.gnu.org>

	* parser.c (cp_parser_nonclass_name): New.
	(cp_parser_pseudo_destructor_name): Use it instead of
	cp_parser_type_name.
	(cp_parser_type_name): Move code to cp_parser_nonclass_name.

Attachment: add-nonclass-name.diff
Description: Text document


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]