wcampbell0x2a / bintex

Create bytefield latex digrams with the use of rust proc-macros and deku
Apache License 2.0
4 stars 0 forks source link

Bump deku from 0.16.0 to 0.17.0 #52

Closed dependabot[bot] closed 4 months ago

dependabot[bot] commented 4 months ago

Bumps deku from 0.16.0 to 0.17.0.

Release notes

Sourced from deku's releases.

v0.17.0

Changes

  • Bumped MSRV to 1.71 (#438)
  • Add DekuWrite impl for [T] (#416)
  • Add no-assert-string feature to remove panic string on failed assertion (#405)
  • Add read_all attribute to read until reader.end() (#387)
  • Changed edition to 2021 (#389)
  • Refactored logging feature with massive usability increases (#352), (#355)
  • Bumped the syn library to 2.0, which required replacing type for Enums with id_type (#386)
 #[derive(PartialEq, Debug, DekuRead, DekuWrite)]
-#[deku(type = "u8")]
+#[deku(id_type = "u8")]
 enum DekuTest {
     #[deku(id_pat = "_")]
     VariantC((u8, u8)),
 }

Updated Reader API

  • Changed API of reading to use io::Read, bringing massive performance and usability improvements (#352)
  • Changed the trait DekuRead to DekuReader

For example:

use std::io::{Seek, SeekFrom, Read};
use std::fs::File;
use deku::prelude::*;

#[derive(Debug, DekuRead, DekuWrite, PartialEq, Eq, Clone, Hash)] #[deku(endian = "big")] struct EcHdr { magic: [u8; 4], version: u8, padding1: [u8; 3], }

let mut file = File::options().read(true).open("file").unwrap(); let ec = EcHdr::from_reader((&mut file, 0)).unwrap();

  • The more internal (with context) read(..) was replaced with from_reader_with_ctx(..). With the switch to internal streaming, the variables deku::input, deku::input_bits, and deku::rest are now not possible and were removed. deku::reader is a replacement for some of the functionality. See https://github.com/sharksforarms/deku/blob/HEAD/examples/deku_input.rs for a new example of caching all reads.

Old:

#[derive(Debug, PartialEq, DekuRead, DekuWrite)]
struct DekuTest {
</tr></table> 

... (truncated)

Changelog

Sourced from deku's changelog.

[0.17.0] - 2024-04-23

Changes

  • Bumped MSRV to 1.71 (#438)
  • Add DekuWrite impl for [T] (#416)
  • Add no-assert-string feature to remove panic string on failed assertion (#405)
  • Add read_all attribute to read until reader.end() (#387)
  • Changed edition to 2021 (#389)
  • Refactored logging feature with massive usability increases (#352), (#355)
  • Bumped the syn library to 2.0, which required replacing type for Enums with id_type (#386)
 #[derive(PartialEq, Debug, DekuRead, DekuWrite)]
-#[deku(type = "u8")]
+#[deku(id_type = "u8")]
 enum DekuTest {
     #[deku(id_pat = "_")]
     VariantC((u8, u8)),
 }

Updated Reader API

  • Changed API of reading to use io::Read, bringing massive performance and usability improvements (#352)
  • Changed the trait DekuRead to DekuReader

For example:

use std::io::{Seek, SeekFrom, Read};
use std::fs::File;
use deku::prelude::*;

#[derive(Debug, DekuRead, DekuWrite, PartialEq, Eq, Clone, Hash)] #[deku(endian = "big")] struct EcHdr { magic: [u8; 4], version: u8, padding1: [u8; 3], }

let mut file = File::options().read(true).open("file").unwrap(); let ec = EcHdr::from_reader((&mut file, 0)).unwrap();

  • The more internal (with context) read(..) was replaced with from_reader_with_ctx(..). With the switch to internal streaming, the variables deku::input, deku::input_bits, and deku::rest are now not possible and were removed. deku::reader is a replacement for some of the functionality. See https://github.com/sharksforarms/deku/blob/master/examples/deku_input.rs for a new example of caching all reads.

Old:

#[derive(Debug, PartialEq, DekuRead, DekuWrite)]
</tr></table> 

... (truncated)

Commits


Dependabot compatibility score

Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot show ignore conditions` will show all of the ignore conditions of the specified dependency - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)