Removed unreachable, switch cases can trigger this

This commit is contained in:
Alexandros Naskos 2020-06-03 19:59:26 +03:00
parent 34fbef97fe
commit b0bb8888d3

View File

@ -982,8 +982,8 @@ pub fn declsFromIndexInternal(
},
// TODO: These convey no type information...
.Payload => try decls.append(node.cast(ast.Node.Payload).?.error_symbol),
// Those are handled in the If, While, For cases.
.PointerPayload => unreachable,
.PointerPayload => try decls.append(node.cast(ast.Node.PointerPayload).?.value_symbol),
// This should be completely handled for the .For code.
.PointerIndexPayload => unreachable,
.VarDecl => {
try decls.append(node);