This is an archive of the discontinued LLVM Phabricator instance.

[clang][dataflow] Fix initializing a reference field with an `InitListExpr`.
ClosedPublic

Authored by mboehme on Jul 11 2023, 7:05 AM.

Details

Summary

I added a test for this as the ongoing migration to strict handling of value categories (see https://discourse.llvm.org/t/70086) will change the code that handles this case. It turns out we already didn't handle this correctly, so I fixed the existing implementation.

Depends On D154961

Diff Detail

Event Timeline

mboehme created this revision.Jul 11 2023, 7:05 AM
Herald added a project: Restricted Project. · View Herald Transcript
mboehme requested review of this revision.Jul 11 2023, 7:05 AM
Herald added a project: Restricted Project. · View Herald TranscriptJul 11 2023, 7:05 AM
Herald added a subscriber: cfe-commits. · View Herald Transcript
mboehme edited the summary of this revision. (Show Details)Jul 11 2023, 7:05 AM
mboehme added reviewers: ymandel, xazax.hun.
xazax.hun accepted this revision.Jul 11 2023, 7:37 AM
xazax.hun added inline comments.
clang/lib/Analysis/FlowSensitive/Transfer.cpp
719–722
This revision is now accepted and ready to land.Jul 11 2023, 7:37 AM
mboehme retitled this revision from [clang][dataflow] Fix initializaing a reference field with an `InitListExpr`. to [clang][dataflow] Fix initializing a reference field with an `InitListExpr`..Jul 11 2023, 9:33 PM
mboehme updated this revision to Diff 539366.Jul 11 2023, 9:43 PM

Changes in response to review comments

mboehme marked an inline comment as done.Jul 11 2023, 9:45 PM
This revision was landed with ongoing or failed builds.Jul 11 2023, 9:53 PM
This revision was automatically updated to reflect the committed changes.