summaryrefslogtreecommitdiffhomepage
path: root/bench/testloop.sh
Commit message (Collapse)AuthorAgeFilesLines
* bench: keep the arithmetic totals inside 32 bitsSean Kurtz11 days1-0/+1
| | | | | | | ksh88 works in 32-bit integers, so summing i*2 over 200000 iterations overflowed and the benchmark reported "differs" instead of a time: the same script, two answers. Summing (i % 100) * 2 does the same work and fits in 31 bits.
* Add [[ ]], make coverage, and fixes found by edge-case testsSean Kurtz2026-11-151-0/+8
[[ ]] is parsed into a tree and evaluated without argv or lookup. Fixes: errexit inside a tested subshell, the ${x:?} message, arithmetic on variables holding expressions, printf %c of an empty argument, job text for arithmetic, and \n and \e prompt escapes.