diff options
author | ronny | 2002-10-31 16:22:06 +0000 |
---|---|---|
committer | ronny | 2002-10-31 16:22:06 +0000 |
commit | 394341d99509da5836cf074590948121bdb8bc20 (patch) | |
tree | 6e7a97b1aaf3ed5f526fda15122392f31394babc /frontend/convertDynamics.icl | |
parent | bug fix for boxed records and ! record selections (diff) |
Fix bug where wrong type code constructor was selected.
The fix is to not use the index and table of type code constructors,.
The indices and tables should be cleaned up later.
git-svn-id: https://svn.cs.ru.nl/repos/clean-compiler/trunk@1265 1f8540f1-abd5-4d5b-9d24-4c5ce8603e2d
Diffstat (limited to 'frontend/convertDynamics.icl')
-rw-r--r-- | frontend/convertDynamics.icl | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/frontend/convertDynamics.icl b/frontend/convertDynamics.icl index 6b3ccb8..0b0b297 100644 --- a/frontend/convertDynamics.icl +++ b/frontend/convertDynamics.icl @@ -623,11 +623,11 @@ convertTypeCode pattern cinp (TCE_App t arg) (has_var, binds, ci) = (App {app_symb = typeapp_symb, app_args = [typecode_t, typecode_arg], app_info_ptr = nilPtr}, st) -convertTypeCode pattern cinp (TCE_Constructor index []) (has_var, binds, ci) +convertTypeCode pattern cinp (TCE_Constructor index cons []) (has_var, binds, ci) # (typecons_symb, ci) = getSymbol PD_Dyn_TypeCons SK_Constructor 1 ci # (constructor, ci) - = typeConstructor cinp.cinp_glob_type_inst.[index] ci + = typeConstructor cons /* cinp.cinp_glob_type_inst.[index]*/ ci = (App {app_symb = typecons_symb, app_args = [constructor], app_info_ptr = nilPtr}, (has_var, binds, ci)) @@ -693,9 +693,9 @@ where = PD_Dyn_TypeCodeConstructor_UnboxedArray // otherwise = fatal "predefinedType" "TC code from predef" -convertTypeCode pattern cinp (TCE_Constructor index args) st +convertTypeCode pattern cinp (TCE_Constructor index cons args) st # curried_type - = foldl TCE_App (TCE_Constructor index []) args + = foldl TCE_App (TCE_Constructor index cons []) args = convertTypeCode pattern cinp curried_type st convertTypeCode pattern cinp (TCE_UniType uni_vars type_code) (has_var, binds, ci) # (tv_symb, ci) |