From 0c289c54fb0a31491aa1d2b030851337430ccd71 Mon Sep 17 00:00:00 2001 From: Mark Wooding Date: Mon, 9 Jul 2018 13:04:38 +0100 Subject: [PATCH] src/module-parse.lisp (parse-class-body): Check for duplicate superclasses. It turns out that this is a thing that can happen. Catch it early rather than waiting for a less helpful message during CPL construction. --- src/module-parse.lisp | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/src/module-parse.lisp b/src/module-parse.lisp index 0a3cd28..747bdf7 100644 --- a/src/module-parse.lisp +++ b/src/module-parse.lisp @@ -267,7 +267,14 @@ (continue () (setf duff t) (list (find-sod-class "SodObject")))))) - superclasses)) + (find-duplicates (lambda (first second) + (declare (ignore second)) + (setf duff t) + (cerror* "Class `~A' has duplicate ~ + direct superclass `~A'" + name first)) + superclasses) + (delete-duplicates superclasses))) (synthetic-name (or name (let ((var (synthetic-name))) (unless pset -- 2.11.0