Commit f92d82bd authored by John van Groningen's avatar John van Groningen
Browse files

feature, add lazy array values: {^array_elements}

parent 80909b28
......@@ -919,8 +919,9 @@ checkExpression free_vars (PE_Generic id=:{id_name,id_info} kind) e_input e_stat
checkExpression free_vars (PE_TypeSignature array_kind expr) e_input e_state e_info cs
# (expr,free_vars,e_state,e_info,cs) = checkExpression free_vars expr e_input e_state e_info cs
predef_array_index = case array_kind of
UnboxedArray -> PD_UnboxedArrayType
LazyArray -> PD_LazyArrayType
StrictArray -> PD_StrictArrayType
UnboxedArray -> PD_UnboxedArrayType
PackedArray -> PD_PackedArrayType
({pds_module,pds_def},cs) = cs!cs_predef_symbols.[predef_array_index]
#! strict_array_ident = predefined_idents.[predef_array_index]
......
......@@ -4777,6 +4777,8 @@ wantRecordOrArrayExp is_pattern pState
-> want_array_elems UnboxedArray pState
CurlyCloseToken
-> (PE_ArrayDenot OverloadedArray [], pState)
IdentToken "^"
-> want_array_elems LazyArray pState
_
# (opt_type, pState) = try_type_specification token pState
-> case opt_type of
......
......@@ -1320,7 +1320,7 @@ instance toString KindInfo
:: ModuleIdent:==Ident
:: ArrayKind = OverloadedArray | StrictArray | UnboxedArray | PackedArray;
:: ArrayKind = LazyArray | StrictArray | UnboxedArray | PackedArray | OverloadedArray;
:: GeneratorKind = IsListGenerator | IsStrictListGenerator | IsOverloadedListGenerator | IsArrayGenerator
......
Supports Markdown
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