Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add back missing derives #27

Merged
merged 1 commit into from
Jul 15, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 3 additions & 5 deletions src/typed/non_utf8/path.rs
Original file line number Diff line number Diff line change
@@ -1,11 +1,9 @@
use alloc::borrow::Cow;
use core::fmt;

#[cfg(feature = "std")]
use std::path::Path;

#[cfg(all(feature = "std", not(target_family = "wasm")))]
use std::io;
#[cfg(feature = "std")]
use std::path::Path;

use crate::common::{CheckedPathError, StripPrefixError};
use crate::convert::TryAsRef;
Expand All @@ -17,7 +15,7 @@ use crate::windows::WindowsPath;
///
/// * [`UnixPath`]
/// * [`WindowsPath`]
#[derive(Clone, Debug, PartialEq, Eq)]
#[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub enum TypedPath<'a> {
Unix(&'a UnixPath),
Windows(&'a WindowsPath),
Expand Down
3 changes: 1 addition & 2 deletions src/typed/non_utf8/pathbuf.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
use alloc::borrow::Cow;
use alloc::collections::TryReserveError;
use core::convert::TryFrom;

#[cfg(feature = "std")]
use std::{io, path::PathBuf};

Expand All @@ -15,7 +14,7 @@ use crate::windows::{WindowsPath, WindowsPathBuf};
///
/// * [`UnixPathBuf`]
/// * [`WindowsPathBuf`]
#[derive(Clone, Debug, PartialEq, Eq)]
#[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub enum TypedPathBuf {
Unix(UnixPathBuf),
Windows(WindowsPathBuf),
Expand Down
3 changes: 1 addition & 2 deletions src/typed/utf8/path.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
use core::fmt;

#[cfg(feature = "std")]
use std::path::Path;

Expand All @@ -15,7 +14,7 @@ use crate::windows::Utf8WindowsPath;
///
/// * [`Utf8UnixPath`]
/// * [`Utf8WindowsPath`]
#[derive(Clone, Debug, PartialEq, Eq)]
#[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub enum Utf8TypedPath<'a> {
Unix(&'a Utf8UnixPath),
Windows(&'a Utf8WindowsPath),
Expand Down
3 changes: 1 addition & 2 deletions src/typed/utf8/pathbuf.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
use alloc::collections::TryReserveError;
use core::convert::TryFrom;
use core::fmt;

#[cfg(feature = "std")]
use std::path::PathBuf;

Expand All @@ -17,7 +16,7 @@ use crate::windows::{Utf8WindowsPath, Utf8WindowsPathBuf};
///
/// * [`Utf8UnixPathBuf`]
/// * [`Utf8WindowsPathBuf`]
#[derive(Clone, Debug, PartialEq, Eq)]
#[derive(Clone, Debug, PartialEq, Eq, Hash, PartialOrd, Ord)]
pub enum Utf8TypedPathBuf {
Unix(Utf8UnixPathBuf),
Windows(Utf8WindowsPathBuf),
Expand Down
Loading