diff options
| author | roblabla <unfiltered@roblab.la> | 2019-10-24 15:29:29 +0000 |
|---|---|---|
| committer | roblabla <unfiltered@roblab.la> | 2019-10-25 13:01:25 +0000 |
| commit | 093ec70b1e4da3d814a137f5aea6f4ff75ad3399 (patch) | |
| tree | 22b3526af7282f81e0efd18de1afe3cc7121a824 /src/libsyntax | |
| parent | 8e0007f829661e57d008d2e908c95f6e84b04b25 (diff) | |
| download | rust-093ec70b1e4da3d814a137f5aea6f4ff75ad3399.tar.gz rust-093ec70b1e4da3d814a137f5aea6f4ff75ad3399.zip | |
Add new EFIAPI ABI
Adds a new ABI for the EFIAPI calls. This ABI should reflect the latest version of the UEFI specification at the time of commit (UEFI spec 2.8, URL below). The specification says that for x86_64, we should follow the win64 ABI, while on all other supported platforms (ia32, itanium, arm, arm64 and risc-v), we should follow the C ABI. To simplify the implementation, we will simply follow the C ABI on all platforms except x86_64, even those technically unsupported by the UEFI specification. https://uefi.org/sites/default/files/resources/UEFI_Spec_2_8_final.pdf
Diffstat (limited to 'src/libsyntax')
| -rw-r--r-- | src/libsyntax/feature_gate/active.rs | 3 | ||||
| -rw-r--r-- | src/libsyntax/feature_gate/check.rs | 4 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/libsyntax/feature_gate/active.rs b/src/libsyntax/feature_gate/active.rs index 1386eac48da..5ca2695fe35 100644 --- a/src/libsyntax/feature_gate/active.rs +++ b/src/libsyntax/feature_gate/active.rs @@ -531,6 +531,9 @@ declare_features! ( /// Non-object safe trait objects safe to use but cannot be created in safe rust (active, object_safe_for_dispatch, "1.40.0", Some(43561), None), + /// Allows using the `efiapi` ABI. + (active, abi_efiapi, "1.40.0", Some(1), None), + // ------------------------------------------------------------------------- // feature-group-end: actual feature gates // ------------------------------------------------------------------------- diff --git a/src/libsyntax/feature_gate/check.rs b/src/libsyntax/feature_gate/check.rs index 172511f0f09..e68675a9b8e 100644 --- a/src/libsyntax/feature_gate/check.rs +++ b/src/libsyntax/feature_gate/check.rs @@ -234,6 +234,10 @@ impl<'a> PostExpansionVisitor<'a> { gate_feature_post!(&self, abi_amdgpu_kernel, span, "amdgpu-kernel ABI is experimental and subject to change"); }, + Abi::EfiApi => { + gate_feature_post!(&self, abi_efiapi, span, + "efiapi ABI is experimental and subject to change"); + }, // Stable Abi::Cdecl | Abi::Stdcall | |
