From 2cddf988fb9feda6d8911e51c3adcdd63360fdf7 Mon Sep 17 00:00:00 2001 From: Kaz Kyheku Date: Fri, 31 Jan 2020 06:33:00 -0800 Subject: doc: defex does allow duplicate registration. * txr.1: Fix wrong documentation about defex. It does allow registration of duplicate relationhips and updates that do not create cycles. Document a rule that is missing: that a subtype relationships can't be registered when the opposite relationship already exists. --- txr.1 | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/txr.1 b/txr.1 index 49fe9810..93018264 100644 --- a/txr.1 +++ b/txr.1 @@ -41752,23 +41752,10 @@ has three or more arguments, they are processed from left to right. If errors are encountered during the processing, the correct registrations already made for prior arguments remain in place. -It is erroneous to register a duplicate relationship. If symbol -.code a -is already a direct or indirect subtype of -.code b -then -.code "(defex a b)" -and -.code "(defex a x b)" -are erroneous. - Every symbol is implicitly considered to be its own exception subtype, therefore it is erroneous to explicitly register a symbol as its own subtype. -The foregoing rules eliminate the possibility of creating cycles in the -exception subtype inheritance graph. - The symbol .code nil is implicitly a subtype of every exception type. Therefore, it is erroneous @@ -41788,6 +41775,15 @@ Using .code t as a supertype in a registration is also erroneous. +A symbol +.code a +may not be registered as a subtype of a symbol +.code b +if the reverse relationship already exists between those two symbols. + +The foregoing rules allow redefinitions to take place, while forbidding cycles +from being created in the exception subtype inheritance graph. + Keyword symbols may be used as exception types. .coNP Function @ register-exception-subtypes -- cgit v1.2.3