Use ev.LookupVar instead of two Lookup calls
diff --git a/eval.go b/eval.go
index 70288bf..2c77b5d 100644
--- a/eval.go
+++ b/eval.go
@@ -129,10 +129,7 @@
 				i++
 			}
 
-			value := ev.outVars.Lookup(varname)
-			if !value.IsDefined() {
-				value = ev.vars.Lookup(varname)
-			}
+			value := ev.LookupVar(varname)
 			val := value.Eval(ev)
 			Log("var %q=>%q=>%q", varname, value, val)
 			if subst != nil {