aboutsummaryrefslogtreecommitdiffhomepage
path: root/interp/frame.go
diff options
context:
space:
mode:
Diffstat (limited to 'interp/frame.go')
-rw-r--r--interp/frame.go10
1 files changed, 8 insertions, 2 deletions
diff --git a/interp/frame.go b/interp/frame.go
index 28e610958..16984f93f 100644
--- a/interp/frame.go
+++ b/interp/frame.go
@@ -111,7 +111,10 @@ func (fr *frame) evalBasicBlock(bb, incoming llvm.BasicBlock, indent string) (re
if inst.IsVolatile() {
fr.builder.CreateStore(value.Value(), ptr.Value())
} else {
- ptr.Store(value.Value())
+ err := ptr.Store(value.Value())
+ if err != nil {
+ return nil, nil, fr.errorAt(inst, err)
+ }
}
case !inst.IsAGetElementPtrInst().IsNil():
value := fr.getLocal(inst.Operand(0))
@@ -422,7 +425,10 @@ func (fr *frame) evalBasicBlock(bb, incoming llvm.BasicBlock, indent string) (re
if err != nil {
return nil, nil, fr.errorAt(inst, err)
}
- dstArray.Store(val)
+ err = dstArray.Store(val)
+ if err != nil {
+ return nil, nil, fr.errorAt(inst, err)
+ }
// dst++
dstArrayValue, err := dstArray.GetElementPtr([]uint32{1})
if err != nil {