decl.c (omp_declare_variant_finalize_one): Call declare_simd_adjust_this not just on the context...
* decl.c (omp_declare_variant_finalize_one): Call declare_simd_adjust_this not just on the context, but also on the variant-id expression for methods. Don't call cp_get_callee_fndecl_nofold, call cp_get_callee and only if it is safe cp_get_fndecl_from_callee. Don't try to print as %qD NULL in diagnostics. * pt.c (tsubst_attribute): Handle "omp declare variant base" attribute. (tsubst_function_decl): Call omp_declare_variant_finalize if there are any "omp declare variant base" attributes left. * g++.dg/gomp/declare-variant-7.C: New test. * g++.dg/gomp/declare-variant-8.C: New test. From-SVN: r277814
Showing
- gcc/cp/ChangeLog 14 additions, 1 deletiongcc/cp/ChangeLog
- gcc/cp/decl.c 17 additions, 4 deletionsgcc/cp/decl.c
- gcc/cp/pt.c 75 additions, 0 deletionsgcc/cp/pt.c
- gcc/testsuite/ChangeLog 5 additions, 0 deletionsgcc/testsuite/ChangeLog
- gcc/testsuite/g++.dg/gomp/declare-variant-7.C 75 additions, 0 deletionsgcc/testsuite/g++.dg/gomp/declare-variant-7.C
- gcc/testsuite/g++.dg/gomp/declare-variant-8.C 18 additions, 0 deletionsgcc/testsuite/g++.dg/gomp/declare-variant-8.C
Loading
Please register or sign in to comment