t / chainlint / exit-loop.teston commit chainlint: fix for core.autocrlf=true (1ce2b45)
   1(
   2        for i in a b c
   3        do
   4# LINT: "|| exit {n}" valid for-loop escape in subshell; no "&&" needed
   5                foo || exit 1
   6                bar &&
   7                baz
   8        done
   9) &&
  10(
  11        while true
  12        do
  13# LINT: "|| exit {n}" valid while-loop escape in subshell; no "&&" needed
  14                foo || exit 1
  15                bar &&
  16                baz
  17        done
  18) &&
  19(
  20        i=0 &&
  21        while test $i -lt 10
  22        do
  23# LINT: "|| exit" (sans exit code) valid escape in subshell; no "&&" needed
  24                echo $i || exit
  25                i=$(($i + 1))
  26        done
  27)