Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Bug in regex library, FIY, and also where to report it?



Hello,
% REGEX='^[þ-ā]+$'; [[ ÿ =~ $REGEX ]] && echo yes
zsh: failed to compile regex: invalid character range

þ is decimal 254, ā is decimal 257. If one splits this range on 255/256 decimal:

% REGEX='^[þ-ÿĀ-ā]+$'; [[ ÿ =~ $REGEX ]] && echo yes
yes

Then it works. Bash 3.2 doesn't print error message, but first regex doesn't yield "yes" in output (in Bash 4.4 both work). Also, Mikachu checked that `setopt rematchpcre` makes first regex work. I checked that the range works if treated as Zsh pattern.

All in all, it seems to be located in the regex library, as Bash shares same issue, and pcre works fine. Has anyone a hint where to report this?

--  
Sebastian Gniazdowski
psprint /at/ zdharma.org



Messages sorted by: Reverse Date, Date, Thread, Author