| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
This change allows to pattern match over type names, term names and
modifiers. Otherwise it can be quite painful to match over complex trees
as each name or modifiers requires a guard.
This pull request also changes the name of default constructor for term
and type names i.e. TypeName(s) instead of newTermName(s). This is
shorter to type, more consistent with the rest of reflection api and
consistent with the way it will be pattern matched later on.
|
|\
| |
| | |
Optimization in SpecializeTypes.
|
| |
| |
| |
| |
| | |
Avoid time traveling to find type parameters which will
never be there.
|
|\ \
| | |
| | | |
Remove stray debugging output line.
|
| | |
| | |
| | |
| | | |
I finally reached my "CHECK THREAD ACCESS" limit.
|
|\ \ \
| |/ /
|/| | |
PluginComponent contributes description to -Xshow-phases. (Fixes SI-6446)
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
In Global, SubComponent is called a phase descriptor, but it doesn't
actually have a description. (Phase itself does.) This fix adds
a description to PluginComponent so that plugins can describe what
they do in -Xshow-phases.
Elliptical descriptions
Exploded archives
Plugged-in partest
Roundup at the Little h!
|
|\ \
| | |
| | | |
SI-6809 Forbids deprecated case class definitions without parameter list
|
| | |
| | |
| | |
| | | |
This has been deprecated since at least 2.7.7, so it should be good to go.
|
|\ \ \
| | | |
| | | | |
Merge 2.10.x into master.
|
| |\ \ \
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
* origin/2.10.x: (31 commits)
Implicit vars should have non-implicit setters.
Deprecate `scala.tools.nsc.Phases` because it's dead-code.
scaladoc Template: remove duplicate code and several usages of Option.get.
adds scala-reflect.jar to MIMA in ant
Test showing the absence of a forward reference
update mailmap
Remove dead code from `Global`.
Cleanup MemberLookup. Better explain ambiguous link targets.
typedIdent no longer destroys attachments
fixes incorrect handling of Annotated in lazy copier
simplifies checkBounds
Recurse into instantiations when stripping type vars.
Extract base scaladoc functionality for the IDE.
Expand pattern match position tests.
SI-6288 Remedy ill-positioned extractor binding.
SI-6288 Fix positioning of label jumps
SI-6288 Position argument of unapply
Fixes SI-6758: force LazyAnnnotationInfo for DefDef and TypeDef
SI-6795 Simplify errors related to "abstract override" on type members
SI-6795 Adds negative check for "abstract override" on types in traits
...
Conflicts:
.mailmap
src/compiler/scala/tools/nsc/Global.scala
src/compiler/scala/tools/nsc/ast/DocComments.scala
src/compiler/scala/tools/nsc/doc/base/CommentFactoryBase.scala
src/compiler/scala/tools/nsc/doc/html/page/Source.scala
src/compiler/scala/tools/nsc/doc/html/page/Template.scala
src/compiler/scala/tools/nsc/doc/model/LinkTo.scala
src/compiler/scala/tools/nsc/doc/model/MemberLookup.scala
src/compiler/scala/tools/nsc/doc/model/diagram/DiagramFactory.scala
src/compiler/scala/tools/nsc/transform/SpecializeTypes.scala
src/compiler/scala/tools/nsc/typechecker/Typers.scala
src/reflect/scala/reflect/runtime/JavaMirrors.scala
test/scaladoc/run/links.scala
|
| | |\ \ \
| | | | | |
| | | | | | |
scaladoc Template: remove duplicate code and several usages of Option.get.
|
| | | | | | |
|
| | |\ \ \ \
| | | | | | |
| | | | | | | |
Merge 2.10.0-wip into 2.10.x
|
| | | |\ \ \ \
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
# By Eugene Burmako (1) and others
# Via Adriaan Moors (2) and others
* origin/2.10.0-wip:
Fixing OSGi distribution.
Fix for rangepos crasher.
SI-6685 fixes error handling in typedApply
|
| | |\ \ \ \ \ \
| | | |/ / / / /
| | |/| | | | | |
Implicit vars should have non-implicit setters.
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Otherwise they trigger spurious feature warnings.
scala> trait T { implicit var a: Any }
<console>:7: warning: implicit conversion method a_= should
be enabled by making the implicit value
language.implicitConversions visible.
|
| | |\ \ \ \ \ \
| | | | | | | | |
| | | | | | | | | |
SI-6795 simplify "abstract override" errors on type members
|
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | | |
Instead of saying "only allowed on non-type members of traits" use
separate errors for "not allowed on types" and "only allowed on members
of traits"
|
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | | |
"abstract override" shouldn't was being allowed on types in traits but the result
made no sense and the spec says that shouldn't be allowed.
|
| | |\ \ \ \ \ \ \
| | | | | | | | | |
| | | | | | | | | | |
Cleanup MemberLookup. Better explain ambiguous link targets.
|
| | | | |_|_|/ / /
| | | |/| | | | | |
|
| | |\ \ \ \ \ \ \
| | | | | | | | | |
| | | | | | | | | | |
Remove dead code from `Global`.
|
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | | |
The 0a2022c made `scala.tools.nsc.Phases` dead-code. It's not private
so it got deprecated instead of being removing right away.
Review by @paulp.
|
| | | |/ / / / / /
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | |
| | | | | | | | | |
This is clearly dead-code (`phaseTimings` is not referred
anywhere else in `Global.scala`) and it's safe to remove it since
`phaseTimings` is private.
This dead-code is leftover from 317a1056.
Review by @paulp.
|
| | |\ \ \ \ \ \ \
| | | | | | | | | |
| | | | | | | | | | |
SI-3995 Exclude companions with an existential prefix.
|
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | |
| | | | | | | | | | |
In `(qual: Q).apply(expr)` where `expr` must be implictily
converted to a path dependent type `T` defined in `qual`,
we were looking for companion implicits via a path prefixed
by an existential skolem `_1`. These aren't much good to us,
as when we try to feed them into `mkAttributedQualifer`, a
crash rightly ensues.
This commit excludes companions prefixed by an existentially
bound path.
|
| | |\ \ \ \ \ \ \ \
| | | | | | | | | | |
| | | | | | | | | | | |
SI-6548 reflection now correctly enters jinners
|
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
initClassModule => initClassAndModule
createClassModule => initAndEnterClassAndModule
|
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
When completing Java classes, runtime reflection enumerates their
fields, methods, constructors and inner classes, loads them and
enters them into either the instance part (ClassSymbol) or the
static part (ModuleSymbol).
However unlike fields, methods and constructors, inner classes don't
need to be entered explicitly - they are entered implicitly when
being loaded.
This patch fixes the double-enter problem, make sure that enter-on-load
uses the correct owner, and also hardens jclassAsScala against double
enters that can occur in a different scenario.
Since the fix is about Java-compiled classes, the test needs *.class
artifacts produced by javac. Therefore I updated javac-artifacts.jar to
include the new artifacts along with their source code.
|
| | |\ \ \ \ \ \ \ \ \
| | | | | | | | | | | |
| | | | | | | | | | | | |
fixes incorrect handling of Annotated in lazy copier
|
| | | | | | | | | | | | |
|
| | |\ \ \ \ \ \ \ \ \ \
| | | |_|_|_|_|_|/ / / /
| | |/| | | | | | | | | |
SI-5390 Detect forward reference of case class apply
|
| | | | |_|/ / / / / /
| | | |/| | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
Refchecks performs (among others) two tasks at once:
- detecting forward references
- translating `qual.Case(...)` to `new qual.Case(...)`
As is often the case with such multi-tasking tree traversals,
completion of one task precluded the other.
|
| | |\ \ \ \ \ \ \ \ \
| | | | | | | | | | | |
| | | | | | | | | | | | |
SI-5361 Avoid cyclic type with malformed refinement
|
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | | |
Check for malformed stats in the refinement body in
the same place we check for erroneous parents.
|
| | | |/ / / / / / / /
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
The statement `val x = this` in the refinment type:
(new {}): {val x = this}
is lazily typechecked, in order to, according to the comment
in `typedRefinment, "avoid cyclic reference errors".
But the approximate type used ends up with:
Refinment@1(
parents = [...]
decls = { val x: Refinement@1 })
This commit eagerly checks that there is no term definitions
in type refinments, rather than delaying this.
This changes the error message for SI-3614.
|
| | |\ \ \ \ \ \ \ \ \
| | | | | | | | | | | |
| | | | | | | | | | | | |
typedIdent no longer destroys attachments
|
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | | |
When transforming Idents to qualified Selects, typedIdent used to forget
about carrying original attachments to the resulting tree. Not anymore.
|
| | |\ \ \ \ \ \ \ \ \ \
| | | |_|_|_|_|/ / / / /
| | |/| | | | | | | | | |
SI-6288 Perfecting positions
|
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | | |
The call to `Option#get` on the result of the
unapply method was unpositioned and ended up
with the position of the `match`.
|
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | | |
ICode generation was assigning the position of
the last label jump to all jumps to that particular
label def.
This problem is particularly annoying under the new
pattern matcher: a breakpoint in the body of the final
case will be triggered on the way out of the body of
any other case.
Thanks to @dragos for the expert guidance as we
wended our way through GenICode to the troublesome
code. Chalk up another bug for mutability.
I believe that the ICode output should be stable
enough to use a a .check file, if it proves otherwise
we should make it so.
|
| | | | |_|/ / / / / /
| | | |/| | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
`atPos(pos) { ... }` doesn't descend into children of
already positioned trees, we need to manually set the
position of `CODE.REF(binder)` to that of the stunt double
`Ident(nme.SELECTOR_DUMMY)`.
|
| | |\ \ \ \ \ \ \ \ \
| | | | | | | | | | | |
| | | | | | | | | | | | |
s/SuperCallArgs/SuperArgs/
|
| | | |/ / / / / / / /
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
Applies a minor renaming that I failed to thoroughly perform
in the last pull request which refactored parent types.
|
| | |\ \ \ \ \ \ \ \ \
| | | | | | | | | | | |
| | | | | | | | | | | | |
prevents spurious kind bound errors
|
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | |
| | | | | | | | | | | | |
This patch is an isomorphic transformation of checkBounds, which avoids
doing any checks altogether if the scrutinee is already erroneous.
Inspection of checkKindBounds and isWithinBounds called from checkBounds
suggests that they don't perform side effects which can't be omitted.
|
| | | |/ / / / / / / /
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
The patch adds a check which makes sure that the trees we're about to
report aren't already erroneous.
|
| | |\ \ \ \ \ \ \ \ \
| | | | | | | | | | | |
| | | | | | | | | | | | |
When we strip tvars we should also recursively strip their instantiation...
|
| | | | |_|_|_|/ / / /
| | | |/| | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | |
| | | | | | | | | | | |
This led to the inference of weird types as list
of lub base types was empty.
This change fixes case x3 in the test case.
|