| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
SI-9361 fixed assert allowing display of improved error message.
|
| | |
|
|\ \
| | |
| | | |
SI-5463 Check .jars before using them
|
| | |
| | |
| | |
| | | |
Make broken JAR files on compiler classpath cause a fatal error
|
|\ \ \
| | | |
| | | | |
Make Range.Partial a value class
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | | |
Clean up JUnit tests, make sure they pass without bootstrap [ci: last-only]
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
Test classes not ending in "Test" are not executed in sbt. IntelliJ
runs them.
After this patch: 803 tests executed both in sbt and junit.
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
|\ \ \ \ \
| | | | | |
| | | | | | |
SI-9665 Backquoted vbar in extractor pattern
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Allow an infix extractor named `|`, when backquoted.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
SI-7916: ScriptEngine support
|
| | |/ / / /
| |/| | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Refactor the ScriptEngine support to an adaptor atop the
IMain API.
Allow references to resolve to context attributes. (The
attributes must be defined at compilation time, though
they may resolve to updated values at evaluation time.)
This means that attributes are not bound statically in
REPL history. In particular, we forgo the trick of binding
attributes named "name: Type" as typed values.
Instead, an `x` bound in dynamic context is injected into
the script as a dynamic selection `$ctx.x` where `ctx`
performs the look-up in the script context.
When a compiled script is re-evaluated, a new instance of
the script class is created and defined symbols are
rebound.
The context stdout writer is handled with `Console.withOut`,
with bytes decoded using the default charset.
Compilation errors are thrown as ScriptException with the
first reported error.
This commit doesn't attempt dynamic selection from objects
in context. Currently, script must cast.
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
[Build] Include missing web assets in scaladoc
|
|/ / / / / |
|
| | | | |
| | | | |
| | | | | |
Test for SI-7088, arrays containing tagged primitives
|
|\ \ \ \ \
| | | | | |
| | | | | | |
SI-9671, SI-7397 fix null.asInstanceOf[Int] when pt erases to Object
|
| | | | | | |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Erasure first replaces null.asInstanceOf[Int] by unbox(null). If the
expected type erases to object, erasure then introduces a box operation,
yielding box(unbox(null)). Note that this value is a box of zero, not
null.
Erasure has an optimization to replace box(unbox(x)) in case x is
of primitive type. 60f1b4b extended this to the case when x is null,
which is incorrect in general. The reason was to prevent creating a
primitive box to be stored in the unused generic field when creating
an instance of a specialized class. A special case ensures that this
optimization is still performed.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
We used to disable generation of static forwarders when a object had a
trait as a companion, as one could not add methods with bodies to an
interface in JVM 6.
The JVM lifted this restriction to support default methods in interfaces,
so we can lift the restriction on static forwarders, too.
Fixes https://github.com/scala/scala-dev/issues/59
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
SD-129 Mark JFunctionN as serializable
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Before this change, if these were used as the target type of a lambda
in Java source code, the lambda would not be serializable. This is
somewhat suprising when contrasted with the way that Scala lambdas
work in Scala source.
Since we copied these classes over from scala-java8-compat, that
project has opted to add Serializable as a parent to solve this issue.
This commit brings our copy of these interfaces into line with that
change.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
SI-8756 Fix generic signature for refinement of primitive
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Java generic signature generation was making the wrong
assumption about how refinement types should erase to
Java generics.
This commit passes through the current value of `primitiveOk`,
rather than forcing it to `true`.
This flag is true when generating the signature for `f2`,
but false in `i2` (as we are in a type argument position).
|
|/ / / / / /
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Java generic signatures assume that refinement types
should be boxed.
Why did `g2` in the test seem to be immune to this bug
demonstrated by `f2`? Because we opt to elide the generic
signature altogether when no generics are involved.
|
| | | | | | |
|
|\ \ \ \ \ \
| |_|_|_|/ /
|/| | | | | |
Improve performance and behavior of ListMap and ListSet
|
| | | | | | |
|
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
ListSet and ListMap are two collections which share the exact same internal structure. This commit makes the two approaches as similar as possible by renaming and reordering internal methods, improving their Scaladoc and their code style. The Scaladoc of the classes and companion objects is also improved in order to alert users of the time complexity of the collections' operations.
|
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Makes the immutable `ListMap` and `ListSet` collections more alike one another, both in their semantics and in their performance.
In terms of semantics, makes the `ListSet` iterator return the elements in their insertion order, as `ListMap` already does. While, as mentioned in SI-8985, `ListMap` and `ListSet` doesn't seem to make any guarantees in terms of iteration order, I believe users expect `ListSet` and `ListMap` to behave in the same way, particularly when they are implemented in the exact same way.
In terms of performance, `ListSet` has a custom builder that avoids creation in O(N^2) time. However, this significantly reduces its performance in the creation of small sets, as its requires the instantiation and usage of an auxilliary HashSet. As `ListMap` and `ListSet` are only suitable for small sizes do to their performance characteristics, the builder is removed, the default `SetBuilder` being used instead.
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
Merge 2.11.x to 2.12.x [ci: last-only]
|
| |\ \ \ \ \ \
| | |_|_|_|/ /
| |/| | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
merge/2.11.x-to-2.12.x-20160517
Conflicts:
build.sbt
test/files/run/repl-javap-app.check
test/files/run/repl-javap-app.scala
|
| | |\ \ \ \ \
| | | | | | | |
| | | | | | | | |
Eliminate major sources of daily noise in SBT build.
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
It avoids confusion with existing test/partest scripts
that test the compiler in build/, while sbt it targeting build-sbt/.
|
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
- Intercept incorrect "binary conflict" warning issued by SBT.
Fixes https://github.com/scala/scala-dev/issues/100
- Bump to a new version of pantsbuild/jarjar to fix an
incompatibility with Java 8 parameter names in class
files, which we run into on the 2.12.x branch. See:
https://github.com/pantsbuild/jarjar/pull/19
- Disable info level logging for dependency resolve/download.
|
| | |\ \ \ \ \ \
| | | | | | | | |
| | | | | | | | | |
SI-9740 Repl import fix -Yrepl-class-based
|
| | | |/ / / / /
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | |
| | | | | | | | |
Under `-Yrepl-class-based`, templating must follow the same scoping
as under traditional object-based. The new test shows a typical
case where two values of the same simple name must be imported in
different scopes.
|
| | | | | | | |
| | | | | | | |
| | | | | | | | |
An empty string yields an empty iterator.
|
|/ / / / / / /
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
Package definitions are priority 4.
Update the big example to be cut/pastable.
|
| |_|_|_|_|/
|/| | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
Many JUnit tests share a compiler instance between all
test cases in a class to reduce overhead.
This commit refactors the mechanism to reduce the boilerplate.
In the new scheme:
- Using the `@ClassRule` hook in JUnit, we create a per-class
map for each test class.
- Per-class values are registered from the test class itself
by calling `cached("someKey", () => mkExpensiveThing)`
- At the end of the test, the entries in this map are `close()`-ed
(if they implement `Closable`), and are released for
garbage collection.)
|
| | | | | | |
|
|\ \ \ \ \ \
| | | | | | |
| | | | | | | |
SI-9045 Error on recursive ctor
|
| | | | | | |
| | | | | | |
| | | | | | |
| | | | | | | |
If the constructor invokes itself, say so.
|