remove Tree when it was the same as Ast

This commit is contained in:
Meghan Denny
2021-09-30 18:57:45 -07:00
parent 3c1152a536
commit b63339e350
7 changed files with 59 additions and 63 deletions

View File

@@ -1,4 +1,5 @@
const std = @import("std");
const Ast = std.zig.Ast;
const DocumentStore = @import("./document_store.zig");
const analysis = @import("./analysis.zig");
const types = @import("./types.zig");
@@ -7,8 +8,6 @@ const log = std.log.scoped(.references);
const Reference = @This();
usingnamespace @import("./ast.zig");
const Ast = std.zig.Ast;
fn tokenReference(handle: *DocumentStore.Handle, tok: Ast.TokenIndex, encoding: offsets.Encoding, context: anytype, comptime handler: anytype) !void {
const loc = offsets.tokenRelativeLocation(handle.tree, 0, handle.tree.tokens.items(.start)[tok], encoding) catch return;
try handler(context, types.Location{