| Commit message (Collapse) | Author | Age | Files | Lines |
|\
| |
| | |
SI-10225 Either docs compile
|
| |
| |
| |
| | |
Per Seth.
|
| |
| |
| |
| |
| |
| |
| |
| | |
But without tut support, who knows.
Boy scout aligns stars and updates several
examples that didn't infer types in a way
that compiles.
|
|/
|
|
|
|
| |
As reported by @djvulee, there was an error in
the example explaining the confusing behavior
of `MatchIterator`. It's really confusing.
|
|
|
|
|
|
|
|
|
| |
`scala.color` now has 3 states: `true`, `false` and `auto`
(the default). `auto` allows colors if not on windows and if the shell
is interactive (as in, both stdin and stdout are a tty).
The autodetect works as expected when run via SBT too, and it can always
be overriden on the CLI or via JAVA_OPTS.
|
|\
| |
| | |
Override equals and hashCode for WrappedArray
|
| | |
|
|/
|
|
|
|
|
|
| |
"sbt" is not an acronym (it used to be, but it isn't any longer).
It's a proper name, like "iPhone" or "eBay".
So, just like you wouldn't write "Get Started With EBay" or
"How To Reset Your IPhone", we don't write "Using the Sbt Build".
|
|
|
|
|
|
| |
This reverts commit 656162bb48fbbd703790a2c94d4563e40ddfdfc2.
Adding new APIs is not possible until a major release.
|
| |
|
|\
| |
| | |
SI-9750 scala.util.Properties.isJavaAtLeast works with JDK9
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Don't assume spec is just major, but allow arbitrary version
number for both spec value and user value to check.
Only the first three dot-separated fields are considered,
after skipping optional leading value "1" in legacy format.
Minimal validity checks of user arg are applied. Leading three
fields, if present, must be number values, but subsequent
fields are ignored.
Note that a version number is not a version string, which
optionally includes pre and build info, `9-ea+109`.
|
| |
| |
| |
| |
| | |
A good opportunity to simplify the API. Versions are strings,
but a spec version is just a number.
|
| |
| |
| |
| |
| |
| |
| | |
Leaves the error string as is, but adds test to show how it looks.
Java calls it a version number. `Not a version: 1.9`.
Don't strip `1.` prefix recursively. (That was Snytt's fault.)
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
The utility method compares javaSpecVersion, which has the
form "1.8" previously and "9" going forward.
The method accepts "1.n" for n < 9. More correctly, the string
argument should be a single number.
Supports JEP-223.
|
| |
| |
| |
| |
| |
| | |
just in time for Halloween. "boostrap" is definitely the most
adorable typo evah -- and one of the most common, too. but we don't
want to scare anybody.
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
for two reasons:
* to facilitate warning-free cross-compilation between Scala 2.11
and 2.12
* because it's not clear that .swap is a good replacement for .left
Either.right seems almost certain to be deprecated in 2.13.
Either.left's future is uncertain; see discussion (and links to
additional discussions) at https://github.com/scala/scala/pull/5135
|
| |
| |
| |
| | |
Also consistently use "LAMP/EPFL" and not "EPFL LAMP".
|
|\ \
| | |
| | | |
Reduce deprecations and warnings
|
| | | |
|
|\ \ \
| |/ /
|/| | |
Improve Scaladoc for Either:
|
| | |
| | |
| | |
| | |
| | | |
- remove text on projections
- add for comprehensions
|
|\ \ \
| | | |
| | | | |
Deprecate and rename Left#a/Right#b to Left#value/Right#value
|
| |/ / |
|
|\ \ \
| |/ /
|/| | |
SI-9827 MatchIterator advances itself
|
| |/
| |
| |
| |
| |
| |
| |
| |
| |
| | |
To avoid caveats about calling `next` (or `hasNext`) before
using `MatchData` methods on `MatchIterator`, just do it
internally as necessary.
Note `MatchIterator` behavior in the docs.
Added tests showing what people cried about.
|
|\ \
| |/
|/| |
Right-bias Either
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- Add operations like map, flatMap which assume right-bias
- Deprecate {Left,Right}Projection
- Deprecate left and right in favor of swap
- Add contains, toOption, toTry, toSeq and filterOrElse
- toSeq returns collection.immutable.Seq instead of collection.Seq
- Don't add get
There are no incompatible changes.
The only possibility of breakage that exists is when people have added
extension methods named map, flatMap etc. to Either in the past doing
something different than the methods added to Either now.
One detail that moved the scales in favor of deprecating LeftProjection
and RightProjection was the desire to have toSeq return
scala.collection.immutable.Seq instead of scala.collection.Seq
like LeftProjection and RightProjection do.
Therefore keeping LeftProjection and RightProjection would introduce
inconsistency.
filter is called filterOrElse because filtering in a for-comprehension
doesn't work if the method needs an explicit argument.
contains was added as safer alternative to
if (either.isRight && either.right.get == $something) ...
While adding filter with an implicit zero value is possible, it's
dangerous as it would require that developers add a "naked" implicit
value of type A to their scope and it would close the door to a future
in which the Scala standard library ships with Monoid and filter could
exist with an implicit Monoid parameter.
|
| | |
|
|/ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Delegate `Match group name` to the underlying `matcher`.
If that fails, try explicit group names as a fall back.
No attempt is made to correlate inline and explicit names.
In the following case, either name is accepted:
```
new Regex("a(?<Bar>b*)c", "Bee")
```
But if names are reversed, the error is undetected:
```
new Regex("a(?<Bee>b*)(?<Bar>c)", "Bar", "Bee")
```
Throw IllegalArg on bad group name to be consistent with Java.
|
|
|
|
|
|
| |
- Extend main comment with additional examples
- Group methods from a user perspective
- List exceptions special cased by shouldRethrow
- Include overlooked withTry in opt, either notes.
|
| |
|
|\
| |
| | |
Accomodate and exploit new library, lang features JDK 8
|
| | |
|
| | |
|
|/
|
|
|
|
| |
- Add unit test for andFinally
- Reduce code duplication in andFinally
- Extend documentation
|
|\
| |
| | |
Added Properties.isLinux to compliment the isWin and isMac methods
|
| | |
|
|\ \
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
merge/2.11.x-to-2.12.x-20160225
Conflicts:
scripts/jobs/integrate/bootstrap
src/build/maven/scala-actors-pom.xml
test/files/pos/t3420.flags
Conflicts were trivial to resolve.
|
| | |
| | |
| | |
| | |
| | | |
google code is dead
http://google-opensource.blogspot.jp/2015/03/farewell-to-google-code.html
|
|\| |
| |/
|/|
| |
| |
| |
| |
| |
| | |
Conflicts:
src/library/scala/collection/Iterator.scala
|
`-- trivial conflicts only. Parens were added to the
next() calls in 2.12.x, while in the meantime
`{Concat,Join}Iterator` were optimized in 2.11.x
|
| | |
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
- Language imports are preceding other imports
- Deleted empty file: InlineErasure
- Removed some unused private[parallel] methods in
scala/collection/parallel/package.scala
This removes hundreds of warnings when compiling with
"-Xlint -Ywarn-dead-code -Ywarn-unused -Ywarn-unused-import".
|
| | |
|
|\|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
there were merge conflicts in the Eclipse config that I resolved with
--ours. I invite @performantdata to submit a followup PR bringing the
Eclipse stuff into a good state on 2.12.x.
there was a test failure in
test/junit/scala/collection/mutable/OpenHashMapTest.scala
due to the 2.12 compiler emitting the field backing a
private var differently (with an unmangled name). Lukas
says the difference is expected, so I just updated the
code in the test.
there were no other merge conflicts.
% git log --decorate --oneline -1 origin/2.11.x | cat
ae5f0de (origin/HEAD, origin/2.11.x) Merge pull request #4791 from performantdata/issue/9508
% git log --decorate --oneline -1 origin/2.12.x | cat
c99e53e (HEAD -> 2.12.x, origin/2.12.x) Merge pull request #4797 from lrytz/M3-versions
% export MB=$(git merge-base 2.12.x origin/2.11.x)
% echo $MB
42cafa21f3c4a08c6dd34608278f810b6ec2886f
% git log --graph --oneline --decorate $MB...origin/2.11.x | cat
* ae5f0de (origin/HEAD, origin/2.11.x) Merge pull request #4791 from performantdata/issue/9508
|\
| * 08dca37 (origin/pull/4791) SI-9508 fix classpaths in Eclipse configuration
* | fe76232 Merge pull request #4798 from performantdata/issue/9513
|\ \
| * | 9c97a7f (origin/pull/4798) Suppress unneeded import.
| * | 30d704d Document some OpenHashMap internal methods.
| * | 1fb32fc SI-9513 decrement "deleted" count in OpenHashMap.put() when slot reused
| |/
* | 14f875c Merge pull request #4788 from dk14/patch-1
|\ \
| * | 42acd55 (origin/pull/4788) explicitly specify insertion-order feature in docs
| /
* | 68ce049 Merge pull request #4771 from som-snytt/issue/9492-here
|\ \
| * | f290962 (origin/pull/4771) SI-9492 Line trimming paste
| * | bc3589d SI-9492 REPL paste here doc
| /
* | 9834fc8 Merge pull request #4610 from todesking/spec-implicits-remove-obsolete
|\ \
| * | 46009b1 (origin/pull/4610) Add view/context-bound parameter ordering rule
| * | 6eba305 Spec: Implicit parameters with context/view bound is allowed since 2.10
| /
* | d792e35 Merge pull request #4789 from janekdb/2.11.x-param-names-predicates-operations
|\ \
| |/
|/|
| * b19a07e (origin/pull/4789) Rename forall, exists and find predicate and operator params.
|/
* 648c7a1 Merge pull request #4790 from SethTisue/issue/9501
|\
| * 40d12f1 (origin/pull/4790) SI-9501 link README to Scala Hacker Guide
* e0b5891 Merge pull request #4786 from performantdata/issue/9506
* 39acad8 (origin/pull/4786) SI-9506 suppress Scala IDE-generated files in the Eclipse project dirs
* 74dc364 SI-9506 suppress Scala IDE-generated files in the Eclipse project dirs
% git merge ae5f0de
Auto-merging src/repl/scala/tools/nsc/interpreter/ILoop.scala
Auto-merging src/library/scala/util/Either.scala
Auto-merging src/library/scala/runtime/Tuple3Zipped.scala
Auto-merging src/library/scala/runtime/Tuple2Zipped.scala
Auto-merging src/library/scala/collection/parallel/ParIterableLike.scala
Auto-merging src/library/scala/collection/immutable/ListMap.scala
Auto-merging src/library/scala/collection/TraversableLike.scala
Auto-merging src/eclipse/test-junit/.classpath
CONFLICT (content): Merge conflict in src/eclipse/test-junit/.classpath
Auto-merging src/eclipse/scaladoc/.classpath
CONFLICT (content): Merge conflict in src/eclipse/scaladoc/.classpath
Auto-merging src/eclipse/scala-compiler/.classpath
Auto-merging src/eclipse/repl/.classpath
CONFLICT (content): Merge conflict in src/eclipse/repl/.classpath
Auto-merging src/eclipse/partest/.classpath
CONFLICT (content): Merge conflict in src/eclipse/partest/.classpath
Auto-merging src/eclipse/interactive/.classpath
Auto-merging README.md
Automatic merge failed; fix conflicts and then commit the result.
% git checkout --ours src/eclipse/partest/.classpath
% git checkout --ours src/eclipse/repl/.classpath
% git checkout --ours src/eclipse/scaladoc/.classpath
% git checkout --ours src/eclipse/test-junit/.classpath
% git add -u
% emacs test/junit/scala/collection/mutable/OpenHashMapTest.scala
% git diff test/junit/scala/collection/mutable/OpenHashMapTest.scala | cat
...
- val field = m.getClass.getDeclaredField("scala$collection$mutable$OpenHashMap$$deleted")
+ val field = m.getClass.getDeclaredField("deleted")
...
% git add -u
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
Align parameters names to use p for predicates and op for combining operations.
Based on #4760. Extended to include,
- Tuple2Zipped
- Tuple3Zipped
- Either
The original author was vsalvis.
|
|\| |
|
| |
| |
| |
| |
| |
| |
| | |
a little piece of #4644 I missed. fixes this:
% scala -version
Scala code runner version 2.11.7 -- Copyright 2002-2013, LAMP/EPFL
|