Skip to content

Commit 85858a0

Browse files
committed
update modules docs
1 parent 1c9f0f6 commit 85858a0

File tree

1 file changed

+111
-4
lines changed

1 file changed

+111
-4
lines changed

MODULES.md

Lines changed: 111 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ The `Eff` type for a computation which has asynchronous effects.
2121
#### `Aff`
2222

2323
``` purescript
24-
data Aff e a
24+
newtype Aff e a
2525
```
2626

2727
A computation with effects `e`. The computation either errors or
@@ -88,6 +88,14 @@ attempt :: forall e a. Aff e a -> Aff e (Either Error a)
8888

8989
Promotes any error to the value level of the asynchronous monad.
9090

91+
#### `apathize`
92+
93+
``` purescript
94+
apathize :: forall e a. Aff e a -> Aff e Unit
95+
```
96+
97+
Ignores any errors.
98+
9199
#### `liftEff'`
92100

93101
``` purescript
@@ -208,8 +216,91 @@ instance monadAffAff :: MonadAff e (Aff e)
208216

209217

210218

219+
## Module Control.Monad.Aff.Par
220+
221+
#### `Par`
222+
223+
``` purescript
224+
newtype Par e a
225+
= Par (AffVar e a)
226+
```
227+
228+
229+
#### `runPar`
230+
231+
``` purescript
232+
runPar :: forall e a. Par e a -> AffVar e a
233+
```
234+
235+
Extracts the `Aff` from the `Par`.
236+
237+
#### `semigroupPar`
238+
239+
``` purescript
240+
instance semigroupPar :: (Semigroup a) => Semigroup (Par e a)
241+
```
242+
243+
244+
#### `monoidPar`
245+
246+
``` purescript
247+
instance monoidPar :: (Monoid a) => Monoid (Par e a)
248+
```
249+
250+
251+
#### `functorPar`
252+
253+
``` purescript
254+
instance functorPar :: Functor (Par e)
255+
```
256+
257+
258+
#### `applyPar`
259+
260+
``` purescript
261+
instance applyPar :: Apply (Par e)
262+
```
263+
264+
265+
#### `applicativePar`
266+
267+
``` purescript
268+
instance applicativePar :: Applicative (Par e)
269+
```
270+
271+
272+
#### `altPar`
273+
274+
``` purescript
275+
instance altPar :: Alt (Par e)
276+
```
277+
278+
Returns the first value, or the first error if both error.
279+
280+
#### `plusPar`
281+
282+
``` purescript
283+
instance plusPar :: Plus (Par e)
284+
```
285+
286+
287+
#### `alternativePar`
288+
289+
``` purescript
290+
instance alternativePar :: Alternative (Par e)
291+
```
292+
293+
294+
211295
## Module Control.Monad.Aff.Unsafe
212296

297+
#### `unsafeTrace`
298+
299+
``` purescript
300+
unsafeTrace :: forall e a. a -> Aff e Unit
301+
```
302+
303+
213304
#### `unsafeInterleaveAff`
214305

215306
``` purescript
@@ -220,10 +311,10 @@ unsafeInterleaveAff :: forall e1 e2 a. Aff e1 a -> Aff e2 a
220311

221312
## Module Control.Monad.Aff.Var
222313

223-
#### `VarF`
314+
#### `VarFx`
224315

225316
``` purescript
226-
data VarF :: !
317+
data VarFx :: !
227318
```
228319

229320

@@ -237,7 +328,7 @@ data Var :: * -> *
237328
#### `AffVar`
238329

239330
``` purescript
240-
type AffVar e a = Aff (var :: VarF | e) a
331+
type AffVar e a = Aff (var :: VarFx | e) a
241332
```
242333

243334

@@ -249,6 +340,14 @@ makeVar :: forall e a. AffVar e (Var a)
249340

250341
Makes a new asynchronous variable.
251342

343+
#### `makeVar'`
344+
345+
``` purescript
346+
makeVar' :: forall e a. a -> AffVar e (Var a)
347+
```
348+
349+
Makes a variable and sets it to some value.
350+
252351
#### `takeVar`
253352

254353
``` purescript
@@ -266,6 +365,14 @@ putVar :: forall e a. Var a -> a -> AffVar e Unit
266365
Puts a new value into the asynchronous variable. If the variable has
267366
been killed, this will result in an error.
268367

368+
#### `modifyVar`
369+
370+
``` purescript
371+
modifyVar :: forall e a. (a -> a) -> Var a -> AffVar e Unit
372+
```
373+
374+
Modifies an asynchronous variable.
375+
269376
#### `killVar`
270377

271378
``` purescript

0 commit comments

Comments
 (0)