deserializeVector<T> function

List<T> deserializeVector<T>(
  1. Deserializer deserializer,
  2. dynamic deserializeFunc
)

Implementation

List<T> deserializeVector<T>(Deserializer deserializer, dynamic deserializeFunc) {
  int length = deserializer.deserializeUleb128AsU32();
  final list = <T>[];
  for (int i = 0; i < length; i += 1) {
    list.add(deserializeFunc(deserializer));
  }
  return list;
}