Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Use \A and \z in regexp for stricter matching
* While \A and ^ are the same, there is a difference between \z and $ Using $ it will match the "end of line", which means that this would match strings like: "en-US\n". While \z means "end of string" and it will not match that, and will only match "en-US". I would assert that most of the time when using anchors you would want to use \A and \z, only falling back to ^ and $ in specific cases.
- Loading branch information