History

Optimize usage of `hex_to_id()`

Remove it where possible, or make it private.

Sebastian Thiel committed 3 years ago

Commit 6fa950d1 parent 17c07766 files · +3 −20Browse files

Showing the changes to git-commitgraph (1 of 6 files). Show all

Unified · Split

git-commitgraph/tests/commitgraph.rs+0−4
@@ -65,10 +65,6 @@ pub fn make_readonly_repo(script_path: &str) -> std::path::PathBuf { · 64 unmodified lines
6565 scripted_fixture_read_only(script_path).expect("script succeeds all the time")
6666 }
6767
68−pub fn hex_to_id(hex: &[u8]) -> git_hash::ObjectId {
69− git_hash::ObjectId::from_hex(hex).expect("40 bytes hex")
70−}
71−
7268 pub struct RefInfo {
7369 id: git_hash::ObjectId,
7470 parent_ids: Vec<git_hash::ObjectId>,

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t