Skip to content

Commit fee9cd5

Browse files
committed
Use ReScript v12 beta
1 parent 534f957 commit fee9cd5

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

69 files changed

+4288
-4798
lines changed

docs/rescript-usage.md

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -68,9 +68,6 @@
6868
- [`noValidation`](#noValidation)
6969

7070
- [Error handling](#error-handling)
71-
- [`Error.make`](#errormake)
72-
- [`Error.raise`](#errorraise)
73-
- [`Error.message`](#errormessage)
7471
- [Global config](#global-config)
7572
- [`defaultAdditionalItems`](#defaultAdditionalItems)
7673
- [`disableNanNumberValidation`](#disablenannumbervalidation)
@@ -1311,7 +1308,7 @@ For some cases you might want to simply assert the input value is valid. For thi
13111308
| --------------- | --------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------- |
13121309
| S.assertOrThrow | `('any, S.t<'value>) => ()` | Asserts that the input value is valid. Since the operation doesn't return a value, it's 2-3 times faster than `parseOrThrow` depending on the schema |
13131310

1314-
All operations either return the output value or raise an exception which you can catch with `try/catch` block:
1311+
All operations either return the output value or throw an exception which you can catch with `try/catch` block:
13151312

13161313
```rescript
13171314
try true->S.parseOrThrow(schema) catch {

packages/e2e/package.json

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@
44
"private": true,
55
"type": "module",
66
"scripts": {
7-
"res": "rescript -w",
8-
"test": "rescript && ava",
7+
"res": "rescript watch --dev",
8+
"test": "rescript --dev && ava",
99
"ppx:install": "node ../sury-ppx/install.cjs",
1010
"ppx:build": "cd ../sury-ppx/src && dune build",
1111
"benchmark": "node ./src/benchmark/Benchmark.res.mjs",
@@ -17,8 +17,7 @@
1717
]
1818
},
1919
"dependencies": {
20-
"rescript": "11.1.0",
21-
"@rescript/core": "1.3.0",
20+
"rescript": "12.0.0-beta.5",
2221
"@dzakh/rescript-ava": "3.1.0",
2322
"ava": "5.2.0",
2423
"benchmark": "2.1.4",

packages/e2e/rescript.json

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -12,13 +12,11 @@
1212
"in-source": true
1313
},
1414
"suffix": ".res.mjs",
15-
"bs-dependencies": ["sury"],
16-
"bs-dev-dependencies": ["@rescript/core", "@dzakh/rescript-ava"],
17-
"ppx-flags": ["../sury-ppx/bin"],
18-
"warnings": {
19-
"error": true,
20-
"number": "-48-44"
21-
},
15+
"dependencies": ["sury"],
16+
"dev-dependencies": ["@dzakh/rescript-ava"],
17+
"ppx-flags": [
18+
"/Users/dzakh/code/DZakh/rescript-schema/packages/sury-ppx/bin"
19+
],
2220
"gentypeconfig": {
2321
"generatedFileExtension": ".gen.ts"
2422
}

packages/e2e/src/benchmark/Benchmark.res

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,3 @@
1-
open RescriptCore
2-
31
module Suite = {
42
module BenchmarkResult = {
53
type t

0 commit comments

Comments
 (0)