SourceSpan constructor

SourceSpan(
  1. SourceLocation start,
  2. SourceLocation end,
  3. String text
)

Creates a new span from start to end (exclusive) containing text.

start and end must have the same source URL and start must come before end. text must have a number of characters equal to the distance between start and end.

Implementation

factory SourceSpan(SourceLocation start, SourceLocation end, String text) =>
    SourceSpanBase(start, end, text);