public IASTLocation Merge(ITokenLocation begin, ITokenLocation end)
        {
            if (begin is SourceRange beginrange && end is SourceRange endrange)
            {
                return(new TokenRangeASTLocation(beginrange, endrange));
            }

            return(new TokenLocationsASTLocation(begin, end));
        }
示例#2
0
 public TokenASTLocation(ITokenLocation tokenLocation)
 {
     this.TokenLocation = tokenLocation;
 }
 public TokenLocationsASTLocation(ITokenLocation begin, ITokenLocation end)
 {
     this.Begin = begin;
     this.End   = end;
 }