[clang] [LifetimeSafety] Detect expiry of loans to trivially destructed types (PR #168855)
Kashika Akhouri via cfe-commits
cfe-commits at lists.llvm.org
Fri Nov 21 01:23:13 PST 2025
================
@@ -696,10 +732,10 @@ void lifetimebound_return_reference() {
{
MyObj obj;
View temp_v = obj;
- const MyObj& ref = GetObject(temp_v);
- ptr = &ref;
- }
- (void)*ptr;
+ const MyObj& ref = GetObject(temp_v);
----------------
kashika0112 wrote:
Done
https://github.com/llvm/llvm-project/pull/168855
More information about the cfe-commits
mailing list