func ImpliedType(gv interface{}) (cty.Type, error) {
	rt := reflect.TypeOf(gv)
	var path cty.Path
	return impliedType(rt, path)
}
ImpliedType takes an arbitrary Go value (as an interface{}) and attempts
to find a suitable cty.Type instance that could be used for a conversion
with ToCtyValue.

This allows -- for simple situations at least -- types to be defined just
once in Go and the cty types derived from the Go types, but in the process
it makes some assumptions that may be undesirable so applications are
encouraged to build their cty types directly if exacting control is
required.

Not all Go types can be represented as cty types, so an error may be
returned which is usually considered to be a bug in the calling program.
In particular, ImpliedType will never use capsule types in its returned
type, because it cannot know the capsule types supported by the calling
program.
package gocty
import (
	"reflect"
	"github.com/zclconf/go-cty/cty"
)