handy.h: Slightly refactor READ_XDIGIT macro

This adds comments as to how it works, factors out the mask to be
specified only once, and uses isDIGIT instead of isALPHA, as the former
is likely to be slightly more efficient (because isDIGIT doesn't have to
worry about there being non-ASCII digits, and isALPHA does have to worry
about non-ASCII alphas).  The result is easier to understand what's
going on.
mg.c: Reorder cases in a switch()

This is just cut and paste with no other changes; it is in preparation
for combining two cases in a future commit
mg.c: Reorder if else clauses

This is to allow two cases in the switch statement to be combined in the
next commit.  There should be no effective logic change
mg.c: Use $! code for $^E on platforms where are same

Only a few platforms have $^E distinguished from $!.  On all others they
should behave identically.  Previous commits, have caused these to get
out-of-sync.  This causes them to share their code on platforms where
they mean the same thing, so this won't happen again.
mg.c: White-space only

Outdent this code as a result of removing outer blocks
mg.c: Extract code into a function.

This is in preparation for the same code to be used in additional
places.  There should be no logic changes.
$^E should have same handling as $! for Win32 and OS/2

Commit 1500bd919ffeae0f3252f8d1bb28b03b043d328e changed the handling of
$! to look for UTF-8 messages.  This issue is also present in Win32 for
$^E.  The two should have uniform treatment, so this commit causes the
actual same code to be executed for both.  OS/2 is also subject to
locale issues, and so it also is changed here to use the same code, so
that future changes will apply to it automatically.

VMS doesn't use locales, so it retains its current behavior.

Note that 1500bd919 has created some field problems, so that the changes
it introduced will be further changed or reverted.  The current commit
just makes sure that whatever those further changes are will be
automatically propagated to all necessary platforms.
Respect 'use bytes' in returning $! and $^E

This addresses some of the field problems caused by commit
1500bd919ffeae0f3252f8d1bb28b03b043d328e, but by no means all.
If the stringification of $^E or $! is done in the scope of 'use bytes',
the UTF-8 flag on the result is now never set.  In such scope, the
behavior is then the same as it was prior to that commit.  The actual
behavior will change before v5.20 ships.