hcl/zcldec/gob.go
Martin Atkins f220c26836 zcldec: initial work on decoding bodies directly to cty.Value
This package is an alternative to gocty for situations where static Go
types are not desired and the application instead wishes to remain in the
cty dynamic type system.
2017-06-03 17:34:32 -07:00

23 lines
646 B
Go

package zcldec
import (
"encoding/gob"
)
func init() {
// Every Spec implementation should be registered with gob, so that
// specs can be sent over gob channels, such as using
// github.com/hashicorp/go-plugin with plugins that need to describe
// what shape of configuration they are expecting.
gob.Register(ObjectSpec(nil))
gob.Register(TupleSpec(nil))
gob.Register((*AttrSpec)(nil))
gob.Register((*LiteralSpec)(nil))
gob.Register((*ExprSpec)(nil))
gob.Register((*BlockSpec)(nil))
gob.Register((*BlockListSpec)(nil))
gob.Register((*BlockSetSpec)(nil))
gob.Register((*BlockMapSpec)(nil))
gob.Register((*BlockLabelSpec)(nil))
}