func removeAll<C : RangeReplaceableCollectionType>(inout: C, keepCapacity: Bool)

Remove all elements from x

Invalidates all indices with respect to x.

keepCapacity, if true, is a non-binding request to avoid releasing storage, which can be a useful optimization when x is going to be grown again.

Complexity: O(count(x)).


func removeAll<C : RangeReplaceableCollectionType>(inout x: C, keepCapacity: Bool = default)