diff --git a/js/js.libraries/src/core/collections/AbstractMutableList.kt b/js/js.libraries/src/core/collections/AbstractMutableList.kt index 82520388df6..af34d7e9185 100644 --- a/js/js.libraries/src/core/collections/AbstractMutableList.kt +++ b/js/js.libraries/src/core/collections/AbstractMutableList.kt @@ -1,5 +1,5 @@ /* - * Copyright 2010-2016 JetBrains s.r.o. + * Copyright 2010-2017 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -174,7 +174,7 @@ public abstract class AbstractMutableList protected constructor() : AbstractM } } - private class SubList(private val list: AbstractMutableList, private val fromIndex: Int, toIndex: Int) : AbstractMutableList() { + private class SubList(private val list: AbstractMutableList, private val fromIndex: Int, toIndex: Int) : AbstractMutableList(), RandomAccess { private var _size: Int = 0 init { diff --git a/libraries/stdlib/src/kotlin/collections/AbstractList.kt b/libraries/stdlib/src/kotlin/collections/AbstractList.kt index 71ff76c4ae4..b64f2d073d6 100644 --- a/libraries/stdlib/src/kotlin/collections/AbstractList.kt +++ b/libraries/stdlib/src/kotlin/collections/AbstractList.kt @@ -1,5 +1,5 @@ /* - * Copyright 2010-2016 JetBrains s.r.o. + * Copyright 2010-2017 JetBrains s.r.o. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -44,7 +44,7 @@ public abstract class AbstractList protected constructor() : AbstractColl override fun subList(fromIndex: Int, toIndex: Int): List = SubList(this, fromIndex, toIndex) - internal open class SubList(private val list: AbstractList, private val fromIndex: Int, toIndex: Int) : AbstractList() { + private class SubList(private val list: AbstractList, private val fromIndex: Int, toIndex: Int) : AbstractList(), RandomAccess { private var _size: Int = 0 init {