r235414 - in /trunk/gcc: ChangeLog attribs.c at...

jason@gcc.gnu.org jason@gcc.gnu.org
Mon Apr 25 17:21:00 GMT 2016


Author: jason
Date: Mon Apr 25 17:21:49 2016
New Revision: 235414

URL: https://gcc.gnu.org/viewcvs?rev=235414&root=gcc&view=rev
Log:
	Implement C++17 [[maybe_unused]] attribute.

gcc/
	* attribs.c (register_scoped_attributes): Fix logic.
	* attribs.h: Declare register_scoped_attributes.
c-family/
	* c-common.c (handle_unused_attribute): Accept CONST_DECL.
	No longer static.
	* c-common.h: Declare it.
	* c-lex.c (c_common_has_attribute): Add maybe_unused.
cp/
	* tree.c (std_attribute_table): New.
	(init_tree): Register it.

Added:
    trunk/gcc/testsuite/g++.dg/cpp1z/maybe_unused1.C
Modified:
    trunk/gcc/ChangeLog
    trunk/gcc/attribs.c
    trunk/gcc/attribs.h
    trunk/gcc/c-family/ChangeLog
    trunk/gcc/c-family/c-common.c
    trunk/gcc/c-family/c-common.h
    trunk/gcc/c-family/c-lex.c
    trunk/gcc/cp/ChangeLog
    trunk/gcc/cp/tree.c
    trunk/gcc/testsuite/c-c++-common/attributes-enum-2.c
    trunk/gcc/testsuite/c-c++-common/cpp/pr63831-1.c
    trunk/gcc/testsuite/g++.dg/cpp1z/feat-cxx1z.C



More information about the Gcc-cvs mailing list