Misunderstanding of how Emacs treats offsets in regexp