diff options
author | Adriaan Moors <adriaan.moors@typesafe.com> | 2015-08-05 10:58:25 -0700 |
---|---|---|
committer | Adriaan Moors <adriaan.moors@typesafe.com> | 2015-08-05 11:04:04 -0700 |
commit | ecf9128d8bf7a965492f0b714876650bba66b040 (patch) | |
tree | 406db7c5db708d03891b463613e3ecd8f210ce19 /src/reflect/scala | |
parent | b8744bafd7a9b3836932cd8348cc6d7cc83cec17 (diff) | |
parent | 928e6892d4fc10a953e0121fbefcae54bff1ab0c (diff) | |
download | scala-ecf9128d8bf7a965492f0b714876650bba66b040.tar.gz scala-ecf9128d8bf7a965492f0b714876650bba66b040.tar.bz2 scala-ecf9128d8bf7a965492f0b714876650bba66b040.zip |
Merge branch '2.11.x' into 2.12.x
Transcript:
```
➜ scala git:(2.12.x) export MB=$(git merge-base 2.12.x 2.11.x)
➜ scala git:(2.12.x) echo $MB
0e9525aa618a2eca143a1c7379ff1e6efd23b86e
➜ scala git:(2.12.x) g log --oneline --graph $MB...2.11.x
```
Read this upside down :-). The last merge comes first,
with merge commands interspersed in the git log.
```
➜ scala git:(2.12.x) g merge 2.11.x
Auto-merging versions.properties
Auto-merging src/reflect/scala/reflect/internal/pickling/UnPickler.scala
Auto-merging src/reflect/scala/reflect/internal/Types.scala
Auto-merging src/reflect/scala/reflect/internal/TreeGen.scala
Auto-merging src/library/scala/collection/immutable/Stream.scala
Auto-merging src/library/scala/collection/convert/Wrappers.scala
Auto-merging build.xml
CONFLICT (content): Merge conflict in build.xml
Auto-merging README.md
Automatic merge failed; fix conflicts and then commit the result.
```
```
* 928e6892d4 (scala/2.11.x, 2.11.x) Merge pull request #4682 from adriaanm/jline-quick.bin
|\
| * b763dbf368 (adriaanm/jline-quick.bin, jline-quick.bin) Include jline on quick.bin tool path
* | ccded7d179 Merge pull request #4680 from janekdb/2.11.x-option
|\ \
| |/
|/|
| * 58ae3e51f7 Delegate null test to Option
|/
* a745f06e35 Merge pull request #4670 from retronym/ticket/9422
|\
| * ec95e534a2 SI-9422 Fix incorrect constant propagation
* 65fa73dff3 Merge pull request #4669 from janekdb/2.11.x-scaladoc-reflect
|\
| * e206a1837d ScalaDoc fixes for reflect
* | 8e7e3b4a5f Merge pull request #4667 from janekdb/2.11.x-scaladoc-library-library-aux
|\ \
| |/
|/|
| * 69c2c106fe ScalaDoc fixes for library and library-aux
* | 7de4cbc5e5 Merge pull request #4665 from lrytz/asm-504-3
|\ \
| * | cdc55c29d0 Upgrade scala-asm to 5.0.4-scala-3
|/ /
* | d8da39a197 Merge pull request #4661 from retronym/ticket/9365
|\ \
| * | 0c99742c51 SI-9365 Don't null out dependencies of transient lazy vals
| /
* | 2279d3f3d9 Merge pull request #4662 from janekdb/2.11.x-redundant-val-modifier
|\ \
| * | 173a6fad95 Remove redundant 'val' from case class params.
* | | e0d21432d6 Merge pull request #4664 from SethTisue/remove-dead-link-in-readme
|\ \ \
| |_|/
|/| |
| * | 600fc4e6e1 fix readme for death of typesafe.artifactoryonline.com
| |/
* | 7492bda816 Merge pull request #4636 from SethTisue/contributor-stuff-from-github-wiki
|\ \
| |/
|/|
| * ed5098dbc4 merge two reviewers lists in readme
| * e136e4ad47 tighten up CONTRIBUTING.md a little
| * f9ca6863d4 readme/contributor's guide tweaks
| * 80e98b03a1 tiny readme fix
| * 197845620c merge in text from pull request policy from old wiki
| * e93ca409ae drop in pull request policy from old wiki
| * 951939d1b3 contributor guide: add a morsel salvaged from GitHub wiki
* f682441f6f Merge pull request #4653 from lrytz/t9403
|\
| * 2678d349b2 SI-9403 fix ICodeReader for negative BIPUSH / SIPUSH values
```
```
➜ scala git:(2.12.x) g merge -s ours f2d7838d90
Merge made by the 'ours' strategy.
```
```
* f2d7838d90 Merge pull request #4657 from lrytz/backports
|\
| * 241bb9ac19 Rename the ENUM / DEFAULTMETHOD flags to include JAVA_
| * 7a7f9927c3 SI-9393 fix modifiers of ClassBTypes for Java annotations
| * 8946d60bd2 [backport] Fix bytecode stability when running the closure optimizer
| * 3b6b2bfe9f [backport] SI-9392 Clarify the workaround comment and introduce a devWarning
| * 091c1e6ed8 [backport] SI-9392 Avoid crash in GenBCode for incoherent trees
| * 6177cb4481 [backport] SI-9393 Temporarily disable two assertions in GenBCode
| * a1d471f7ba [backport] Refactor the ClosureOptimizer, run ProdCons only once per method
| * f5e72765f2 [backport] SI-9387 Fix VerifyError introduced by indylambda
| * 41b99e2531 [backport] Integrate the LMFInvokeDynamic extractor into LambdaMetaFactoryCall
| * fc1cda2118 [backport] Small refactoring to the closure optimizer
| * 8f272c0ad2 [backport] Accessibility checks for methods with an InvokeDynamic instruction
| * 1c1d8259b5 [backport] Fix bytecode stability
| * ef9d845676 [backport] Support methodHandle / invokeDynamic constant pool entries in scalap
| * 60747c7555 [backport] Skip mirror class when invoking deserializeLambda
| * 404e86239e [backport] Prevent infinite recursion in ProdConsAnalyzer
| * 1b0703e74d [backport] SI-9376 don't crash when inlining a closure body that throws.
| * e511375a90 [backport] Fix superclass for Java interface symbols created in JavaMirrors
| * 1b57723169 [backport] `deserializeLambda` should not use encoded class name
| * 8bafa8ed88 [backport] Java parser: default methods in interfaces are not `DEFERRED`
| * 44e2761a9b [backport] SI-6613 fixed in GenBCode
```
```
➜ scala git:(2.12.x) g merge 4c6dcfe934
Auto-merging src/scaladoc/scala/tools/nsc/doc/html/page/Template.scala
Auto-merging doc/License.rtf
Auto-merging doc/LICENSE.md
Auto-merging build.xml
Auto-merging build.sbt
Merge made by the 'recursive' strategy.
Auto packing the repository in background for optimum performance.
See "git help gc" for manual housekeeping.
build.sbt | 2 +-
build.xml | 2 +-
doc/LICENSE.md | 4 ++--
doc/License.rtf | 4 ++--
src/scaladoc/scala/tools/nsc/doc/html/page/Template.scala | 2 +-
src/scalap/decoder.properties | 2 +-
6 files changed, 8 insertions(+), 8 deletions(-)
```
```
* | 4c6dcfe934 Merge pull request #4656 from lrytz/filtersOpenJDK
|\ \
| |/
|/|
| * 0b35bc29aa Ignore OpenJDK warnings in partest filters
* 6eb0812050 Merge pull request #4644 from SethTisue/copyright-2015
* e0aac7c9ef bump copyright year to 2015
```
Diffstat (limited to 'src/reflect/scala')
10 files changed, 14 insertions, 17 deletions
diff --git a/src/reflect/scala/reflect/api/Trees.scala b/src/reflect/scala/reflect/api/Trees.scala index 2bf407ee19..a43195d9b6 100644 --- a/src/reflect/scala/reflect/api/Trees.scala +++ b/src/reflect/scala/reflect/api/Trees.scala @@ -143,7 +143,7 @@ trait Trees { self: Universe => /** Find all subtrees matching predicate `p`. Same as `withFilter` */ def filter(f: Tree => Boolean): List[Tree] - /** Apply `pf' to each subtree on which the function is defined and collect the results. + /** Apply `pf` to each subtree on which the function is defined and collect the results. */ def collect[T](pf: PartialFunction[Tree, T]): List[T] diff --git a/src/reflect/scala/reflect/api/TypeTags.scala b/src/reflect/scala/reflect/api/TypeTags.scala index 7db375ca61..bc239ca870 100644 --- a/src/reflect/scala/reflect/api/TypeTags.scala +++ b/src/reflect/scala/reflect/api/TypeTags.scala @@ -53,7 +53,7 @@ import java.io.ObjectStreamException * Each of these methods constructs a `TypeTag[T]` or `ClassTag[T]` for the given * type argument `T`. * - * === #2 Using an implicit parameter of type `TypeTag[T]`, `ClassTag[T]`, or `WeakTypeTag[T] + * === #2 Using an implicit parameter of type `TypeTag[T]`, `ClassTag[T]`, or `WeakTypeTag[T]` * * For example: * {{{ diff --git a/src/reflect/scala/reflect/internal/ExistentialsAndSkolems.scala b/src/reflect/scala/reflect/internal/ExistentialsAndSkolems.scala index 0eeca4aace..3e18f88f80 100644 --- a/src/reflect/scala/reflect/internal/ExistentialsAndSkolems.scala +++ b/src/reflect/scala/reflect/internal/ExistentialsAndSkolems.scala @@ -110,7 +110,7 @@ trait ExistentialsAndSkolems { /** * Compute an existential type from hidden symbols `hidden` and type `tp`. * @param hidden The symbols that will be existentially abstracted - * @param hidden The original type + * @param tp The original type * @param rawOwner The owner for Java raw types. */ final def packSymbols(hidden: List[Symbol], tp: Type, rawOwner: Symbol = NoSymbol): Type = diff --git a/src/reflect/scala/reflect/internal/SymbolPairs.scala b/src/reflect/scala/reflect/internal/SymbolPairs.scala index 4763e77a34..a52d2d8510 100644 --- a/src/reflect/scala/reflect/internal/SymbolPairs.scala +++ b/src/reflect/scala/reflect/internal/SymbolPairs.scala @@ -217,7 +217,7 @@ abstract class SymbolPairs { bs(nshifted) |= nmask } - /** Implements `bs1 * bs2 * {0..n} != 0. + /** Implements `bs1 * bs2 * {0..n} != 0`. * Used in hasCommonParentAsSubclass */ private def intersectionContainsElementLeq(bs1: BitSet, bs2: BitSet, n: Int): Boolean = { val nshifted = n >> 5 diff --git a/src/reflect/scala/reflect/internal/TreeGen.scala b/src/reflect/scala/reflect/internal/TreeGen.scala index 894038dd0a..5c8ae17f5b 100644 --- a/src/reflect/scala/reflect/internal/TreeGen.scala +++ b/src/reflect/scala/reflect/internal/TreeGen.scala @@ -594,13 +594,12 @@ abstract class TreeGen { * TupleN(x_1, ..., x_N) * } ...) * - * If any of the P_i are variable patterns, the corresponding `x_i @ P_i' is not generated + * If any of the P_i are variable patterns, the corresponding `x_i @ P_i` is not generated * and the variable constituting P_i is used instead of x_i * - * @param mapName The name to be used for maps (either map or foreach) - * @param flatMapName The name to be used for flatMaps (either flatMap or foreach) * @param enums The enumerators in the for expression - * @param body The body of the for expression + * @param sugarBody The body of the for expression + * @param fresh A source of new names */ def mkFor(enums: List[Tree], sugarBody: Tree)(implicit fresh: FreshNameCreator): Tree = { val (mapName, flatMapName, body) = sugarBody match { diff --git a/src/reflect/scala/reflect/internal/Types.scala b/src/reflect/scala/reflect/internal/Types.scala index 9c681f3423..375218248e 100644 --- a/src/reflect/scala/reflect/internal/Types.scala +++ b/src/reflect/scala/reflect/internal/Types.scala @@ -739,7 +739,7 @@ trait Types * * `SubstThisAndSymMap` performs a breadth-first map over this type, which meant that * symbol substitution occurred before `ThisType` substitution. Consequently, in substitution - * of a `SingleType(ThisType(`from`), sym), symbols were rebound to `from` rather than `to`. + * of a `SingleType(ThisType(from), sym)`, symbols were rebound to `from` rather than `to`. */ def substThisAndSym(from: Symbol, to: Type, symsFrom: List[Symbol], symsTo: List[Symbol]): Type = if (symsFrom eq symsTo) substThis(from, to) @@ -763,7 +763,7 @@ trait Types /** Apply `f` to each part of this type */ def foreach(f: Type => Unit) { new ForEachTypeTraverser(f).traverse(this) } - /** Apply `pf' to each part of this type on which the function is defined */ + /** Apply `pf` to each part of this type on which the function is defined */ def collect[T](pf: PartialFunction[Type, T]): List[T] = new CollectTypeCollector(pf).collect(this) /** Apply `f` to each part of this type; children get mapped before their parents */ @@ -2059,7 +2059,7 @@ trait Types /** SI-3731, SI-8177: when prefix is changed to `newPre`, maintain consistency of prefix and sym * (where the symbol refers to a declaration "embedded" in the prefix). * - * @returns newSym so that `newPre` binds `sym.name` to `newSym`, + * @return newSym so that `newPre` binds `sym.name` to `newSym`, * to remain consistent with `pre` previously binding `sym.name` to `sym`. * * `newSym` and `sym` are conceptually the same symbols, but some change to our `prefix` diff --git a/src/reflect/scala/reflect/internal/pickling/UnPickler.scala b/src/reflect/scala/reflect/internal/pickling/UnPickler.scala index 951c155de6..15e0f9cc14 100644 --- a/src/reflect/scala/reflect/internal/pickling/UnPickler.scala +++ b/src/reflect/scala/reflect/internal/pickling/UnPickler.scala @@ -168,7 +168,7 @@ abstract class UnPickler { } /** If entry at `i` is undefined, define it by performing - * operation `op` with `readIndex at start of i'th + * operation `op` with `readIndex` at start of i'th * entry. Restore `readIndex` afterwards. */ protected def at[T <: AnyRef](i: Int, op: () => T): T = { diff --git a/src/reflect/scala/reflect/internal/util/AbstractFileClassLoader.scala b/src/reflect/scala/reflect/internal/util/AbstractFileClassLoader.scala index 30dcbc21ca..5cbdb92664 100644 --- a/src/reflect/scala/reflect/internal/util/AbstractFileClassLoader.scala +++ b/src/reflect/scala/reflect/internal/util/AbstractFileClassLoader.scala @@ -12,7 +12,7 @@ import java.security.cert.Certificate import java.security.{ ProtectionDomain, CodeSource } import java.util.{ Collections => JCollections, Enumeration => JEnumeration } -/** A class loader that loads files from a {@link scala.tools.nsc.io.AbstractFile}. +/** A class loader that loads files from a [[scala.reflect.io.AbstractFile]]. * * @author Lex Spoon */ diff --git a/src/reflect/scala/reflect/runtime/TwoWayCache.scala b/src/reflect/scala/reflect/runtime/TwoWayCache.scala index d0fc3dac74..6c1ca5b571 100644 --- a/src/reflect/scala/reflect/runtime/TwoWayCache.scala +++ b/src/reflect/scala/reflect/runtime/TwoWayCache.scala @@ -26,8 +26,7 @@ private[runtime] class TwoWayCache[J, S] { private object SomeRef { def unapply[T](optRef: Option[WeakReference[T]]): Option[T] = if (optRef.nonEmpty) { - val result = optRef.get.get - if (result != null) Some(result) else None + Option(optRef.get.get) } else None } diff --git a/src/reflect/scala/reflect/runtime/TwoWayCaches.scala b/src/reflect/scala/reflect/runtime/TwoWayCaches.scala index 6e2890e536..6ce0c0a728 100644 --- a/src/reflect/scala/reflect/runtime/TwoWayCaches.scala +++ b/src/reflect/scala/reflect/runtime/TwoWayCaches.scala @@ -26,8 +26,7 @@ private[runtime] trait TwoWayCaches { self: SymbolTable => private object SomeRef { def unapply[T](optRef: Option[WeakReference[T]]): Option[T] = if (optRef.nonEmpty) { - val result = optRef.get.get - if (result != null) Some(result) else None + Option(optRef.get.get) } else None } |