Skip to content

Commit

Permalink
Merge branch 'Wilfred:master' into master
Browse files Browse the repository at this point in the history
  • Loading branch information
nimrodkor authored Jun 3, 2024
2 parents 7457002 + 1fba1c7 commit 7733071
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 41 deletions.
37 changes: 10 additions & 27 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

11 changes: 6 additions & 5 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -37,17 +37,18 @@ pkg-url = "{ repo }/releases/download/{ version }/difft-{ target }.{ archive-for
pkg-fmt = "zip"

[dependencies]
# regex 1.10 requires rust 1.65.
regex = ">= 1.9, < 1.10"

regex = "1.10.4"
clap = { version = "3.2.25", features = ["cargo", "env", "wrap_help"] }
itertools = "0.11.0"
typed-arena = "2.0.2"
rustc-hash = "1.1.0"
strsim = "0.10.0"
lazy_static = "1.4.0"
# tree-sitter 0.20.10 requires rust 1.65, although it could be lower.
# https://github.com/tree-sitter/tree-sitter/issues/2669
# tree-sitter 0.22.5 uses std::os::fd::AsRawFd, which was added in Rust 1.66.
# https://github.com/tree-sitter/tree-sitter/commit/a7a47d561d4e64eaf226f93c4d68076afa67fdda
#
# tree-sitter 0.22.0 has some API changes which we need to update
# difftastic for.
tree-sitter = "0.20.10"
libc = "0.2.108"
log = "0.4.14"
Expand Down
2 changes: 1 addition & 1 deletion sample_files/compare.expected
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ sample_files/erlang_1.erl sample_files/erlang_2.erl
dccdb8f65d2f099ab1a8cb66011376a2 -

sample_files/f_sharp_1.fs sample_files/f_sharp_2.fs
6ba65e62a804124f56bdfb19afc8cd40 -
1a9173c15a42c1ebb9522109df172faf -

sample_files/hack_1.php sample_files/hack_2.php
c2bb0aa7d7b07d6ced79f6a5363e878b -
Expand Down
8 changes: 0 additions & 8 deletions src/lines.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,6 @@ pub(crate) fn format_line_num(line_num: LineNumber) -> String {
format!("{} ", line_num.display())
}

/// A position in a single line of a string.
#[derive(Debug, PartialEq, Clone, Copy)]
struct LinePosition {
/// Both zero-indexed.
pub(crate) line: LineNumber,
column: usize,
}

/// Return the length of `s` in bytes.
///
/// This is a trivial wrapper to make it clear when we want bytes not
Expand Down

0 comments on commit 7733071

Please sign in to comment.