   [?aspect ?super]
   (all
     (aspect-declaredsuper ?aspect ?super)
-    (succeeds (.isClass  ?super))))
+    (class ?super)))
+
+
+(defn
+  type-declaredsuper+
+  "Relation between a type and one of the ancestors in its declared super hierarchy."
+  [?type ?ancestor]
+  (conde
+    [(type-declaredsuper ?type ?ancestor) ]
+    [(fresh [?inbetween]
+              (type-declaredsuper ?type ?inbetween)
+              (type-declaredsuper+ ?inbetween ?ancestor))]))
 
 
 (defn
   aspect-declaredsuper+
   "Relation between an aspect and one of the ancestors in its declared super hierarchy."
   [?aspect ?ancestor]
-  (conde
-    [(aspect-declaredsuper ?aspect ?ancestor) ]
-    [(fresh [?inbetween]
-              (aspect-declaredsuper ?aspect ?inbetween)
-              (aspect-declaredsuper+ ?inbetween ?ancestor))]))
-
+  (all
+    (aspect ?aspect)
+    (type-declaredsuper+ ?aspect ?ancestor)))
+  
 (defn
   aspect-declaredsuperaspect+
   "Relation between an aspect and one of the ancestor aspects in its declared super hierarchy."

  [?aspect ?ancestor]
  (all
    (aspect-declaredsuper+ ?aspect ?ancestor)
    (succeeds (.isClass  ?ancestor))))


;todo: wantgenerics is true, check whether this is compatible with the types returned by the other predicates
;(i.e., test with a parameterized aspec)
(defn
  aspect-super+
  "Relation between an aspect and one of its direct or indirect

   including those that stem from an intertype declaration."
  [?aspect ?type]
  (all
    (aspect ?aspect)
    (type-super+ ?aspect ?type)))


(defn
  aspect-superaspect+
