Skip to content

Commit

Permalink
Use From instead of Into
Browse files Browse the repository at this point in the history
  • Loading branch information
ankane committed Sep 30, 2023
1 parent 1037755 commit 48545e3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
2 changes: 1 addition & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ repository = "https://github.com/pgvector/pgvector-rust"
license = "MIT OR Apache-2.0"
authors = ["Andrew Kane <andrew@ankane.org>"]
edition = "2018"
rust-version = "1.32.0"
rust-version = "1.56.0"
readme = "README.md"

[dependencies]
Expand Down
6 changes: 3 additions & 3 deletions src/vector.rs
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ impl From<Vec<f32>> for Vector {
}
}

impl Into<Vec<f32>> for Vector {
fn into(self) -> Vec<f32> {
self.0
impl From<Vector> for Vec<f32> {
fn from(val: Vector) -> Self {
val.0
}
}

Expand Down

0 comments on commit 48545e3

Please sign in to comment.