[all-commits] [llvm/llvm-project] 6ee589: [CGObjCMac] Use castAs<> instead of getAs<> to avo...
Simon Pilgrim via All-commits
all-commits at lists.llvm.org
Sat Jan 8 08:19:18 PST 2022
Branch: refs/heads/main
Home: https://github.com/llvm/llvm-project
Commit: 6ee589e2f563a2a5c91f9aeb2762f092dd197e32
https://github.com/llvm/llvm-project/commit/6ee589e2f563a2a5c91f9aeb2762f092dd197e32
Author: Simon Pilgrim <llvm-dev at redking.me.uk>
Date: 2022-01-08 (Sat, 08 Jan 2022)
Changed paths:
M clang/lib/CodeGen/CGObjCMac.cpp
Log Message:
-----------
[CGObjCMac] Use castAs<> instead of getAs<> to avoid dereference of nullptr inside BuildRCBlockVarRecordLayout
This will assert the cast is correct instead of returning nullptr (UnionType is a subtype of RecordType so this should be clean).
More information about the All-commits
mailing list