This is an archive of the discontinued LLVM Phabricator instance.

Fix UB passing nullptr to an EmptyProperties class when building OpAdaptor
ClosedPublic

Authored by mehdi_amini on May 5 2023, 3:14 PM.

Details

Summary

A new forwarding constructor is introduced on the adaptor to take directly
an OpaqueProperties object and do the nullptr checking and casting to avoid
the boilerplate at callsites.

Diff Detail

Event Timeline

mehdi_amini created this revision.May 5 2023, 3:14 PM
Herald added a project: Restricted Project. · View Herald TranscriptMay 5 2023, 3:14 PM
mehdi_amini requested review of this revision.May 5 2023, 3:14 PM
benvanik accepted this revision.May 5 2023, 3:21 PM
This revision is now accepted and ready to land.May 5 2023, 3:21 PM
rriddle accepted this revision.May 5 2023, 3:23 PM