core: EvalWriteOutput handle dynamic pseudo-type

This should actually have been caught by !val.IsWhollyKnown, since
DynamicVal is always unknown, but something isn't working quite right here
and so for now we'll redundantly check also if it's of the dynamic
pseudo-type, and then revisit cty later to see if there's a real bug
hiding down there.
This commit is contained in:
Martin Atkins 2018-05-16 08:22:30 -07:00
parent 5281afcc07
commit 8b6ef7c8d3
1 changed files with 1 additions and 1 deletions

View File

@ -137,7 +137,7 @@ func (n *EvalWriteOutput) Eval(ctx EvalContext) (interface{}, error) {
Sensitive: n.Sensitive,
Value: valueTyped,
}
case !val.IsWhollyKnown():
case ty == cty.DynamicPseudoType || !val.IsWhollyKnown():
// While we're still using our existing state format, we can't represent
// partially-unknown values properly, so we'll just stub the whole
// thing out.