Skip to content

Commit 4630dd2

Browse files
authored
Merge pull request rust-lang#72 from AwesomeCompiler/feature/edition-2018
(master) Update to 2018 edition
2 parents ed11c8e + d49ca5f commit 4630dd2

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+201
-197
lines changed

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,10 @@ authors = ["Daniel Kolsoi <[email protected]>"]
55
description = "Inkwell aims to help you pen your own programming languages by safely wrapping llvm-sys."
66
repository = "https://github.com/TheDan64/inkwell"
77
readme = "README.md"
8-
changelog = "CHANGELOG.md"
98
keywords = ["llvm", "safe", "wrapper"]
109
license = "Apache-2.0"
1110
categories = ["development-tools::ffi"]
11+
edition = "2018"
1212

1313
[features]
1414
default = []

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@
55
[![codecov](https://codecov.io/gh/TheDan64/inkwell/branch/master/graph/badge.svg)](https://codecov.io/gh/TheDan64/inkwell)
66
[![lines of code](https://tokei.rs/b1/github/TheDan64/inkwell)](https://github.com/Aaronepower/tokei)
77
[![Join the chat at https://gitter.im/inkwell-rs/Lobby](https://badges.gitter.im/inkwell-rs/Lobby.svg)](https://gitter.im/inkwell-rs/Lobby?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge&utm_content=badge)
8-
![Minimum rustc 1.30](https://img.shields.io/badge/rustc-1.30+-brightgreen.svg)
8+
![Minimum rustc 1.31](https://img.shields.io/badge/rustc-1.31+-brightgreen.svg)
99

1010
**I**t's a **N**ew **K**ind of **W**rapper for **E**xposing **LL**VM (*S*afely)
1111

1212
Inkwell aims to help you pen your own programming languages by safely wrapping llvm-sys. It provides a more strongly typed interface than the underlying LLVM API so that certain types of errors can be caught at compile time instead of at LLVM's runtime. This means we are trying to replicate LLVM IR's strong typing as closely as possible. The ultimate goal is to make LLVM safer from the rust end and a bit easier to learn (via documentation) and use.
1313

1414
## Requirements
1515

16-
* Rust 1.30+
16+
* Rust 1.31+
1717
* Rust Stable, Beta, or Nightly
18-
* LLVM 3.6, 3.7, 3.8, 3.9, 4.0, 5.0, 6.0, or 7
18+
* LLVM 3.6, 3.7, 3.8, 3.9, 4.0, 5.0, 6.0, or 7.0
1919

2020
## Usage
2121

@@ -48,8 +48,6 @@ Documentation is automatically [deployed here](https://thedan64.github.io/inkwel
4848
### Tari's [llvm-sys example](https://bitbucket.org/tari/llvm-sys.rs/src/ea4ac92a171da2c1851806b91e531ed3a0b41091/examples/jit-function.rs) written in safe code<sup>1</sup> with Inkwell:
4949

5050
```rust
51-
extern crate inkwell;
52-
5351
use inkwell::OptimizationLevel;
5452
use inkwell::builder::Builder;
5553
use inkwell::context::Context;

examples/kaleidoscope/main.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ use self::inkwell::types::BasicTypeEnum;
3030
use self::inkwell::values::{BasicValueEnum, FloatValue, FunctionValue, PointerValue};
3131
use self::inkwell::{OptimizationLevel, FloatPredicate};
3232

33-
use Token::*;
33+
use crate::Token::*;
3434

3535
const ANONYMOUS_FUNCTION_NAME: &str = "anonymous";
3636

internal_macros/Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
name = "inkwell_internal_macros"
33
version = "0.1.0"
44
authors = ["Daniel Kolsoi <[email protected]>"]
5+
edition = "2018"
56

67
[dependencies]
78
quote = "0.6"

src/basic_block.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5,8 +5,8 @@ use llvm_sys::core::{LLVMGetBasicBlockParent, LLVMGetBasicBlockTerminator, LLVMG
55
use llvm_sys::core::LLVMGetBasicBlockName;
66
use llvm_sys::prelude::{LLVMValueRef, LLVMBasicBlockRef};
77

8-
use context::{Context, ContextRef};
9-
use values::{FunctionValue, InstructionValue};
8+
use crate::context::{Context, ContextRef};
9+
use crate::values::{FunctionValue, InstructionValue};
1010

1111
use std::fmt;
1212
use std::ffi::{CStr, CString};

src/builder.rs

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,10 +3,10 @@ use llvm_sys::core::{LLVMBuildAdd, LLVMBuildAlloca, LLVMBuildAnd, LLVMBuildArray
33
use llvm_sys::prelude::{LLVMBuilderRef, LLVMValueRef};
44
use llvm_sys::{LLVMTypeKind};
55

6-
use {AtomicOrdering, IntPredicate, FloatPredicate};
7-
use basic_block::BasicBlock;
8-
use values::{AggregateValue, AggregateValueEnum, AsValueRef, BasicValue, BasicValueEnum, PhiValue, FunctionValue, IntValue, PointerValue, VectorValue, InstructionValue, GlobalValue, IntMathValue, FloatMathValue, PointerMathValue, InstructionOpcode, CallSiteValue};
9-
use types::{AsTypeRef, BasicType, IntMathType, FloatMathType, PointerType, PointerMathType};
6+
use crate::{AtomicOrdering, IntPredicate, FloatPredicate};
7+
use crate::basic_block::BasicBlock;
8+
use crate::values::{AggregateValue, AggregateValueEnum, AsValueRef, BasicValue, BasicValueEnum, PhiValue, FunctionValue, IntValue, PointerValue, VectorValue, InstructionValue, GlobalValue, IntMathValue, FloatMathValue, PointerMathValue, InstructionOpcode, CallSiteValue};
9+
use crate::types::{AsTypeRef, BasicType, IntMathType, FloatMathType, PointerType, PointerMathType};
1010

1111
use std::ffi::CString;
1212

@@ -667,6 +667,11 @@ impl Builder {
667667
/// if the leftmost bit was one.
668668
///
669669
/// ```rust,no_run
670+
/// //fix doc error about overflowing_literals
671+
/// //rendered rfc: https://github.com/rust-lang/rfcs/blob/master/text/2438-deny-integer-literal-overflow-lint.md
672+
/// //tracking issue: https://github.com/rust-lang/rust/issues/54502
673+
/// #![allow(overflowing_literals)]
674+
///
670675
/// // Logical Right Shift
671676
/// assert_eq!(0b1100_0000 >> 2, 0b0011_0000);
672677
/// assert_eq!(0b0000_0010 >> 1, 0b0000_0001);

src/context.rs

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,14 +8,14 @@ use llvm_sys::ir_reader::LLVMParseIRInContext;
88
use libc::c_void;
99

1010
#[llvm_versions(4.0 => latest)]
11-
use attributes::Attribute;
12-
use basic_block::BasicBlock;
13-
use builder::Builder;
14-
use memory_buffer::MemoryBuffer;
15-
use module::Module;
16-
use support::LLVMString;
17-
use types::{BasicTypeEnum, FloatType, IntType, StructType, VoidType, AsTypeRef};
18-
use values::{AsValueRef, FunctionValue, StructValue, MetadataValue, BasicValueEnum, VectorValue};
11+
use crate::attributes::Attribute;
12+
use crate::basic_block::BasicBlock;
13+
use crate::builder::Builder;
14+
use crate::memory_buffer::MemoryBuffer;
15+
use crate::module::Module;
16+
use crate::support::LLVMString;
17+
use crate::types::{BasicTypeEnum, FloatType, IntType, StructType, VoidType, AsTypeRef};
18+
use crate::values::{AsValueRef, FunctionValue, StructValue, MetadataValue, BasicValueEnum, VectorValue};
1919

2020
use std::ffi::CString;
2121
use std::mem::forget;

src/data_layout.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
use std::ffi::CStr;
22
use std::fmt;
33

4-
use support::{LLVMString, LLVMStringOrRaw};
4+
use crate::support::{LLVMString, LLVMStringOrRaw};
55

66
#[derive(Eq)]
77
pub struct DataLayout {

src/execution_engine.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,11 @@
11
use libc::c_int;
22
use llvm_sys::execution_engine::{LLVMGetExecutionEngineTargetData, LLVMExecutionEngineRef, LLVMRunFunction, LLVMRunFunctionAsMain, LLVMDisposeExecutionEngine, LLVMGetFunctionAddress, LLVMAddModule, LLVMFindFunction, LLVMLinkInMCJIT, LLVMLinkInInterpreter, LLVMRemoveModule, LLVMGenericValueRef, LLVMFreeMachineCodeForFunction, LLVMAddGlobalMapping, LLVMRunStaticConstructors, LLVMRunStaticDestructors};
33

4-
use context::Context;
5-
use module::Module;
6-
use support::LLVMString;
7-
use targets::TargetData;
8-
use values::{AnyValue, AsValueRef, FunctionValue, GenericValue};
4+
use crate::context::Context;
5+
use crate::module::Module;
6+
use crate::support::LLVMString;
7+
use crate::targets::TargetData;
8+
use crate::values::{AnyValue, AsValueRef, FunctionValue, GenericValue};
99

1010
use std::error::Error;
1111
use std::rc::Rc;

src/memory_buffer.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ use llvm_sys::core::{LLVMCreateMemoryBufferWithContentsOfFile, LLVMCreateMemoryB
22
use llvm_sys::prelude::LLVMMemoryBufferRef;
33
use llvm_sys::object::LLVMCreateObjectFile;
44

5-
use object_file::ObjectFile;
6-
use support::LLVMString;
5+
use crate::object_file::ObjectFile;
6+
use crate::support::LLVMString;
77

88
use std::ffi::CString;
99
use std::mem::{forget, zeroed};

src/module.rs

Lines changed: 12 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -26,19 +26,19 @@ use std::ptr;
2626
use std::rc::Rc;
2727
use std::slice::from_raw_parts;
2828

29-
use {AddressSpace, OptimizationLevel};
29+
use crate::{AddressSpace, OptimizationLevel};
3030
#[llvm_versions(7.0 => latest)]
31-
use comdat::Comdat;
32-
use context::{Context, ContextRef};
33-
use data_layout::DataLayout;
34-
use execution_engine::ExecutionEngine;
35-
use memory_buffer::MemoryBuffer;
36-
use support::LLVMString;
37-
use targets::{Target, InitializationConfig};
38-
use types::{AsTypeRef, BasicType, FunctionType, BasicTypeEnum};
39-
use values::{AsValueRef, FunctionValue, GlobalValue, MetadataValue};
31+
use crate::comdat::Comdat;
32+
use crate::context::{Context, ContextRef};
33+
use crate::data_layout::DataLayout;
34+
use crate::execution_engine::ExecutionEngine;
35+
use crate::memory_buffer::MemoryBuffer;
36+
use crate::support::LLVMString;
37+
use crate::targets::{Target, InitializationConfig};
38+
use crate::types::{AsTypeRef, BasicType, FunctionType, BasicTypeEnum};
39+
use crate::values::{AsValueRef, FunctionValue, GlobalValue, MetadataValue};
4040
#[llvm_versions(7.0 => latest)]
41-
use values::BasicValue;
41+
use crate::values::BasicValue;
4242

4343
enum_rename!{
4444
/// This enum defines how to link a global variable or function in a module. The variant documenation is
@@ -1292,7 +1292,7 @@ impl Module {
12921292
}
12931293
#[cfg(not(any(feature = "llvm3-6", feature = "llvm3-7")))]
12941294
{
1295-
use support::error_handling::get_error_str_diagnostic_handler;
1295+
use crate::support::error_handling::get_error_str_diagnostic_handler;
12961296
use llvm_sys::linker::LLVMLinkModules2;
12971297
use libc::c_void;
12981298

src/passes.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,11 +8,11 @@ use llvm_sys::transforms::scalar::{LLVMAddAggressiveDCEPass, LLVMAddMemCpyOptPas
88
use llvm_sys::transforms::scalar::LLVMAddBitTrackingDCEPass;
99
use llvm_sys::transforms::vectorize::{LLVMAddLoopVectorizePass, LLVMAddSLPVectorizePass};
1010

11-
use OptimizationLevel;
12-
use module::Module;
11+
use crate::OptimizationLevel;
12+
use crate::module::Module;
1313
#[llvm_versions(3.6 => 3.8)]
14-
use targets::TargetData;
15-
use values::{AsValueRef, FunctionValue};
14+
use crate::targets::TargetData;
15+
use crate::values::{AsValueRef, FunctionValue};
1616

1717
// REVIEW: Opt Level might be identical to targets::Option<CodeGenOptLevel>
1818
#[derive(Debug)]

src/targets.rs

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -3,15 +3,15 @@ use either::Either;
33
use llvm_sys::target::{LLVMTargetDataRef, LLVMCopyStringRepOfTargetData, LLVMSizeOfTypeInBits, LLVMCreateTargetData, LLVMByteOrder, LLVMPointerSize, LLVMByteOrdering, LLVMStoreSizeOfType, LLVMABISizeOfType, LLVMABIAlignmentOfType, LLVMCallFrameAlignmentOfType, LLVMPreferredAlignmentOfType, LLVMPreferredAlignmentOfGlobal, LLVMElementAtOffset, LLVMOffsetOfElement, LLVMDisposeTargetData, LLVMPointerSizeForAS, LLVMIntPtrType, LLVMIntPtrTypeForAS, LLVMIntPtrTypeInContext, LLVMIntPtrTypeForASInContext};
44
use llvm_sys::target_machine::{LLVMGetFirstTarget, LLVMTargetRef, LLVMGetNextTarget, LLVMGetTargetFromName, LLVMGetTargetFromTriple, LLVMGetTargetName, LLVMGetTargetDescription, LLVMTargetHasJIT, LLVMTargetHasTargetMachine, LLVMTargetHasAsmBackend, LLVMTargetMachineRef, LLVMDisposeTargetMachine, LLVMGetTargetMachineTarget, LLVMGetTargetMachineTriple, LLVMSetTargetMachineAsmVerbosity, LLVMCreateTargetMachine, LLVMGetTargetMachineCPU, LLVMGetTargetMachineFeatureString, LLVMGetDefaultTargetTriple, LLVMAddAnalysisPasses, LLVMCodeGenOptLevel, LLVMCodeModel, LLVMRelocMode, LLVMCodeGenFileType, LLVMTargetMachineEmitToMemoryBuffer, LLVMTargetMachineEmitToFile};
55

6-
use {AddressSpace, OptimizationLevel};
7-
use context::Context;
8-
use data_layout::DataLayout;
9-
use memory_buffer::MemoryBuffer;
10-
use module::Module;
11-
use passes::PassManager;
12-
use support::LLVMString;
13-
use types::{AnyType, AsTypeRef, IntType, StructType};
14-
use values::{AsValueRef, GlobalValue};
6+
use crate::{AddressSpace, OptimizationLevel};
7+
use crate::context::Context;
8+
use crate::data_layout::DataLayout;
9+
use crate::memory_buffer::MemoryBuffer;
10+
use crate::module::Module;
11+
use crate::passes::PassManager;
12+
use crate::support::LLVMString;
13+
use crate::types::{AnyType, AsTypeRef, IntType, StructType};
14+
use crate::values::{AsValueRef, GlobalValue};
1515

1616
use std::default::Default;
1717
use std::ffi::{CStr, CString};

src/types/array_type.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
use llvm_sys::core::{LLVMConstArray, LLVMGetArrayLength};
22
use llvm_sys::prelude::{LLVMTypeRef, LLVMValueRef};
33

4-
use AddressSpace;
5-
use context::ContextRef;
6-
use support::LLVMString;
7-
use types::traits::AsTypeRef;
8-
use types::{Type, BasicTypeEnum, PointerType, FunctionType};
9-
use values::{AsValueRef, ArrayValue, IntValue};
4+
use crate::AddressSpace;
5+
use crate::context::ContextRef;
6+
use crate::support::LLVMString;
7+
use crate::types::traits::AsTypeRef;
8+
use crate::types::{Type, BasicTypeEnum, PointerType, FunctionType};
9+
use crate::values::{AsValueRef, ArrayValue, IntValue};
1010

1111
/// An `ArrayType` is the type of contiguous constants or variables.
1212
#[derive(Debug, PartialEq, Eq, Clone, Copy)]

src/types/enums.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,8 @@ use llvm_sys::core::LLVMGetTypeKind;
22
use llvm_sys::LLVMTypeKind;
33
use llvm_sys::prelude::LLVMTypeRef;
44

5-
use types::{IntType, VoidType, FunctionType, PointerType, VectorType, ArrayType, StructType, FloatType};
6-
use types::traits::AsTypeRef;
5+
use crate::types::{IntType, VoidType, FunctionType, PointerType, VectorType, ArrayType, StructType, FloatType};
6+
use crate::types::traits::AsTypeRef;
77

88
macro_rules! enum_type_set {
99
($(#[$enum_attrs:meta])* $enum_name:ident: { $($(#[$variant_attrs:meta])* $args:ident,)+ }) => (

src/types/float_type.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ use llvm_sys::core::{LLVMConstReal, LLVMHalfType, LLVMFloatType, LLVMDoubleType,
22
use llvm_sys::execution_engine::LLVMCreateGenericValueOfFloat;
33
use llvm_sys::prelude::{LLVMTypeRef, LLVMValueRef};
44

5-
use AddressSpace;
6-
use context::ContextRef;
7-
use support::LLVMString;
8-
use types::traits::AsTypeRef;
9-
use types::{Type, PointerType, FunctionType, BasicTypeEnum, ArrayType, VectorType};
10-
use values::{AsValueRef, ArrayValue, FloatValue, GenericValue, IntValue};
5+
use crate::AddressSpace;
6+
use crate::context::ContextRef;
7+
use crate::support::LLVMString;
8+
use crate::types::traits::AsTypeRef;
9+
use crate::types::{Type, PointerType, FunctionType, BasicTypeEnum, ArrayType, VectorType};
10+
use crate::values::{AsValueRef, ArrayValue, FloatValue, GenericValue, IntValue};
1111

1212
/// A `FloatType` is the type of a floating point constant or variable.
1313
#[derive(Debug, PartialEq, Eq, Clone, Copy)]

src/types/fn_type.rs

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@ use llvm_sys::prelude::LLVMTypeRef;
44
use std::fmt;
55
use std::mem::forget;
66

7-
use AddressSpace;
8-
use context::ContextRef;
9-
use support::LLVMString;
10-
use types::traits::AsTypeRef;
11-
use types::{PointerType, Type, BasicTypeEnum};
7+
use crate::AddressSpace;
8+
use crate::context::ContextRef;
9+
use crate::support::LLVMString;
10+
use crate::types::traits::AsTypeRef;
11+
use crate::types::{PointerType, Type, BasicTypeEnum};
1212

1313
// REVIEW: Add a get_return_type() -> Option<BasicTypeEnum>?
1414
/// A `FunctionType` is the type of a function variable.

src/types/int_type.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -2,12 +2,12 @@ use llvm_sys::core::{LLVMInt1Type, LLVMInt8Type, LLVMInt16Type, LLVMInt32Type, L
22
use llvm_sys::execution_engine::LLVMCreateGenericValueOfInt;
33
use llvm_sys::prelude::{LLVMTypeRef, LLVMValueRef};
44

5-
use AddressSpace;
6-
use context::ContextRef;
7-
use support::LLVMString;
8-
use types::traits::AsTypeRef;
9-
use types::{Type, ArrayType, BasicTypeEnum, VectorType, PointerType, FunctionType};
10-
use values::{AsValueRef, ArrayValue, GenericValue, IntValue};
5+
use crate::AddressSpace;
6+
use crate::context::ContextRef;
7+
use crate::support::LLVMString;
8+
use crate::types::traits::AsTypeRef;
9+
use crate::types::{Type, ArrayType, BasicTypeEnum, VectorType, PointerType, FunctionType};
10+
use crate::values::{AsValueRef, ArrayValue, GenericValue, IntValue};
1111

1212
/// An `IntType` is the type of an integer constant or variable.
1313
#[derive(Debug, PartialEq, Eq, Clone, Copy)]

src/types/mod.rs

Lines changed: 15 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -20,17 +20,17 @@ mod vec_type;
2020
#[deny(missing_docs)]
2121
mod void_type;
2222

23-
pub use types::array_type::ArrayType;
24-
pub use types::enums::{AnyTypeEnum, BasicTypeEnum};
25-
pub use types::float_type::FloatType;
26-
pub use types::fn_type::FunctionType;
27-
pub use types::int_type::IntType;
28-
pub use types::ptr_type::PointerType;
29-
pub use types::struct_type::StructType;
30-
pub use types::traits::{AnyType, BasicType, IntMathType, FloatMathType, PointerMathType};
31-
pub use types::vec_type::VectorType;
32-
pub use types::void_type::VoidType;
33-
pub(crate) use types::traits::AsTypeRef;
23+
pub use crate::types::array_type::ArrayType;
24+
pub use crate::types::enums::{AnyTypeEnum, BasicTypeEnum};
25+
pub use crate::types::float_type::FloatType;
26+
pub use crate::types::fn_type::FunctionType;
27+
pub use crate::types::int_type::IntType;
28+
pub use crate::types::ptr_type::PointerType;
29+
pub use crate::types::struct_type::StructType;
30+
pub use crate::types::traits::{AnyType, BasicType, IntMathType, FloatMathType, PointerMathType};
31+
pub use crate::types::vec_type::VectorType;
32+
pub use crate::types::void_type::VoidType;
33+
pub(crate) use crate::types::traits::AsTypeRef;
3434

3535
#[llvm_versions(3.7 => 4.0)]
3636
use llvm_sys::core::LLVMDumpType;
@@ -40,10 +40,10 @@ use llvm_sys::prelude::{LLVMTypeRef, LLVMValueRef};
4040
use std::fmt;
4141
use std::rc::Rc;
4242

43-
use AddressSpace;
44-
use context::{Context, ContextRef};
45-
use support::LLVMString;
46-
use values::IntValue;
43+
use crate::AddressSpace;
44+
use crate::context::{Context, ContextRef};
45+
use crate::support::LLVMString;
46+
use crate::values::IntValue;
4747

4848
// Worth noting that types seem to be singletons. At the very least, primitives are.
4949
// Though this is likely only true per thread since LLVM claims to not be very thread-safe.

src/types/ptr_type.rs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
use llvm_sys::core::{LLVMGetPointerAddressSpace, LLVMConstArray};
22
use llvm_sys::prelude::{LLVMTypeRef, LLVMValueRef};
33

4-
use AddressSpace;
5-
use context::ContextRef;
6-
use support::LLVMString;
7-
use types::traits::AsTypeRef;
8-
use types::{AnyTypeEnum, Type, BasicTypeEnum, ArrayType, FunctionType, VectorType};
9-
use values::{AsValueRef, ArrayValue, PointerValue, IntValue};
4+
use crate::AddressSpace;
5+
use crate::context::ContextRef;
6+
use crate::support::LLVMString;
7+
use crate::types::traits::AsTypeRef;
8+
use crate::types::{AnyTypeEnum, Type, BasicTypeEnum, ArrayType, FunctionType, VectorType};
9+
use crate::values::{AsValueRef, ArrayValue, PointerValue, IntValue};
1010

1111
/// A `PointerType` is the type of a pointer constant or variable.
1212
#[derive(Debug, PartialEq, Eq, Clone, Copy)]

0 commit comments

Comments
 (0)