Make SetMCJITOptimizationLevel more of a method and pass options
[oota-llvm.git] / bindings / go / llvm / executionengine_test.go
index 1a3fd456abe9571534996dab593b946c86a064da..03fabc83c6ff49a16cfbdbe1de39436d5c9e375d 100644 (file)
@@ -66,7 +66,9 @@ func TestFactorial(t *testing.T) {
                return
        }
 
-       engine, err := NewMCJITCompiler(mod, MCJITCompilerOptions{OptLevel: 2})
+       options := NewMCJITCompilerOptions()
+       options.SetMCJITOptimizationLevel(2)
+       engine, err := NewMCJITCompiler(mod, options)
        if err != nil {
                t.Errorf("Error creating JIT: %s", err)
                return