Next: , Previous: , Up: srfi list discussion   [Index]


2.2.4.4 Errors

Note that statements of the form “it is an error” merely mean “don’t do that”. They are no a guarantees that a conforming implementation will “catch” such improper use by, for example, raising some kind of exception. Regrettably, R5RS Scheme requires no firmer guarantee even for basic operators such as car and cdr, so there’s little point in requiring these procedures to do more. Here is the relevant section of the R5RS:

When speaking of an error situation, this report uses the phrase “an error is signalled” to indicate that implementations must detect and report the error. If such wording does not appear in the discussion of an error, then implementations are not required to detect or report the error, though they are encouraged to do so. An error situation that implementations are not required to detect is usually referred to simply as “an error”.

For example, it is an error for a procedure to be passed an argument that the procedure is not explicitly specified to handle, even though such domain errors are seldom mentioned in this report. Implementations may extend a procedure’s domain of definition to include such arguments.