Re: Proposed solution to the "predetermined states" problem
Peter McGoron 03 Jun 2026 16:14 UTC
> I don't think it does. The return value of 'port-position' is allowed
to be implementation-dependent only for textual input ports. For binary
input ports, the position is an exact integer. Chez and Guile both
enforce this type requirement.
I find it odd that "should" here
> The get-position procedure (if supplied) should return an exact
integer object representing the current position of the input port. If
not supplied, the custom port will not support the port-position operation.
means (or gets interpreted to mean) that an implementation should reject
procedures that return non-exact integers, and not that the programmer
should only write procedures that return exact integer objects. (Another
reason to dislike R6RS's strictness.)
-- Peter McGoron