This is an archive of the discontinued LLVM Phabricator instance.

__has_trivial_copy should map to __is_trivially_copyable
ClosedPublic

Authored by zahen on Aug 11 2022, 3:03 PM.

Details

Summary

Found during clang 15 RC1 testing due to the new diagnostic added by @royjacobson since clang 14. Uncertain if this fix meets the bar to also be applied to the release branch.

If accepted, I'll need someone with commit access to submit on my behalf.

Diff Detail

Event Timeline

zahen created this revision.Aug 11 2022, 3:03 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 11 2022, 3:03 PM
zahen requested review of this revision.Aug 11 2022, 3:03 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 11 2022, 3:03 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
royjacobson accepted this revision.Aug 12 2022, 1:14 AM

LGTM, thank you for this patch!
I'll wait until Monday to let others have a look and then we can backport, I think it's useful and it's small enough to not be a problem.

Could you add name+email for the commit message?

This revision is now accepted and ready to land.Aug 12 2022, 1:14 AM
erichkeane accepted this revision.Aug 12 2022, 5:57 AM

Did @royjacobson 's patch make it to the 15.0 branch? If so, Roy: After this is committed, can you file to get this merged into the 15.x branch? This seems trivial enough (HAH!) of a fix that it is zero risk, and also keeps it from being all that embarassing here.

zahen added a comment.Aug 12 2022, 6:29 AM

Did @royjacobson 's patch make it to the 15.0 branch? If so, Roy: After this is committed, can you file to get this merged into the 15.x branch? This seems trivial enough (HAH!) of a fix that it is zero risk, and also keeps it from being all that embarrassing here.

Yes this is definitely in 15. During RC testing the diagnostic fired. The test build where I followed the suggestion and replaced has_trivial_copy with is_trivially_constructible didn't go very well.

zahen added a comment.Aug 12 2022, 6:29 AM

Could you add name+email for the commit message?

Zachary Henkel
zahen@microsoft.com
Github Username: ZacharyHenkel

This revision was automatically updated to reflect the committed changes.