Skip to content

Commit 95a05f0

Browse files
pgavlinstack72
authored andcommitted
[schema] Export hcl2shum.HCL2ValueFromConfigValue.
We need this in the bridge.
1 parent c8e465f commit 95a05f0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

helper/schema/exports.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,9 +3,14 @@ package schema
33
import (
44
"github.com/hashicorp/go-cty/cty"
55
"github.com/hashicorp/terraform-plugin-sdk/v2/internal/configs/configschema"
6+
"github.com/hashicorp/terraform-plugin-sdk/v2/internal/configs/hcl2shim"
67
"github.com/hashicorp/terraform-plugin-sdk/v2/internal/plans/objchange"
78
)
89

910
func NormalizeObjectFromLegacySDK(val cty.Value, schema *configschema.Block) cty.Value {
1011
return objchange.NormalizeObjectFromLegacySDK(val, schema)
1112
}
13+
14+
func HCL2ValueFromConfigValue(v interface{}) cty.Value {
15+
return hcl2shim.HCL2ValueFromConfigValue(v)
16+
}

0 commit comments

Comments
 (0)