scala/scala — pull request #1548 by paulp (2012-10-31 15:54:29+00:00)
Title: Fix for -Xcheckinit failures.

The GenASM phase had an eager val which required loading
a bunch of symbols, which meant an earlier call to isPastTyper
could lead to a cycle of the form:

new Run
new GenASM
rootMirror.getRequiredClass
findMember
defineBaseClassesOfCompoundType
isPastTyper
currentRun.typerPhase

and the opening "new Run" hasn't yet caught up to where
currentRun.typerPhase is set.

This was remedied by making the eager val lazy, and
substantially hardened against recurrence via a method on
global "isGlobalInitialized" which verifies that both
the definitions object and the root mirror have completed
their init methods.