diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/boot/me/trans.ml | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/boot/me/trans.ml b/src/boot/me/trans.ml index 385db253..5b1e4da0 100644 --- a/src/boot/me/trans.ml +++ b/src/boot/me/trans.ml @@ -768,8 +768,12 @@ let trans_visitor add_to vc sz; Il.Mem (based v, elt_rty) end - | _ -> bug () "get_element_ptr_dyn %d on cell %s" i - (cell_str mem_cell) + | Il.Mem (_, Il.StructTy elts) -> + bug () + "get_element_ptr dyn %d out of bounds (len %d) on cell %s" + i (Array.length elts) (cell_str mem_cell) + | _ -> + bug () "get_element_ptr_dyn %d on cell %s" i (cell_str mem_cell) in let get_element_ptr_dyn_in_current_frame |