CurryInfo: spicey-4.2.0 / Spicey.GenerationHelper.manyToMany

definition:
manyToMany :: [Entity] -> Entity -> [(String,String)]
manyToMany entities forEntity =
  map (getOtherREnd forEntity)
      (filter (\ (Entity ename attr) -> isGenerated (Entity ename attr) &&
                                        isRelevantForEntity forEntity attr)
              entities)
 where
  getOtherREnd (Entity ename _)
               (Entity mmename [(Attribute _ (KeyDom name1) _ _),
                                (Attribute _ (KeyDom name2) _ _)]) =
    (if name1 == ename then name2 else name1, mmename)
demand:
argument 1
deterministic:
deterministic operation
documentation:
--- Returns for a given entity the many-to-many related entity names
--- together with the relation name.
failfree:
<FAILING>
indeterministic:
referentially transparent operation
infix:
no fixity defined
iotype:
{(_,_) |-> {:,[]}}
name:
manyToMany
precedence:
no precedence defined
result-values:
{:,[]}
signature:
[Database.ERD.Entity] -> Database.ERD.Entity -> [(String, String)]
solution-complete:
operation might suspend on free variables
terminating:
possibly non-terminating
totally-defined:
possibly non-reducible on same data term