This is an archive of the discontinued LLVM Phabricator instance.

[flang] Better error recovery for missing THEN in IF construct
ClosedPublic

Authored by klausler on May 17 2023, 8:01 AM.

Details

Summary

Presented with "IF (...)" with no following tokens in the statement,
diagnose a missing "THEN" instead of complaining about all of the
possible action statement initial tokens that could have been there
for a non-construct IF statement.

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

Diff Detail

Event Timeline

klausler created this revision.May 17 2023, 8:01 AM
Herald added a project: Restricted Project. · View Herald Transcript
klausler requested review of this revision.May 17 2023, 8:01 AM
PeteSteinfeld accepted this revision.May 17 2023, 8:57 AM

All builds and test correctly and looks good.

This revision is now accepted and ready to land.May 17 2023, 8:57 AM