is_type_function is const

This commit is contained in:
Alexandros Naskos 2020-05-08 18:07:14 +03:00
parent 29b0045bc7
commit d8457c96a1

View File

@ -177,7 +177,7 @@ fn publishDiagnostics(document: *types.TextDocument) !void {
if (func.name_token) |name_token| {
const loc = tree.tokenLocation(0, name_token);
var is_type_function = switch (func.return_type) {
const is_type_function = switch (func.return_type) {
.Explicit => |node| if (node.cast(std.zig.ast.Node.Identifier)) |ident|
std.mem.eql(u8, tree.tokenSlice(ident.token), "type")
else