Skip to content

chore: release v0.3.0#135

Merged
mergify[bot] merged 1 commit into
mainfrom
release-plz-2026-03-02T05-33-50Z
Mar 2, 2026
Merged

chore: release v0.3.0#135
mergify[bot] merged 1 commit into
mainfrom
release-plz-2026-03-02T05-33-50Z

Conversation

@github-actions
Copy link
Copy Markdown
Contributor

@github-actions github-actions Bot commented Mar 2, 2026

🤖 New release

  • libmagic-rs: 0.2.1 -> 0.3.0 (⚠ API breaking changes)

libmagic-rs breaking changes

--- failure enum_no_repr_variant_discriminant_changed: enum variant had its discriminant change value ---

Description:
The enum's variant had its discriminant value change. This breaks downstream code that used its value via a numeric cast like `as isize`.
        ref: https://doc.rust-lang.org/reference/items/enumerations.html#assigning-discriminant-values
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.46.0/src/lints/enum_no_repr_variant_discriminant_changed.ron

Failed in:
  variant TypeKind::String 3 -> 4 in /tmp/.tmp3M9g71/libmagic-rs/src/parser/ast.rs:119
  variant TypeKind::String 3 -> 4 in /tmp/.tmp3M9g71/libmagic-rs/src/parser/ast.rs:119
  variant TypeKind::String 3 -> 4 in /tmp/.tmp3M9g71/libmagic-rs/src/parser/ast.rs:119

--- failure enum_variant_added: enum variant added on exhaustive enum ---

Description:
A publicly-visible enum without #[non_exhaustive] has a new variant.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#enum-variant-new
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.46.0/src/lints/enum_variant_added.ron

Failed in:
  variant TypeKind:Quad in /tmp/.tmp3M9g71/libmagic-rs/src/parser/ast.rs:112
  variant TypeKind:Quad in /tmp/.tmp3M9g71/libmagic-rs/src/parser/ast.rs:112
  variant TypeKind:Quad in /tmp/.tmp3M9g71/libmagic-rs/src/parser/ast.rs:112

--- failure struct_missing: pub struct removed or renamed ---

Description:
A publicly-visible struct cannot be imported by its prior path. A `pub use` may have been removed, or the struct itself may have been renamed or removed entirely.
        ref: https://doc.rust-lang.org/cargo/reference/semver.html#item-remove
       impl: https://github.com/obi1kenobi/cargo-semver-checks/tree/v0.46.0/src/lints/struct_missing.ron

Failed in:
  struct libmagic_rs::evaluator::MatchResult, previously in file /tmp/.tmpp8oIWU/libmagic-rs/src/evaluator/mod.rs:207
  struct libmagic_rs::MatchResult, previously in file /tmp/.tmpp8oIWU/libmagic-rs/src/evaluator/mod.rs:207
Changelog

[0.3.0] - 2026-03-02

Features

  • parser: Implement quad 64-bit integer type with endian variants (#133)


This PR was generated with release-plz.

@dosubot dosubot Bot added the size:XS This PR changes 0-9 lines, ignoring generated files. label Mar 2, 2026
@mergify
Copy link
Copy Markdown
Contributor

mergify Bot commented Mar 2, 2026

Merge Protections

Your pull request matches the following merge protections and will not be merged until they are valid.

🟢 Do not merge outdated PRs

Wonderful, this rule succeeded.

Make sure PRs are within 10 commits of the base branch before merging

  • #commits-behind <= 3

@dosubot dosubot Bot added evaluator Rule evaluation engine and logic parser Magic file parsing components and grammar labels Mar 2, 2026
@mergify mergify Bot merged commit 31884cd into main Mar 2, 2026
6 checks passed
@mergify mergify Bot deleted the release-plz-2026-03-02T05-33-50Z branch March 2, 2026 05:35
@dosubot
Copy link
Copy Markdown
Contributor

dosubot Bot commented Mar 2, 2026

Documentation Updates

1 document(s) were updated by changes in this PR:

api-reference
View Changes
@@ -226,6 +226,7 @@
 | `Byte { signed }` | Single byte with explicit signedness (struct variant since v0.2.0; previously unit variant) |
 | `Short { endian, signed }` | 16-bit integer |
 | `Long { endian, signed }` | 32-bit integer |
+| `Quad { endian, signed }` | 64-bit quad integer (quaddouble/lequad/bequad/mequad) |
 | `String { max_length }` | String data |
 
 ### Operator
@@ -370,19 +371,7 @@
 
 ### MatchResult (Evaluator)
 
-Result from internal evaluation.
-
-```rust
-use libmagic_rs::evaluator::MatchResult;
-```
-
-| Field | Type | Description |
-|-------|------|-------------|
-| `message` | `String` | Match description |
-| `offset` | `usize` | Match offset |
-| `level` | `u32` | Rule level |
-| `value` | `Value` | Matched value |
-| `confidence` | `f64` | Confidence score |
+**Note**: This type was removed in v0.3.0. Match results are handled internally and exposed through the `output::MatchResult` type.
 
 ## Output Module
 
@@ -460,7 +449,7 @@
 pub use parser::ast::{Endianness, MagicRule, OffsetSpec, Operator, StrengthModifier, TypeKind, Value};
 
 // Evaluator types
-pub use evaluator::{EvaluationContext, MatchResult};
+pub use evaluator::EvaluationContext;
 
 // Error types
 pub use error::{EvaluationError, LibmagicError, ParseError};
@@ -477,7 +466,12 @@
 - **Minimum Rust Version**: 1.85
 - **Edition**: 2024
 - **License**: Apache-2.0
-- **Current Version**: 0.2.1
+- **Current Version**: 0.3.0
+
+### Breaking Changes in v0.3.0
+
+- `TypeKind::Quad` variant added to support 64-bit quad integer types (breaking change due to exhaustive enum)
+- `TypeKind::String` discriminant changed from 3 to 4 due to insertion of `Quad` variant
 
 ### Breaking Changes in v0.2.0
 

How did I do? Any feedback?  Join Discord

dosubot Bot added a commit that referenced this pull request Mar 2, 2026
@dosubot dosubot Bot mentioned this pull request Mar 2, 2026
mergify Bot pushed a commit that referenced this pull request Mar 2, 2026
Update documentation for
#135

_Generated by [Dosu](https://dosu.dev)_

Co-authored-by: dosubot[bot] <131922026+dosubot[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

evaluator Rule evaluation engine and logic parser Magic file parsing components and grammar size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants