From 5c00b8cd03cbfc516cce92229f3f4974d7549c24 Mon Sep 17 00:00:00 2001 From: _ov4 Date: Fri, 16 Oct 2026 20:53:52 +0800 Subject: test(compiler): cover fixed CIE behavior and runtime boundaries Record independently traced outputs with pending human review. Keep standard syntax and naming conflicts as real failures. Co-Authored-By: Claude Fable 5.1 --- tests/i/stdin/case.json | 1 + tests/i/stdin/expected.txt | 1 + tests/i/stdin/input.txt | 4 ++++ tests/i/stdin/notes.md | 5 +++++ tests/i/stdin/program.cps | 9 +++++++++ 5 files changed, 20 insertions(+) create mode 100644 tests/i/stdin/case.json create mode 100644 tests/i/stdin/expected.txt create mode 100644 tests/i/stdin/input.txt create mode 100644 tests/i/stdin/notes.md create mode 100644 tests/i/stdin/program.cps (limited to 'tests/i/stdin') diff --git a/tests/i/stdin/case.json b/tests/i/stdin/case.json new file mode 100644 index 0000000..0967ef4 --- /dev/null +++ b/tests/i/stdin/case.json @@ -0,0 +1 @@ +{} diff --git a/tests/i/stdin/expected.txt b/tests/i/stdin/expected.txt new file mode 100644 index 0000000..acfc9ae --- /dev/null +++ b/tests/i/stdin/expected.txt @@ -0,0 +1 @@ +-7:TRUE:Z:hello diff --git a/tests/i/stdin/input.txt b/tests/i/stdin/input.txt new file mode 100644 index 0000000..604b657 --- /dev/null +++ b/tests/i/stdin/input.txt @@ -0,0 +1,4 @@ +-7 +1 +Z +hello diff --git a/tests/i/stdin/notes.md b/tests/i/stdin/notes.md new file mode 100644 index 0000000..62f8727 --- /dev/null +++ b/tests/i/stdin/notes.md @@ -0,0 +1,5 @@ +# stdin + +Human review: pending. Expected output was independently traced by AI, not captured from cpsc. + +Basis and trace: CIE p. 15; the project INPUT contract reads BOOLEAN as an integer (nonzero is true) and STRING as a whitespace-delimited token. diff --git a/tests/i/stdin/program.cps b/tests/i/stdin/program.cps new file mode 100644 index 0000000..025c634 --- /dev/null +++ b/tests/i/stdin/program.cps @@ -0,0 +1,9 @@ +DECLARE N : INTEGER +DECLARE Flag : BOOLEAN +DECLARE Letter : CHAR +DECLARE Text : STRING +INPUT N +INPUT Flag +INPUT Letter +INPUT Text +OUTPUT N, ":", Flag, ":", Letter, ":", Text -- cgit v1.3.1-4-g156e