Commit e01e76ba authored by Martin Wierich's avatar Martin Wierich

Added preprocessor directives, so that one and the same source can be

compiled with Clean 1.3 and Clean 2.0
function "wrapNode" in module Wrap will abort under Clean 2.0 (otherwise
no executable could be generated because of a link problem, however
wrapNode won't be called anyway in this revision)
parent 69c6b6a0
......@@ -84,7 +84,8 @@ debugShowWithOptions debugOptions debugValue
= {options & terminator=terminator}
:: Indicators
= ...
// MW 2.0 was: = ...
= @...
| .+.
MaxCharsString
......@@ -92,7 +93,8 @@ MaxCharsString
MaxBreadthString
:== "..."
MaxBreadthIndicator
:== wrapNode ...
// MW 2.0 was: :== wrapNode ...
:== wrapNode @...
MaxDepthIndicator
:== wrapNode .+.
......@@ -138,7 +140,13 @@ pruneWrappedNode maxDepth maxBreadth value
// otherwise
= {prune (depth+1) e \\ e <-: a}
// MW:
//1.3
pruneBasicArray :: !Int !(a b) -> WrappedNode | Array .a & ArrayElem b
//3.1
/*2.0
pruneBasicArray :: !Int !(a b) -> WrappedNode | Array a b
0.2*/
pruneBasicArray depth a
| size a > maxBreadth
= WrappedArray (pruneArray depth {wrapNode e \\ e <-: a & i <- [0 .. maxBreadth]})
......
......@@ -71,7 +71,10 @@ showDescriptor WrappedDescriptorCons
showDescriptor WrappedDescriptorTuple
= "(..)"
// MW
//1.3
showBasicArray :: {#a} -> [{#Char}] | toString, ArrayElem a
//3.1
showBasicArray a
= ["{" : separate ", " [toString el \\ el <-: a]] ++ ["}"]
......
......@@ -7,7 +7,7 @@
*/
implementation module Wrap
import StdOverloaded
import StdOverloaded, StdMisc
:: WrappedDescriptorId = {descriptorId :: !Int}
......@@ -48,6 +48,10 @@ instance toString WrappedDescriptorId where
wrapNode :: !.a -> WrappedNode
wrapNode node
/*2.0
= abort "WrapDebug still does not work whith Clean 2.0"
0.2*/
//1.3
= code
{
| A: <node> <result>
......@@ -709,3 +713,4 @@ wrapNode node
| B:
rtn
}
//3.1
\ No newline at end of file
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