blob: 8792e3393bf00241acac2b8b6215e38024e63745 [file] [log] [blame]
// Code generated by go generate. DO NOT EDIT.
//go:generate rm pkg.go
//go:generate go run ../../gen/gen.go
package yaml
import (
"cuelang.org/go/internal/core/adt"
"cuelang.org/go/pkg/internal"
)
func init() {
internal.Register("encoding/yaml", pkg)
}
var _ = adt.TopKind // in case the adt package isn't used
var pkg = &internal.Package{
Native: []*internal.Builtin{{
Name: "Marshal",
Params: []internal.Param{
{Kind: adt.TopKind},
},
Result: adt.StringKind,
Func: func(c *internal.CallCtxt) {
v := c.Value(0)
if c.Do() {
c.Ret, c.Err = Marshal(v)
}
},
}, {
Name: "MarshalStream",
Params: []internal.Param{
{Kind: adt.TopKind},
},
Result: adt.StringKind,
Func: func(c *internal.CallCtxt) {
v := c.Value(0)
if c.Do() {
c.Ret, c.Err = MarshalStream(v)
}
},
}, {
Name: "Unmarshal",
Params: []internal.Param{
{Kind: adt.BytesKind | adt.StringKind},
},
Result: adt.TopKind,
Func: func(c *internal.CallCtxt) {
data := c.Bytes(0)
if c.Do() {
c.Ret, c.Err = Unmarshal(data)
}
},
}, {
Name: "Validate",
Params: []internal.Param{
{Kind: adt.BytesKind | adt.StringKind},
{Kind: adt.TopKind},
},
Result: adt.BoolKind,
Func: func(c *internal.CallCtxt) {
b, v := c.Bytes(0), c.Value(1)
if c.Do() {
c.Ret, c.Err = Validate(b, v)
}
},
}, {
Name: "ValidatePartial",
Params: []internal.Param{
{Kind: adt.BytesKind | adt.StringKind},
{Kind: adt.TopKind},
},
Result: adt.BoolKind,
Func: func(c *internal.CallCtxt) {
b, v := c.Bytes(0), c.Value(1)
if c.Do() {
c.Ret, c.Err = ValidatePartial(b, v)
}
},
}},
}