packages feed

purescript-0.13.0: tests/purs/publish/basic-example/output/Control.MonadZero/docs.json

{"reExports":[],"name":"Control.MonadZero","comments":null,"declarations":[{"children":[{"comments":null,"title":"monadZeroArray","info":{"declType":"instance","dependencies":[],"type":{"annotation":[],"tag":"TypeApp","contents":[{"annotation":[],"tag":"TypeConstructor","contents":[["Control","MonadZero"],"MonadZero"]},{"annotation":[],"tag":"TypeConstructor","contents":[["Prim"],"Array"]}]}},"sourceSpan":{"start":[34,1],"name":"../../../support/bower_components/purescript-control/src/Control/MonadZero.purs","end":[34,43]}}],"comments":"The `MonadZero` type class has no members of its own; it just specifies\nthat the type has both `Monad` and `Alternative` instances.\n\nTypes which have `MonadZero` instances should also satisfy the following\nlaws:\n\n- Annihilation: `empty >>= f = empty`\n","title":"MonadZero","info":{"fundeps":[],"arguments":[["m",null]],"declType":"typeClass","superclasses":[{"constraintAnn":[],"constraintClass":[["Control","Monad"],"Monad"],"constraintArgs":[{"annotation":[],"tag":"TypeVar","contents":"m"}],"constraintData":null},{"constraintAnn":[],"constraintClass":[["Control","Alternative"],"Alternative"],"constraintArgs":[{"annotation":[],"tag":"TypeVar","contents":"m"}],"constraintData":null}]},"sourceSpan":{"start":[32,1],"name":"../../../support/bower_components/purescript-control/src/Control/MonadZero.purs","end":[32,46]}},{"children":[],"comments":"Fail using `Plus` if a condition does not hold, or\nsucceed using `Monad` if it does.\n\nFor example:\n\n```purescript\nimport Prelude\nimport Control.Monad (bind)\nimport Control.MonadZero (guard)\nimport Data.Array ((..))\n\nfactors :: Int -> Array Int\nfactors n = do\n  a <- 1..n\n  b <- 1..n\n  guard $ a * b == n\n  pure a\n```\n","title":"guard","info":{"declType":"value","type":{"annotation":[],"tag":"ForAll","contents":["m",{"annotation":[],"tag":"ConstrainedType","contents":[{"constraintAnn":[],"constraintClass":[["Control","MonadZero"],"MonadZero"],"constraintArgs":[{"annotation":[],"tag":"TypeVar","contents":"m"}],"constraintData":null},{"annotation":[],"tag":"TypeApp","contents":[{"annotation":[],"tag":"TypeApp","contents":[{"annotation":[],"tag":"TypeConstructor","contents":[["Prim"],"Function"]},{"annotation":[],"tag":"TypeConstructor","contents":[["Prim"],"Boolean"]}]},{"annotation":[],"tag":"TypeApp","contents":[{"annotation":[],"tag":"TypeVar","contents":"m"},{"annotation":[],"tag":"TypeConstructor","contents":[["Data","Unit"],"Unit"]}]}]}]},null]}},"sourceSpan":{"start":[54,1],"name":"../../../support/bower_components/purescript-control/src/Control/MonadZero.purs","end":[54,52]}}]}