in reply to Difference between these regexes

The three cases will indeed match a string from < to the first > on its right, for different reasons. Either because the ? modifier can be understood to mean "as soon as a match is found, from left to right" and therefore find "the first match", or because no > can be contained in the capture. (?!>). and [^>] match the same thing under /s.