Skip to content

Commit

Permalink
c
Browse files Browse the repository at this point in the history
  • Loading branch information
nameexhaustion committed Aug 29, 2024
1 parent 97564b7 commit e9a2e96
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 16 deletions.
2 changes: 1 addition & 1 deletion crates/polars-io/src/ipc/ipc_reader_async.rs
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ impl IpcReaderAsync {
Some(projection) => {
fn prepare_schema(mut schema: Schema, row_index: Option<&RowIndex>) -> Schema {
if let Some(rc) = row_index {
let _ = schema.insert_at_index(0, rc.name.as_ref().into(), IDX_DTYPE);
let _ = schema.insert_at_index(0, rc.name.as_str().into(), IDX_DTYPE);
}
schema
}
Expand Down
4 changes: 2 additions & 2 deletions crates/polars-io/src/partition.rs
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,8 @@ where
let partition_by_col_idx = partition_by
.iter()
.map(|x| {
let Some(i) = schema.index_of(x.as_ref()) else {
polars_bail!(col_not_found = x.as_ref())
let Some(i) = schema.index_of(x.as_str()) else {
polars_bail!(col_not_found = x.as_str())
};
Ok(i)
})
Expand Down
14 changes: 1 addition & 13 deletions crates/polars-utils/src/pl_str.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,19 +94,7 @@ impl core::borrow::Borrow<str> for PlSmallStr {
}
}

/// AsRef impls for other types

impl AsRef<std::path::Path> for PlSmallStr {
fn as_ref(&self) -> &std::path::Path {
self.as_str().as_ref()
}
}

impl AsRef<[u8]> for PlSmallStr {
fn as_ref(&self) -> &[u8] {
self.as_str().as_ref()
}
}
/// AsRef impls for other types (TODO)

/// From impls

Expand Down

0 comments on commit e9a2e96

Please sign in to comment.