[PATCH] D76782: [CodeGenObjC] Fix a crash when attempting to copy a zero-sized bit-field in a non-trivial C struct

2020-04-06 Thread Erik Pilkington via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd33c7de8e11f: [CodeGenObjC] Fix a crash when attempting to copy a zero-sized bit-field in a… (authored by erik.pilkington). Herald added a project: clang. Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D76782: [CodeGenObjC] Fix a crash when attempting to copy a zero-sized bit-field in a non-trivial C struct

2020-04-06 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak accepted this revision. ahatanak added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76782/new/ https://reviews.llvm.org/D76782 ___ cfe-commits mailing list

[PATCH] D76782: [CodeGenObjC] Fix a crash when attempting to copy a zero-sized bit-field in a non-trivial C struct

2020-04-06 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington updated this revision to Diff 255385. erik.pilkington marked 3 inline comments as done. erik.pilkington added a comment. Don't bother including zero length bit-fields in the mangling of the copy/destroy helpers. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D76782/new/

[PATCH] D76782: [CodeGenObjC] Fix a crash when attempting to copy a zero-sized bit-field in a non-trivial C struct

2020-04-03 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. Thanks for fixing this! Comment at: clang/lib/CodeGen/CGNonTrivialStruct.cpp:545 LValue DstLV, SrcLV; if (FD) { + // No need to copy zero-length bit-fields. Can you add the same check to

[PATCH] D76782: [CodeGenObjC] Fix a crash when attempting to copy a zero-sized bit-field in a non-trivial C struct

2020-03-25 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. erik.pilkington added a reviewer: ahatanak. Herald added subscribers: ributzka, dexonsmith, jkorous. Zero sized bit-fields aren't included in the CGRecordLayout, so we shouldn't be calling EmitLValueForField for them. rdar://60695105