| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Go back to using globalError to report when a stub's info is referenced,
and only throw the MissingRequirementError when compilation really
must abort due to having a StubTermSymbol in a place where a
StubClassSymbol would have been a better choice.
This situation arises when an entire package is missing from the
classpath, as was the case in the reported bug.
Adds `StoreReporterDirectTest`, which buffers messages issued
during compilation for more structured interrogation. Use this
in two test for manifests -- these tests were using a crude means
of grepping compiler console output to focus on the relevant output,
but this approach was insufficient with the new multi-line error
message emitted as part of this change.
Also used that base test class to add two new tests: one for
the reported error (package missing), and another for a simpler
error (class missing). The latter test shows how stub symbols
allow code to compile if it doesn't the subset of signatures
in some type that refer to a missing class.
Gave the INFO/WARNING/ERROR members of Reporter sensible
toString implementations; they inherit from Enumeration#Value
in an unusual manner (why?) that means the built in toString of
Enumeration printed `Severity@0`.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The situation (I don't know how to make partest test this) is
package s
class A ; class S { def f(): A = ??? }
If one compiles this and removes A.class, should references to
class S cause the compiler to explode eagerly and fail to load S,
or explode lazily if and when it needs to know something about A?
This patch takes us from the former strategy to the latter.
Review by @xeno-by.
|
|
Unfortunately we have to wrap transform to catch all
the MissingRequirementErrors exceptions (wrapped in TypeErrors).
This is because we force the info of the symbol in a couple of
places and we would have to catch all/some of them
(and remove the duplicates as well which really becomes messy).
Review by @axel22.
|