From d2d59e96beb9894d8fb762d4488984955db2925b Mon Sep 17 00:00:00 2001 From: Christoph Knittel Date: Fri, 21 Apr 2023 07:44:24 +0200 Subject: [PATCH 1/3] Make "rescript format" work with node 10 again --- scripts/rescript_format.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/rescript_format.js b/scripts/rescript_format.js index c22bd39b7b..939f8d4274 100644 --- a/scripts/rescript_format.js +++ b/scripts/rescript_format.js @@ -5,7 +5,7 @@ var format_usage = `Usage: rescript format [files] \`rescript format\` formats the current directory `; var child_process = require("child_process"); -var util = require("node:util"); +var util = require("util"); var asyncExecFile = util.promisify(child_process.execFile); var path = require("path"); var fs = require("fs"); From 884162573903ca73c3367f9638f65eb4f231ede7 Mon Sep 17 00:00:00 2001 From: Christoph Knittel Date: Fri, 21 Apr 2023 07:49:41 +0200 Subject: [PATCH 2/3] Add engines field to package.json --- package.json | 3 +++ 1 file changed, 3 insertions(+) diff --git a/package.json b/package.json index 843f7d283b..60644f9490 100644 --- a/package.json +++ b/package.json @@ -7,6 +7,9 @@ "prettier": "^2.7.1", "rollup": "^0.49.2" }, + "engines": { + "node": ">=10" + }, "bin": { "bsc": "bsc", "bstracing": "lib/bstracing", From 041fe8d2e1e35d8d837937622c0aa15631c248f7 Mon Sep 17 00:00:00 2001 From: Christoph Knittel Date: Fri, 21 Apr 2023 07:59:16 +0200 Subject: [PATCH 3/3] Update CHANGELOG --- CHANGELOG.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 60b4fe053a..7701c44994 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -16,6 +16,10 @@ - Parse `assert` as a regular function. `assert` is no longer a unary expression. Example: before `assert 1 == 2` is parsed as `(assert 1) == 2`, now it is parsed as `assert(1 == 2)`. https://github.com/rescript-lang/rescript-compiler/pull/6180 +#### :bug: Bug Fix + +- Make "rescript format" work with node 10 again and set minimum required node version to 10 in package.json. https://github.com/rescript-lang/rescript-compiler/pull/6186 + # 11.0.0-alpha.4 #### :rocket: Main New Feature