aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--frontend/check.icl2
-rw-r--r--frontend/checktypes.icl1
-rw-r--r--frontend/comparedefimp.icl7
-rw-r--r--frontend/explicitimports.icl6
-rw-r--r--frontend/parse.icl3
-rw-r--r--frontend/predef.icl2
-rw-r--r--frontend/syntax.dcl7
7 files changed, 11 insertions, 17 deletions
diff --git a/frontend/check.icl b/frontend/check.icl
index b99daf1..c8d8a5e 100644
--- a/frontend/check.icl
+++ b/frontend/check.icl
@@ -1177,7 +1177,7 @@ renumber_icl_definitions_as_dcl_definitions (Yes icl_to_dcl_index_table) icl_siz
reorder_common_definitions {com_type_defs,com_cons_defs,com_selector_defs,com_class_defs,com_member_defs,com_instance_defs,com_generic_defs,com_gencase_defs}
# dummy_ident = {id_name="",id_info=nilPtr}
# com_type_defs=reorder_and_enlarge_array com_type_defs n_dictionary_types icl_to_dcl_index_table.[cTypeDefs]
- {td_ident=dummy_ident,td_index= -1,td_arity=0,td_args=[],td_attrs=[],td_context=[],td_rhs=UnknownType,td_attribute=TA_None,td_pos=NoPos,td_used_types=[],
+ {td_ident=dummy_ident,td_index= -1,td_arity=0,td_args=[],td_attrs=[],td_rhs=UnknownType,td_attribute=TA_None,td_pos=NoPos,td_used_types=[],
td_fun_index = NoIndex}
# dummy_symbol_type={st_vars=[],st_args=[],st_args_strictness=NotStrict,st_arity=0,st_result={at_attribute=TA_None,at_type=TE},st_context=[],st_attr_vars=[],st_attr_env=[]}
# com_selector_defs=reorder_and_enlarge_array com_selector_defs n_dictionary_selectors icl_to_dcl_index_table.[cSelectorDefs]
diff --git a/frontend/checktypes.icl b/frontend/checktypes.icl
index b286222..3af1c3b 100644
--- a/frontend/checktypes.icl
+++ b/frontend/checktypes.icl
@@ -1538,7 +1538,6 @@ where
, td_arity = 0
, td_args = td_args
, td_attrs = []
- , td_context = []
, td_rhs = RecordType {rt_constructor = cons_symbol, rt_fields = { field \\ field <- reverse rev_fields }, rt_is_boxed_record=False}
, td_attribute = TA_None
, td_pos = NoPos
diff --git a/frontend/comparedefimp.icl b/frontend/comparedefimp.icl
index a7a2ccf..17f32a7 100644
--- a/frontend/comparedefimp.icl
+++ b/frontend/comparedefimp.icl
@@ -734,12 +734,11 @@ instance t_corresponds (TypeDef TypeRhs) where
= t_corresponds_TypeDef dclDef iclDef
where
t_corresponds_TypeDef dclDef iclDef tc_state
-// | False--->("comparing:", dclDef, iclDef)
-// = undef
# tc_state = init_attr_vars dclDef.td_attrs iclDef.td_attrs tc_state
tc_state = init_atype_vars dclDef.td_args iclDef.td_args tc_state
- = t_corresponds (dclDef.td_args, (dclDef.td_rhs, (dclDef.td_context, dclDef.td_attribute)))
- (iclDef.td_args, (iclDef.td_rhs, (iclDef.td_context, iclDef.td_attribute))) tc_state
+ = t_corresponds (dclDef.td_args, (dclDef.td_rhs, dclDef.td_attribute))
+ (iclDef.td_args, (iclDef.td_rhs, iclDef.td_attribute)) tc_state
+
instance t_corresponds TypeContext where
t_corresponds dclDef iclDef
= t_corresponds dclDef.tc_class iclDef.tc_class
diff --git a/frontend/explicitimports.icl b/frontend/explicitimports.icl
index dc5222e..6e38f6c 100644
--- a/frontend/explicitimports.icl
+++ b/frontend/explicitimports.icl
@@ -801,12 +801,10 @@ instance check_completeness TypeContext where
check_completeness {tc_class=TCGeneric {gtc_generic={glob_module,glob_object={ds_ident,ds_index}}}, tc_types} cci ccs
= check_completeness tc_types cci
(check_whether_ident_is_imported ds_ident glob_module ds_index STE_Generic cci ccs)
-
instance check_completeness (TypeDef TypeRhs) where
- check_completeness td=:{td_rhs, td_context} cci ccs
- = check_completeness td_rhs cci
- (check_completeness td_context cci ccs)
+ check_completeness td=:{td_rhs} cci ccs
+ = check_completeness td_rhs cci ccs
instance check_completeness TypeRhs where
check_completeness (SynType aType) cci ccs
diff --git a/frontend/parse.icl b/frontend/parse.icl
index 8ae7c78..14ec95e 100644
--- a/frontend/parse.icl
+++ b/frontend/parse.icl
@@ -1655,8 +1655,7 @@ where
(name, pState) = wantConstructorName "Type name" pState
(ident, pState) = stringToIdent name IC_Type pState // -->> ("Type name",name)
(args, pState) = parseList tryAttributedTypeVar pState
- (contexts, pState) = optionalContext pState
- = (MakeTypeDef ident args (ConsList []) attr contexts pos, annot, pState)
+ = (MakeTypeDef ident args (ConsList []) attr pos, annot, pState)
want_type_rhs :: !Token !ParseContext !ParsedTypeDef !Annotation !ParseState -> (ParsedDefinition, !ParseState)
want_type_rhs EqualToken parseContext td=:{td_ident,td_attribute} annot pState
diff --git a/frontend/predef.icl b/frontend/predef.icl
index 60d6509..cbc1f5e 100644
--- a/frontend/predef.icl
+++ b/frontend/predef.icl
@@ -390,7 +390,7 @@ cTCInstanceSymbIndex :== 0
make_type_def :: !Int ![TypeVar] !a !*{#PredefinedSymbol} -> (!TypeDef a,!.{#PredefinedSymbol})
make_type_def type_cons_index type_vars type_rhs pre_def_symbols
# type_cons_ident = predefined_idents.[type_cons_index]
- = (MakeTypeDef type_cons_ident (map (\tv -> MakeAttributedTypeVar tv) type_vars) type_rhs TA_None [] NoPos, pre_def_symbols)
+ = (MakeTypeDef type_cons_ident (map (\tv -> MakeAttributedTypeVar tv) type_vars) type_rhs TA_None NoPos, pre_def_symbols)
make_list_definition :: Int Int Int Ident TypeVar AType StrictnessList *{#PredefinedSymbol} -> (!TypeDef TypeRhs,!ConsDef,!ConsDef,!.{#PredefinedSymbol})
make_list_definition list_type_pre_def_symbol_index cons_pre_def_symbol_index nil_pre_def_symbol_index pre_mod_id type_var type_var_with_attr cons_strictness pre_def_symbols
diff --git a/frontend/syntax.dcl b/frontend/syntax.dcl
index 22aedd1..295e60b 100644
--- a/frontend/syntax.dcl
+++ b/frontend/syntax.dcl
@@ -411,7 +411,7 @@ cNameLocationDependent :== True
| TypeConsVar TypeVar
:: GenericCaseDef =
- { gc_ident :: !Ident // name in IC_GenricCase namespace
+ { gc_ident :: !Ident // name in IC_GenricCase namespace
, gc_gident :: !Ident // name in IC_Generic namespace
, gc_generic :: !GlobalIndex // index of the generic
, gc_arity :: !Int // arity of the function
@@ -524,7 +524,6 @@ NoGlobalIndex :== {gi_module=NoIndex,gi_index=NoIndex}
, td_arity :: !Int
, td_args :: ![ATypeVar]
, td_attrs :: ![AttributeVar]
- , td_context :: ![TypeContext]
, td_rhs :: !type_rhs
, td_attribute :: !TypeAttribute
, td_pos :: !Position
@@ -1502,8 +1501,8 @@ ParsedInstanceToClassInstance pi members :==
it_context = pi.pi_context },
ins_members = members, ins_specials = pi.pi_specials, ins_pos = pi.pi_pos}
-MakeTypeDef name lhs rhs attr contexts pos :==
- { td_ident = name, td_index = -1, td_arity = length lhs, td_args = lhs, td_attrs = [], td_attribute = attr, td_context = contexts,
+MakeTypeDef name lhs rhs attr pos :==
+ { td_ident = name, td_index = -1, td_arity = length lhs, td_args = lhs, td_attrs = [], td_attribute = attr,
td_pos = pos, td_rhs = rhs, td_used_types = [], td_fun_index = NoIndex
}