Skip to content

Commit 597ac01

Browse files
committed
Updates for 0.7
1 parent 145360e commit 597ac01

File tree

10 files changed

+80
-464
lines changed

10 files changed

+80
-464
lines changed

bower.json

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,11 +6,16 @@
66
"purescript"
77
],
88
"license": "MIT",
9+
"repository": {
10+
"type": "git",
11+
"url": "git://github.com/purescript/purescript-maybe.git"
12+
},
913
"ignore": [
1014
"**/.*",
1115
"bower_components",
1216
"node_modules",
1317
"output",
18+
"test",
1419
"bower.json",
1520
"gulpfile.js",
1621
"package.json"

docs/Data.Maybe.First.md

Lines changed: 10 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
# Module Documentation
2-
31
## Module Data.Maybe.First
42

53
#### `First`
@@ -9,112 +7,36 @@ newtype First a
97
= First (Maybe a)
108
```
119

12-
Monoid returning the first (left-most) non-`Nothing` value.
13-
14-
``` purescript
15-
First (Just x) <> First (Just y) == First (Just x)
16-
First Nothing <> First (Just y) == First (Just y)
17-
First Nothing <> Nothing == First Nothing
18-
mempty :: First _ == First Nothing
19-
```
20-
21-
#### `runFirst`
22-
23-
``` purescript
24-
runFirst :: forall a. First a -> Maybe a
25-
```
26-
27-
28-
#### `eqFirst`
29-
10+
##### Instances
3011
``` purescript
3112
instance eqFirst :: (Eq a) => Eq (First a)
32-
```
33-
34-
35-
#### `ordFirst`
36-
37-
``` purescript
3813
instance ordFirst :: (Ord a) => Ord (First a)
39-
```
40-
41-
42-
#### `boundedFirst`
43-
44-
``` purescript
4514
instance boundedFirst :: (Bounded a) => Bounded (First a)
46-
```
47-
48-
49-
#### `functorFirst`
50-
51-
``` purescript
5215
instance functorFirst :: Functor First
53-
```
54-
55-
56-
#### `applyFirst`
57-
58-
``` purescript
5916
instance applyFirst :: Apply First
60-
```
61-
62-
63-
#### `applicativeFirst`
64-
65-
``` purescript
6617
instance applicativeFirst :: Applicative First
67-
```
68-
69-
70-
#### `bindFirst`
71-
72-
``` purescript
7318
instance bindFirst :: Bind First
74-
```
75-
76-
77-
#### `monadFirst`
78-
79-
``` purescript
8019
instance monadFirst :: Monad First
81-
```
82-
83-
84-
#### `extendFirst`
85-
86-
``` purescript
8720
instance extendFirst :: Extend First
88-
```
89-
90-
91-
#### `invariantFirst`
92-
93-
``` purescript
9421
instance invariantFirst :: Invariant First
95-
```
96-
97-
98-
#### `showFirst`
99-
100-
``` purescript
10122
instance showFirst :: (Show a) => Show (First a)
23+
instance semigroupFirst :: Semigroup (First a)
24+
instance monoidFirst :: Monoid (First a)
10225
```
10326

104-
105-
#### `semigroupFirst`
27+
Monoid returning the first (left-most) non-`Nothing` value.
10628

10729
``` purescript
108-
instance semigroupFirst :: Semigroup (First a)
30+
First (Just x) <> First (Just y) == First (Just x)
31+
First Nothing <> First (Just y) == First (Just y)
32+
First Nothing <> Nothing == First Nothing
33+
mempty :: First _ == First Nothing
10934
```
11035

111-
112-
#### `monoidFirst`
36+
#### `runFirst`
11337

11438
``` purescript
115-
instance monoidFirst :: Monoid (First a)
39+
runFirst :: forall a. First a -> Maybe a
11640
```
11741

11842

119-
120-

docs/Data.Maybe.Last.md

Lines changed: 10 additions & 88 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
# Module Documentation
2-
31
## Module Data.Maybe.Last
42

53
#### `Last`
@@ -9,112 +7,36 @@ newtype Last a
97
= Last (Maybe a)
108
```
119

12-
Monoid returning the last (right-most) non-`Nothing` value.
13-
14-
``` purescript
15-
Last (Just x) <> Last (Just y) == Last (Just y)
16-
Last (Just x) <> Nothing == Last (Just x)
17-
Last Nothing <> Nothing == Last Nothing
18-
mempty :: Last _ == Last Nothing
19-
```
20-
21-
#### `runLast`
22-
23-
``` purescript
24-
runLast :: forall a. Last a -> Maybe a
25-
```
26-
27-
28-
#### `eqLast`
29-
10+
##### Instances
3011
``` purescript
3112
instance eqLast :: (Eq a) => Eq (Last a)
32-
```
33-
34-
35-
#### `ordLast`
36-
37-
``` purescript
3813
instance ordLast :: (Ord a) => Ord (Last a)
39-
```
40-
41-
42-
#### `boundedLast`
43-
44-
``` purescript
4514
instance boundedLast :: (Bounded a) => Bounded (Last a)
46-
```
47-
48-
49-
#### `functorLast`
50-
51-
``` purescript
5215
instance functorLast :: Functor Last
53-
```
54-
55-
56-
#### `applyLast`
57-
58-
``` purescript
5916
instance applyLast :: Apply Last
60-
```
61-
62-
63-
#### `applicativeLast`
64-
65-
``` purescript
6617
instance applicativeLast :: Applicative Last
67-
```
68-
69-
70-
#### `bindLast`
71-
72-
``` purescript
7318
instance bindLast :: Bind Last
74-
```
75-
76-
77-
#### `monadLast`
78-
79-
``` purescript
8019
instance monadLast :: Monad Last
81-
```
82-
83-
84-
#### `extendLast`
85-
86-
``` purescript
8720
instance extendLast :: Extend Last
88-
```
89-
90-
91-
#### `invariantLast`
92-
93-
``` purescript
9421
instance invariantLast :: Invariant Last
95-
```
96-
97-
98-
#### `showLast`
99-
100-
``` purescript
10122
instance showLast :: (Show a) => Show (Last a)
23+
instance semigroupLast :: Semigroup (Last a)
24+
instance monoidLast :: Monoid (Last a)
10225
```
10326

104-
105-
#### `semigroupLast`
27+
Monoid returning the last (right-most) non-`Nothing` value.
10628

10729
``` purescript
108-
instance semigroupLast :: Semigroup (Last a)
30+
Last (Just x) <> Last (Just y) == Last (Just y)
31+
Last (Just x) <> Nothing == Last (Just x)
32+
Last Nothing <> Nothing == Last Nothing
33+
mempty :: Last _ == Last Nothing
10934
```
11035

111-
112-
#### `monoidLast`
36+
#### `runLast`
11337

11438
``` purescript
115-
instance monoidLast :: Monoid (Last a)
39+
runLast :: forall a. Last a -> Maybe a
11640
```
11741

11842

119-
120-

docs/Data.Maybe.Unsafe.md

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
# Module Documentation
2-
31
## Module Data.Maybe.Unsafe
42

53
#### `fromJust`
@@ -13,4 +11,3 @@ constructor. Passing `Nothing` to `fromJust` will throw an error at
1311
runtime.
1412

1513

16-

0 commit comments

Comments
 (0)