Elimination of is/asInstanceOf's based on static information.
Fix #874: Calling null.synchronized does not throw NPE/TypeError.

Also fix the fact that side-effects of the receiver were dropped.
Merge pull request #877 from sjrd/static-opt-of-isasinstanceof

Elimination of is/asInstanceOf's based on static information.
Merge pull request #881 from sjrd/fix-synchronized-npe

Fix #874: Calling null.synchronized does not throw NPE/TypeError.