summaryrefslogtreecommitdiff
path: root/src/library/scala/Function0.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/library/scala/Function0.scala')
-rw-r--r--src/library/scala/Function0.scala28
1 files changed, 13 insertions, 15 deletions
diff --git a/src/library/scala/Function0.scala b/src/library/scala/Function0.scala
index 5fadb9ab27..d17122c0d8 100644
--- a/src/library/scala/Function0.scala
+++ b/src/library/scala/Function0.scala
@@ -5,35 +5,33 @@
** /____/\___/_/ |_/____/_/ | | **
** |/ **
\* */
-
-// generated by genprod on Sat Oct 16 11:19:09 PDT 2010 (with fancy comment)
+// GENERATED CODE: DO NOT EDIT.
+// genprod generated these sources at: Sat Feb 19 20:13:51 PST 2011
package scala
-
-
-/** Function with 0 parameters.
+/** A function of 0 parameters.
*
- * In the following example the definition of
- * currentSeconds is a shorthand for the anonymous class
- * definition anonfun0:
+ * In the following example, the definition of javaVersion is a
+ * shorthand for the anonymous class definition anonfun0:
*
* {{{
* object Main extends Application {
- * val currentSeconds = () => System.currentTimeMillis() / 1000L
+ * val javaVersion = () => sys.props("java.version")
*
- * val anonfun0 = new Function0[Long] {
- * def apply(): Long = System.currentTimeMillis() / 1000L
+ * val anonfun0 = new Function0[String] {
+ * def apply(): String = sys.props("java.version")
* }
- *
- * println(currentSeconds())
- * println(anonfun0())
+ * assert(javaVersion() == anonfun0())
* }
* }}}
*/
trait Function0[@specialized +R] extends AnyRef { self =>
+ /** Apply the body of this function to the arguments.
+ * @return the result of function application.
+ */
def apply(): R
- override def toString() = "<function0>"
+ override def toString() = "<function0>"
}