File tree Expand file tree Collapse file tree 8 files changed +16
-17
lines changed Expand file tree Collapse file tree 8 files changed +16
-17
lines changed Original file line number Diff line number Diff line change 13
13
"url" : " git://github.com/purescript-node/purescript-node-buffer"
14
14
},
15
15
"dependencies" : {
16
- "purescript-eff" : " ~0.1 .0" ,
17
- "purescript-maybe" : " ~0.3.1 "
16
+ "purescript-eff" : " ^1.0 .0" ,
17
+ "purescript-maybe" : " ^1.0.0 "
18
18
},
19
19
"devDependencies" : {
20
- "purescript-assert" : " ~0.1.1 " ,
21
- "purescript-console" : " ~0.1.1 " ,
22
- "purescript-foldable-traversable" : " ~0.4.1 "
20
+ "purescript-assert" : " ^1.0.0 " ,
21
+ "purescript-console" : " ^1.0.0 " ,
22
+ "purescript-foldable-traversable" : " ^1.0.0 "
23
23
}
24
24
}
Original file line number Diff line number Diff line change @@ -27,7 +27,7 @@ An instance of Node's Buffer class.
27
27
28
28
##### Instances
29
29
``` purescript
30
- instance showBuffer :: Show Buffer
30
+ Show Buffer
31
31
```
32
32
33
33
#### ` BUFFER `
@@ -62,7 +62,7 @@ Enumeration of the numeric types that can be written to a buffer.
62
62
63
63
##### Instances
64
64
``` purescript
65
- instance showBufferValueType :: Show BufferValueType
65
+ Show BufferValueType
66
66
```
67
67
68
68
#### ` create `
Original file line number Diff line number Diff line change 6
6
slice :: Offset -> Offset -> Buffer -> Buffer
7
7
```
8
8
9
+ Creates a new buffer slice that acts like a window on the original buffer.
10
+ Writing to the slice buffer updates the original buffer and vice-versa.
11
+ This is considered unsafe as writing to a slice can result in action at a
12
+ distance.
13
+
9
14
Original file line number Diff line number Diff line change @@ -15,7 +15,7 @@ data Encoding
15
15
16
16
##### Instances
17
17
``` purescript
18
- instance showEncoding :: Show Encoding
18
+ Show Encoding
19
19
```
20
20
21
21
#### ` byteLength `
Original file line number Diff line number Diff line change 3
3
/* global require */
4
4
"use strict" ;
5
5
6
- // module Node.Buffer
7
-
8
6
exports . showImpl = require ( 'util' ) . inspect ;
9
7
10
8
exports . create = function ( size ) {
Original file line number Diff line number Diff line change @@ -23,9 +23,9 @@ module Node.Buffer
23
23
) where
24
24
25
25
import Prelude
26
- import Control.Monad.Eff
27
- import Data.Maybe
28
- import Node.Encoding
26
+ import Control.Monad.Eff ( Eff )
27
+ import Data.Maybe ( Maybe (..))
28
+ import Node.Encoding ( Encoding )
29
29
30
30
-- | Type synonym indicating the value should be an octet (0-255). If the value
31
31
-- | provided is outside this range it will be used as modulo 255.
Original file line number Diff line number Diff line change 2
2
/* global Buffer */
3
3
"use strict" ;
4
4
5
- // module Node.Buffer.Unsafe
6
-
7
5
exports . slice = function ( start ) {
8
6
return function ( end ) {
9
7
return function ( buff ) {
Original file line number Diff line number Diff line change 2
2
/* global Buffer */
3
3
"use strict" ;
4
4
5
- // module Node.Encoding
6
-
7
5
exports . byteLengthImpl = function ( str ) {
8
6
return function ( enc ) {
9
7
return Buffer . byteLength ( str , enc ) ;
You can’t perform that action at this time.
0 commit comments