restructure dump.c slightly to make it more flexible
WIP: progress towards serializing/deserializing a single module at a time
WIP: add support for forward value references in the backref table
WIP: rehash affected method tables due to datatype->uid changes after restoring
be alot more careful about serializing types, especially ones that are also methods, and minor corrections
serialize methlist in reverse order to stabilize method order after deserializing (see #8652 for cause). note this causes more nuisance ambiguity warnings
Merge branch 'jn/static_compile_3'