Use \A and \z as begin/end anchors in regexp