Skip to content

Commit 9b3369c

Browse files
committed
Remove some unnecessary internal LLVM module prefixes.
1 parent f5ae50f commit 9b3369c

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

src/core/value/constant.jl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -151,7 +151,7 @@ export GlobalValue,
151151
unnamed_addr, unnamed_addr!,
152152
alignment, alignment!
153153

154-
parent(val::GlobalValue) = LLVM.Module(API.LLVMGetGlobalParent(ref(val)))
154+
parent(val::GlobalValue) = Module(API.LLVMGetGlobalParent(ref(val)))
155155

156156
isdeclaration(val::GlobalValue) = convert(Core.Bool, API.LLVMIsDeclaration(ref(val)))
157157

src/pass.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ export ModulePass
1616

1717
function ModulePass(name::String, runner::Core.Function)
1818
function callback(ptr::Ptr{Cvoid})::Core.Bool
19-
mod = LLVM.Module(convert(reftype(Module), ptr))
19+
mod = Module(convert(reftype(Module), ptr))
2020
return runner(mod)::Core.Bool
2121
end
2222

@@ -38,7 +38,7 @@ export FunctionPass
3838

3939
function FunctionPass(name::String, runner::Core.Function)
4040
function callback(ptr::Ptr{Cvoid})::Core.Bool
41-
fn = LLVM.Function(convert(reftype(Function), ptr))
41+
fn = Function(convert(reftype(Function), ptr))
4242
return runner(fn)::Core.Bool
4343
end
4444

src/passmanager.jl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ function ModulePassManager(f::Core.Function, args...)
3232
end
3333

3434
run!(mpm::ModulePassManager, mod::Module) =
35-
LLVM.convert(Core.Bool, API.LLVMRunPassManager(ref(mpm), ref(mod)))
35+
convert(Core.Bool, API.LLVMRunPassManager(ref(mpm), ref(mod)))
3636

3737

3838

@@ -65,4 +65,4 @@ finalize!(fpm::FunctionPassManager) =
6565
convert(Core.Bool, API.LLVMFinalizeFunctionPassManager(ref(fpm)))
6666

6767
run!(fpm::FunctionPassManager, f::Function) =
68-
LLVM.convert(Core.Bool, API.LLVMRunFunctionPassManager(ref(fpm), ref(f)))
68+
convert(Core.Bool, API.LLVMRunFunctionPassManager(ref(fpm), ref(f)))

0 commit comments

Comments
 (0)