diff options
author | mihaylov <mihaylov@epfl.ch> | 2007-07-13 10:56:44 +0000 |
---|---|---|
committer | mihaylov <mihaylov@epfl.ch> | 2007-07-13 10:56:44 +0000 |
commit | d93096ce9283641f027e0c81b6f52ef07a1e1bf0 (patch) | |
tree | 92710dbd2cbdaed9fb24fecbac15f97fc60bb4a3 /src | |
parent | ca623645faee8ba8dc5d88da3b2faf0eceabc288 (diff) | |
download | scala-d93096ce9283641f027e0c81b6f52ef07a1e1bf0.tar.gz scala-d93096ce9283641f027e0c81b6f52ef07a1e1bf0.tar.bz2 scala-d93096ce9283641f027e0c81b6f52ef07a1e1bf0.zip |
Synced dotnet library with rev 12294
Diffstat (limited to 'src')
-rw-r--r-- | src/compiler/scala/tools/nsc/backend/msil/GenMSIL.scala | 16 | ||||
-rw-r--r-- | src/compiler/scala/tools/nsc/symtab/clr/TypeParser.scala | 2 | ||||
-rw-r--r-- | src/dotnet-library/scala/Console.scala | 10 | ||||
-rw-r--r-- | src/dotnet-library/scala/compat/Math.scala | 6 |
4 files changed, 17 insertions, 17 deletions
diff --git a/src/compiler/scala/tools/nsc/backend/msil/GenMSIL.scala b/src/compiler/scala/tools/nsc/backend/msil/GenMSIL.scala index 115eb8e7ff..39c128d847 100644 --- a/src/compiler/scala/tools/nsc/backend/msil/GenMSIL.scala +++ b/src/compiler/scala/tools/nsc/backend/msil/GenMSIL.scala @@ -303,17 +303,17 @@ abstract class GenMSIL extends SubComponent { log("creating attributes: " + attributes + " for member : " + member) for (attr@ AnnotationInfo(typ, annArgs, nvPairs) <- attributes ; if attr.isConstant) - /* !typ.symbol.hasFlag(Flags.JAVA) */ + /* !typ.typeSymbol.hasFlag(Flags.JAVA) */ { // assert(consts.length <= 1, // "too many constant arguments for attribute; "+consts.toString()) // Problem / TODO having the symbol of the attribute type would be nicer - // (i hope that type.symbol is the same as the one in types2create) + // (i hope that type.typeSymbol is the same as the one in types2create) // AND: this will crash if the attribute Type is already compiled (-> not a typeBuilder) // when this is solved, types2create will be the same as icodes.classes, thus superfluous - val attrType: TypeBuilder = getType(typ.symbol).asInstanceOf[TypeBuilder] -// val attrType: MsilType = getType(typ.symbol) + val attrType: TypeBuilder = getType(typ.typeSymbol).asInstanceOf[TypeBuilder] +// val attrType: MsilType = getType(typ.typeSymbol) // Problem / TODO: i have no idea which constructor is used. This // information should be available in AnnotationInfo. @@ -1918,7 +1918,7 @@ abstract class GenMSIL extends SubComponent { if (sym.tpe.paramTypes.length == 1) { toTypeKind(sym.tpe.paramTypes(0)) match { case ARRAY(elem) => - if (elem.toType.symbol == definitions.StringClass){ + if (elem.toType.typeSymbol == definitions.StringClass){ return true } case _ => () @@ -1982,7 +1982,7 @@ abstract class GenMSIL extends SubComponent { def createTypeBuilder(iclass: IClass) { def getMsilType(tpe: Type): MsilType = { - val sym = tpe.symbol + val sym = tpe.typeSymbol types.get(sym) match { case Some(mtype) => mtype case None => createTypeBuilder(classes(sym)); types(sym) @@ -1999,14 +1999,14 @@ abstract class GenMSIL extends SubComponent { val superType = if (isInterface(sym)) null else getMsilType(parents.head) if (settings.debug.value) - log("super type: " + parents(0).symbol + ", msil type: " + superType) + log("super type: " + parents(0).typeSymbol + ", msil type: " + superType) val interfaces: Array[MsilType] = parents.tail.map(getMsilType).toArray if (parents.length > 1) { if (settings.debug.value){ log("interfaces:") for (i <- 0.until(interfaces.length)){ - log(" type: " + parents(i + 1).symbol + ", msil type: " + interfaces(i)) + log(" type: " + parents(i + 1).typeSymbol + ", msil type: " + interfaces(i)) } } } diff --git a/src/compiler/scala/tools/nsc/symtab/clr/TypeParser.scala b/src/compiler/scala/tools/nsc/symtab/clr/TypeParser.scala index 5f83206c36..784a89658a 100644 --- a/src/compiler/scala/tools/nsc/symtab/clr/TypeParser.scala +++ b/src/compiler/scala/tools/nsc/symtab/clr/TypeParser.scala @@ -434,7 +434,7 @@ abstract class TypeParser { // java.lang.Number to get the value (if a number, not for boolean, character) // see ch.epfl.lamp.compiler.msil.util.PEStream.java def getConstant(constType: Type, value: Object): Constant = { - val typeClass = constType.symbol + val typeClass = constType.typeSymbol if (typeClass == definitions.BooleanClass) Constant(value.asInstanceOf[java.lang.Boolean].booleanValue) else if (typeClass == definitions.ByteClass) diff --git a/src/dotnet-library/scala/Console.scala b/src/dotnet-library/scala/Console.scala index 23d70cd081..7a9c20c034 100644 --- a/src/dotnet-library/scala/Console.scala +++ b/src/dotnet-library/scala/Console.scala @@ -66,7 +66,7 @@ object Console { * * @param out the new output stream. */ - def setOut(out: TextWriter): Unit = outVar.value = out + def setOut(out: TextWriter) { outVar.value = out } /** Set the default output stream for the duration * of execution of one thunk. @@ -109,7 +109,7 @@ object Console { * output (i.e. output not terminated by a new line character) has * to be made visible on the terminal. */ - def flush(): Unit = out.Flush() + def flush() { out.Flush() } /** Print a new line character on the terminal. */ @@ -130,16 +130,16 @@ object Console { * <code>text</code>. The arguments that are inserted into specific * locations in <code>text</code> are provided with parameter * <code>args</code>. See class <a href="" target="contentFrame" - * class="java_text_MessageFormat"><code>java.text.MessageFormat</code></a> + * class="java/text/MessageFormat"><code>java.text.MessageFormat</code></a> * for a full specification of the <a href="#syntax" target="contentFrame" - * class="java_util_Formatter">format syntax</a>. + * class="java/util/Formatter">format syntax</a>. * </p> * * @param text the format of the text to print out. * @param args the parameters used to instantiate the format. * @throws java.lang.IllegalArgumentException */ - def printf(text: String, args: Any*): Unit = format(text, args: _*) + def printf(text: String, args: Any*) { format(text, args: _*) } /** * @see <a href="#printf(java.lang.String,scala.Any*)" diff --git a/src/dotnet-library/scala/compat/Math.scala b/src/dotnet-library/scala/compat/Math.scala index ff820bb074..d59f3bdd15 100644 --- a/src/dotnet-library/scala/compat/Math.scala +++ b/src/dotnet-library/scala/compat/Math.scala @@ -1,7 +1,7 @@ /* __ *\ ** ________ ___ / / ___ Scala API ** -** / __/ __// _ | / / / _ | (c) 2002-2006, LAMP/EPFL ** -** __\ \/ /__/ __ |/ /__/ __ | ** +** / __/ __// _ | / / / _ | (c) 2002-2007, LAMP/EPFL ** +** __\ \/ /__/ __ |/ /__/ __ | http://scala-lang.org/ ** ** /____/\___/_/ |_/____/_/ | | ** ** |/ ** \* */ @@ -12,7 +12,7 @@ package scala.compat /** - * This class will be removed soon. Use scala.Math instead + * This class will be removed soon. Use <code>scala.Math</code> instead. */ @deprecated object Math { |