<html>
<head>
<base href="https://llvm.org/bugs/" />
</head>
<body><table border="1" cellspacing="0" cellpadding="8">
<tr>
<th>Bug ID</th>
<td><a class="bz_bug_link
bz_status_NEW "
title="NEW --- - False-positive with CLANG_ANALYZER_NONNULL"
href="https://llvm.org/bugs/show_bug.cgi?id=26143">26143</a>
</td>
</tr>
<tr>
<th>Summary</th>
<td>False-positive with CLANG_ANALYZER_NONNULL
</td>
</tr>
<tr>
<th>Product</th>
<td>clang
</td>
</tr>
<tr>
<th>Version</th>
<td>unspecified
</td>
</tr>
<tr>
<th>Hardware</th>
<td>Macintosh
</td>
</tr>
<tr>
<th>OS</th>
<td>MacOS X
</td>
</tr>
<tr>
<th>Status</th>
<td>NEW
</td>
</tr>
<tr>
<th>Severity</th>
<td>normal
</td>
</tr>
<tr>
<th>Priority</th>
<td>P
</td>
</tr>
<tr>
<th>Component</th>
<td>Static Analyzer
</td>
</tr>
<tr>
<th>Assignee</th>
<td>kremenek@apple.com
</td>
</tr>
<tr>
<th>Reporter</th>
<td>coeur@gmx.fr
</td>
</tr>
<tr>
<th>CC</th>
<td>llvm-bugs@lists.llvm.org
</td>
</tr>
<tr>
<th>Classification</th>
<td>Unclassified
</td>
</tr></table>
<p>
<div>
<pre>Created <span class=""><a href="attachment.cgi?id=15632" name="attach_15632" title="warning with code">attachment 15632</a> <a href="attachment.cgi?id=15632&action=edit" title="warning with code">[details]</a></span>
warning with code
Summary:
CLANG_ANALYZER_NONNULL with Xcode 7.3 Beta 1 is giving false-positive warnings.
Steps to Reproduce:
static NSString *stringArray[] = {
@"<a href="http://example.net">http://example.net</a>"
};
+ (void)load {
[[[self alloc] init] useIndex:0];
}
- (void)useIndex:(int)index {
if (stringArray[index]) {
}
NSURL *url = [NSURL URLWithString:stringArray[index]];
NSLog(@"%@", url);
}
Expected Results:
No warning
Actual Results:
Warning "Null passed to a callee that requires a non-null argument"
Version:
Xcode Version 7.3 beta (7D111g)
OS X beta 10.11.4 (15E27e)</pre>
</div>
</p>
<hr>
<span>You are receiving this mail because:</span>
<ul>
<li>You are on the CC list for the bug.</li>
</ul>
</body>
</html>