aboutsummaryrefslogtreecommitdiff
path: root/frontend/type.icl
diff options
context:
space:
mode:
authorjohnvg2007-04-11 12:51:42 +0000
committerjohnvg2007-04-11 12:51:42 +0000
commitb21ac99170e93de3911140c7516b77fa35f612ac (patch)
tree2aa7f68bc8ea0a93a170c5735a51d6aee13b26fb /frontend/type.icl
parentremove import of module checksupport, remove unused function: newFunction (diff)
remove cons_index field in pattern in functions that do not use this field
git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@1664 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'frontend/type.icl')
-rw-r--r--frontend/type.icl9
1 files changed, 3 insertions, 6 deletions
diff --git a/frontend/type.icl b/frontend/type.icl
index a6ce95c..5d90d97 100644
--- a/frontend/type.icl
+++ b/frontend/type.icl
@@ -3,7 +3,7 @@ implementation module type
import StdEnv
import syntax, typesupport, check, analtypes, overloading, unitype, refmark, predef, utilities, compare_constructor // , RWSDebug
import compilerSwitches
-import genericsupport // AA
+import genericsupport
:: TypeInput =
{ ti_common_defs :: !{# CommonDefs }
@@ -720,7 +720,7 @@ freshAlgebraicType {glob_module, glob_object} patterns common_defs ts=:{ts_var_s
// ---> ("freshAlgebraicType", alg_type, cons_types)
where
fresh_symbol_types [{ap_symbol={glob_object},ap_expr}] cons_defs var_store attr_store type_heaps all_exis_variables
- # {cons_type = ct=:{st_args,st_attr_env,st_result}, cons_index, cons_exi_vars} = cons_defs.[glob_object.ds_index]
+ # {cons_type = ct=:{st_args,st_attr_env,st_result}, cons_exi_vars} = cons_defs.[glob_object.ds_index]
(exis_variables, var_store, attr_store, type_heaps) = freshExistentialVariables cons_exi_vars var_store attr_store type_heaps
// -?-> (not (isEmpty cons_exi_vars), ("fresh_symbol_types", cons_exi_vars, ct))
(attr_env, th_attrs) = fresh_environment st_attr_env [] type_heaps.th_attrs
@@ -731,7 +731,7 @@ where
fresh_symbol_types [{ap_symbol={glob_object},ap_expr} : patterns] cons_defs var_store attr_store type_heaps all_exis_variables
# (cons_types, result_type, attr_env, var_store, attr_store, type_heaps, all_exis_variables)
= fresh_symbol_types patterns cons_defs var_store attr_store type_heaps all_exis_variables
- {cons_type = ct=:{st_args,st_attr_env}, cons_index, cons_exi_vars} = cons_defs.[glob_object.ds_index]
+ {cons_type = ct=:{st_args,st_attr_env}, cons_exi_vars} = cons_defs.[glob_object.ds_index]
(exis_variables, var_store, attr_store, type_heaps) = freshExistentialVariables cons_exi_vars var_store attr_store type_heaps
// -?-> (not (isEmpty cons_exi_vars), ("fresh_symbol_types", cons_exi_vars, ct))
(attr_env, th_attrs) = fresh_environment st_attr_env attr_env type_heaps.th_attrs
@@ -1760,12 +1760,9 @@ where
requirements _ (ABCCodeExpr _ _) (reqs, ts)
# (fresh_v, ts) = freshAttributedVariable ts
= (fresh_v, No, (reqs, ts))
-
requirements _ expr reqs_ts
= (abort ("Error in requirements\n" ---> expr), No, reqs_ts)
-import StdDebug
-
:: Box a = { box :: !a}
basicIntType =: {box=TB BT_Int}