summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDominik Gruntz <dominik.gruntz@fhnw.ch>2014-08-06 17:12:20 +0200
committerAntoine Gourlay <antoine@gourlay.fr>2014-08-11 17:56:03 +0200
commit5cb672bdc6e8a662ddc68a07811956e78a134acf (patch)
tree9dc3aa9380b2babcc61d7a43268eb5ccb90f65d2 /src
parent2b78c32b42b55b96834df31824fdb081a095cf5f (diff)
downloadscala-5cb672bdc6e8a662ddc68a07811956e78a134acf.tar.gz
scala-5cb672bdc6e8a662ddc68a07811956e78a134acf.tar.bz2
scala-5cb672bdc6e8a662ddc68a07811956e78a134acf.zip
[backport] Fixes cut sentences in the generated scaladocs
This commit changes all first sentences of library functions which contain `i.e.` or `e.g.` and adds a `,` to prevent that the scaladoc summary sentence is cut after this abbreviation. This is possible as pull/3824 fixed how Scaladoc parses the first sentence of a method description into a sumary sentence(now the first sentence has to end with a dot followed by whitespace). Only docs in the core library are changed (src/library/**/*.scala) and only if they occur in the first sentence. Review by @heathermiller (cherry picked from commit 72721ff5dd06dea1235ecb71acae0bd61aee4814)
Diffstat (limited to 'src')
-rw-r--r--src/library/scala/collection/GenMapLike.scala2
-rw-r--r--src/library/scala/collection/TraversableOnce.scala2
-rw-r--r--src/library/scala/collection/immutable/Stream.scala2
-rw-r--r--src/library/scala/collection/immutable/StringLike.scala4
-rw-r--r--src/library/scala/concurrent/duration/Deadline.scala6
-rw-r--r--src/library/scala/math/BigDecimal.scala6
-rw-r--r--src/library/scala/math/BigInt.scala6
-rw-r--r--src/library/scala/runtime/ScalaRunTime.scala2
-rw-r--r--src/library/scala/sys/Prop.scala2
-rw-r--r--src/library/scala/util/Properties.scala2
-rw-r--r--src/library/scala/util/matching/Regex.scala2
11 files changed, 18 insertions, 18 deletions
diff --git a/src/library/scala/collection/GenMapLike.scala b/src/library/scala/collection/GenMapLike.scala
index 4e7d359251..bce9740522 100644
--- a/src/library/scala/collection/GenMapLike.scala
+++ b/src/library/scala/collection/GenMapLike.scala
@@ -102,7 +102,7 @@ trait GenMapLike[A, +B, +Repr] extends GenIterableLike[(A, B), Repr] with Equals
*/
def mapValues[C](f: B => C): GenMap[A, C]
- /** Compares two maps structurally; i.e. checks if all mappings
+ /** Compares two maps structurally; i.e., checks if all mappings
* contained in this map are also contained in the other map,
* and vice versa.
*
diff --git a/src/library/scala/collection/TraversableOnce.scala b/src/library/scala/collection/TraversableOnce.scala
index a8c4e047ab..13cd99d910 100644
--- a/src/library/scala/collection/TraversableOnce.scala
+++ b/src/library/scala/collection/TraversableOnce.scala
@@ -75,7 +75,7 @@ trait TraversableOnce[+A] extends Any with GenTraversableOnce[A] {
// at least indirectly. Currently, these are `ArrayOps` and `StringOps`.
// It is also implemented in `TraversableOnce[A]`.
/** A version of this collection with all
- * of the operations implemented sequentially (i.e. in a single-threaded manner).
+ * of the operations implemented sequentially (i.e., in a single-threaded manner).
*
* This method returns a reference to this collection. In parallel collections,
* it is redefined to return a sequential implementation of this collection. In
diff --git a/src/library/scala/collection/immutable/Stream.scala b/src/library/scala/collection/immutable/Stream.scala
index d3ff5e8abf..37a0b373da 100644
--- a/src/library/scala/collection/immutable/Stream.scala
+++ b/src/library/scala/collection/immutable/Stream.scala
@@ -469,7 +469,7 @@ self =>
else super.flatMap(f)(bf)
/** Returns all the elements of this `Stream` that satisfy the predicate `p`
- * in a new `Stream` - i.e. it is still a lazy data structure. The order of
+ * in a new `Stream` - i.e., it is still a lazy data structure. The order of
* the elements is preserved
*
* @param p the predicate used to filter the stream.
diff --git a/src/library/scala/collection/immutable/StringLike.scala b/src/library/scala/collection/immutable/StringLike.scala
index 8e1d950d00..738b294ce6 100644
--- a/src/library/scala/collection/immutable/StringLike.scala
+++ b/src/library/scala/collection/immutable/StringLike.scala
@@ -121,14 +121,14 @@ self =>
}
/** Return all lines in this string in an iterator, excluding trailing line
- * end characters, i.e. apply `.stripLineEnd` to all lines
+ * end characters, i.e., apply `.stripLineEnd` to all lines
* returned by `linesWithSeparators`.
*/
def lines: Iterator[String] =
linesWithSeparators map (line => new WrappedString(line).stripLineEnd)
/** Return all lines in this string in an iterator, excluding trailing line
- * end characters, i.e. apply `.stripLineEnd` to all lines
+ * end characters, i.e., apply `.stripLineEnd` to all lines
* returned by `linesWithSeparators`.
*/
@deprecated("Use `lines` instead.","2.11.0")
diff --git a/src/library/scala/concurrent/duration/Deadline.scala b/src/library/scala/concurrent/duration/Deadline.scala
index 61cbe47530..a25a478602 100644
--- a/src/library/scala/concurrent/duration/Deadline.scala
+++ b/src/library/scala/concurrent/duration/Deadline.scala
@@ -25,15 +25,15 @@ package scala.concurrent.duration
*/
case class Deadline private (time: FiniteDuration) extends Ordered[Deadline] {
/**
- * Return a deadline advanced (i.e. moved into the future) by the given duration.
+ * Return a deadline advanced (i.e., moved into the future) by the given duration.
*/
def +(other: FiniteDuration): Deadline = copy(time = time + other)
/**
- * Return a deadline moved backwards (i.e. towards the past) by the given duration.
+ * Return a deadline moved backwards (i.e., towards the past) by the given duration.
*/
def -(other: FiniteDuration): Deadline = copy(time = time - other)
/**
- * Calculate time difference between this and the other deadline, where the result is directed (i.e. may be negative).
+ * Calculate time difference between this and the other deadline, where the result is directed (i.e., may be negative).
*/
def -(other: Deadline): FiniteDuration = time - other.time
/**
diff --git a/src/library/scala/math/BigDecimal.scala b/src/library/scala/math/BigDecimal.scala
index bcbed645a7..5a81710986 100644
--- a/src/library/scala/math/BigDecimal.scala
+++ b/src/library/scala/math/BigDecimal.scala
@@ -617,10 +617,10 @@ extends ScalaNumber with ScalaNumericConversions with Serializable {
*/
def abs: BigDecimal = if (signum < 0) unary_- else this
- /** Returns the sign of this BigDecimal, i.e.
+ /** Returns the sign of this BigDecimal;
* -1 if it is less than 0,
- * +1 if it is greater than 0
- * 0 if it is equal to 0
+ * +1 if it is greater than 0,
+ * 0 if it is equal to 0.
*/
def signum: Int = this.bigDecimal.signum()
diff --git a/src/library/scala/math/BigInt.scala b/src/library/scala/math/BigInt.scala
index 689fc0c3e1..abc7371d9f 100644
--- a/src/library/scala/math/BigInt.scala
+++ b/src/library/scala/math/BigInt.scala
@@ -282,10 +282,10 @@ final class BigInt(val bigInteger: BigInteger) extends ScalaNumber with ScalaNum
*/
def abs: BigInt = new BigInt(this.bigInteger.abs())
- /** Returns the sign of this BigInt, i.e.
+ /** Returns the sign of this BigInt;
* -1 if it is less than 0,
- * +1 if it is greater than 0
- * 0 if it is equal to 0
+ * +1 if it is greater than 0,
+ * 0 if it is equal to 0.
*/
def signum: Int = this.bigInteger.signum()
diff --git a/src/library/scala/runtime/ScalaRunTime.scala b/src/library/scala/runtime/ScalaRunTime.scala
index 5fb24f2a36..f50059ce54 100644
--- a/src/library/scala/runtime/ScalaRunTime.scala
+++ b/src/library/scala/runtime/ScalaRunTime.scala
@@ -62,7 +62,7 @@ object ScalaRunTime {
}
/** Return the class object representing an unboxed value type,
- * e.g. classOf[int], not classOf[java.lang.Integer]. The compiler
+ * e.g., classOf[int], not classOf[java.lang.Integer]. The compiler
* rewrites expressions like 5.getClass to come here.
*/
def anyValClass[T <: AnyVal : ClassTag](value: T): jClass[T] =
diff --git a/src/library/scala/sys/Prop.scala b/src/library/scala/sys/Prop.scala
index 04c7b5108c..17ae8cb69c 100644
--- a/src/library/scala/sys/Prop.scala
+++ b/src/library/scala/sys/Prop.scala
@@ -20,7 +20,7 @@ package sys
* @since 2.9
*/
trait Prop[+T] {
- /** The full name of the property, e.g. "java.awt.headless".
+ /** The full name of the property, e.g., "java.awt.headless".
*/
def key: String
diff --git a/src/library/scala/util/Properties.scala b/src/library/scala/util/Properties.scala
index 2daa4de9a6..8835730d95 100644
--- a/src/library/scala/util/Properties.scala
+++ b/src/library/scala/util/Properties.scala
@@ -107,7 +107,7 @@ private[scala] trait PropertiesTrait {
val versionString = "version " + scalaPropOrElse("version.number", "(unknown)")
val copyrightString = scalaPropOrElse("copyright.string", "Copyright 2002-2013, LAMP/EPFL")
- /** This is the encoding to use reading in source files, overridden with -encoding
+ /** This is the encoding to use reading in source files, overridden with -encoding.
* Note that it uses "prop" i.e. looks in the scala jar, not the system properties.
*/
def sourceEncoding = scalaPropOrElse("file.encoding", "UTF-8")
diff --git a/src/library/scala/util/matching/Regex.scala b/src/library/scala/util/matching/Regex.scala
index f35ea566ba..2e1bfb02e4 100644
--- a/src/library/scala/util/matching/Regex.scala
+++ b/src/library/scala/util/matching/Regex.scala
@@ -543,7 +543,7 @@ object Regex {
if (start(i) >= 0) source.subSequence(start(i), end(i)).toString
else null
- /** All matched subgroups, i.e. not including group(0) */
+ /** All matched subgroups, i.e., not including group(0) */
def subgroups: List[String] = (1 to groupCount).toList map group
/** The char sequence before first character of match,