Yes, strange. It only fails with assignment, though:
// mark := [5,11] // should fail, but does not.
mark :=[]
include(mark,5);// OK
include(mark,11)// fails, rangecheck error
OTOH the
for in do doesn't see the 11 as part of the set so that behaves correct.
I also tested making the set a type too, but the same behavior: it does not range check the inititial set assignment.
This is a bug indeed, also in 3.3.1.
I will report it with a simplified example.