You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
terraform/internal/lang/ephemeral/paths.go

19 lines
451 B

// Copyright IBM Corp. 2014, 2026
// SPDX-License-Identifier: BUSL-1.1
package ephemeral
import (
"github.com/zclconf/go-cty/cty"
"github.com/hashicorp/terraform/internal/lang/marks"
)
// EphemeralValuePaths returns the paths within the given value that are
// marked as ephemeral, if any.
func EphemeralValuePaths(v cty.Value) []cty.Path {
_, pvms := v.UnmarkDeepWithPaths()
ret, _ := marks.PathsWithMark(pvms, marks.Ephemeral)
return ret
}