[stdlib] Improve the Erlang shell's handling of scanner errors

The Erlang shell now skips the rest of the line when
it encounters an Erlang scanner error.

Examples:

1> $\xtt.
* 1: illegal character
1> "$\xtt".
* 1: illegal character
1>
Merge branch 'hb/stdlib/shell_improvement/OTP-10659'

* hb/stdlib/shell_improvement/OTP-10659:
  [stdlib] Improve the Erlang shell's handling of scanner errors