Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: Minor xtrace inaccuracy
Here's one of them test thingies for trace output from some basic
conditions. If you're doing this at home, you need to know you don't
get a trace of the full test, just the bits actually executed by the
short-cutting logic, hence precedence and parentheses are irrelevant.
diff --git a/Test/E02xtrace.ztst b/Test/E02xtrace.ztst
index 2420aeb..093a587 100644
--- a/Test/E02xtrace.ztst
+++ b/Test/E02xtrace.ztst
@@ -118,3 +118,12 @@
?+./fnfile:5> :
?+./fnfile:6> fn
?+./fnfile:3> print This is fn.
+
+ set -x
+ [[ 'f o' = 'f x'* || 'b r' != 'z o' && 'squashy sound' < 'squishy sound' ]]
+ [[ -e nonexistentfile || ( -z '' && -t 3 ) ]]
+ set +x
+0:Trace for conditions
+?+(eval):2> [[ 'f o' == f\ x* || 'b r' != z\ o && 'squashy sound' < 'squishy sound' ]]
+?+(eval):3> [[ -e nonexistentfile || -z '' && -t 3 ]]
+?+(eval):4> set +x
pws
Messages sorted by:
Reverse Date,
Date,
Thread,
Author