diff --git a/src/Control/Abstract/Analysis.hs b/src/Control/Abstract/Analysis.hs index 9b48bea9f..f5cc97f50 100644 --- a/src/Control/Abstract/Analysis.hs +++ b/src/Control/Abstract/Analysis.hs @@ -7,9 +7,9 @@ import Prologue -- -- This typeclass is left intentionally unconstrained to avoid circular dependencies between it and other typeclasses. class Monad m => MonadAnalysis term value m | m -> term, m -> value where - -- | Evaluate a term to a value using the semantics of the current analysis. This should always be used instead of explicitly folding 'eval' over subterms, except in 'MonadAnalysis' instances themselves. analyzeTerm :: SubtermAlgebra (Base term) term (m value) + -- | Evaluate a term to a value using the semantics of the current analysis. This should always be used instead of explicitly folding 'eval' over subterms, except in 'MonadAnalysis' instances themselves. evaluateTerm :: MonadAnalysis term value m => term -> m value default evaluateTerm :: (MonadAnalysis term value m, Recursive term) => term -> m value evaluateTerm = foldSubterms analyzeTerm