mirai-core / net.mamoe.mirai.utils / toList

toList

fun <E> LockFreeLinkedList<E>.toList(): List<E>

Collect all the elements into a MutableList then cast it as a List