diff --git a/ssa/ssa_test.go b/ssa/ssa_test.go index 17b7ccf5..08f00f2d 100644 --- a/ssa/ssa_test.go +++ b/ssa/ssa_test.go @@ -25,6 +25,28 @@ import ( "github.com/goplus/llvm" ) +func TestSetBlock(t *testing.T) { + defer func() { + if r := recover(); r == nil { + t.Log("SetBlock: no error?") + } + }() + fn := &aFunction{} + b := &aBuilder{Func: fn} + b.SetBlock(&aBasicBlock{}) +} + +func TestSetBlockEx(t *testing.T) { + defer func() { + if r := recover(); r == nil { + t.Log("SetBlockEx: no error?") + } + }() + fn := &aFunction{} + b := &aBuilder{Func: fn} + b.SetBlockEx(&aBasicBlock{fn: fn}, -1) +} + func TestSetPython(t *testing.T) { prog := NewProgram(nil) typ := types.NewPackage("foo", "foo")