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

remove shorthand and iso functions from generic ranges,

first all main instances are build, then all shorthand instances,
shorthand instances directly call the main instance (SK_Function instead of SK_Generic),
call toGeneric.. and fromGeneric.. functions directly if possible, instead of iso..
parent 20ce191e
This diff is collapsed.
...@@ -553,7 +553,9 @@ NoGlobalIndex :== {gi_module=NoIndex,gi_index=NoIndex} ...@@ -553,7 +553,9 @@ NoGlobalIndex :== {gi_module=NoIndex,gi_index=NoIndex}
:: GenericTypeRep = :: GenericTypeRep =
{ gtr_type :: GenTypeStruct // generic structure type { gtr_type :: GenTypeStruct // generic structure type
, gtr_iso :: DefinedSymbol // the conversion isomorphism , gtr_iso :: !DefinedSymbol // the conversion isomorphism
, gtr_to :: !DefinedSymbol
, gtr_from :: !DefinedSymbol
} }
:: TypeDefInfos :== {# .{# TypeDefInfo}} :: TypeDefInfos :== {# .{# TypeDefInfo}}
...@@ -772,7 +774,6 @@ cNonRecursiveAppl :== False ...@@ -772,7 +774,6 @@ cNonRecursiveAppl :== False
/* Some auxiliary type definitions used during fusion. Actually, these definitions /* Some auxiliary type definitions used during fusion. Actually, these definitions
should have been given in seperate module. Unfortunately, Clean's module system should have been given in seperate module. Unfortunately, Clean's module system
forbids cyclic dependencies between def modules. forbids cyclic dependencies between def modules.
*/ */
:: FunctionHeap :== Heap FunctionInfo :: FunctionHeap :== Heap FunctionInfo
...@@ -1020,6 +1021,7 @@ cNonRecursiveAppl :== False ...@@ -1020,6 +1021,7 @@ cNonRecursiveAppl :== False
| TVI_ConsInstance !DefinedSymbol //AA: generic cons instance function | TVI_ConsInstance !DefinedSymbol //AA: generic cons instance function
| TVI_Normalized !Int /* MV - position of type variable in its definition */ | TVI_Normalized !Int /* MV - position of type variable in its definition */
| TVI_Expr !Expression /* AA: Expression corresponding to the type var during generic specialization */ | TVI_Expr !Expression /* AA: Expression corresponding to the type var during generic specialization */
| TVI_Iso !DefinedSymbol !DefinedSymbol !DefinedSymbol
| TVI_GenTypeVarNumber !Int | TVI_GenTypeVarNumber !Int
| TVI_CPSTypeVar !CheatCompiler /* MdM: a pointer to a variable in CleanProverSystem is stored here, using a cast */ | TVI_CPSTypeVar !CheatCompiler /* MdM: a pointer to a variable in CleanProverSystem is stored here, using a cast */
......
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