Skip to content

Commit

Permalink
fix excluding double inheritance on multiple inheritance (#183)
Browse files Browse the repository at this point in the history
 - close #183
  • Loading branch information
marcellussiegburg committed Jun 21, 2024
1 parent 23e8b02 commit 9f37695
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
2 changes: 1 addition & 1 deletion alloy/cd/generate.als
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ pred classDiagram [
#{ c : compositions | not validLimitsComposition [c]} = wrongCompositions
#{ r : nonInheritances | selfRelationship [r]} = selfRelationships
#{ i : inheritances | selfRelationship [i]} = selfInheritances
no i : inheritances | not noDoubleRelationships [i]
noDoubleRelationships [inheritances]
no i : inheritances, a : nonInheritances |
sameDirection [i, a] or reverseRelationship [i, a]
hasDoubleRelationships = True
Expand Down
4 changes: 1 addition & 3 deletions test/Modelling/CdOd/GenerateSpec.hs
Original file line number Diff line number Diff line change
Expand Up @@ -96,12 +96,10 @@ spec =
hasReverseInheritances = False,
hasReverseRelationships = Just False
}
-- Disabled due to varying definitions of multiple inheritances:
{- generateProperty
generateProperty
"multipleInheritances"
(const $ not . null . multipleInheritances)
defaultProperties { hasMultipleInheritances = Just True }
-}
generateProperty
"no multipleInheritances"
(const $ null . multipleInheritances)
Expand Down

0 comments on commit 9f37695

Please sign in to comment.