Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

webassemblyjs

Package Overview
Dependencies
Maintainers
1
Versions
96
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

webassemblyjs - npm Package Compare versions

Comparing version 1.2.6 to 1.2.7

5

lib/compiler/compile/module.js

@@ -11,4 +11,6 @@ "use strict";

var _validation = _interopRequireDefault(require("../validation"));
var _denormalizeTypeReferences = require("@webassemblyjs/ast/lib/transform/denormalize-type-references");
var _validation = _interopRequireDefault(require("@webassemblyjs/validation"));
function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; }

@@ -40,2 +42,3 @@

(0, _denormalizeTypeReferences.transform)(ast);
(0, _wastIdentifierToIndex.transform)(ast);

@@ -42,0 +45,0 @@ (0, _validation.default)(ast);

4

lib/interpreter/kernel/exec.js

@@ -1014,2 +1014,3 @@ "use strict";

case "i32":
case "u32":
pushResult(i32.createValueFromArrayBuffer(_memory.buffer, _ptr, extend, signed));

@@ -1029,2 +1030,5 @@ break;

break;
default:
throw new _errors.RuntimeError("Unsupported " + _object + " load");
}

@@ -1031,0 +1035,0 @@

@@ -8,6 +8,4 @@ "use strict";

var _isConst = require("../../../compiler/validation/is-const");
var _validation = require("@webassemblyjs/validation");
var _typeInference = require("../../../compiler/validation/type-inference");
var _require = require("../../partial-evaluation"),

@@ -25,3 +23,3 @@ evaluate = _require.evaluate;

if (node.init.length > 0 && (0, _isConst.isConst)(node.init) === false) {
if (node.init.length > 0 && (0, _validation.isConst)(node.init) === false) {
throw new CompileError("constant expression required");

@@ -38,5 +36,5 @@ } // None or multiple constant expressions in the initializer seems not possible

var resultInferedType = (0, _typeInference.getType)(node.init);
var resultInferedType = (0, _validation.getType)(node.init);
if (resultInferedType != null && (0, _typeInference.typeEq)([node.globalType.valtype], resultInferedType) === false) {
if (resultInferedType != null && (0, _validation.typeEq)([node.globalType.valtype], resultInferedType) === false) {
throw new CompileError("type mismatch");

@@ -43,0 +41,0 @@ }

{
"name": "webassemblyjs",
"version": "1.2.6",
"version": "1.2.7",
"keywords": [

@@ -21,9 +21,10 @@ "webassembly",

"dependencies": {
"@webassemblyjs/ast": "1.2.6",
"@webassemblyjs/wasm-parser": "1.2.6",
"@webassemblyjs/wast-parser": "1.2.6",
"@webassemblyjs/ast": "1.2.7",
"@webassemblyjs/validation": "1.2.7",
"@webassemblyjs/wasm-parser": "1.2.7",
"@webassemblyjs/wast-parser": "1.2.7",
"long": "^3.2.0"
},
"devDependencies": {
"@webassemblyjs/floating-point-hex-parser": "1.2.6"
"@webassemblyjs/floating-point-hex-parser": "1.2.7"
},

@@ -30,0 +31,0 @@ "repository": {

// @flow
import { transform } from "@webassemblyjs/ast/lib/transform/wast-identifier-to-index";
import { transform as wastIdentifierToIndex } from "@webassemblyjs/ast/lib/transform/wast-identifier-to-index";
import { transform as denormalizeTypeReferences } from "@webassemblyjs/ast/lib/transform/denormalize-type-references";
const t = require("@webassemblyjs/ast");
import validateAST from "../validation";
import validateAST from "@webassemblyjs/validation";
const { CompileError } = require("../../errors");

@@ -39,3 +40,4 @@

// semantics during execution
transform(ast);
denormalizeTypeReferences(ast);
wastIdentifierToIndex(ast);

@@ -42,0 +44,0 @@ validateAST(ast);

@@ -1011,2 +1011,3 @@ // @flow

case "i32":
case "u32":
pushResult(

@@ -1037,2 +1038,5 @@ i32.createValueFromArrayBuffer(

break;
default:
throw new RuntimeError("Unsupported " + object + " load");
}

@@ -1039,0 +1043,0 @@

// @flow
import { isConst } from "../../../compiler/validation/is-const";
import { getType, typeEq } from "../../../compiler/validation/type-inference";
import { isConst, getType, typeEq } from "@webassemblyjs/validation";

@@ -6,0 +5,0 @@ const { evaluate } = require("../../partial-evaluation");

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc