package binaryimport ()// decodeMemory returns the api.Memory decoded with the WebAssembly 1.0 (20191205) Binary Format.//// See https://www.w3.org/TR/2019/REC-wasm-core-1-20191205/#binary-memoryfunc decodeMemory( *bytes.Reader,api.CoreFeatures,func( uint32, *uint32) (, , uint32),uint32,) (*wasm.Memory, error) { , , , := decodeLimitsType()if != nil {returnnil, }if {if !.IsEnabled(experimental.CoreFeaturesThreads) {returnnil, fmt.Errorf("shared memory requested but threads feature not enabled") }// This restriction may be lifted in the future. // https://webassembly.github.io/threads/core/binary/types.html#memory-typesif == nil {returnnil, fmt.Errorf("shared memory requires a maximum size to be specified") } } , , := (, ) := &wasm.Memory{Min: , Cap: , Max: , IsMaxEncoded: != nil, IsShared: }return , .Validate()}
The pages are generated with Goldsv0.8.2. (GOOS=linux GOARCH=amd64)
Golds is a Go 101 project developed by Tapir Liu.
PR and bug reports are welcome and can be submitted to the issue list.
Please follow @zigo_101 (reachable from the left QR code) to get the latest news of Golds.