core: `sched_switch()` switch if not on runqueue

Fixes #1935.

`sched_switch()` should not only switch if the other priority is higher,
but also if the current thread was moved from the runqueue.
Don't evaluate inISR() if not needed
Merge pull request #1958 from Kijewski/sched_switch-on-run-queue

core: `sched_switch()` switch if not on runqueue