save-analysis: emit names of items that a glob import actually imports.

There is also some work here to make resolve a bit more stable - it no longer overwrites a specific import with a glob import.

r?
I don't think this is the right condition to check. The pointer is always valid, and an invalid `Weak` is indicated by the strong count being 0.