[clean-list] array update example in language report

T.Yamauchi acatofearlgrey at ybb.ne.jp
Sun Mar 4 06:01:39 MET 2007


Hello,

I found a wrong example in language report 2.1.
There are examples of array update in p.57.

----
Creating an array with the integer elements 1,3,5,7,9 using the update operator
in combination with array and list comprehensions.

{CreateArray 5 0 & [i] = 2*i+1 \\ i <- [0..4]}
{CreateArray 5 0 & [i] = elem \\ elem <-: {1,3,5,7,9} & i <- [0..4]}
{CreateArray 5 0 & elem \\ elem <-: {1,3,5,7,9}}
----

But I cannot compile the third example. The error message is

----
Parse error [Main.icl,10;35,field assignment]: = expected instead of \\
----

I think it is a wrong example or otherwise it is a compiler bug.


lethevert


More information about the clean-list mailing list