authorgravatar for thatlemon@gmail.comLemonBoy <thatlemon@gmail.com> 2019-11-04 10:38:48+01:00
committergravatar for thatlemon@gmail.comLemonBoy <thatlemon@gmail.com> 2019-11-04 20:33:40+01:00
log2b4bf1e7ced151482ce741788eadcb39f6d60f72
tree89a1618cd0f63d9c5f2f4edfbf06dfd64a7807b3
parent61825062aadd68e6cd2e864c717b3a8ce482258d

Fix crash in #3483

The bytesToSlice is still not evaluated at comptime but at least it doesn't crash anymore.

1 files changed, 1 insertions(+), 1 deletions(-)

src/ir.cpp+1-1
...@@ -1668,7 +1668,7 @@ static IrInstruction *ir_build_resize_slice(IrAnalyze *ira, IrInstruction *sourc...@@ -1668,7 +1668,7 @@ static IrInstruction *ir_build_resize_slice(IrAnalyze *ira, IrInstruction *sourc
1668 instruction->result_loc = result_loc;1668 instruction->result_loc = result_loc;
16691669
1670 ir_ref_instruction(operand, ira->new_irb.current_basic_block);1670 ir_ref_instruction(operand, ira->new_irb.current_basic_block);
1671 ir_ref_instruction(result_loc, ira->new_irb.current_basic_block);1671 if (result_loc != nullptr) ir_ref_instruction(result_loc, ira->new_irb.current_basic_block);
16721672
1673 return &instruction->base;1673 return &instruction->base;
1674}1674}