Skip to content

Commit

Permalink
👕 Format code in example
Browse files Browse the repository at this point in the history
  • Loading branch information
ChanTsune committed Nov 22, 2024
1 parent 079112a commit 41f156c
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 2 deletions.
5 changes: 4 additions & 1 deletion lib/src/archive/read/slice.rs
Original file line number Diff line number Diff line change
Expand Up @@ -221,7 +221,10 @@ impl<'a, 'r> Entries<'a, 'r> {
/// # fn main() -> io::Result<()> {
/// let file = include_bytes!("../../../../resources/test/zstd.pna");
/// let mut archive = Archive::read_header_from_slice(&file[..])?;
/// for entry in archive.entries_slice().extract_solid_entries(Some("password")) {
/// for entry in archive
/// .entries_slice()
/// .extract_solid_entries(Some("password"))
/// {
/// let mut reader = entry?.reader(ReadOptions::builder().build());
/// // fill your code
/// }
Expand Down
6 changes: 5 additions & 1 deletion lib/src/chunk.rs
Original file line number Diff line number Diff line change
Expand Up @@ -304,7 +304,11 @@ pub(crate) fn chunk_data_split(
/// let archive = fs::File::open("foo.pna")?;
/// for chunk in read_as_chunks(archive)? {
/// let chunk = chunk?;
/// println!("chunk type: {}, chunk data size: {}", chunk.ty(), chunk.length());
/// println!(
/// "chunk type: {}, chunk data size: {}",
/// chunk.ty(),
/// chunk.length()
/// );
/// }
/// # Ok(())
/// # }
Expand Down

0 comments on commit 41f156c

Please sign in to comment.