doubleFieldNames property

Set<String> get doubleFieldNames

ghissues32: the instance fields declared double / double? in this class, its superclasses and its mixins - the fields an int widens in. Computed on first use (instances are created after every class of the library is declared, so the hierarchy is complete by then) and kept.

Implementation

Set<String> get doubleFieldNames => _doubleFieldNames ??= {
  ...?superclass?.doubleFieldNames,
  for (final mixin in mixins) ...mixin.doubleFieldNames,
  for (final declaration in fieldDeclarations)
    if (!declaration.isStatic &&
        ResolvedBinding.declaresDouble(declaration.fields?.type))
      for (final variable in declaration.fields?.variables ?? const [])
        variable.name?.name ?? '',
};