Proto/Michelson: rename allow_big_map -> allow_lazy_stoage

parent 7b1e10e8
......@@ -1537,7 +1537,7 @@ and parse_packable_ty :
parse_ty
ctxt
~legacy
~allow_big_map:false
~allow_lazy_storage:false
~allow_operation:false
~allow_contract:legacy
......@@ -1547,7 +1547,7 @@ and parse_parameter_ty :
parse_ty
ctxt
~legacy
~allow_big_map:true
~allow_lazy_storage:true
~allow_operation:false
~allow_contract:true
......@@ -1557,7 +1557,7 @@ and parse_normal_storage_ty :
parse_ty
ctxt
~legacy
~allow_big_map:true
~allow_lazy_storage:true
~allow_operation:false
~allow_contract:legacy
......@@ -1567,19 +1567,19 @@ and parse_any_ty :
parse_ty
ctxt
~legacy
~allow_big_map:true
~allow_lazy_storage:true
~allow_operation:true
~allow_contract:true
and parse_ty :
context ->
legacy:bool ->
allow_big_map:bool ->
allow_lazy_storage:bool ->
allow_operation:bool ->
allow_contract:bool ->
Script.node ->
(ex_ty * context) tzresult =
fun ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract node ->
fun ctxt ~legacy ~allow_lazy_storage ~allow_operation ~allow_contract node ->
Gas.consume ctxt Typecheck_costs.cycle
>>? fun ctxt ->
match node with
......@@ -1674,9 +1674,21 @@ and parse_ty :
>>? fun (utl, left_field) ->
extract_field_annot utr
>>? fun (utr, right_field) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract utl
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
utl
>>? fun (Ex_ty tl, ctxt) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract utr
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
utr
>>? fun (Ex_ty tr, ctxt) ->
parse_type_annot loc annot
>>? fun ty_name ->
......@@ -1690,9 +1702,21 @@ and parse_ty :
>>? fun (utl, left_constr) ->
extract_field_annot utr
>>? fun (utr, right_constr) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract utl
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
utl
>>? fun (Ex_ty tl, ctxt) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract utr
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
utr
>>? fun (Ex_ty tr, ctxt) ->
parse_type_annot loc annot
>>? fun ty_name ->
......@@ -1717,12 +1741,24 @@ and parse_ty :
>>? fun (ty_name, _none_constr, _) -> ok (ut, ty_name)
else parse_type_annot loc annot >>? fun ty_name -> ok (ut, ty_name) )
>>? fun (ut, ty_name) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract ut
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
ut
>>? fun (Ex_ty t, ctxt) ->
Gas.consume ctxt (Typecheck_costs.type_ 2)
>|? fun ctxt -> (Ex_ty (Option_t (t, ty_name)), ctxt)
| Prim (loc, T_list, [ut], annot) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract ut
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
ut
>>? fun (Ex_ty t, ctxt) ->
parse_type_annot loc annot
>>? fun ty_name ->
......@@ -1738,13 +1774,19 @@ and parse_ty :
| Prim (loc, T_map, [uta; utr], annot) ->
parse_comparable_ty ctxt uta
>>? fun (Ex_comparable_ty ta, ctxt) ->
parse_ty ctxt ~legacy ~allow_big_map ~allow_operation ~allow_contract utr
parse_ty
ctxt
~legacy
~allow_lazy_storage
~allow_operation
~allow_contract
utr
>>? fun (Ex_ty tr, ctxt) ->
parse_type_annot loc annot
>>? fun ty_name ->
Gas.consume ctxt (Typecheck_costs.type_ 2)
>|? fun ctxt -> (Ex_ty (Map_t (ta, tr, ty_name)), ctxt)
| Prim (loc, T_big_map, args, annot) when allow_big_map ->
| Prim (loc, T_big_map, args, annot) when allow_lazy_storage ->
parse_big_map_ty ctxt ~legacy loc args annot
>>? fun (big_map_ty, ctxt) ->
Gas.consume ctxt (Typecheck_costs.type_ 2)
......
......@@ -201,7 +201,7 @@ val parse_parameter_ty :
val parse_ty :
context ->
legacy:bool ->
allow_big_map:bool ->
allow_lazy_storage:bool ->
allow_operation:bool ->
allow_contract:bool ->
Script.node ->
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment