summaryrefslogtreecommitdiff
path: root/gcc/cp/tree.c
diff options
context:
space:
mode:
authorJakub Jelinek <jakub@redhat.com>2019-10-30 12:58:03 +0100
committerJakub Jelinek <jakub@gcc.gnu.org>2019-10-30 12:58:03 +0100
commit42ceec0607f3235904c68d3ede1aaddb70eb06aa (patch)
tree313194a2ff9eb15d51d4ebe286f26d7fc0e7899b /gcc/cp/tree.c
parent96e05bf5aece312bb35736bf3b6bd59560b312a1 (diff)
downloadgcc-42ceec0607f3235904c68d3ede1aaddb70eb06aa.tar.gz
cp-tree.h (omp_declare_variant_finalize, [...]): Declare.
* cp-tree.h (omp_declare_variant_finalize, build_local_temp): Declare. * decl.c: Include omp-general.h. (declare_simd_adjust_this): Add forward declaration. (omp_declare_variant_finalize_one, omp_declare_variant_finalize): New function. (cp_finish_decl, finish_function): Call omp_declare_variant_finalize. * parser.c (cp_finish_omp_declare_variant): Adjust parsing of the variant id-expression and propagate enough information to omp_declare_variant_finalize_one in the attribute so that it can finalize it. * class.c (finish_struct): Call omp_declare_variant_finalize. * tree.c (build_local_temp): No longer static, remove forward declaration. * c-c++-common/gomp/declare-variant-2.c: Add a test with , before match clause. * c-c++-common/gomp/declare-variant-6.c: Expect diagnostics also from C++ FE and adjust regexp so that it handles C++ pretty printing of function names. * g++.dg/gomp/declare-variant-1.C: New test. * g++.dg/gomp/declare-variant-2.C: New test. * g++.dg/gomp/declare-variant-3.C: New test. * g++.dg/gomp/declare-variant-4.C: New test. * g++.dg/gomp/declare-variant-5.C: New test. From-SVN: r277613
Diffstat (limited to 'gcc/cp/tree.c')
-rw-r--r--gcc/cp/tree.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/gcc/cp/tree.c b/gcc/cp/tree.c
index 9d63736a394..ca4d3e2a48b 100644
--- a/gcc/cp/tree.c
+++ b/gcc/cp/tree.c
@@ -43,7 +43,6 @@ static hashval_t list_hash_pieces (tree, tree, tree);
static tree build_target_expr (tree, tree, tsubst_flags_t);
static tree count_trees_r (tree *, int *, void *);
static tree verify_stmt_tree_r (tree *, int *, void *);
-static tree build_local_temp (tree);
static tree handle_init_priority_attribute (tree *, tree, tree, int, bool *);
static tree handle_abi_tag_attribute (tree *, tree, tree, int, bool *);
@@ -525,7 +524,7 @@ build_target_expr (tree decl, tree value, tsubst_flags_t complain)
/* Return an undeclared local temporary of type TYPE for use in building a
TARGET_EXPR. */
-static tree
+tree
build_local_temp (tree type)
{
tree slot = build_decl (input_location,