fix Issue 10651 - Throwing non-Throwable object causes ICE
Merge pull request #2350 from 9rnsr/fix10651

Issue 10651 - Throwing non-Throwable object causes ICE