raz / test / run / CheckOff.raz

19 lines · 504 B · raw · history · last change 264716cb

1module CheckOff;
2(* check off leaves out the checks of its own module only: here
3 Unchecked reads past an array, into the field after it, and makes a
4 slice past its string's end; then this module's own index fails *)
5import Out, Unchecked;
6import SYSTEM;
7
8proc main*;
9var p: Unchecked.Pair; i: INT;
10begin
11 p.b := 42;
12 Out.int(Unchecked.get(SYSTEM.ADR(p), 2)); Out.str(" ");
13 Out.int(Unchecked.width("abc", 1, 5)); Out.ln;
14 Out.flush;
15 i := 2;
16 Out.int(p.a[i]);
17end;
18
19end CheckOff.