Tony Zorman writes: > On Sun, Sep 24 2023 16:31, Philip Kaludercic wrote: >> Tony Zorman writes: >> >>> On Wed, Sep 20 2023 07:32, Philip Kaludercic wrote: >>>> + (unless (string-match-p ignored-files file) >>> >>> One thing that did jump out to me just now, which I hadn't considered >>> before: when ignored-files is the empty string, this will always match >>> any file—not what we want :) >> >> Do you mean because the empty glob expression doesn't match everything, >> but the empty regular expression does? >> >> The easiest solution seems to be to just check if the empty string is >> listed and handle that separately (whatever the correct behaviour is in >> that case), but on the other hand, why should a user list an empty >> string in the list of ignored files? > > The point I was making was that `(mapconcat (λ…) nil) ≡ ""`, since > mapconcat always returns a string. Even if there were no :ignored-files > listed, the ignored-files variable would then be the empty string, > matching each and every file. Oops, right, in that case this should be preferable: