This is an archive of the discontinued LLVM Phabricator instance.

[mlir] do not hardcode the name of the undefined function in the error message
ClosedPublic

Authored by ftynse on Jun 26 2020, 10:05 AM.

Details

Summary

The error message in the std.constant verifier for function-typed constants
had the name of the undefined function hardcoded to bar. Report the actual
name instead.

Diff Detail

Event Timeline

ftynse created this revision.Jun 26 2020, 10:05 AM
Herald added a project: Restricted Project. · View Herald TranscriptJun 26 2020, 10:05 AM
silvas accepted this revision.Jun 26 2020, 10:45 AM
silvas added a subscriber: silvas.

Thanks!

This revision is now accepted and ready to land.Jun 26 2020, 10:45 AM
stephenneuendorffer added inline comments.
mlir/lib/Dialect/StandardOps/IR/Ops.cpp
1124

nit: Generally, the first part of the message gets passed as an argument to emitOpError...

rriddle accepted this revision.Jun 26 2020, 12:09 PM
ftynse marked an inline comment as done.Jun 29 2020, 12:54 AM
ftynse added inline comments.
mlir/lib/Dialect/StandardOps/IR/Ops.cpp
1124

I see two occurrences of passing the first part as argument and fifteen of using repeated operator<< in this file, so I prefer (at least local) consistency.

This revision was automatically updated to reflect the committed changes.