diff options
Diffstat (limited to 'gcc/cp/semantics.c')
-rw-r--r-- | gcc/cp/semantics.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gcc/cp/semantics.c b/gcc/cp/semantics.c index 183a78a..f64246d 100644 --- a/gcc/cp/semantics.c +++ b/gcc/cp/semantics.c @@ -8746,6 +8746,10 @@ begin_lambda_type (tree lambda) /* Designate it as a struct so that we can use aggregate initialization. */ CLASSTYPE_DECLARED_CLASS (type) = false; + /* Cross-reference the expression and the type. */ + LAMBDA_EXPR_CLOSURE (lambda) = type; + CLASSTYPE_LAMBDA_EXPR (type) = lambda; + /* Clear base types. */ xref_basetypes (type, /*bases=*/NULL_TREE); @@ -8754,10 +8758,6 @@ begin_lambda_type (tree lambda) if (type == error_mark_node) return error_mark_node; - /* Cross-reference the expression and the type. */ - LAMBDA_EXPR_CLOSURE (lambda) = type; - CLASSTYPE_LAMBDA_EXPR (type) = lambda; - return type; } |