Skip to content

Commit 5199cdf

Browse files
committed
Merge pull request scala#4539 from vsalvis/vsalvis-docfixes
Doc fixes
2 parents 6e07146 + 479fedb commit 5199cdf

File tree

6 files changed

+12
-31
lines changed

6 files changed

+12
-31
lines changed

src/build/genprod.scala

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -123,7 +123,10 @@ object FunctionOne extends Function(1) {
123123
* def apply(x: Int): Int = x + 1
124124
* }
125125
* assert(succ(0) == anonfun1(0))
126-
* """)
126+
* """) + """
127+
*
128+
* Note that the difference between `Function1` and [[scala.PartialFunction]]
129+
* is that the latter can specify inputs which it will not handle."""
127130

128131
override def moreMethods = """
129132
/** Composes two instances of Function1 in a new Function1, with this function applied last.
@@ -178,13 +181,7 @@ class Function(val i: Int) extends Group("Function") with Arity {
178181
*
179182
* {{{
180183
* object Main extends App {%s}
181-
* }}}
182-
*
183-
* Note that `Function1` does not define a total function, as might
184-
* be suggested by the existence of [[scala.PartialFunction]]. The only
185-
* distinction between `Function1` and `PartialFunction` is that the
186-
* latter can specify inputs which it will not handle.
187-
"""
184+
* }}}"""
188185

189186
def toStr() = "\"" + ("<function%d>" format i) + "\""
190187
def apply() = {

src/library/scala/Function0.scala

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
** |/ **
77
\* */
88
// GENERATED CODE: DO NOT EDIT.
9-
// genprod generated these sources at: Sun Sep 15 20:42:00 CEST 2013
9+
// genprod generated these sources at: Mon Jun 08 18:05:40 CEST 2015
1010

1111
package scala
1212

@@ -26,12 +26,6 @@ package scala
2626
* assert(javaVersion() == anonfun0())
2727
* }
2828
* }}}
29-
*
30-
* Note that `Function1` does not define a total function, as might
31-
* be suggested by the existence of [[scala.PartialFunction]]. The only
32-
* distinction between `Function1` and `PartialFunction` is that the
33-
* latter can specify inputs which it will not handle.
34-
3529
*/
3630
trait Function0[@specialized(Specializable.Primitives) +R] extends AnyRef { self =>
3731
/** Apply the body of this function to the arguments.

src/library/scala/Function1.scala

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,11 +25,8 @@ package scala
2525
* }
2626
* }}}
2727
*
28-
* Note that `Function1` does not define a total function, as might
29-
* be suggested by the existence of [[scala.PartialFunction]]. The only
30-
* distinction between `Function1` and `PartialFunction` is that the
31-
* latter can specify inputs which it will not handle.
32-
28+
* Note that the difference between `Function1` and [[scala.PartialFunction]]
29+
* is that the latter can specify inputs which it will not handle.
3330
*/
3431
@annotation.implicitNotFound(msg = "No implicit view available from ${T1} => ${R}.")
3532
trait Function1[@specialized(scala.Int, scala.Long, scala.Float, scala.Double) -T1, @specialized(scala.Unit, scala.Boolean, scala.Int, scala.Float, scala.Long, scala.Double) +R] extends AnyRef { self =>

src/library/scala/Function2.scala

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -25,12 +25,6 @@ package scala
2525
* assert(max(0, 1) == anonfun2(0, 1))
2626
* }
2727
* }}}
28-
*
29-
* Note that `Function1` does not define a total function, as might
30-
* be suggested by the existence of [[scala.PartialFunction]]. The only
31-
* distinction between `Function1` and `PartialFunction` is that the
32-
* latter can specify inputs which it will not handle.
33-
3428
*/
3529
trait Function2[@specialized(scala.Int, scala.Long, scala.Double) -T1, @specialized(scala.Int, scala.Long, scala.Double) -T2, @specialized(scala.Unit, scala.Boolean, scala.Int, scala.Float, scala.Long, scala.Double) +R] extends AnyRef { self =>
3630
/** Apply the body of this function to the arguments.

src/library/scala/collection/immutable/NumericRange.scala

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,9 @@ package immutable
1212

1313
import mutable.{ Builder, ListBuffer }
1414

15+
// TODO: Now the specialization exists there is no clear reason to have
16+
// separate classes for Range/NumericRange. Investigate and consolidate.
17+
1518
/** `NumericRange` is a more generic version of the
1619
* `Range` class which works with arbitrary types.
1720
* It must be supplied with an `Integral` implementation of the
@@ -28,9 +31,6 @@ import mutable.{ Builder, ListBuffer }
2831
* assert(r1 sameElements r2.map(_ - veryBig))
2932
* }}}
3033
*
31-
* TODO: Now the specialization exists there is no clear reason to have
32-
* separate classes for Range/NumericRange. Investigate and consolidate.
33-
*
3434
* @author Paul Phillips
3535
* @version 2.8
3636
* @define Coll `NumericRange`
@@ -266,7 +266,7 @@ object NumericRange {
266266
// Numbers may be big.
267267
val one = num.one
268268
val limit = num.fromInt(Int.MaxValue)
269-
def check(t: T): T =
269+
def check(t: T): T =
270270
if (num.gt(t, limit)) throw new IllegalArgumentException("More than Int.MaxValue elements.")
271271
else t
272272
// If the range crosses zero, it might overflow when subtracted

src/scaladoc/scala/tools/nsc/doc/html/page/Template.scala

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,6 @@ class Template(universe: doc.Universe, generator: DiagramGenerator, tpl: DocTemp
177177
<li class="hideall out"><span>Hide All</span></li>
178178
<li class="showall in"><span>Show all</span></li>
179179
</ol>
180-
<a href="http://docs.scala-lang.org/overviews/scaladoc/usage.html#members" target="_blank">Learn more about member selection</a>
181180
</div>
182181
}
183182
{

0 commit comments

Comments
 (0)