Skip to content

Commit 45009c2

Browse files
paulpadriaanm
authored andcommitted
Following up on things that -Xlint told me, som...
Following up on things that -Xlint told me, sometimes because Mr. Linty was being sensible and other times just to shut him up so we can hear better in the future. - made xml.Equality public because it occurs in public method signatures - made some actor classes with inaccessible-unoverridable methods final - eliminated a bunch of "dead code follows" warnings by deleting the dead code which really did follow - improved the reliability of warnings about inaccessible types For the changes in actors, review by phaller.
1 parent 906fc49 commit 45009c2

File tree

4 files changed

+4
-5
lines changed

4 files changed

+4
-5
lines changed

src/library/scala/xml/Attribute.scala

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@ package scala.xml
1515

1616
object Attribute {
1717
def unapply(x: Attribute) = x match {
18-
case PrefixedAttribute(_, key, value, next) => Some(key, value, next)
19-
case UnprefixedAttribute(key, value, next) => Some(key, value, next)
18+
case PrefixedAttribute(_, key, value, next) => Some((key, value, next))
19+
case UnprefixedAttribute(key, value, next) => Some((key, value, next))
2020
case _ => None
2121
}
2222

src/library/scala/xml/Equality.scala

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,6 @@ object Equality {
6565
}
6666
import Equality._
6767

68-
private[xml]
6968
trait Equality extends scala.Equals {
7069
def basisForHashCode: Seq[Any]
7170
def strict_==(other: Equality): Boolean

src/library/scala/xml/PrefixedAttribute.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,5 +53,5 @@ extends Attribute
5353
}
5454

5555
object PrefixedAttribute {
56-
def unapply(x: PrefixedAttribute) = Some(x.pre, x.key, x.value, x.next)
56+
def unapply(x: PrefixedAttribute) = Some((x.pre, x.key, x.value, x.next))
5757
}

src/library/scala/xml/UnprefixedAttribute.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,5 +56,5 @@ extends Attribute
5656
next(namespace, scope, key)
5757
}
5858
object UnprefixedAttribute {
59-
def unapply(x: UnprefixedAttribute) = Some(x.key, x.value, x.next)
59+
def unapply(x: UnprefixedAttribute) = Some((x.key, x.value, x.next))
6060
}

0 commit comments

Comments
 (0)