Commit 1f3c1cba authored by dingfei's avatar dingfei
Browse files

[Parser][ObjC] Fix crash on nested top-level block with better recovery path

Delay consuming tokens until we are certain that the next token is not top
level block. Otherwise we bail out as if we saw an @end for better diagnostic
and recovery.

Fixes https://github.com/llvm/llvm-project/issues/64065.

Reviewed By: rjmccall

Differential Revision: https://reviews.llvm.org/D156277.
parent c988e78f
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment