Skip to content
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
9 changes: 6 additions & 3 deletions Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[package]
name = "structdiff"
version = "0.7.1"
version = "0.7.2"
edition = "2021"
license = "Apache-2.0 OR MIT"
repository = "https://github.com/knickish/structdiff"
Expand All @@ -22,9 +22,12 @@ structdiff-derive = { path = "derive", version = "=0.7.1" }
"generated_setters" = ["structdiff-derive/generated_setters"]
"rustc_hash" = ["dep:rustc-hash"]
"debug_asserts" = []
"__rope_benchmarks" = []

[dev-dependencies]
bincode = "1.3.3"
assert_unordered = "0.3.5"
nanorand = { version = "0.7.0" }
nanorand = "0.7.0"
pretty_assertions = "1.4.1"

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(unused)'] }
4 changes: 0 additions & 4 deletions benchmarks/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,3 @@ harness = false
[[bench]]
name = "large"
harness = false

[[bench]]
name = "rope"
harness = false
182 changes: 0 additions & 182 deletions benchmarks/benches/rope.rs

This file was deleted.

3 changes: 3 additions & 0 deletions derive/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,3 +19,6 @@ serde = { version = "^1.0.0", optional = true, features = ["derive
"serde" = ["dep:serde"]
"debug_diffs" = []
"generated_setters" = []

[lints.rust]
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(unused)'] }
4 changes: 0 additions & 4 deletions src/collections/mod.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,3 @@
#[cfg(feature = "__rope_benchmarks")]
pub mod rope;

#[cfg(not(feature = "__rope_benchmarks"))]
pub(crate) mod rope;

pub mod unordered_array_like;
Expand Down
18 changes: 8 additions & 10 deletions src/collections/ordered_array_like.rs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
source_end: source.len(),
},
)
.into_iter()
.collect::<Vec<_>>()
{
empty if empty.is_empty() => None,
Expand Down Expand Up @@ -52,7 +51,6 @@
source_end: source.len(),
},
)
.into_iter()
.collect::<Vec<_>>()
{
empty if empty.is_empty() => None,
Expand Down Expand Up @@ -239,7 +237,7 @@
let mut target_forward = target_start..target_end;
let mut target_rev = (target_end..target_start).rev();

let (target_range, source_range): (

Check warning on line 240 in src/collections/ordered_array_like.rs

View workflow job for this annotation

GitHub Actions / Clippy (ubuntu-latest, x86_64-unknown-linux-gnu)

very complex type used. Consider factoring parts into `type` definitions
&mut dyn Iterator<Item = usize>,
Box<dyn Fn() -> Box<dyn Iterator<Item = usize>>>,
) = match rev {
Expand Down Expand Up @@ -314,8 +312,8 @@
(false, true) => {
let iter: Box<dyn Iterator<Item = _>> = Box::new(
target[target_start..target_end]
.into_iter()
.map(|a| *a)
.iter()
.copied()
.enumerate()
.map(|(i, v)| {
let idx = source_end + i;
Expand Down Expand Up @@ -367,8 +365,8 @@
.unwrap();

let left = hirschberg_impl(
&target,
&source,
target,
source,
Indices {
target_end: target_split_index,
source_end: source_split_index,
Expand All @@ -377,8 +375,8 @@
);

let right = hirschberg_impl(
&target,
&source,
target,
source,
Indices {
target_start: target_split_index,
source_start: source_split_index,
Expand Down Expand Up @@ -561,8 +559,8 @@

changelist_from_change_table(
table,
&target,
&source,
target,
source,
Indices {
target_start,
target_end,
Expand Down
Loading
Loading