toArray method

List<E> toArray()

Returns an array containing all elements in this stack (top to bottom order).

Implementation

List<E> toArray() {
  return toList(growable: false);
}