I certainly can’t say authoritatively, but I suspect that it can’t be simplified further than
#lastP != null && #lastP != #P && #lastP != #C
which is equivalent by DeMorgan’s law to
#lastP != null && !(#lastP == #P || #lastP == #C)
if that’s how you prefer to look at it.
I’ve updated the Wiki to at least be correct, maybe it can be improved upon later from that point 
Thanks for helping clarify!