warpo 2.2.2 → 2.2.4

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
@@ -16,7 +16,7 @@ https://wasm-ecosystem.github.io/warpo/
16
16
 
17
17
  ## Acknowledgment
18
18
 
19
- - [Assemblyscript](https://www.assemblyscript.org/)
19
+ - [AssemblyScript](https://www.assemblyscript.org/)
20
20
  - [binaryen](https://github.com/WebAssembly/binaryen)
21
21
 
22
22
  ## for Developer
@@ -84,7 +84,7 @@ declare type stringview_iter = ref_stringview_iter | null;
84
84
 
85
85
  /** Compiler target. 0 = JS, 1 = WASM32, 2 = WASM64. */
86
86
  declare const ASC_TARGET: i32;
87
- /** Runtime type. 0 = Stub, 1 = Minimal, 2 = Incremental. */
87
+ /** Runtime type. 0 = Stub, 1 = Radical, 2 = Incremental. */
88
88
  declare const ASC_RUNTIME: i32;
89
89
  /** Provided noAssert option. */
90
90
  declare const ASC_NO_ASSERT: bool;
package/create/index.ts CHANGED
@@ -1,5 +1,5 @@
1
1
  import * as api from "./__warpo_create";
2
- import { __collect } from "rt/itcms";
2
+ import { __collect } from "rt/index";
3
3
 
4
4
  __collect(); // trigger GC to ensure the env is loaded.
5
5
  export const __dirname: string = api.getCreateFileDirName();
package/dist/lib.js CHANGED
@@ -6,8 +6,9 @@ const dirname = import.meta.dirname;
6
6
  function download_url(version) {
7
7
  const arch = os.arch();
8
8
  const platform = os.platform();
9
+ const base_url = process.env["WARPO_DOWNLOAD_BASE_URL"] ?? `https://github.com/wasm-ecosystem/warpo/releases/download`;
9
10
  if ((platform === "linux" && arch === "x64") || (platform === "darwin" && arch === "arm64")) {
10
- return `https://github.com/wasm-ecosystem/warpo/releases/download/${version}/warpo-${version}-${platform}-${arch}.tar.gz`;
11
+ return `${base_url}/${version}/warpo-${version}-${platform}-${arch}.tar.gz`;
11
12
  }
12
13
  console.log(`there is no precompiled binary for ${version} + ${platform} + ${arch}, please compile from source.`);
13
14
  process.exit(1);
package/dist/warpo.js CHANGED
File without changes
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "warpo",
3
- "version": "2.2.2",
3
+ "version": "2.2.4",
4
4
  "description": "next generation AssemblyScript compiler with optimizations",
5
5
  "type": "module",
6
6
  "bin": {
@@ -20,6 +20,7 @@
20
20
  "test:debug_symbol:update": "cross-env-shell build/tests/DebugSymbol/TestDebugSymbol --update-fixtures",
21
21
  "test:driver": "node tests/driver/index.mjs",
22
22
  "test": "npm run test:as:ut && npm run test:cpp:ut && npm run test:as:snapshot && npm run test:opt:snapshot && npm run test:driver && npm run test:debug_symbol && npm run test:bootstrap:debug && npm run test:bootstrap:release",
23
+ "test:update": "npm run test:as:snapshot -- -u && npm run test:opt:snapshot -- -u && npm run test:driver -- -u && npm run test:debug_symbol -- -u",
23
24
  "docs:dev": "vitepress dev docs",
24
25
  "docs:build": "vitepress build docs",
25
26
  "prettier": "prettier --check .",
@@ -1,6 +1,10 @@
1
1
  /// <reference path="../../assemblyscript/std/assembly/index.d.ts" />
2
2
 
3
- declare namespace utf8 {
3
+ declare module "rt/index" {
4
+ export function __collect(): void;
5
+ }
6
+
7
+ declare module "warpo/utf8/const_str" {
4
8
  class ConstStr {
5
9
  toString(): string;
6
10
  get addr(): usize;
@@ -8,7 +12,3 @@ declare namespace utf8 {
8
12
  }
9
13
  function build(s: string): ConstStr;
10
14
  }
11
-
12
- declare module "rt/itcms" {
13
- export function __collect(): void;
14
- }