See last test at http://www.richinstyle.com/test/keyconcepts/comments2.html Basically, we treat the selector ":lang/* */(fr)" as identical to ":lang(fr)". That's wrong.
Comment on attachment 138880 [details] [diff] [review] Patch r+sr=dbaron if you put a rather verbose comment above the definition of |isTree| explaining how that interacts with what you just added to allow the tree pseudo-elements to be optionally functional.
Added: // If a tree pseudo-element is using the function syntax, it will // get isTree set here and will pass the check below that only // allows functions if they are in our list of things allowed to be // functions. If it is _not_ using the function syntax, isTree will // be false, and it will still pass that check. So the tree // pseudo-elements are allowed to be either functions or not, as // desired. and checked in.