useless 'instanceof' removal pass

I met some users that used such statements just to hint their IDE about auto-completion.

$a instance Foo;

This is a useless statement that gets compiled and run every time for nothing.

This PR adds a pass to optimize such statement