Added missing error reporting during scoping pass.
This commit is contained in:
parent
faf232ad64
commit
d57196bb24
|
@ -242,6 +242,7 @@ let rec translate_type loc local_const ty =
|
||||||
|
|
||||||
|
|
||||||
and translate_exp local_const env e =
|
and translate_exp local_const env e =
|
||||||
|
try
|
||||||
let desc =
|
let desc =
|
||||||
(*try (* try to see if the exp is a constant *)
|
(*try (* try to see if the exp is a constant *)
|
||||||
Heptagon.Econst (static_exp_of_exp local_const e)
|
Heptagon.Econst (static_exp_of_exp local_const e)
|
||||||
|
@ -250,6 +251,7 @@ and translate_exp local_const env e =
|
||||||
{ Heptagon.e_desc = desc;
|
{ Heptagon.e_desc = desc;
|
||||||
Heptagon.e_ty = Types.invalid_type;
|
Heptagon.e_ty = Types.invalid_type;
|
||||||
Heptagon.e_loc = e.e_loc }
|
Heptagon.e_loc = e.e_loc }
|
||||||
|
with ScopingError(error) -> message e.e_loc error
|
||||||
|
|
||||||
and translate_desc loc local_const env = function
|
and translate_desc loc local_const env = function
|
||||||
| Econst c -> Heptagon.Econst (translate_static_exp local_const c)
|
| Econst c -> Heptagon.Econst (translate_static_exp local_const c)
|
||||||
|
|
Loading…
Reference in a new issue