This is an archive of the discontinued LLVM Phabricator instance.

[AsmParser] Adopt emitWrongTokenError more, improving QoI
ClosedPublic

Authored by lattner on May 11 2022, 12:52 AM.

Details

Summary

This is a full audit of emitError calls, I took the opportunity
to remove extranous parens and fix a couple cases where we'd
generate multiple diagnostics for the same error.

Diff Detail

Event Timeline

lattner created this revision.May 11 2022, 12:52 AM
Herald added a reviewer: rriddle. · View Herald Transcript
Herald added a project: Restricted Project. · View Herald Transcript
lattner requested review of this revision.May 11 2022, 12:52 AM
lattner added a reviewer: bollu.
lattner added a subscriber: bollu.

Pair programmed with @bollu

bzcheeseman added inline comments.May 11 2022, 8:38 AM
mlir/lib/Parser/AffineParser.cpp
300

Does this error get emitted in parseElement now?

rriddle accepted this revision.May 11 2022, 9:03 AM
This revision is now accepted and ready to land.May 11 2022, 9:03 AM

Thx for the reviews!

mlir/lib/Parser/AffineParser.cpp
300

Yes, i always did, this was generating two diagnostics for the same line.

This revision was automatically updated to reflect the committed changes.