996
|
1 iffit1.i and iffit2.b98 are a test of the C-INTERCAL/cfunge external
|
|
2 calls system. To use the test, use this command:
|
|
3
|
|
4 ick -ea iffit1.i iffit2.b98
|
|
5
|
|
6 What follows is the expected output, annotated to show what causes
|
|
7 each line to be printed.
|
|
8
|
|
9 Before IFFI... Printed by the Funge program before IFFI is loaded.
|
|
10 0 Printed immediately after IFFI loads; the program then
|
|
11 yields immediately, running the INTERCAL program.
|
|
12 I Printed at the start of the INTERCAL program; tests Y.
|
|
13 2 Printed by the Funge program after (100) is NEXTed to.
|
|
14 This tests NEXTING to an L in the Funge program.
|
|
15 III Printed by INTERCAL after the Funge program does 2R
|
|
16 (i.e. RESUME 2).
|
|
17 IV Tests COMING FROM an L when in mark-mode after a NEXT.
|
|
18 5 Tests NEXTING FROM the INTERCAL program to the Funge
|
|
19 program using X.
|
|
20 VI Tests RESUMING to the INTERCAL program after the NEXT
|
|
21 FROM in the Befunge program.
|
|
22 VII Tests that COME FROMs happen at the end of a command.
|
|
23 8 Tests COMING FROM the INTERCAL program to the Funge
|
|
24 program using C.
|
|
25 IX Tests FORGET using F, and also RESUME after a COME FROM
|
|
26 in the Befunge program.
|
|
27 X This (irrelevantly) tests ONCE in the INTERCAL program.
|
|
28 11 This (likewise irrelevantly) tests that p in Funge has
|
|
29 correctly altered the flow of control.
|
|
30 XII Tests COMING FROM an L when not in mark-mode.
|
|
31 13 Tests variable access using G in the Funge program to
|
|
32 read an INTERCAL variable, also a second marker.
|
|
33 XIV Tests the use of S to set an INTERCAL variable.
|
|
34 15 Tests that CREATEd commands send values correctly.
|
|
35 16 Tests that CREATEd commands send bitwidths correctly.
|
|
36 17 Tests that CREATEd commands send names correctly.
|
|
37 The above three tests test CREATION using A and D.
|
|
38 XVIII Tests that V sets arguments to CREATED commands
|
|
39 correctly, and also that Y correctly reflects the
|
|
40 second time.
|
|
41
|
|
42 At this point the program should end, having tested all the commands
|
|
43 in the IFFI fingerprint. (Obviously, this is not an exhaustive test,
|
|
44 because, for instance, G was only used to get onespot variables not
|
|
45 twospot variables.)
|
|
46
|
|
47 It is an interesting challenge to try to figure out how the tests
|
|
48 work, especially given that the Funge program is self-modifying, the
|
|
49 statements in the INTERCAL program don't always do the same thing
|
|
50 every time they're run, and the Funge program modifies the syntax of
|
|
51 the INTERCAL program at runtime.
|