oxc-parser 0.71.0 → 0.72.0

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/README.md CHANGED
@@ -20,6 +20,9 @@ The only differences between Oxc's AST and ESTree / TS-ESTree are:
20
20
 
21
21
  - Support for Stage 3 ECMA features [`import defer`](https://github.com/tc39/proposal-defer-import-eval)
22
22
  and [`import source`](https://github.com/tc39/proposal-source-phase-imports).
23
+ - In TS-ESTree AST, `import.defer(...)` and `import.source(...)` are represented as an `ImportExpression`
24
+ with `'defer'` or `'source'` in `phase` field (as in ESTree spec), where TS-ESLint represents these
25
+ as a `CallExpression` with `MetaProperty` as its `callee`.
23
26
  - Addition of a non-standard `hashbang` field to `Program`.
24
27
 
25
28
  That aside, the AST should completely align with Acorn's ESTree AST or TS-ESLint's TS-ESTree.
@@ -1057,6 +1057,7 @@ function deserializeImportExpression(pos) {
1057
1057
  end: deserializeU32(pos + 4),
1058
1058
  source: deserializeExpression(pos + 8),
1059
1059
  options: deserializeOptionExpression(pos + 24),
1060
+ phase: deserializeOptionImportPhase(pos + 40),
1060
1061
  };
1061
1062
  }
1062
1063
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "oxc-parser",
3
- "version": "0.71.0",
3
+ "version": "0.72.0",
4
4
  "main": "index.js",
5
5
  "browser": "wasm.mjs",
6
6
  "engines": {
@@ -39,7 +39,7 @@
39
39
  "access": "public"
40
40
  },
41
41
  "dependencies": {
42
- "@oxc-project/types": "^0.71.0"
42
+ "@oxc-project/types": "^0.72.0"
43
43
  },
44
44
  "devDependencies": {
45
45
  "@codspeed/vitest-plugin": "^4.0.0",
@@ -77,23 +77,23 @@
77
77
  "dtsHeaderFile": "header.js"
78
78
  },
79
79
  "optionalDependencies": {
80
- "@oxc-parser/binding-win32-x64-msvc": "0.71.0",
81
- "@oxc-parser/binding-win32-arm64-msvc": "0.71.0",
82
- "@oxc-parser/binding-linux-x64-gnu": "0.71.0",
83
- "@oxc-parser/binding-linux-x64-musl": "0.71.0",
84
- "@oxc-parser/binding-freebsd-x64": "0.71.0",
85
- "@oxc-parser/binding-linux-arm64-gnu": "0.71.0",
86
- "@oxc-parser/binding-linux-arm64-musl": "0.71.0",
87
- "@oxc-parser/binding-linux-arm-gnueabihf": "0.71.0",
88
- "@oxc-parser/binding-linux-arm-musleabihf": "0.71.0",
89
- "@oxc-parser/binding-linux-s390x-gnu": "0.71.0",
90
- "@oxc-parser/binding-linux-riscv64-gnu": "0.71.0",
91
- "@oxc-parser/binding-darwin-x64": "0.71.0",
92
- "@oxc-parser/binding-darwin-arm64": "0.71.0",
93
- "@oxc-parser/binding-wasm32-wasi": "0.71.0"
80
+ "@oxc-parser/binding-win32-x64-msvc": "0.72.0",
81
+ "@oxc-parser/binding-win32-arm64-msvc": "0.72.0",
82
+ "@oxc-parser/binding-linux-x64-gnu": "0.72.0",
83
+ "@oxc-parser/binding-linux-x64-musl": "0.72.0",
84
+ "@oxc-parser/binding-freebsd-x64": "0.72.0",
85
+ "@oxc-parser/binding-linux-arm64-gnu": "0.72.0",
86
+ "@oxc-parser/binding-linux-arm64-musl": "0.72.0",
87
+ "@oxc-parser/binding-linux-arm-gnueabihf": "0.72.0",
88
+ "@oxc-parser/binding-linux-arm-musleabihf": "0.72.0",
89
+ "@oxc-parser/binding-linux-s390x-gnu": "0.72.0",
90
+ "@oxc-parser/binding-linux-riscv64-gnu": "0.72.0",
91
+ "@oxc-parser/binding-darwin-x64": "0.72.0",
92
+ "@oxc-parser/binding-darwin-arm64": "0.72.0",
93
+ "@oxc-parser/binding-wasm32-wasi": "0.72.0"
94
94
  },
95
95
  "scripts": {
96
- "build-dev": "napi build --no-dts-cache --platform --js bindings.js",
96
+ "build-dev": "napi build --platform --js bindings.js",
97
97
  "build": "pnpm run build-dev --features allocator --release",
98
98
  "postbuild-dev": "node patch.mjs",
99
99
  "build-wasi": "pnpm run build-dev --release --target wasm32-wasip1-threads",