In jQuery 1.8.0 the (obviously invalid) code:
results in the error:
TypeError: groups is null
(jquery.js Line 4664)
Then the next time you run a valid pseudoclass selector (eg ":first") you get the following error:
Error: Syntax error, unrecognized expression: unsupported pseudo: last
(jquery.js Line 4512)
Selectors run after this appear to work normally.
There are two problems here:
Firstly any selector run after the offending ":first.not(.asd)" doesn't work.
Secondly, previous jquery versions allowed ":first.not(.foo)" to pass without an error. I came across this bug as the shopping cart software we use pulls the latest version from Google, and had the above invalid selector (obviously they mean ":not" rather than ".not" but never noticed). When 1.8.0 made it onto Google's servers certain things no longer worked across a range of sites (I'm not really blaming jQuery here, but there was a change in behaviour. Is it intended that an error of some sort be raised here?)