diff options
author | Martin Sebor <msebor@redhat.com> | 2018-11-21 02:50:02 +0000 |
---|---|---|
committer | Martin Sebor <msebor@gcc.gnu.org> | 2018-11-20 19:50:02 -0700 |
commit | 98f08eb8939735c1e9cbc1ec5cadebe79e935c90 (patch) | |
tree | 9fb2084c7e170349abee1d8f950047936556b98a /gcc/fortran/options.c | |
parent | 48d1f31d1b7131e8f809ede8256e4f1eb6c5c3ae (diff) | |
download | gcc-98f08eb8939735c1e9cbc1ec5cadebe79e935c90.zip gcc-98f08eb8939735c1e9cbc1ec5cadebe79e935c90.tar.gz gcc-98f08eb8939735c1e9cbc1ec5cadebe79e935c90.tar.bz2 |
c-parser.c (c_parser_has_attribute_expression): New function.
gcc/c/ChangeLog:
* c-parser.c (c_parser_has_attribute_expression): New function.
(c_parser_attribute): New function.
(c_parser_attributes): Move code into c_parser_attribute.
(c_parser_unary_expression): Handle RID_HAS_ATTRIBUTE_EXPRESSION.
gcc/c-family/ChangeLog:
* c-attribs.c (type_for_vector_size): New function.
(type_valid_for_vector_size): Same.
(handle_vector_size_attribute): Move code to the functions above
and call them.
(validate_attribute, has_attribute): New functions.
* c-common.h (has_attribute): Declare.
(rid): Add RID_HAS_ATTRIBUTE_EXPRESSION.
* c-common.c (c_common_resword): Same.
gcc/cp/ChangeLog:
* cp-tree.h (cp_check_const_attributes): Declare.
* decl2.c (cp_check_const_attributes): Declare extern.
* parser.c (cp_parser_has_attribute_expression): New function.
(cp_parser_unary_expression): Handle RID_HAS_ATTRIBUTE_EXPRESSION.
(cp_parser_gnu_attribute_list): Add argument.
gcc/ChangeLog:
* doc/extend.texi (Other Builtins): Add __builtin_has_attribute.
gcc/testsuite/ChangeLog:
* c-c++-common/builtin-has-attribute-2.c: New test.
* c-c++-common/builtin-has-attribute-3.c: New test.
* c-c++-common/builtin-has-attribute-4.c: New test.
* c-c++-common/builtin-has-attribute.c: New test.
* gcc.dg/builtin-has-attribute.c: New test.
* gcc/testsuite/gcc.target/i386/builtin-has-attribute.c: New test.
From-SVN: r266335
Diffstat (limited to 'gcc/fortran/options.c')
0 files changed, 0 insertions, 0 deletions