Open Scope logic.
Instance CompSpecs : compspecs. make_compspecs prog. Defined.
Definition Vprog : varspecs. mk_varspecs prog. Defined.
Definition t_struct_list := Tstruct _list noattr.
Fixpoint listrep (sh: share)
(contents: list val) (x: val) : mpred :=
match contents with
| h::hs =>
EX y:val,
data_at sh t_struct_list (h,y) x * listrep sh hs y
| nil => !! (x = nullval) && emp
end.
Arguments listrep sh contents x : simpl never.
Hint Resolve listrep_local_facts : saturate_local.
Hint Resolve listrep_valid_pointer : valid_pointer.

Lemma is_pointer_or_null_not_null:
forall x, is_pointer_or_null x -> x <> nullval -> isptr x.