PTR
#define HASH(PTR) (((uintptr_t)(PTR) >> 3) & 127)
#define __validate_container_of(PTR, TYPE, FIELD) \
(0 * sizeof((PTR) - &((TYPE *)(((char *)(PTR)) - \
#define container_of(PTR, TYPE, FIELD) \
((TYPE *)(((char *)(PTR)) - offsetof(TYPE, FIELD)) \
+ __validate_container_of(PTR, TYPE, FIELD))
#define KMEM_CACHE_PROBE(ARRAY, INDEX, PTR, REQSIZE, ALLOCSIZE, FLAGS) \
#define KMEM_CACHE_PROBE(ARRAY, INDEX, PTR, REQSIZE, ALLOCSIZE, FLAGS) do \
(uintptr_t)(PTR), \
#define PPPOE_ADD_16(PTR, VAL) \
*(PTR)++ = (VAL) / 256; \
*(PTR)++ = (VAL) % 256
#define PPPOE_ADD_HEADER(PTR, CODE, SESS, LEN) \
*(PTR)++ = PPPOE_VERTYPE; \
*(PTR)++ = (CODE); \
PPPOE_ADD_16(PTR, SESS); \
PPPOE_ADD_16(PTR, LEN)
#define __validate_container_of(PTR, TYPE, FIELD) 0
#define __validate_const_container_of(PTR, TYPE, FIELD) 0
#define __validate_container_of(PTR, TYPE, FIELD) \
(0 * sizeof((PTR) - &((TYPE *)(((char *)(PTR)) - \
#define __validate_const_container_of(PTR, TYPE, FIELD) \
(0 * sizeof((PTR) - &((const TYPE *)(((const char *)(PTR)) - \
#define container_of(PTR, TYPE, FIELD) \
((TYPE *)(((char *)(PTR)) - offsetof(TYPE, FIELD)) \
+ __validate_container_of(PTR, TYPE, FIELD))
#define const_container_of(PTR, TYPE, FIELD) \
((const TYPE *)(((const char *)(PTR)) - offsetof(TYPE, FIELD)) \
+ __validate_const_container_of(PTR, TYPE, FIELD))
typeinfo("pointer", PTR, PTR, PTR_SIZE, 5, 'p'),
case PTR:
type_t *void_ptr = block_derive_type(gettyp(VOID), PTR);
dsym->s_type = tp = block_derive_type(tp, t = PTR);
type_t *tp = block_derive_type(stp, PTR);
else if (dsym->s_type->t_tspec == PTR
else if (dsym->s_type->t_tspec == PTR
sym->s_type = block_derive_type(subt, PTR);
sym->s_type = block_derive_type(sym->s_type, PTR);
return tp->t_tspec == PTR &&
} else if (t == PTR)
t == FUNC ? *tpp : (*tpp)->t_subt, PTR);
if (t == VOID && to != PTR) {
return t == PTR || is_uinteger(t) || (ui & bit(bits - 1)) == 0
tn->u.ops.left->tn_type->t_tspec == PTR &&
else if (ln->tn_type->t_tspec != PTR) {
lint_assert(tp->t_tspec == PTR);
tnode_t *cn = ln->tn_type->t_tspec == PTR
if (rn->tn_type->t_tspec == PTR && is_integer(ln->tn_type->t_tspec)) {
if (lt == PTR && rt != PTR) {
if (rt == PTR) {
lint_assert(lt == PTR);
return ((t == PTR && tn->tn_type->t_subt->t_tspec == VOID)
lint_assert(tp1->t_tspec == PTR);
lint_assert(tp2->t_tspec == PTR);
} else if (lt == PTR && is_integer(rt)) {
} else if (rt == PTR && is_integer(lt)) {
} else if (lt == PTR && is_null_pointer(rn))
else if (rt == PTR && is_null_pointer(ln))
else if (lt == PTR && ln->tn_type->t_subt->t_tspec == VOID)
else if (rt == PTR && rn->tn_type->t_subt->t_tspec == VOID)
if (nt == PTR && ot == PTR) {
if ((op == ADDASS || op == SUBASS) && lt == PTR) {
&& (op == ASSIGN || lt != PTR)
if (lt == PTR && ln->tn_type->t_subt->t_tspec != VOID
&& rt == PTR && rn->tn_type->t_subt->t_tspec == VOID
if (op == ARROW && tn->tn_type->t_tspec == PTR
if (!allow_c90 && tn->tn_type->t_tspec == PTR)
if (lt == PTR || (!allow_c90 && is_integer(lt)))
if (t != PTR) {
if ((lt == PTR && !is_integer(rt)) || (rt == PTR && !is_integer(lt))) {
if ((lt == PTR && rt != PTR && !is_integer(rt)) ||
(lt != PTR && rt == PTR)) {
if (lt == PTR && rt == PTR &&
if (lt == PTR && is_null_pointer(rn))
if (rt == PTR && is_null_pointer(ln))
lint_assert(ltp->t_tspec == PTR);
lint_assert(rtp->t_tspec == PTR);
if (lt == PTR && rt == PTR) {
if (lt != PTR && rt != PTR)
const char *lx = lt == PTR ? "pointer" : "integer";
const char *rx = rt == PTR ? "pointer" : "integer";
if (lt == PTR && is_null_pointer(rn))
if (rt == PTR && is_null_pointer(ln))
if ((lt == PTR && is_integer(rt)) || (is_integer(lt) && rt == PTR)) {
const char *lx = lt == PTR ? "pointer" : "integer";
const char *rx = rt == PTR ? "pointer" : "integer";
if (lt == PTR && rt == PTR) {
if (!(lt == PTR && rt == PTR && (lst == VOID || rst == VOID)))
return tp->t_tspec == PTR &&
return tp->t_tspec == PTR && tp->t_subt->t_const;
if (!(lt == PTR && rt == PTR && (lst == VOID || rst == VOID ||
if (!((lt == PTR && is_integer(rt)) || (is_integer(lt) && rt == PTR)))
const char *lx = lt == PTR ? "pointer" : "integer";
const char *rx = rt == PTR ? "pointer" : "integer";
if (!(lt == PTR && rt == PTR))
if ((lt = (ltp = ln->tn_type)->t_tspec) == PTR)
if ((rt = (rtp = rn->tn_type)->t_tspec) == PTR)
if (lt == PTR && is_null_pointer(rn)) {
if ((lt == PTR && !is_integer(rt)) || rt == PTR) {
((ln->tn_type->t_is_enum && rn->tn_type->t_tspec == PTR) ||
(rn->tn_type->t_is_enum && ln->tn_type->t_tspec == PTR))) {
if (portable_rank_cmp(nt, PTR) >= 0)
if (pflag && size_in_bits(nt) >= size_in_bits(PTR)) {
else if (ot == PTR)
} else if (nt == PTR) {
} else if (ot == PTR && op == CVT)
nv->u.floating = (ot == PTR || is_uinteger(ot)) ?
nv->u.floating = (ot == PTR || is_uinteger(ot)) ?
nv->u.floating = (ot == PTR || is_uinteger(ot))
} else if (nt != PTR && is_uinteger(nt) &&
ot != PTR && !is_uinteger(ot) && v->u.integer < 0)
if (n->tn_type->t_tspec == PTR
&& n->u.ops.left->u.ops.left->tn_type->t_tspec == PTR) {
} else if (nt == PTR && is_integer(ot)) {
} else if (nt == PTR && ot == PTR) {
&& call->args[0]->tn_type->t_tspec == PTR)
if (func->tn_type->t_tspec != PTR ||
if ((!is_integer(t) && t != PTR) ||
(!is_integer(ot) && ot != PTR)) {
if (tn->u.ops.left->tn_type->t_tspec == PTR)
tp2->t_tspec = PTR;
lint_assert(ln->tn_type->t_tspec == PTR);
if (t1 != PTR || t2 != PTR) {
if (asgn && to == PTR) {
if (sflag || hflag || to != PTR)
} else if (t1 == PTR && is_integer(t2)) {
if ((t1 = tp->t_tspec) == PTR)
if (t1 != PTR ||
if (t1 != PTR || (hflag && t2 != VOID))
if (t1 != PTR) {
if ((t1 = tp->t_tspec) == PTR)
if (t1 != PTR) {
if (t1 != PTR) {
return PTR;
case PTR:
t = PTR;
case PTR: