#name: dont pass incomplete values to builtins
#evalFull
-- in.cue --
import "encoding/json"

input: string
foo:   json.Marshal(input)
-- out/def --
import "encoding/json"

input: string
foo:   json.Marshal(input)
-- out/legacy-debug --
<0>{input: string, foo: <1>.Marshal (<2>.input)}
-- out/evalalpha/stats --
Leaks:  3
Freed:  0
Reused: 0
Allocs: 3
Retain: 0

Unifications: 3
Conjuncts:    3
Disjuncts:    0
-- diff/-out/evalalpha/stats<==>+out/eval/stats --
diff old new
--- old
+++ new
@@ -1,9 +1,9 @@
-Leaks:  0
-Freed:  3
-Reused: 1
-Allocs: 2
+Leaks:  3
+Freed:  0
+Reused: 0
+Allocs: 3
 Retain: 0
 
 Unifications: 3
-Conjuncts:    7
-Disjuncts:    3
+Conjuncts:    3
+Disjuncts:    0
-- out/eval/stats --
Leaks:  0
Freed:  3
Reused: 1
Allocs: 2
Retain: 0

Unifications: 3
Conjuncts:    7
Disjuncts:    3
-- out/eval --
(struct){
  input: (string){ string }
  foo: (_|_){
    // [incomplete] foo: non-concrete argument 0:
    //     ./in.cue:4:8
  }
}
-- out/compile --
--- in.cue
{
  input: string
  foo: 〈import;"encoding/json"〉.Marshal(〈0;input〉)
}
