aboutsummaryrefslogtreecommitdiff
path: root/clang/test/Analysis/nullability.m
blob: 216ceffd25e619231957e2f8f1776a23aa886f1a (plain)
1
2
3
4
5
6
7
8
9
10
11
12
// RUN: %clang_analyze_cc1 -analyzer-checker core,nullability -w -verify %s

// expected-no-diagnostics

id _Nonnull conjure_nonnull(void);
void use_nullable(_Nullable id x);

id _Nonnull foo(void) {
  void *j = conjure_nonnull();
  use_nullable(j);
  return j; // no-warning
}