summaryrefslogtreecommitdiff
path: root/src/library
diff options
context:
space:
mode:
authormichelou <michelou@epfl.ch>2007-11-26 12:25:03 +0000
committermichelou <michelou@epfl.ch>2007-11-26 12:25:03 +0000
commit639adcce01aeef1d8161b2e6f3bf0fad16928f15 (patch)
tree327197fad80f2fa504e016e26c20d920bfd82bf3 /src/library
parent50a757c94708bba01a60a911d95ba4c6dd2db22c (diff)
downloadscala-639adcce01aeef1d8161b2e6f3bf0fad16928f15.tar.gz
scala-639adcce01aeef1d8161b2e6f3bf0fad16928f15.tar.bz2
scala-639adcce01aeef1d8161b2e6f3bf0fad16928f15.zip
Fixed runtime.StringAdd for MSIL and CLDC
Diffstat (limited to 'src/library')
-rw-r--r--src/library/scala/runtime/StringAdd.scala14
1 files changed, 8 insertions, 6 deletions
diff --git a/src/library/scala/runtime/StringAdd.scala b/src/library/scala/runtime/StringAdd.scala
index cf451403a7..a7da9a5d17 100644
--- a/src/library/scala/runtime/StringAdd.scala
+++ b/src/library/scala/runtime/StringAdd.scala
@@ -15,18 +15,20 @@ package scala.runtime
import Predef._
final class StringAdd(self: Any) {
+
def +(other: String) = self.toString + other
- /** Formats string according to given locale and format string. Formatstrings
- * are as for String.format (@see java.lang.String.format)
- */
+ /** Formats string according to given <code>locale</code> and
+ * <code>format</code> string. Formatstrings are as for
+ * <code>String.format</code> (@see java.lang.String.format)
+ */
def format(locale: java.util.Locale, format: String): String =
String.format(locale, format, Array(self.asInstanceOf[Object]))
- /** Formats string according to given format string. Formatstrings
- * are as for String.format (@see java.lang.String.format)
+ /** Formats string according to given <code>format</code> string.
+ * Format strings are as for <code>String.format</code>
+ * (@see java.lang.String.format).
*/
def format(format: String): String =
String.format(format, Array(self.asInstanceOf[Object]))
}
-