findReservedNames method

Iterable<String> findReservedNames()

Returns all the reserved names, including from ancestor mixins.

Implementation

Iterable<String> findReservedNames() {
  final names = <String>{};
  for (PbMixin? m = this; m != null; m = m.parent) {
    names.add(m.name);
    if (m.reservedNames != null) {
      names.addAll(m.reservedNames!);
    }
  }
  return names;
}