mirror of
https://github.com/boykopovar/AnyPS5.git
synced 2026-11-03 12:57:27 +00:00
Value::setTypeMismatchHandler, setElementAccessFailureHandler and setSpecialFloatHandler were stubs that threw NotImplemented. PPSA07411 calls all three while it sets up its documents. The title calls them as members of Value: on its root Value before parsing into it, with the handler and its context, and treats an int result of 0 as success. They now store the handler and context on that Value and on the values it holds, and return 0. A Value keeps its handlers when its content changes (set, clear, operator=, Parser::parse), and Parser::parse gives the values it creates the handlers of the Value it parses into, since the title reads the errors its handlers record after accessing parsed members. A copy does not carry them. A typed getter on a non-null value of another type calls the type mismatch handler with the requested type, the value, null and the context, and returns its result when it has the requested type, else the getter's default. The element access failure and special float handlers are stored but not called: the error code the console passes to the first and the FunctionType it passes to the second are unknown. A failed element access on a value carrying the first throws instead of reaching the null-access callback. Serializing a non-finite real already threw; with the second set it throws naming the unknown FunctionType. The technical debt entry records what is inferred. Co-Authored-By: Claude Opus 5.5 <[email protected]>