@@ -59,7 +59,7 @@ type PutM = WriterT Builder
59
59
type Put = PutM Effect
60
60
61
61
-- | Build an `ArrayBuffer` with do-notation in any `MonadEffect`. *O(n)*
62
- execPutM :: forall m . ( MonadEffect m ) => PutM m Unit -> m ArrayBuffer
62
+ execPutM :: forall m . MonadEffect m => PutM m Unit -> m ArrayBuffer
63
63
execPutM = Internal .execBuilder <=< execWriterT
64
64
65
65
-- | Build an `ArrayBuffer` with do-notation in `Effect`. *O(n)*
@@ -84,73 +84,73 @@ execPut = execPutM
84
84
-- | putInt32be $ length messageBuilder
85
85
-- | tell messageBuilder
86
86
-- | ```
87
- subBuilder :: forall m . ( MonadEffect m ) => PutM m Unit -> PutM m Builder
87
+ subBuilder :: forall m . Monad m => PutM m Unit -> PutM m Builder
88
88
subBuilder = lift <<< execWriterT
89
89
90
90
-- | Append an `ArrayBuffer` to the builder.
91
- putArrayBuffer :: forall m . ( MonadEffect m ) => ArrayBuffer -> PutM m Unit
91
+ putArrayBuffer :: forall m . Monad m => ArrayBuffer -> PutM m Unit
92
92
putArrayBuffer = tell <<< Internal .singleton <<< Internal.Buff
93
93
94
94
-- | Append a `DataView` to the builder.
95
- putDataView :: forall m . ( MonadEffect m ) => DataView -> PutM m Unit
95
+ putDataView :: forall m . Monad m => DataView -> PutM m Unit
96
96
putDataView = tell <<< Internal .singleton <<< Internal.View
97
97
98
98
-- | Append either an `ArrayBuffer` or a `DataView` to the builder.
99
- putDataBuff :: forall m . ( MonadEffect m ) => DataBuff -> PutM m Unit
99
+ putDataBuff :: forall m . Monad m => DataBuff -> PutM m Unit
100
100
putDataBuff = tell <<< Internal .singleton
101
101
102
102
-- | Append an 8-bit unsigned integer (byte) to the builder.
103
- putUint8 :: forall m . ( MonadEffect m ) => UInt -> PutM m Unit
103
+ putUint8 :: forall m . MonadEffect m => UInt -> PutM m Unit
104
104
putUint8 = putArrayBuffer <=< Internal .encodeUint8
105
105
106
106
-- | Append an 8-bit two’s-complement signed integer (char) to the builder.
107
- putInt8 :: forall m . ( MonadEffect m ) => Int -> PutM m Unit
107
+ putInt8 :: forall m . MonadEffect m => Int -> PutM m Unit
108
108
putInt8 = putArrayBuffer <=< Internal .encodeInt8
109
109
110
110
-- | Append a 16-bit big-endian unsigned integer to the builder.
111
- putUint16be :: forall m . ( MonadEffect m ) => UInt -> PutM m Unit
111
+ putUint16be :: forall m . MonadEffect m => UInt -> PutM m Unit
112
112
putUint16be = putArrayBuffer <=< Internal .encodeUint16be
113
113
114
114
-- | Append a 16-bit little-endian unsigned integer to the builder.
115
- putUint16le :: forall m . ( MonadEffect m ) => UInt -> PutM m Unit
115
+ putUint16le :: forall m . MonadEffect m => UInt -> PutM m Unit
116
116
putUint16le = putArrayBuffer <=< Internal .encodeUint16le
117
117
118
118
-- | Append a 16-bit big-endian two’s-complement signed integer to the builder.
119
- putInt16be :: forall m . ( MonadEffect m ) => Int -> PutM m Unit
119
+ putInt16be :: forall m . MonadEffect m => Int -> PutM m Unit
120
120
putInt16be = putArrayBuffer <=< Internal .encodeInt16be
121
121
122
122
-- | Append a 16-bit little-endian two’s-complement signed integer to the builder.
123
- putInt16le :: forall m . ( MonadEffect m ) => Int -> PutM m Unit
123
+ putInt16le :: forall m . MonadEffect m => Int -> PutM m Unit
124
124
putInt16le = putArrayBuffer <=< Internal .encodeInt16le
125
125
126
126
-- | Append a 32-bit big-endian unsigned integer to the builder.
127
- putUint32be :: forall m . ( MonadEffect m ) => UInt -> PutM m Unit
127
+ putUint32be :: forall m . MonadEffect m => UInt -> PutM m Unit
128
128
putUint32be = putArrayBuffer <=< Internal .encodeUint32be
129
129
130
130
-- | Append a 32-bit little-endian unsigned integer to the builder.
131
- putUint32le :: forall m . ( MonadEffect m ) => UInt -> PutM m Unit
131
+ putUint32le :: forall m . MonadEffect m => UInt -> PutM m Unit
132
132
putUint32le = putArrayBuffer <=< Internal .encodeUint32le
133
133
134
134
-- | Append a 32-bit big-endian two’s-complement signed integer to the builder.
135
- putInt32be :: forall m . ( MonadEffect m ) => Int -> PutM m Unit
135
+ putInt32be :: forall m . MonadEffect m => Int -> PutM m Unit
136
136
putInt32be = putArrayBuffer <=< Internal .encodeInt32be
137
137
138
138
-- | Append a 32-bit little-endian two’s-complement signed integer to the builder.
139
- putInt32le :: forall m . ( MonadEffect m ) => Int -> PutM m Unit
139
+ putInt32le :: forall m . MonadEffect m => Int -> PutM m Unit
140
140
putInt32le = putArrayBuffer <=< Internal .encodeInt32le
141
141
142
142
-- | Append a 32-bit big-endian IEEE single-precision float to the builder.
143
- putFloat32be :: forall m . ( MonadEffect m ) => Float32 -> PutM m Unit
143
+ putFloat32be :: forall m . MonadEffect m => Float32 -> PutM m Unit
144
144
putFloat32be = putArrayBuffer <=< Internal .encodeFloat32be
145
145
146
146
-- | Append a 32-bit little-endian IEEE single-precision float to the builder.
147
- putFloat32le :: forall m . ( MonadEffect m ) => Float32 -> PutM m Unit
147
+ putFloat32le :: forall m . MonadEffect m => Float32 -> PutM m Unit
148
148
putFloat32le = putArrayBuffer <=< Internal .encodeFloat32le
149
149
150
150
-- | Append a 64-bit big-endian IEEE double-precision float to the builder.
151
- putFloat64be :: forall m . ( MonadEffect m ) => Number -> PutM m Unit
151
+ putFloat64be :: forall m . MonadEffect m => Number -> PutM m Unit
152
152
putFloat64be = putArrayBuffer <=< Internal .encodeFloat64be
153
153
154
154
-- | Append a 64-bit little-endian IEEE double-precision float to the builder.
155
- putFloat64le :: forall m . ( MonadEffect m ) => Number -> PutM m Unit
155
+ putFloat64le :: forall m . MonadEffect m => Number -> PutM m Unit
156
156
putFloat64le = putArrayBuffer <=< Internal .encodeFloat64le
0 commit comments