| Commit message (Collapse) | Author | Age | Files | Lines |
... | |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Move code that manipulates the error buffers / reporters
into combinators in Context/ContextReporter.
Eventually, would like to statically know when we're in silent mode,
and only then use buffering (push buffering code down to BufferingReporter).
Simplify TryTwice; avoid capturing mutable var in closure.
Changed inSilentMode to no longer check `&& !reporter.hasErrors`;
disassembling optimized code showed that this was keeping the inliner
from inlining this method.
Introduce a couple more combinators:
- withFreshErrorBuffer
- propagatingErrorsTo
- propagateImplicitTypeErrorsTo
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Could not figure it out, so resorting to brain dumping.
something with private classes and defaults,
the default getter will be in the private companion module,
but there's no accessor to get the module???
maybe something related to make non-private of the accessor?
while running the repl or, e.g., the test presentation/ide-t1000567
AbstractMethodError: scala.tools.nsc.interactive.Global$$anon$5.scala$tools$nsc$typechecker$Contexts$$BufferingReporter()Lscala/tools/nsc/typechecker/Contexts$BufferingReporter$;
at scala.tools.nsc.typechecker.Contexts$Context.makeSilent(Contexts.scala:518)
in progress minimal repro:
```
package a
class Reporter
class Global {
lazy val analyzer = new {
val global: Global.this.type = Global.this
} with Analyzer
}
trait Analyzer extends AnyRef with Contexts {
val global : Global
}
trait Contexts { self: Analyzer =>
// the accessor to get to ContextReporter's companion object
// to get the default for x is not emitted for some reason
// the expected accessor is the non-private version
// `def scala$tools$nsc$typechecker$Contexts$$BufferingReporter: scala.tools.nsc.typechecker.Contexts#BufferingReporter$`
// (as seen in the AbstractMethodError's message)
abstract class ContextReporter(x: Any = null) extends Reporter
private class ThrowingReporter extends ContextReporter
class Context(a: Any, private[this] var _reporter: ContextReporter = new ThrowingReporter) {
def reporter = _reporter
}
object NoContext extends Context(null)
}
package b
trait ReplGlobal extends a.Global {
// this anon class corresponds to scala.tools.nsc.interactive.Global$$anon$5 in the above AbstractMethodError
override lazy val analyzer = new {
val global: ReplGlobal.this.type = ReplGlobal.this
} with a.Analyzer { }
}
```
|
|
|
|
|
|
|
|
| |
Next step: more principled buffering, make use of the single-entry point reporter.
First example simplification in `TryTwice`:
No need to store and restore errors -- just use a fresh reporter.
Also, control-flow with vars ftw.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reporting mode used to be governed by contextMode.
This logic is left in place by this commit, and the consistency
of the new and the old is checked. Will be removed in follow-up commit.
The main difference is that we no longer throw TypeErrors in buffering mode.
There was one instance of context.error in implicit search the exploited the
fact that implicit search runs in buffering (silent) mode and thus calls to
error(pos,msg) used to throw new TypeError(pos, msg) -- made this explicit,
and removed throwing behavior from the buffering context reporter.
|
| |
|
|
|
|
| |
This is used by the tree checkers.
|
|
|
|
| |
The overload was used only once.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Now that all reporting mode manipulators are private to Context,
let's untangle this logic:
- every `setReportErrors` gets a corresponding `setAmbiguousErrors(true)`
- every `setBufferErrors` gets a corresponding `setAmbiguousErrors(false)`
- every `setThrowErrors` gets a corresponding `setAmbiguousErrors(false)`
`ambiguousErrors` means that ambiguity errors *must* be reported,
even when in silent mode. When it's false, they are *not* reported,
but they are buffered when the context reporter is buffering.
TODO: this seems a bit dubious, but this is what happens now.
Let's see if we can simplify this once the refactoring is complete.
Again, the end goal is a strategy-based approach to reporting,
where the reporting mode is captured in the reporter being used,
with as little mutation as possible to capture more invariants
(would like to stop throwing TypeError eventually and only have two reporters:
buffering reporter, regular reporter)
|
| |
|
|
|
|
|
|
| |
This allows local reasoning about these bits,
giving some more confidence for the refactoring
that's underway.
|
| |
|
| |
|
|
|
|
|
|
| |
- when warning must not be suppressed, use `reporter.warning`
- don't (implicitly) rely on `reporter.warning` being silent after typer
--> don't do pure expression check after typer
|
|
|
|
| |
Introduce `initRootContext` to set the relevant bits.
|
|
|
|
|
| |
All functionality that's closely tied to the error buffer should be in
`Context`'s reporting infrastructure. (called `ContextReporter`, soon to follow.)
|
|
|
|
| |
Setting the scene of removing the reporting mode bits from `contextMode`.
|
|
|
|
|
|
|
|
|
| |
Once we get the next diagnostic, lets encapsulate them in an
object, with a boolean flag for each one when it needs to trigger,
and a nice message that should be presented to our delighted user.
A list of Strings that is searched by contents is a bit fragile,
and can't be very fast either.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The two functional differences are:
- always add the diagnostics string
- check erroneousness in `issueAmbiguousTypeErrorUnlessErroneous`,
before even constructing the error message.
Consider this nugget:
```
- def issueAmbiguousError(pre: Type, sym1: Symbol, sym2: Symbol, err: AbsTypeError) {
- issueCommon(err) { case _ if ambiguousErrors =>
- if (!pre.isErroneous && !sym1.isErroneous && !sym2.isErroneous)
```
I'd like to state for the record that the if-erroneous in the
case of the partial function looked super-dodgy: it meant that,
when `ambiguousErrors`, `issueCommon` would not get to the `else` branches
that buffer or throw, and if the erroneous condition was met,
nothing would be issued/buffered/thrown.
This refactoring checks this condition up front.
|
|
|
|
|
|
|
| |
Both refchecks and typer constructed the same message. But different.
Now with more DRYness.
Note that no check files had to be updated (disconcerting)...
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Inline the forwarders from CompilationUnit, which should not affect behavior.
Since all forwarders lead to global.reporter, don't first navigate
to a compilation unit, only to then forward back to global.reporter.
The cleanup in the previous commits revealed a ton of confusion
regarding how to report an error.
This was a mechanical search/replace, which has low potential for messing
things up, since the list of available methods are disjoint between
`reporter` and `currentRun.reporting`. The changes involving `typer.context`
were done previously.
Essentially, there are three ways to report:
- via typer.context, so that reporting can be silenced (buffered)
- via global.currentRun.reporting, which summarizes (e.g., deprecation)
- via global.reporter, which is (mostly) stateless and straightforward.
Ideally, these should all just go through `global.currentRun.reporting`,
with the typing context changing that reporter to buffer where necessary.
After the refactor, these are the ways in which we report (outside of typer):
- reporter.comment
- reporter.echo
- reporter.error
- reporter.warning
- currentRun.reporting.deprecationWarning
- currentRun.reporting.incompleteHandled
- currentRun.reporting.incompleteInputError
- currentRun.reporting.inlinerWarning
- currentRun.reporting.uncheckedWarning
Before:
- c.cunit.error
- c.enclosingUnit.deprecationWarning
- context.unit.error
- context.unit.warning
- csymCompUnit.warning
- cunit.error
- cunit.warning
- currentClass.cunit.warning
- currentIClazz.cunit.inlinerWarning
- currentRun.currentUnit.error
- currentRun.reporting
- currentUnit.deprecationWarning
- currentUnit.error
- currentUnit.warning
- getContext.unit.warning
- getCurrentCUnit.error
- global.currentUnit.uncheckedWarning
- global.currentUnit.warning
- global.reporter
- icls.cunit.warning
- item.cunit.warning
- reporter.comment
- reporter.echo
- reporter.error
- reporter.warning
- reporting.deprecationWarning
- reporting.incompleteHandled
- reporting.incompleteInputError
- reporting.inlinerWarning
- reporting.uncheckedWarning
- typer.context.unit.warning
- unit.deprecationWarning
- unit.echo
- unit.error
- unit.incompleteHandled
- unit.incompleteInputError
- unit.uncheckedWarning
- unit.warning
- v1.cunit.warning
All these methods ended up calling a method on `global.reporter`
or on `global.currentRun.reporting` (their interfaces are disjoint).
Also clean up `TypeDiagnostics`: inline nearly-single-use private methods.
|
|
|
|
|
|
|
|
|
|
| |
Continue the work started in SI-8450
(no "implicit numeric widening" warning in silent mode),
which was caused by going straight to the reporter instead of
using the context for type error reporting (which buffers in silent mode).
Ideally, this mistake should not be possible: typer should change
the current reporter to buffer where appropriate.
|
|
|
|
|
|
|
|
|
|
|
|
| |
Position the error based on Select tree that failed to type check,
presumably due to an underlying MissingRequirementError, which has no position.
There are lots of other ways we could rewrap a MRE and supplement position info,
but that remains TODO. Jason's review comment is recorded in the code.
Also try to detect the case of a missing module and provide some advice,
as well as linking to the forthcoming 2.11 guide at
http://docs.scala-lang.org/overviews/core/scala-2.11.html.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Regressed in dbd8457 which changed `Context#make` to automatically
include the imports from the given `Tree` if it was an `Import`
tree, rather than requiring callers to call `makeNewImport`.
However, this turns out to double up the imports for the "inner" namer
of a template that starts with imports. The inner namer has a new
scope, but the same owner and tree as its parent.
This commit detects this case by seeing if the `Import` tree used
to consruct the child context is the same as the parent context.
If that is the case, we don't augment `Context#imports`.
|
|
|
|
|
|
|
|
|
| |
This is reminiscent of the bug that I recently fixed in paradise:
https://github.com/scalamacros/paradise/commit/0dc4e35883d357b7cbcdfd83b5b4821c1dcc0bb1.
When doing something non-standard with contexts, we usually have to keep
in mind that new contexts are created not only for trees that demarcate
blocks of code, but also for imports.
|
|\
| |
| | |
SI-8063 and its seventy friends
|
| |
| |
| |
| |
| |
| |
| |
| | |
This is the first step in disentangling api#Symbol.isPackage, which is
supposed to return false for package classes, and internal#Symbol.isPackage,
which has traditionally being used as a synonym for hasPackageFlag and
hence returned true for package classes (unlike isModule which is false
for module classes).
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
There’s been a conflation of two distinct meanings of the word “local”
in the internal symbol API: the first meaning being “local to this”
(as in has the LOCAL flag set), the second meaning being “local to block”
(as in declared in a block, i.e. having owner being a term symbol).
Especially confusing is the fact that sym.isLocal isn’t the same as
sym.hasFlag(LOCAL), which has led to now fixed SI-6733.
This commit fixes the semantic mess by deprecating both Symbol.isLocal and
Symbol.hasLocalFlag (that we were forced to use, because Symbol.isLocal
had already been taken), and replacing them with Symbol.isLocalToThis
and Symbol.isLocalToBlock. Unfortunately, we can’t remove the deprecated
methods right away, because they are used in SBT, so I had to take small
steps.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Experience building open source projects like Specs that use
`-Xlint` suggests that this warning is too noisy to lump in
with the others.
We are lacking in more fine-grained control of these things, so
simply turning of `-Xlint` in favour of its underlying `-Y` options
ends up *losing* some other important warnings that are predicated
directly on `-Xlint`.
Furthermore, bug reports against M8, SI-7707 SI-7712, show that
unused private/local warnings, while far less noisy, are still
in need of polish.
This commit moves these warnings to a pair of new -Y options,
neither of which is part of `-Xlint`..
Let's ask people to opt in for 2.11, and as it stabilizes, we can
consider adding it to Xlint (or the desirable evolution of that)
in the next release.
|
|\
| |
| | |
Fix regression for using Scala IDE on scala-library
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
This reverts commit 66904556ef34dc81cbb7c09257b013b3ddb76f78.
Conflicts:
src/reflect/scala/reflect/internal/TreeInfo.scala
As evidenced by the highlights of the stack trace in Scala IDE,
my assertion in the 66904556e wasn't universally true.
The change was only motivated by removing a special case, not in
order to fix some other problem. So the revert is the most straight
forward course of action for now.
I haven't pinned this down with a test outside of Eclipse, and
given the lateness of the hour wrt 2.11.0, I'll have to submit
without one.
2013-03-10 08:38:04,690 ERROR [main] - org.scala-ide.sdt.core - org.scala-ide.sdt.core - org.scala-ide.sdt.core - 0 - Error during askOption
scala.reflect.internal.Symbols$CyclicReference: illegal cyclic reference involving object Predef
...
at scala.reflect.internal.Symbols$Symbol.lock(Symbols.scala:482)
at scala.reflect.internal.Symbols$Symbol.info(Symbols.scala:1216)
at scala.reflect.internal.Symbols$Symbol.tpe(Symbols.scala:1200)
at scala.reflect.internal.Symbols$Symbol.tpeHK(Symbols.scala:1201)
at scala.reflect.internal.Types$Type.computeMemberType(Types.scala:784)
at scala.reflect.internal.Types$Type.memberType(Types.scala:781)
at scala.reflect.internal.TreeGen.mkAttributedSelect(TreeGen.scala:203)
...
at scala.reflect.internal.TreeGen.mkAttributedStableRef(TreeGen.scala:162)
at scala.tools.nsc.ast.TreeGen.mkWildcardImport(TreeGen.scala:39)
at scala.tools.nsc.typechecker.Contexts$Context.makeNewImport(Contexts.scala:308)
at scala.tools.nsc.typechecker.Contexts$class.rootContext(Contexts.scala:69)
at scala.tools.nsc.Global$$anon$1.rootContext(Global.scala:492)
at scala.tools.nsc.typechecker.Contexts$class.rootContext(Contexts.scala:64)
at scala.tools.nsc.Global$$anon$1.rootContext(Global.scala:492)
at scala.tools.nsc.typechecker.Analyzer$namerFactory$$anon$1.apply(Analyzer.scala:43)
at scala.tools.nsc.Global$GlobalPhase.applyPhase(Global.scala:463)
...
at scala.tools.nsc.Global$Run.compileLate(Global.scala:1681)
at scala.tools.nsc.Global$Run.compileLate(Global.scala:1671)
at scala.tools.nsc.symtab.SymbolLoaders$SourcefileLoader.doComplete(SymbolLoaders.scala:284)
at scala.tools.nsc.symtab.SymbolLoaders$SymbolLoader.complete(SymbolLoaders.scala:187)
at scala.reflect.internal.Symbols$Symbol.info(Symbols.scala:1229)
at scala.reflect.internal.Symbols$Symbol.tpe(Symbols.scala:1200)
at scala.reflect.internal.Symbols$Symbol.tpeHK(Symbols.scala:1201)
at scala.reflect.internal.Types$Type.computeMemberType(Types.scala:784)
at scala.reflect.internal.Types$Type.memberType(Types.scala:781)
at scala.reflect.internal.TreeGen.mkAttributedSelect(TreeGen.scala:203)
at scala.reflect.internal.TreeGen.mkAttributedRef(TreeGen.scala:124)
at scala.reflect.internal.TreeGen.mkAttributedRef(TreeGen.scala:130)
at scala.reflect.internal.TreeGen.mkAttributedStableRef(TreeGen.scala:162)
at scala.tools.nsc.ast.TreeGen.mkWildcardImport(TreeGen.scala:39)
...
at scala.tools.nsc.Global$$anon$1.rootContext(Global.scala:492)
at scala.tools.nsc.typechecker.Analyzer$namerFactory$$anon$1.apply(Analyzer.scala:43)
at scala.tools.nsc.Global$GlobalPhase.applyPhase(Global.scala:463)
...
at scala.tools.nsc.Global$Run.compileLate(Global.scala:1671)
at scala.tools.nsc.symtab.SymbolLoaders$SourcefileLoader.doComplete(SymbolLoaders.scala:284)
at scala.tools.nsc.symtab.SymbolLoaders$SymbolLoader.complete(SymbolLoaders.scala:187)
at scala.reflect.internal.Symbols$Symbol.info(Symbols.scala:1229)
at scala.reflect.internal.Symbols$Symbol.initialize(Symbols.scala:1365)
...
at scala.collection.immutable.HashSet$HashSet1.foreach(HashSet.scala:153)
at scala.collection.immutable.HashSet$HashTrieSet.foreach(HashSet.scala:306)
at scala.tools.eclipse.javaelements.ScalaJavaMapper$class.initializeRequiredSymbols(ScalaJavaMapper.scala:29)
...
at scala.tools.nsc.util.InterruptReq.execute(InterruptReq.scala:26)
at scala.tools.nsc.interactive.Global.pollForWork(Global.scala:340)
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In 4c86dbbc492 / SI-6358, synthesis of lazy val accessors trees was
moved into the typer phase (in MethodSynthesis). Before that point,
the symobl for the accessor *was* created early, but the tree was
not. This led to crashes in intervening phases (extensionmethods)
as `changeOwner` calls didn't catch the smuggled symbol.
Moving the accessor generation forward, however, brought a problem:
we now introduce a DefDef around the RHS of the lazy val, but we're
not actually guaranteed that the body has already been typechecked.
If it happened to be typechecked for the purposes of return type
inference, we'll pick up the typechecked tree from `transformed`:
// LazyValGetter#derivedTree
val rhs1 = transformed.getOrElse(rhs0, rhs0)
But if the method had an explicit return type (which must *always*
be the case if it contains a `return`!), `rhs0` will be untyped.
This leads to, e.g.:
def foo(o: Option[Int]): Int = {
lazy val i = o.getOrElse(return -1)
i + 1
}
def foo(o: Option[Int]): Int = {
lazy <artifact> var i$lzy: Int = _;
<stable> <accessor> lazy def i: Int = {
i$lzy = o.getOrElse(return -1);
i$lzy
};
i.+(1)
};
When this is typechecked, the `return` binds to the closest enclosing
`DefDef`, `lazy def i`. This commit changes `Context#enclMethod` to
treat `DefDef`s as transparent.
`enclMethod` is only used in one other spot that enforces the
implementation restriction that "module extending its companion class
cannot use default constructor arguments".
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Use a specialized version of List#{map, collectFirst}
These special case mapping over an empty list and avoid
allocating.
- Avoid nonEmpty in favor of `ne Nil`
I see in the order of 2% speedup.
Perhaps more useful is that
these methods no longer dominate the YourKit profiles, even though
profiler bias due to safepoints at allocation of the ListBuffer
might have been overstating their significance.
|
|
|
|
|
| |
This cute little type is necessary for importers to work correctly.
I wonder how we could overlook its existence for almost 2 years.
|
|\
| |
| | |
SI-8024 Fix inaccurate message on overloaded ambiguous ident
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
`Symbol#owner` of an overloaded symbol doesn't necessarily correspond
to the owner of any of the alternatives, and as such it shouldn't
be used in error message.
neg/t8024.scala actually represents a progression since 2.10.3;
the ambiguity was not reported. I bisected the change to
https://github.com/scala/scala/pull/1554.
|
| |
| |
| |
| |
| |
| |
| | |
- split out a method for the part concernted with implicits from
the current context
- leaving the outer code to handle caching, cycle detection,
and recursion up the context chain.
|
|/
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Implicit searches in the body of implicit members with inferred
types were leading to cycles. Before we used to resolve that
by saying there were no implicits in scope at all; now we just
skip the current context and still include the enclosing implicits.
Care is taken not to cache results under these circumstances.
This entails reworking `Context#implicitss` so that:
- the implicit info cache only contains implicits from the current
level. The List[List[_]] is now contructed on demand;
- we can detect cycles by setting `implicitsCacheRunId` to -1 during
the computation. The outer implicits when we encounter that.
- we avoid caching when we hit a cycle or when the owner is uninitialized.
|
|
|
|
|
|
| |
We go through similar gymnastics to make companion implicits
work for local class/object pairings, so we ought to be consistent
when it comes to access
|
|
|
|
|
|
|
| |
Rather than just the first.
For example, `foo(wizzle, wuzzle, woggle)` should report all three
not-found symbols.
|
|
|
|
|
|
| |
Calling position factories rather than instantiating these
particular classes. Not calling deprecated methods. Added a few
position combinator methods.
|
|
|
|
|
| |
Looks like emptyValDef.isEmpty was already changed to return
false, so now all that's left is a name which means something.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Misc irrelevant work, which I can only offer as-is. It lowers
the noise in -Ycheck:* output and performs some common sense
chillaxes like not screaming ERROR IN INTERNAL CHECKING! WE'RE
ALL GOING TO DIE! when a tree doesn't hit all nine points at
the Jiffy Tree.
You can see some reasonably well reduced symbol flailing if
you run the included pending tests:
test/partest --show-diff test/pending/pos/treecheckers
Example output,
Out of scope symbol reference {
tree TypeTree Factory[Traversable]
position OffsetPosition test/pending/pos/treecheckers/c5.scala:3
with sym ClassSymbol Factory: Factory[CC]
and tpe ClassArgsTypeRef Factory[Traversable]
encl(1) ModuleSymbol object Test5
ref to AbstractTypeSymbol X (<deferred> <param>)
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Reduced the amount of extraneous logging noise at the
default logging level.
Was brought to my usual crashing halt by the discovery of identical
logging statements throughout GenASM and elsewhere. I'm supposing
the reason people so grossly underestimate the cost of such duplication
is that most of the effects are in things which don't happen, aka
"silent evidence".
An example of a thing which isn't happening is the remainder of
this commit, which exists only in parallel universes.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Historically calling NoSymbol.owner has crashed the compiler.
With this commit, NoSymbol owns itself. This is consistent with
the way ownership chains are handled elsewhere in the compiler
(e.g. NoContext.owner is NoContext, NoSymbol.enclClass is
NoSymbol, and so on) and frees every call site which handles
symbols from having to perform precondition tests against
NoSymbol.
Since calling NoSymbol.owner sometimes (not always) indicates
a bug which we'd like to catch sooner than later, I have
introduced a couple more methods for selected call sites.
def owner: Symbol // NoSymbol.owner is self, log if -Xdev
def safeOwner: Symbol // NoSymbol.owner is self, ignore
def assertOwner: Symbol // NoSymbol.owner is fatal
The idea is that everyone can call sym.owner without undue anxiety
or paranoid null-like tests. When compiling under -Xdev calls to
`owner` are logged with a stack trace, so any call sites for which
that is an expected occurrence should call safeOwner instead to
communicate the intention and stay out of the log. Conversely, any
call site where crashing on the owner call was a desirable behavior
can opt into calling assertOwner.
This commit also includes all the safeOwner calls necessary to
give us a silent log when compiling scala.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
I added a language.existential import to LazyCombiner.scala which
should not be necessary, but causes a spurious warning otherwise:
scala/src/library/scala/collection/parallel/mutable/LazyCombiner.scala:33:
warning: the existential type
scala.collection.parallel.mutable.LazyCombiner[_$1,_$2,_$3] forSome {
type _$1; type _$2; type _$3 <: scala.collection.generic.Growable[_$1] with scala.collection.generic.Sizing },
which cannot be expressed by wildcards, should be enabled by making the implicit value scala.language.existentials visible.
if (other.isInstanceOf[LazyCombiner[_, _, _]]) {
^
I created ticket SI-7750 to track this issue.
|
|
|
|
|
|
| |
I won't even try to explain the error reporting code, because
it would have no basis in reality. However this change appears
to fix the symptom reported.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Summary:
- Remove the last vestiges of xml from Predef and Contexts.
- Change build to compile scala.xml to scala-xml.jar.
- Deploy scala-xml module to maven.
- Update partest accordingly.
Note:
An older compiler cannot use the new standard library to
compile projects that use XML. Thus, skipping locker will
break the build until we use 2.11.0-M4 for STARR.
In the future build process, where we drop locker,
we would have to release a milestone that supports the old
and the new approach to xml. As soon as we'd be using that
new milestone for starr, we could drop support for the old approach.
|