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]

[C++0x] Default to C++0x mode on cxx0x-branch


The attached patch switches the default on the cxx0x-branch to C++0x
mode (with GNU extensions) rather than C++98 mode (with GNU
extensions). Switching the default means that (1) the compiler on this
branch always acts like a C++0x compiler, so (2) we get better testing
of C++0x features and semantics than we do on mainline.

Tested powerpc-apple-darwin8.9.0, and committed to cxx0x-branch.

The testsuite bits of these patches would be no-ops on mainline. I
suggest that we commit the testsuite changes to mainline, to identify
the places where semantics have changed from C++98 to C++0x. Okay?

- Doug

2007-04-24 Douglas Gregor <doug.gregor@gmail.com>

	* gcc/testsuite/g++.old-deja/g++.pt/defarg6.C: Only run with
	-std=gnu++98.
	* gcc/testsuite/g++.old-deja/g++.pt/ucnid-1.C: Ditto.
	* gcc/testsuite/g++.dg/cpp0x/variadic61.C: Ditto.
	* gcc/testsuite/g++.dg/cpp0x/warn_cxx0x.C: Ditto.
	* gcc/testsuite/g++.dg/cpp0x/variadic62.C: Ditto.
	* gcc/testsuite/g++.dg/template/meminit1.C: Ditto.
	* gcc/testsuite/g++.dg/template/operator7.C: Ditto.
	* gcc/testsuite/g++.dg/template/static15.C: Ditto.
	* gcc/testsuite/g++.dg/template/invalid1.C: Ditto.
	* gcc/testsuite/g++.dg/template/shift1.C: Ditto.
	* gcc/testsuite/g++.dg/template/error10.C: Ditto.
	* gcc/c-opts.c (c_common_init_options): Default to C++0x mode with
	GNU extensions.
	(c_common_handle_option): -ansi selects C++0x mode.
	(set_std_cxx98): Turn of FLAG_CPP0X.
	* gcc/c-common.c (flag_cpp0x): Default to 1 (C++0x mode on).

Attachment: cxx0x-default.patch
Description: Binary data


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