Skip to content

Commit 87513b0

Browse files
committed
Let RawOsError be a pub type
1 parent 38e4ad3 commit 87513b0

File tree

2 files changed

+6
-3
lines changed

2 files changed

+6
-3
lines changed

src/error.rs

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,14 @@ cfg_if::cfg_if!(
99
if #[cfg(target_os = "uefi")] {
1010
// See the UEFI spec for more information:
1111
// https://uefi.org/specs/UEFI/2.10/Apx_D_Status_Codes.html
12-
type RawOsError = usize;
12+
pub type RawOsError = usize;
1313
type NonZeroRawOsError = core::num::NonZeroUsize;
1414
const UEFI_ERROR_FLAG: RawOsError = 1 << (RawOsError::BITS - 1);
1515
} else {
16-
type RawOsError = i32;
16+
/// Raw error code
17+
///
18+
/// This type is platform-dependent.
19+
pub type RawOsError = i32;
1720
type NonZeroRawOsError = core::num::NonZeroI32;
1821
}
1922
);

src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ mod util;
3939
#[cfg(feature = "std")]
4040
mod error_std_impls;
4141

42-
pub use crate::error::Error;
42+
pub use crate::error::{Error, RawOsError};
4343

4444
/// Fill `dest` with random bytes from the system's preferred random number source.
4545
///

0 commit comments

Comments
 (0)