import { XmlStreamReader, XmlSymbol } from "../reader"; export class LocationContext { static fromStreamSymbol>(stream: T, symbol: XmlSymbol): LocationContext ? Tag : unknown> { return new LocationContext( stream.tag, symbol.location.start, symbol.location.end, stream.getSource(), ) } constructor( public readonly tag: T, public readonly startPosition: number, public readonly endPosition: number, public readonly source: string, ) {} }