Skip to content
This repository was archived by the owner on Oct 23, 2022. It is now read-only.

Commit 337ad5b

Browse files
bors[bot]c410-f3r
andauthored
Merge #412
412: doc(unixfs): fix typos r=koivunej a=c410-f3r Co-authored-by: Caio <c410.f3r@gmail.com>
2 parents 015523c + ffd9e80 commit 337ad5b

File tree

3 files changed

+5
-5
lines changed

3 files changed

+5
-5
lines changed

unixfs/src/dagpb.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -48,7 +48,7 @@ fn subslice_to_range(full: &[u8], sub: &[u8]) -> Option<Range<usize>> {
4848
sub.checked_sub(full)
4949
// not needed as it would divide by one: .map(|diff| diff / mem::size_of::<T>())
5050
//
51-
// if there are two slices of a continious chunk, [A|B] we need to make sure B will not be
51+
// if there are two slices of a continuous chunk, [A|B] we need to make sure B will not be
5252
// calculated as subslice of A
5353
.and_then(|start| if start >= max { None } else { Some(start) })
5454
.map(|start| start..(start + amt))

unixfs/src/file/adder.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ pub struct FileAdder {
2222
block_buffer: Vec<u8>,
2323
// all unflushed links as a flat vec; this is compacted as we grow and need to create a link
2424
// block for the last N blocks, as decided by the collector.
25-
// FIXME: this is a cause of likely "accidentially quadratic" behaviour visible when adding a
25+
// FIXME: this is a cause of likely "accidentally quadratic" behavior visible when adding a
2626
// large file and using a minimal chunk size. Could be that this must be moved to Collector to
2727
// help collector (or layout) to decide how this should be persisted.
2828
unflushed_links: Vec<Link>,
@@ -109,7 +109,7 @@ impl fmt::Debug for Link {
109109
}
110110
}
111111

112-
/// Convinience type to facilitate configuring [`FileAdder`]s.
112+
/// Convenience type to facilitate configuring [`FileAdder`]s.
113113
#[derive(Default)]
114114
pub struct FileAdderBuilder {
115115
chunker: Chunker,

unixfs/src/walk.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -407,7 +407,7 @@ impl InnerEntry {
407407
self.depth = self
408408
.depth
409409
.checked_sub(1)
410-
.expect("undeflowed path components");
410+
.expect("underflowed path components");
411411
}
412412

413413
self.path.push(name);
@@ -474,7 +474,7 @@ impl InnerEntry {
474474
self.depth = self
475475
.depth
476476
.checked_sub(1)
477-
.expect("underlowed depth calculation during bucket->bucket");
477+
.expect("underflowed depth calculation during bucket->bucket");
478478
}
479479

480480
assert_eq!(self.depth, depth, "{:?}", self.path);

0 commit comments

Comments
 (0)