Skip to content

Commit 16ac788

Browse files
committed
Merge pull request #2 from lfairy/patch-1
Rename extension traits as per rust-lang/rfcs#445
2 parents 63241dd + 0d8607b commit 16ac788

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

src/lib.rs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,12 @@ pub fn unreachable<T = ()>(_: Void) -> T {
5656
}
5757

5858
/// Extensions to `Result<T, Void>`
59-
pub trait VoidExtensions<T>: Sized {
59+
pub trait ResultVoidExt<T>: Sized {
6060
/// Get the value out of a wrapper.
6161
fn void_unwrap(self) -> T;
6262
}
6363

64-
impl<T> VoidExtensions<T> for Result<T, Void> {
64+
impl<T> ResultVoidExt<T> for Result<T, Void> {
6565
/// Get the value out of an always-ok Result.
6666
///
6767
/// Never panics, since it is statically known to be Ok.
@@ -75,12 +75,12 @@ impl<T> VoidExtensions<T> for Result<T, Void> {
7575
}
7676

7777
/// Extensions to `Result<Void, E>`
78-
pub trait ErrVoidExtensions<E>: Sized {
78+
pub trait ResultVoidErrExt<E>: Sized {
7979
/// Get the error out of a wrapper.
8080
fn void_unwrap_err(self) -> E;
8181
}
8282

83-
impl<E> ErrVoidExtensions<E> for Result<Void, E> {
83+
impl<E> ResultVoidErrExt<E> for Result<Void, E> {
8484
/// Get the error out of an always-err Result.
8585
///
8686
/// Never panics, since it is statically known to be Err.

0 commit comments

Comments
 (0)