asutton/clang

Injected statements are not added to compound-statement bodies

Closed this issue · 1 comments

Which causes assertions in codegen. For example:

int main() {
  constexpr { -> { int n = 0; } }
  ++n; // crash!
}

We need to return injected statements back to the point at which a compound-statement parses the declaration-statement containing the constexpr declaration.

Partially fixed in 805cf0b. As noted, I expect this to re-open as we find new contexts to inject statements.