Skip to content

Commit 167c586

Browse files
authored
make Js.Json.t use Boolean(bool) instead of explicit true/false (#6421)
* make Js.Json.t use Boolean(bool) instead of explicit true/false * changelog * move changelog entry to breaking changes
1 parent b8c4157 commit 167c586

File tree

3 files changed

+3
-4
lines changed

3 files changed

+3
-4
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@
2929

3030
#### :boom: Breaking Change
3131
- Add smart printer for pipe-chains. https://github.com/rescript-lang/rescript-compiler/pull/6411 (the formatter will reformat existing code in certain cases)
32+
- `Js.Json.t` now uses `Boolean(bool)` instead of explicit `@as(true) True | @as(false) False`. https://github.com/rescript-lang/rescript-compiler/pull/6421
3233

3334
#### :nail_care: Polish
3435

jscomp/others/js_json.res

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,7 @@
2626

2727
@unboxed
2828
type rec t =
29-
| @as(false) False
30-
| @as(true) True
29+
| Boolean(bool)
3130
| @as(null) Null
3231
| String(string)
3332
| Number(float)

jscomp/others/js_json.resi

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,7 @@
3232

3333
@unboxed /** The JSON data structure */
3434
type rec t =
35-
| @as(false) False
36-
| @as(true) True
35+
| Boolean(bool)
3736
| @as(null) Null
3837
| String(string)
3938
| Number(float)

0 commit comments

Comments
 (0)