deepCopyList<T> function
Deeply copies list
.
copier
Copy Function for non-primitive types.
Implementation
List<T>? deepCopyList<T>(List<T>? l, {Copier? copier}) {
if (l == null) return null;
if (l.isEmpty) return <T>[];
return l.map((T e) => deepCopy(e, copier: copier)!).toList();
}