I know there is the [A-Z] notation.. but I am not sure if [a-z] is the same as \\w.
I\'d like to match \\w
\w is equivalent of this character class:
[a-zA-Z0-9_]
If you want upper case unicode characters only then use this character class:
'/[\p{Lu}\p{N}_]/u'
This will match any one of:
You can use Unicode character properties. For example,
'/\p{Lu}/u'
Will match any uppercase letter.