getSpan function
Implementation
SourceSpan getSpan(SourceFile sourceFile, AstNode node,
{bool skipCommentAndMetadata = true}) {
if (skipCommentAndMetadata && node is AnnotatedNode) {
return sourceFile.span(
node.firstTokenAfterCommentAndMetadata.offset, node.end);
}
return sourceFile.span(node.offset, node.end);
}