/src/wasmtime/target/debug/build/target-lexicon-a3ca722bc69aa2e0/out/host.rs
Line | Count | Source (jump to first uncovered line) |
1 | | #[allow(unused_imports)] |
2 | | use crate::Aarch64Architecture::*; |
3 | | #[allow(unused_imports)] |
4 | | use crate::ArmArchitecture::*; |
5 | | #[allow(unused_imports)] |
6 | | use crate::CustomVendor; |
7 | | #[allow(unused_imports)] |
8 | | use crate::Mips32Architecture::*; |
9 | | #[allow(unused_imports)] |
10 | | use crate::Mips64Architecture::*; |
11 | | #[allow(unused_imports)] |
12 | | use crate::Riscv32Architecture::*; |
13 | | #[allow(unused_imports)] |
14 | | use crate::Riscv64Architecture::*; |
15 | | #[allow(unused_imports)] |
16 | | use crate::X86_32Architecture::*; |
17 | | |
18 | | /// The `Triple` of the current host. |
19 | | pub const HOST: Triple = Triple { |
20 | | architecture: Architecture::X86_64, |
21 | | vendor: Vendor::Unknown, |
22 | | operating_system: OperatingSystem::Linux, |
23 | | environment: Environment::Gnu, |
24 | | binary_format: BinaryFormat::Elf, |
25 | | }; |
26 | | |
27 | | impl Architecture { |
28 | | /// Return the architecture for the current host. |
29 | 0 | pub const fn host() -> Self { |
30 | 0 | Architecture::X86_64 |
31 | 0 | } |
32 | | } |
33 | | |
34 | | impl Vendor { |
35 | | /// Return the vendor for the current host. |
36 | 0 | pub const fn host() -> Self { |
37 | 0 | Vendor::Unknown |
38 | 0 | } |
39 | | } |
40 | | |
41 | | impl OperatingSystem { |
42 | | /// Return the operating system for the current host. |
43 | 0 | pub const fn host() -> Self { |
44 | 0 | OperatingSystem::Linux |
45 | 0 | } |
46 | | } |
47 | | |
48 | | impl Environment { |
49 | | /// Return the environment for the current host. |
50 | 0 | pub const fn host() -> Self { |
51 | 0 | Environment::Gnu |
52 | 0 | } |
53 | | } |
54 | | |
55 | | impl BinaryFormat { |
56 | | /// Return the binary format for the current host. |
57 | 0 | pub const fn host() -> Self { |
58 | 0 | BinaryFormat::Elf |
59 | 0 | } |
60 | | } |
61 | | |
62 | | impl Triple { |
63 | | /// Return the triple for the current host. |
64 | 249k | pub const fn host() -> Self { |
65 | 249k | Self { |
66 | 249k | architecture: Architecture::X86_64, |
67 | 249k | vendor: Vendor::Unknown, |
68 | 249k | operating_system: OperatingSystem::Linux, |
69 | 249k | environment: Environment::Gnu, |
70 | 249k | binary_format: BinaryFormat::Elf, |
71 | 249k | } |
72 | 249k | } |
73 | | } |