Tweaks doc for NewRuntimeConfig to describe API behavior (#603)
Signed-off-by: Anuraag Agrawal <anuraaga@gmail.com>
This commit is contained in:
@@ -137,6 +137,12 @@ type RuntimeConfig interface {
|
|||||||
WithWasmCore2() RuntimeConfig
|
WithWasmCore2() RuntimeConfig
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// NewRuntimeConfig returns a RuntimeConfig using the compiler if it is supported in this environment,
|
||||||
|
// or the interpreter otherwise.
|
||||||
|
func NewRuntimeConfig() RuntimeConfig {
|
||||||
|
return newRuntimeConfig()
|
||||||
|
}
|
||||||
|
|
||||||
type runtimeConfig struct {
|
type runtimeConfig struct {
|
||||||
enabledFeatures wasm.Features
|
enabledFeatures wasm.Features
|
||||||
newEngine func(wasm.Features) wasm.Engine
|
newEngine func(wasm.Features) wasm.Engine
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
package wazero
|
package wazero
|
||||||
|
|
||||||
// NewRuntimeConfig returns NewRuntimeConfigCompiler
|
func newRuntimeConfig() RuntimeConfig {
|
||||||
func NewRuntimeConfig() RuntimeConfig {
|
|
||||||
return NewRuntimeConfigCompiler()
|
return NewRuntimeConfigCompiler()
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,6 @@
|
|||||||
|
|
||||||
package wazero
|
package wazero
|
||||||
|
|
||||||
// NewRuntimeConfig returns NewRuntimeConfigInterpreter
|
func newRuntimeConfig() RuntimeConfig {
|
||||||
func NewRuntimeConfig() RuntimeConfig {
|
|
||||||
return NewRuntimeConfigInterpreter()
|
return NewRuntimeConfigInterpreter()
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user