It may be novice question. I'm just trying to learn elisp regex, and can't get my head arround why below is matching.
Here, I'm trying to match with string that has only Uppercase letters, but below is clearly matching with the lowercase ones.
(string-match-p "^[A-Z]+$" "ASDaF")
(string-match-p "^[[:upper:]]+$" "ASDaF")
(string-match-p "^[[:upper:]]+$" "alllowercase")
;; all return 0 not nil
Also with M-x re-builder
.