Fish v3.7.1, tested with clean home.
https://asciinema.org/a/jZhHcUByvJ80NkbRp75krG8x4
When set -l var'ing in a loop, the variable stays set in the following loop iterations.
Expected
Like in example 2 with the explicit begin; …; end I would expect the variable to go out of scope in every loop iteration (as is the case with any major programming language today AFAIK).
Fish v3.7.1, tested with clean home.
https://asciinema.org/a/jZhHcUByvJ80NkbRp75krG8x4
When
set -l var'ing in a loop, the variable stays set in the following loop iterations.Expected
Like in example 2 with the explicit
begin; …; endI would expect the variable to go out of scope in every loop iteration (as is the case with any major programming language today AFAIK).