Sign in
android
/
platform
/
external
/
clang
/
73078642d3c32499ee573bd458af6d384fa7f6d8
/
.
/
test
/
Analysis
/
sizeofpointer.c
blob: aa85fc002aa14a515090ee791043ac41a5f4bdd9 [
file
] [
log
] [
blame
]
// RUN: %clang_cc1 -analyze -analyzer-checker=experimental.core.SizeofPtr -verify %s
struct
s
{
};
int
f
(
struct
s
*
p
)
{
return
sizeof
(
p
);
// expected-warning{{The code calls sizeof() on a pointer type. This can produce an unexpected result}}
}