diff options
author | Antonio Cunei <antonio.cunei@epfl.ch> | 2009-12-23 11:36:08 +0000 |
---|---|---|
committer | Antonio Cunei <antonio.cunei@epfl.ch> | 2009-12-23 11:36:08 +0000 |
commit | 4069be072e8ad7ec53a1d91a639c03ad96d98070 (patch) | |
tree | dd49b65b4e9b28e8b47de46448efaedb84046357 /src/scalap | |
parent | 648a50a76eb865b3891092aff0fc06a92a9edf1c (diff) | |
download | scala-4069be072e8ad7ec53a1d91a639c03ad96d98070.tar.gz scala-4069be072e8ad7ec53a1d91a639c03ad96d98070.tar.bz2 scala-4069be072e8ad7ec53a1d91a639c03ad96d98070.zip |
Merged revisions 20262-20263,20266-20267,20269-...
Merged revisions
20262-20263,20266-20267,20269-20270,20284,20287-20289,20292,20294-20297,
20300 via svnmerge from
https://lampsvn.epfl.ch/svn-repos/scala/scala/trunk
........
r20262 | phaller | 2009-12-21 17:03:07 +0100 (Mon, 21 Dec 2009) | 1 line
closed #2829. review by rompf.
........
r20263 | phaller | 2009-12-21 17:36:37 +0100 (Mon, 21 Dec 2009) | 1 line
small correction in doc comment. no review.
........
r20266 | phaller | 2009-12-21 18:16:55 +0100 (Mon, 21 Dec 2009) | 1 line
closed #2181. no review.
........
r20267 | odersky | 2009-12-21 18:30:23 +0100 (Mon, 21 Dec 2009) | 3 lines
(1) Added some classes to allow arbitrary patches to source buffers.
These are not yet complete so do not need a review yet I think. (2)
Avoided reflexive array operations in ScalaRunTime. review by community.
........ r20269 | phaller | 2009-12-21 20:28:18 +0100 (Mon, 21 Dec 2009)
| 1 line
closed #1449. review by community.
........
r20270 | odersky | 2009-12-21 20:41:51 +0100 (Mon, 21 Dec 2009) | 2 lines
Closed #2709. Thanks for the patch! Review by community. ........
r20284 | rytz | 2009-12-22 10:56:21 +0100 (Tue, 22 Dec 2009) | 1 line
close #2809. thanks for the small example. review by community
........ r20287 | rytz | 2009-12-22 13:22:56 +0100 (Tue, 22 Dec 2009) |
1 line
fix the build. no review.
........
r20288 | prokopec | 2009-12-22 15:00:58 +0100 (Tue, 22 Dec 2009) | 2 lines
fixed #2548 - reverse, reverseIterator for views bug. Also - reverseMap for views now should work.
review by phaller.
........
r20289 | prokopec | 2009-12-22 15:32:16 +0100 (Tue, 22 Dec 2009) | 2 lines
Small change in test.
no review
........
r20292 | odersky | 2009-12-22 18:11:54 +0100 (Tue, 22 Dec 2009) | 1 line
Closes #2819, #2705, #2805. Review by community.
........
r20294 | odersky | 2009-12-22 18:57:13 +0100 (Tue, 22 Dec 2009) | 1 line
Closes #2812 (and removed a left-over println in Types). no review
necessary. ........ r20295 | phaller | 2009-12-22 19:15:43 +0100 (Tue,
22 Dec 2009) | 1 line
Closes #2538. no review necessary.
........
r20296 | extempore | 2009-12-22 21:11:29 +0100 (Tue, 22 Dec 2009) | 3 lines
Took full advantage of the new =>? alias for the superverbosely named
PartialFunction by renaming every usage of the latter except when in
comments. ........ r20297 | odersky | 2009-12-23 00:42:37 +0100 (Wed, 23
Dec 2009) | 2 lines
tentative fix for RC5 lift build problem.
........
r20300 | odersky | 2009-12-23 01:22:11 +0100 (Wed, 23 Dec 2009) | 2 lines
Another fix to make lift build under RC5; review by dragos ........
Diffstat (limited to 'src/scalap')
-rw-r--r-- | src/scalap/scala/tools/scalap/scalax/rules/Rule.scala | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/scalap/scala/tools/scalap/scalax/rules/Rule.scala b/src/scalap/scala/tools/scalap/scalax/rules/Rule.scala index 1500b81050..f65c688aa7 100644 --- a/src/scalap/scala/tools/scalap/scalax/rules/Rule.scala +++ b/src/scalap/scala/tools/scalap/scalax/rules/Rule.scala @@ -56,9 +56,9 @@ trait Rule[-In, +Out, +A, +X] extends (In => Result[Out, A, X]) { def ^^[B](fa2b : A => B) = map(fa2b) - def ^^?[B](pf : PartialFunction[A, B]) = filter (pf.isDefinedAt(_)) ^^ pf + def ^^?[B](pf : A =>? B) = filter (pf.isDefinedAt(_)) ^^ pf - def ??(pf : PartialFunction[A, Any]) = filter (pf.isDefinedAt(_)) + def ??(pf : A =>? Any) = filter (pf.isDefinedAt(_)) def -^[B](b : B) = map { any => b } @@ -73,7 +73,7 @@ trait Rule[-In, +Out, +A, +X] extends (In => Result[Out, A, X]) { def >->[Out2, B, X2 >: X](fa2resultb : A => Result[Out2, B, X2]) = flatMap { a => any => fa2resultb(a) } - def >>?[Out2, B, X2 >: X](pf : PartialFunction[A, Rule[Out, Out2, B, X2]]) = filter(pf isDefinedAt _) flatMap pf + def >>?[Out2, B, X2 >: X](pf : A =>? Rule[Out, Out2, B, X2]) = filter(pf isDefinedAt _) flatMap pf def >>&[B, X2 >: X](fa2ruleb : A => Out => Result[Any, B, X2]) = flatMap { a => out => fa2ruleb(a)(out) mapOut { any => out } } |