diff options
| author | Andrew Kelley <andrew@ziglang.org> | 2018-12-18 15:48:26 -0500 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2018-12-18 15:48:26 -0500 |
| commit | e077a446566b0aa77a121f9554f3cb355899653a (patch) | |
| tree | 1fce8c2ab0559b96f8e262f06eaf6c2ab827e199 /src/ir.cpp | |
| parent | f75262b79f0656ebfac7fb5bd2d6d8e8cce01258 (diff) | |
| download | zig-e077a446566b0aa77a121f9554f3cb355899653a.tar.gz zig-e077a446566b0aa77a121f9554f3cb355899653a.zip | |
ir: delete dead code
Diffstat (limited to 'src/ir.cpp')
| -rw-r--r-- | src/ir.cpp | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/ir.cpp b/src/ir.cpp index 09a9fceabe..76dd6c6391 100644 --- a/src/ir.cpp +++ b/src/ir.cpp @@ -9339,7 +9339,6 @@ static bool eval_const_expr_implicit_cast(IrAnalyze *ira, IrInstruction *source_ const_val->type = new_type; break; case CastOpResizeSlice: - case CastOpBytesToSlice: // can't do it zig_unreachable(); case CastOpIntToFloat: @@ -9396,7 +9395,7 @@ static IrInstruction *ir_resolve_cast(IrAnalyze *ira, IrInstruction *source_inst ZigType *wanted_type, CastOp cast_op, bool need_alloca) { if ((instr_is_comptime(value) || !type_has_bits(wanted_type)) && - cast_op != CastOpResizeSlice && cast_op != CastOpBytesToSlice) + cast_op != CastOpResizeSlice) { IrInstruction *result = ir_create_const(&ira->new_irb, source_instr->scope, source_instr->source_node, wanted_type); |
