Make all APIChange subclasses final.

They should have been final from the beginning. We are fixing that
omission now.
This commit is contained in:
Grzegorz Kossakowski 2014-01-06 22:24:00 +01:00
parent 6cf79aba08
commit f4940df48d
1 changed files with 4 additions and 4 deletions

View File

@ -22,14 +22,14 @@ sealed abstract class APIChange[T](val modified: T)
* api has changed. The reason is that there's no way to determine if changes to macros implementation * api has changed. The reason is that there's no way to determine if changes to macros implementation
* are affecting its users or not. Therefore we err on the side of caution. * are affecting its users or not. Therefore we err on the side of caution.
*/ */
case class APIChangeDueToMacroDefinition[T](modified0: T) extends APIChange(modified0) final case class APIChangeDueToMacroDefinition[T](modified0: T) extends APIChange(modified0)
case class SourceAPIChange[T](modified0: T) extends APIChange(modified0) final case class SourceAPIChange[T](modified0: T) extends APIChange(modified0)
/** /**
* An APIChange that carries information about modified names. * An APIChange that carries information about modified names.
* *
* This class is used only when name hashing algorithm is enabled. * This class is used only when name hashing algorithm is enabled.
*/ */
case class NamesChange[T](modified0: T, modifiedNames: ModifiedNames) extends APIChange(modified0) final case class NamesChange[T](modified0: T, modifiedNames: ModifiedNames) extends APIChange(modified0)
/** /**
* ModifiedNames are determined by comparing name hashes in two versions of an API representation. * ModifiedNames are determined by comparing name hashes in two versions of an API representation.
@ -39,7 +39,7 @@ case class NamesChange[T](modified0: T, modifiedNames: ModifiedNames) extends AP
* on whether modified name is implicit or not. Implicit names are much more difficult to handle * on whether modified name is implicit or not. Implicit names are much more difficult to handle
* due to difficulty of reasoning about the implicit scope. * due to difficulty of reasoning about the implicit scope.
*/ */
case class ModifiedNames(regularNames: Set[String], implicitNames: Set[String]) { final case class ModifiedNames(regularNames: Set[String], implicitNames: Set[String]) {
override def toString: String = override def toString: String =
s"ModifiedNames(regularNames = ${regularNames mkString ", "}, implicitNames = ${implicitNames mkString ", "})" s"ModifiedNames(regularNames = ${regularNames mkString ", "}, implicitNames = ${implicitNames mkString ", "})"
} }