@greenlabs/ppx-spice 0.2.8 → 0.2.9
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +5 -0
- package/README.md +7 -5
- package/package.json +1 -1
- package/ppx-osx.exe +0 -0
- package/ppx-windows.exe +0 -0
- package/src/rescript/Spice.res +5 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,10 @@
|
|
|
1
1
|
# CHANGELOG
|
|
2
2
|
|
|
3
|
+
## 0.2.9
|
|
4
|
+
|
|
5
|
+
- Update test project for compiler v12. https://github.com/green-labs/ppx_spice/pull/94
|
|
6
|
+
- Fix bigint codec on rescript v12. https://github.com/green-labs/ppx_spice/pull/93
|
|
7
|
+
|
|
3
8
|
## 0.2.8
|
|
4
9
|
|
|
5
10
|
- Dropped support for curried mode in accordance with compiler v12 changes.
|
package/README.md
CHANGED
|
@@ -128,11 +128,13 @@ Read our [Guide with examples](docs/GUIDE.md)
|
|
|
128
128
|
|
|
129
129
|
### Compatibility on the compiler versions
|
|
130
130
|
|
|
131
|
-
| Compiler
|
|
132
|
-
|
|
|
133
|
-
| v12
|
|
134
|
-
|
|
|
135
|
-
|
|
|
131
|
+
| Compiler | Ppx_spice | Note |
|
|
132
|
+
| ------------- | --------------------- | ----------------------------- |
|
|
133
|
+
| v12-alpha.14 | v0.2.9 >= | Bigint.fromFloat type changed |
|
|
134
|
+
| v12-alpha.5 | v0.2.8 | Curried mode deprecated |
|
|
135
|
+
| v12-alpha.4 | v0.2.7 >= && > v0.2.2 | |
|
|
136
|
+
| v11 | v0.2.2 >= && > v0.2.0 | |
|
|
137
|
+
| v10 | v0.2.0 >= | |
|
|
136
138
|
|
|
137
139
|
NOTE: Starting from v0.2.8, support for curried mode is discontinued to align with the changes in compiler v12.
|
|
138
140
|
|
package/package.json
CHANGED
package/ppx-osx.exe
CHANGED
|
Binary file
|
package/ppx-windows.exe
CHANGED
|
Binary file
|
package/src/rescript/Spice.res
CHANGED
|
@@ -39,7 +39,11 @@ let bigintToJson = (i): Js.Json.t => Js.Json.Number(BigInt.toFloat(i))
|
|
|
39
39
|
|
|
40
40
|
let bigintFromJson = j =>
|
|
41
41
|
switch (j: Js.Json.t) {
|
|
42
|
-
| Js.Json.Number(n) =>
|
|
42
|
+
| Js.Json.Number(n) =>
|
|
43
|
+
switch BigInt.fromFloat(n) {
|
|
44
|
+
| Some(v) => v->Ok
|
|
45
|
+
| None => error("Not a bigint", j)
|
|
46
|
+
}
|
|
43
47
|
| _ => error("Not a number", j)
|
|
44
48
|
}
|
|
45
49
|
|