diff options
Diffstat (limited to 'gcc/cp/semantics.c')
-rw-r--r-- | gcc/cp/semantics.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index 7f861fd..107d39d 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -5083,7 +5083,7 @@ handle_omp_array_sections_1 (tree c, tree t, vec<tree> &types, { if (length == NULL_TREE) { - if (DECL_ARRAY_PARAMETER_P (ret)) + if (TREE_CODE (ret) == PARM_DECL && DECL_ARRAY_PARAMETER_P (ret)) error_at (OMP_CLAUSE_LOCATION (c), "for array function parameter length expression " "must be specified"); |