printAnnotated method

void printAnnotated(
  1. String text,
  2. List<NamedLocation> namedLocations
)

Implementation

void printAnnotated(String text, List<NamedLocation> namedLocations) {
  final indentOffset = _needIndent ? _indent.length : 0;
  print(text);
  for (final location in namedLocations) {
    _addAnnotation(location.fieldPathSegment, location.name,
        location.start + indentOffset);
  }
}