blob: 3e24df768e281c40ed47d037810151210c728b63 [file] [log] [blame]
Denys Vlasenko64981b42020-11-01 18:47:24 +01001v='*.z'
2
3# Buggy:
4# the problem is that expansion rules of LHS and RHS of ~=
5# should not be the same: in RHS, "$v" and "*" should escape metas
6# (currently "$v" does not),
7# but in LHS, they should _not_ do that
8# (currently "*" does). Thus these cases fail:
9[[ a.z == "$v" ]]; echo 4:no:$? # BUG: "$v" expands to *.z
10[[ "*".z == ?.z ]]; echo 5:YES:$? # BUG: "*" expands to \*