The Cnt variable is adjusted (incremented) for simplification of
checking logic. The increment should not be stored in the state.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@174104
91177308-0d34-0410-b5e6-
96231b3b80d8
else
V = V ^ RefVal::NotOwned;
} else {
- V.setCount(Cnt - ACnt);
+ V.setCount(V.getCount() - ACnt);
V.setAutoreleaseCount(0);
}
return setRefBinding(state, Sym, V);
id contextObject = (id)contextInfo;
[contextObject release];
}
+
+- (id)copyAutoreleaseRadar13081402 {
+ id x = [[[NSString alloc] initWithUTF8String:"foo"] autorelease];
+ [x retain];
+ return x; // no warning
+}
+
@end
//===----------------------------------------------------------------------===//
// Test returning allocated memory in a struct.
}
+
// CHECK: <key>diagnostics</key>
// CHECK-NEXT: <array>
// CHECK-NEXT: <dict>