unresolvedSource method

String unresolvedSource(
  1. Iterable<SourceSpanMessageTuple> tuples, {
  2. required String reason,
})

Returns a message that the following sourceSpans were unresolvable.

Implementation

String unresolvedSource(
  Iterable<SourceSpanMessageTuple> tuples, {
  required String reason,
}) {
  final buffer = StringBuffer(reason)
    ..writeln()
    ..writeln();
  for (final tuple in tuples) {
    buffer.writeln(tuple.sourceSpan.message(tuple.message));
  }
  return buffer.toString();
}