allowing abstraction of Tvar's

Reviewed By: cristianoc

Differential Revision: D2960706

fb-gh-sync-id: 152f975
shipit-source-id: 152f975
master
Sam Blackshear 9 years ago committed by facebook-github-bot-5
parent af5f4c6afd
commit 9f346ea1fc

@ -419,12 +419,12 @@ let typ_get_recursive_flds tenv typ_exp =
in in
match typ_exp with match typ_exp with
| Sil.Sizeof (typ, _) -> | Sil.Sizeof (typ, _) ->
(match typ with (match Sil.expand_type tenv typ with
| Sil.Tvar _ -> assert false (* there should be no indirection *)
| Sil.Tint _ | Sil.Tvoid | Sil.Tfun _ | Sil.Tptr _ | Sil.Tfloat _ | Sil.Tenum _ -> [] | Sil.Tint _ | Sil.Tvoid | Sil.Tfun _ | Sil.Tptr _ | Sil.Tfloat _ | Sil.Tenum _ -> []
| Sil.Tstruct { Sil.instance_fields } -> | Sil.Tstruct { Sil.instance_fields } ->
IList.map (fun (x, _, _) -> x) (IList.filter (filter typ) instance_fields) IList.map (fun (x, _, _) -> x) (IList.filter (filter typ) instance_fields)
| Sil.Tarray _ -> []) | Sil.Tarray _ -> []
| Sil.Tvar _ -> assert false)
| Sil.Var _ -> [] (* type of |-> not known yet *) | Sil.Var _ -> [] (* type of |-> not known yet *)
| Sil.Const _ -> [] | Sil.Const _ -> []
| _ -> | _ ->

Loading…
Cancel
Save