Skip to content

Commit

Permalink
node tag .identifier != token tag .identifier, eg @Some
Browse files Browse the repository at this point in the history
  • Loading branch information
llogick committed Dec 6, 2023
1 parent b45f7a8 commit eec8061
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/analysis.zig
Original file line number Diff line number Diff line change
Expand Up @@ -3103,6 +3103,7 @@ pub const DeclWithHandle = struct {
}
return try analyser.resolveTypeOfNodeInternal(.{ .node = param.type_expr, .handle = self.handle });
} else if (node_tags[param.type_expr] == .identifier) {
if (tree.tokens.items(.tag)[main_tokens[param.type_expr]] != .identifier) return null;
const param_type_name = offsets.identifierTokenToNameSlice(tree, main_tokens[param.type_expr]);
if (param.name_token) |name_tok| {
const name = offsets.identifierTokenToNameSlice(tree, name_tok);
Expand Down

0 comments on commit eec8061

Please sign in to comment.