Commit 265f1eab authored by John van Groningen's avatar John van Groningen
Browse files

prevent crash if a newtype is used with -dynamics

parent a1971e18
...@@ -103,10 +103,10 @@ where ...@@ -103,10 +103,10 @@ where
= fwritei (get_type_var_nf_number v) tcl_file = fwritei (get_type_var_nf_number v) tcl_file
# wtis & wtis_type_heaps = {wtis_type_heaps & th_vars = th_vars} # wtis & wtis_type_heaps = {wtis_type_heaps & th_vars = th_vars}
= (tcl_file,wtis) = (tcl_file,wtis)
where where
get_type_var_nf_number (TVI_Normalized i) = i get_type_var_nf_number (TVI_Normalized i) = i
instance WriteTypeInfo TypeRhs instance WriteTypeInfo TypeRhs
where where
write_type_info (AlgType defined_symbols) tcl_file wtis write_type_info (AlgType defined_symbols) tcl_file wtis
...@@ -134,6 +134,10 @@ where ...@@ -134,6 +134,10 @@ where
write_type_info (AlgConses _ _) tcl_file wtis write_type_info (AlgConses _ _) tcl_file wtis
// unimplemented // unimplemented
= (tcl_file,wtis) = (tcl_file,wtis)
write_type_info (NewType _) tcl_file wtis
#! tcl_file = fwritec AbstractTypeCode tcl_file;
// unimplemented
= (tcl_file,wtis)
instance WriteTypeInfo DefinedSymbol instance WriteTypeInfo DefinedSymbol
where where
...@@ -392,7 +396,7 @@ write_type_info_of_array i limit array tcl_file wtis ...@@ -392,7 +396,7 @@ write_type_info_of_array i limit array tcl_file wtis
# (tcl_file,wtis) # (tcl_file,wtis)
= write_type_info array.[i] tcl_file wtis = write_type_info array.[i] tcl_file wtis
= write_type_info_of_array (inc i) limit array tcl_file wtis = write_type_info_of_array (inc i) limit array tcl_file wtis
instance WriteTypeInfo [a] | WriteTypeInfo a instance WriteTypeInfo [a] | WriteTypeInfo a
where where
write_type_info l tcl_file wtis write_type_info l tcl_file wtis
......
Markdown is supported
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