This is an archive of the discontinued LLVM Phabricator instance.

[mlir] Update Attributes to use the new casting infra
ClosedPublic

Authored by rriddle on Sep 20 2022, 4:44 PM.

Details

Summary

This allows for using the llvm namespace cast methods instead
of the ones on the Attribute class. The Attribute class methods
are kept for now, but we'll want to remove these eventually
(with a really long lead time).

Diff Detail

Event Timeline

rriddle created this revision.Sep 20 2022, 4:44 PM
rriddle requested review of this revision.Sep 20 2022, 4:44 PM
bzcheeseman accepted this revision.Sep 20 2022, 5:50 PM

Thanks River :)

mlir/include/mlir/IR/Attributes.h
132

nit: dyn_cast_if_present? Or, add dyn_cast_if_present to Attribute?

This revision is now accepted and ready to land.Sep 20 2022, 5:50 PM
This revision was landed with ongoing or failed builds.Sep 20 2022, 11:46 PM
This revision was automatically updated to reflect the committed changes.
rriddle marked an inline comment as done.