Support character range patterns (e.g. [0-9], [a-z]), like other globs do

This feature was overlooked in the original pull request (#8914).

r? @alexcrichton