Duplicate MutableList.add docs in AbstractMutableList.add

Because the documentation inheritance doesn't work as desired here.
This commit is contained in:
Ilya Gorbunov
2018-10-23 20:33:09 +03:00
parent efa7bf0c37
commit c8caed5b6f
2 changed files with 10 additions and 0 deletions
@@ -22,6 +22,11 @@ expect abstract class AbstractMutableList<E> : MutableList<E> {
// From MutableList
/**
* Adds the specified element to the end of this list.
*
* @return `true` because the list is always modified as the result of this operation.
*/
override fun add(element: E): Boolean
override fun remove(element: E): Boolean
override fun addAll(elements: Collection<E>): Boolean
@@ -22,6 +22,11 @@ public actual abstract class AbstractMutableList<E> protected actual constructor
abstract override fun removeAt(index: Int): E
abstract override fun set(index: Int, element: E): E
/**
* Adds the specified element to the end of this list.
*
* @return `true` because the list is always modified as the result of this operation.
*/
actual override fun add(element: E): Boolean {
add(size, element)
return true