From c4565386553ea86308a9487650d2435804893ed0 Mon Sep 17 00:00:00 2001 From: _ov4 Date: Thu, 15 Oct 2026 02:41:11 +0000 Subject: fix(codegen): restore runtime diagnostics before throwing Reuse historical runtime messages and source-line reporting for arithmetic, array, enum, pointer and file checks while preserving anonymous exceptions. Update the manuals and subsystem guidance to describe diagnostic output. Co-Authored-By: Claude Fable 5.1 --- include/cps/FileHandler.h | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'include/cps/FileHandler.h') diff --git a/include/cps/FileHandler.h b/include/cps/FileHandler.h index 8b8ddf4..50593de 100644 --- a/include/cps/FileHandler.h +++ b/include/cps/FileHandler.h @@ -38,6 +38,10 @@ class FileHandler { llvm::Value *ModeReadStr = nullptr, *ModeWriteStr = nullptr, *ModeAppendStr = nullptr; + llvm::Value *ErrOpenFail = nullptr, *ErrAlreadyOpen = nullptr, *ErrTableFull = nullptr, + *ErrNotOpen = nullptr, *ErrNotRead = nullptr, *ErrNotWrite = nullptr, + *ErrPastEof = nullptr; + // synthesized helpers (internal linkage; pseudocode identifiers cannot // start with '_', so these names are un-collidable) llvm::Function *FindFn = nullptr, *OpenFn = nullptr, *ReadFn = nullptr, -- cgit v1.3.1-4-g156e