Details
- Reviewers
- None
- Group Reviewers
hg-reviewers - Commits
- rHGd07e4656ff5a: hg-core: use `u32` instead of `i32` in `Chunk` (D8958#inline-15001 followup)
Diff Detail
- Repository
- rHG Mercurial
- Branch
- default
- Lint
No Linters Available - Unit
No Unit Test Coverage
Event Timeline
rust/hg-core/src/revlog/patch.rs | ||
---|---|---|
25 | Is the offset always positive? Same question for all affected methods. |
rust/hg-core/src/revlog/patch.rs | ||
---|---|---|
25 | The start of the replaced chunk cannot be negative. Negative start would mean that the replacement start before the start of the data. Same for the other methods. |
rust/hg-core/src/revlog/patch.rs | ||
---|---|---|
25 | I'm only asking because if self.start is 0, and offset is -1, the as u32 conversion would put the result to u32::max_value(). But maybe that never happens? |
rust/hg-core/src/revlog/patch.rs | ||
---|---|---|
25 | Theoretically no. But if there is a mistake... maybe checked_add should be used |
rust/hg-core/src/revlog/patch.rs | ||
---|---|---|
112 | nit: delta seems like a clearer name |
Is the offset always positive? Same question for all affected methods.