/* Copyright 2021 Mozilla Foundation * *LicensedundertheApacheLicense,Version2.0(the"License"); *youmaynotusethisfileexceptincompliancewiththeLicense. *YoumayobtainacopyoftheLicenseat * *http://www.apache.org/licenses/LICENSE-2.0 * *Unlessrequiredbyapplicablelaworagreedtoinwriting,software *distributedundertheLicenseisdistributedonan"ASIS"BASIS, *WITHOUTWARRANTIESORCONDITIONSOFANYKIND,eitherexpressorimplied. *SeetheLicenseforthespecificlanguagegoverningpermissionsand *limitationsundertheLicense.
*/
// ./test/core/multi-memory/binary0.wast
// ./test/core/multi-memory/binary0.wast:2
let $0 = instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\07\\02" ;; Memory section with 2 entries "\\00\\82\\00" ;; no max, minimum 2 "\\00\\82\\00" ;; no max, minimum 2
)`);
// ./test/core/multi-memory/binary0.wast:8
let $1 = instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\13\\03" ;; Memory section with 3 entries "\\00\\83\\80\\80\\80\\00" ;; no max, minimum 3 "\\00\\84\\80\\80\\80\\00" ;; no max, minimum 4 "\\00\\85\\80\\80\\80\\00" ;; no max, minimum 5
)`);
// ./test/core/multi-memory/binary0.wast:16
let $2 = instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\05\\02" ;; Memory section with 2 entries "\\00\\00" ;; no max, minimum 0 "\\00\\00" ;; no max, minimum 0 "\\0b\\06\\01" ;; Data section with 1 entry "\\00" ;; Memory index 0 "\\41\\00\\0b\\00" ;; (i32.const0) with contents ""
)`);
// ./test/core/multi-memory/binary0.wast:26
let $3 = instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\05\\02" ;; Memory section with 2 entries "\\00\\00" ;; no max, minimum 0 "\\00\\01" ;; no max, minimum 1 "\\0b\\07\\01" ;; Data section with 1 entry "\\02\\01" ;; Memory index 1 "\\41\\00\\0b\\00" ;; (i32.const0) with contents ""
)`);
// ./test/core/multi-memory/binary0.wast:36
let $4 = instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\05\\02" ;; Memory section with 2 entries "\\00\\00" ;; no max, minimum 0 "\\00\\01" ;; no max, minimum 1 "\\0b\\0a\\01" ;; Data section with 1 entry "\\02\\81\\80\\80\\00" ;; Memory index 1 "\\41\\00\\0b\\00" ;; (i32.const0) with contents ""
)`);
// ./test/core/multi-memory/binary0.wast:47
assert_malformed(
() => instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\0a\\02" ;; Memory section with 2 entries "\\00\\01" ;; no max, minimum 1 "\\00\\82\\80\\80\\80\\80\\00" ;; no max, minimum 2 with one byte too many
)`),
`integer representation too long`,
);
// ./test/core/multi-memory/binary0.wast:58
assert_malformed(
() => instantiate(`(module binary "\\00asm""\\01\\00\\00\\00" "\\05\\03\\02" ;; memory section with inconsistent count (1 declared, 0 given) "\\00\\00" ;; memory 0 (missed)
;; "\\00\\00" ;; memory 1 (missing)
)`),
`unexpected end of section or function`,
);
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.