Java 8 override restrictions: interface can't implement a method of 'Any'
- update Range and related classes
This commit is contained in:
@@ -62,6 +62,8 @@ class GenerateRanges(out: PrintWriter) : BuiltInsSourceGenerator(out) {
|
||||
" }"
|
||||
}
|
||||
|
||||
val toString = "\"\$start..\$end\""
|
||||
|
||||
out.println(
|
||||
"""/**
|
||||
* A range of values of type `$t`.
|
||||
@@ -82,6 +84,8 @@ public class $range(override val start: $t, override val end: $t) : Range<$t>, P
|
||||
|
||||
override fun hashCode(): Int $hashCode
|
||||
|
||||
override fun toString(): String = $toString
|
||||
|
||||
companion object {
|
||||
/** An empty range of values of type $t. */
|
||||
public val EMPTY: $range = $range($emptyBounds)
|
||||
|
||||
Reference in New Issue
Block a user