PR c++/84455
* pt.c (tsubst_lambda_expr): If not nested, increment temporarily
function_depth to avoid GC during finish_lambda_function.
* g++.dg/cpp0x/lambda/lambda-ice26.C: New test.
From-SVN: r257838
+2018-02-20 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/84455
+ * pt.c (tsubst_lambda_expr): If not nested, increment temporarily
+ function_depth to avoid GC during finish_lambda_function.
+
2018-02-19 Jason Merrill <jason@redhat.com>
PR c++/84429 - ICE capturing VLA.
bool nested = cfun;
if (nested)
push_function_context ();
+ else
+ /* Still increment function_depth so that we don't GC in the
+ middle of an expression. */
+ ++function_depth;
local_specialization_stack s (lss_copy);
if (nested)
pop_function_context ();
+ else
+ --function_depth;
/* The capture list was built up in reverse order; fix that now. */
LAMBDA_EXPR_CAPTURE_LIST (r)
+2018-02-20 Jakub Jelinek <jakub@redhat.com>
+
+ PR c++/84455
+ * g++.dg/cpp0x/lambda/lambda-ice26.C: New test.
+
2018-02-19 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83344
--- /dev/null
+// PR c++/84455
+// { dg-do compile { target c++11 } }
+// { dg-options "--param ggc-min-heapsize=0" }
+
+#include "lambda-ice14.C"