diff options
author | Antonio Cunei <antonio.cunei@epfl.ch> | 2010-01-18 16:45:48 +0000 |
---|---|---|
committer | Antonio Cunei <antonio.cunei@epfl.ch> | 2010-01-18 16:45:48 +0000 |
commit | 2cff99f2d2cff5a3e1b896177abbd2acda239744 (patch) | |
tree | 4e553e0c7d9d63dd6d8ecedaa8be51144db4308c /src/build/genprod.scala | |
parent | 7aa371b39388bc510e9cd3f081b2019b09da0a63 (diff) | |
download | scala-2cff99f2d2cff5a3e1b896177abbd2acda239744.tar.gz scala-2cff99f2d2cff5a3e1b896177abbd2acda239744.tar.bz2 scala-2cff99f2d2cff5a3e1b896177abbd2acda239744.zip |
Merged revisions 20538-20539,20543-20544,20549,...
Merged revisions
20538-20539,20543-20544,20549,20555-20556,20559-20562,20564-20566 via
svnmerge from https://lampsvn.epfl.ch/svn-repos/scala/scala/trunk
........
r20538 | extempore | 2010-01-15 19:00:51 +0100 (Fri, 15 Jan 2010) | 11 lines
Fix for #2365. Structural type mono and poly caches now wrap a soft
reference around cached classes so they do not interfere with garbage
collection. There is a test case, but it is in pending because I spent
longer trying to get it to fail under partest than I did writing
the actual patch. If you would like to see the behavior which was
corrected, go to
test/pending/run/bug2365
and run that script with scalac built before and after this commit.
Review by dubochet. ........ r20539 | extempore | 2010-01-15 20:48:57
+0100 (Fri, 15 Jan 2010) | 2 lines
Wrapped a buffered output stream around class file generation. This
has a nontrivial impact on total build time. Closes #2906. ........
r20543 | extempore | 2010-01-16 04:54:39 +0100 (Sat, 16 Jan 2010) | 2
lines
Exposed native Array clone() method. Closes #1051. Review by dragos.
........ r20544 | extempore | 2010-01-16 07:37:37 +0100 (Sat, 16 Jan
2010) | 2 lines
Made Iterator consistent with Iterable by adding grouped and sliding
to IterableLike. Closes #2837. Review by community. ........ r20549 |
extempore | 2010-01-16 22:52:44 +0100 (Sat, 16 Jan 2010) | 8 lines
New repl feature: you can start a line with . to invoke actions on the
previous result. For instance:
scala> (1 to 10).iterator
res0: Iterator[Int] = non-empty iterator
scala> .toList.sum
res1: Int = 55
........
r20555 | extempore | 2010-01-17 20:07:38 +0100 (Sun, 17 Jan 2010) | 2 lines
Brought ShowPickler somewhat more up to date with the current pickler
format. ........ r20556 | extempore | 2010-01-17 21:50:47 +0100 (Sun, 17
Jan 2010) | 2 lines
Don't insert whitespace on multiline strings and xml literals. Closes
#2115. No review. ........ r20559 | extempore | 2010-01-18 05:14:06
+0100 (Mon, 18 Jan 2010) | 1 line
Test case closes #1737. Review by community.
........
r20560 | extempore | 2010-01-18 05:14:25 +0100 (Mon, 18 Jan 2010) | 1 line
Fix and test case for #408. Review by community. ........ r20561 |
extempore | 2010-01-18 06:02:30 +0100 (Mon, 18 Jan 2010) | 4 lines
Adjectified some parts of speech as discussed on the mailing list. The
methods to call on FunctionN are "curried" and "tupled" with "curry"
deprecated and "tuple" gone. Closes #2907. Review by community. ........
r20562 | milessabin | 2010-01-18 13:20:57 +0100 (Mon, 18 Jan 2010) | 1
line
Fix and test case for #2891. No review necessary. ........ r20564 |
odersky | 2010-01-18 15:53:54 +0100 (Mon, 18 Jan 2010) | 1 line
cleaned up explicit tailcalls
........
r20565 | odersky | 2010-01-18 15:57:18 +0100 (Mon, 18 Jan 2010) | 1 line
some more performance tunings. No review.
........
r20566 | odersky | 2010-01-18 15:57:47 +0100 (Mon, 18 Jan 2010) | 1 line
new test. no review.
........
Diffstat (limited to 'src/build/genprod.scala')
-rw-r--r-- | src/build/genprod.scala | 16 |
1 files changed, 8 insertions, 8 deletions
diff --git a/src/build/genprod.scala b/src/build/genprod.scala index ae2a3d7972..099c24ef20 100644 --- a/src/build/genprod.scala +++ b/src/build/genprod.scala @@ -209,37 +209,37 @@ trait {className}{contraCoArgs} extends AnyRef {{ self => List.map2(xdefs, targs)("(%s: %s) => ".format(_, _)).mkString("", "", body) } - // (x1: T1) => ((x2: T2, x3: T3, x4: T4, x5: T5, x6: T6, x7: T7) => self.apply(x1,x2,x3,x4,x5,x6,x7)).curry + // (x1: T1) => ((x2: T2, x3: T3, x4: T4, x5: T5, x6: T6, x7: T7) => self.apply(x1,x2,x3,x4,x5,x6,x7)).curried def longCurry = (List.map2(xdefs, targs)(_ + ": " + _) drop 1).mkString( "(x1: T1) => ((", ", ", - ") => self.apply%s).curry".format(commaXs) + ") => self.apply%s).curried".format(commaXs) ) - // f(x1,x2,x3,x4,x5,x6) == (f.curry)(x1)(x2)(x3)(x4)(x5)(x6) + // f(x1,x2,x3,x4,x5,x6) == (f.curried)(x1)(x2)(x3)(x4)(x5)(x6) def curryComment = { """ - /** f%s == (f.curry)%s + /** f%s == (f.curried)%s */ """.format(commaXs, xdefs map ("(" + _ + ")") mkString) } def tupleMethod = { def comment = """ - /* f%s == (f.tuple)(Tuple%d%s) + /* f%s == (f.tupled)(Tuple%d%s) */ """.format(commaXs, i, commaXs) def body = "case Tuple%d%s => apply%s".format(i, commaXs, commaXs) - comment + " def tuple: Tuple%d%s => R = {\n %s\n }\n".format(i, invariantArgs, body) + comment + " def tupled: Tuple%d%s => R = {\n %s\n }\n".format(i, invariantArgs, body) } def curryMethod = { val body = if (i < 5) shortCurry else longCurry curryComment + - " def curry: %s => R = {\n %s\n }\n".format( + " def curried: %s => R = {\n %s\n }\n".format( targs mkString " => ", body - ) + ) + """ @deprecated("Use 'curried' instead")""" + "\n def curry = curried\n" } override def moreMethods = curryMethod + tupleMethod |