A major update from the popular lexer generator logos introduces a completely rewritten engine in version 0.16. This new release prioritizes correctness and more powerful regular expression support over raw speed.

With this significant change, the crate is trading a small performance cost for more accurate and reliable parsing. This move raises a key question for developers: how does this new balance affect complex parsing tasks in production?

In this weeks’s Rust Crates recap:

> logos 0.16 lexer engine rewrite

> derive_more 2.1.0 ergonomic enhancements

> graphql_client 0.15 security and spec updates

> Sentry's sourcemap crate improves debug integration

Logos 0.16 Revamps its Lexer Engine

The Recap: The popular high-performance lexer generator, logos, just dropped v0.16.0, introducing a major overhaul of its internal engine. This update prioritizes correctness and more powerful regular expression support, and you can see the full list of changes on GitHub.

Unpacked:

  • The lexer's core has been rewritten from the ground up to provide more accurate regex semantics, fixing long-standing backtracking bugs and expanding pattern support.

  • This focus on correctness may result in a slight performance dip in some cases. The previous version, v0.15, will no longer be maintained, so upgrading is recommended for future updates.

  • Due to the extensive changes, this release includes several breaking changes. Developers should consult the official migration guide for a smooth transition.

  • The Minimum Supported Rust Version (MSRV) has been bumped to 1.80 to leverage features like LazyLock.

Bottom line: This update makes logos an even more reliable tool for complex parsing, trading a small performance cost for greater correctness. Developers get a more robust lexer engine that better handles a wider range of regular expressions.

Derive_more 2.1.0 Makes Derives More Ergonomic

The Recap: The widely-used derive_more crate has released v2.1.0, packed with ergonomic improvements to further reduce boilerplate for common traits. You can review the full changelog on GitHub for all the details.

Unpacked:

  • The headline feature is rename_all support for Display and FromStr derives, allowing you to automatically apply casing conventions (like snake_case or kebab-case) to unit variants.

  • Error handling gets a boost, as the Error derive now supports optional source fields, making it more flexible when wrapping different error types.

  • The FromStr derive now works correctly with structs that have no fields, and the PartialEq/Eq derives have been improved to better handle generics.

  • This release raises the MSRV to 1.81 and includes fixes for several deprecation warnings and bugs in the TryInto derive.

Bottom line: This update reinforces derive_more's position as an essential tool for cutting down on repetitive Rust code. These ergonomic enhancements allow developers to write cleaner, more maintainable projects with less effort.

GraphQL Client v0.15 Ships Security Fix and Spec Updates

The Recap: The graphql_client crate has released v0.15.0, a solid update focused on security, standards compliance, and dependency maintenance. For a detailed breakdown of all the changes, you can view the full changelog on GitHub.

Unpacked:

  • This version includes an important security fix that addresses the moderate-severity advisory RUSTSEC-2022-0074.

  • The client now supports oneOf input objects, keeping it up-to-date with the latest additions to the official GraphQL specification.

  • The #[derive(GraphQLQuery)] macro is now more flexible, as the serde dependency is no longer a strict requirement for its use.

  • Several key dependencies were updated, including reqwest, clap, tokio, and openssl, ensuring the crate remains compatible and secure.

Bottom line: This release reinforces graphql_client as a mature and reliable choice for interacting with GraphQL APIs in Rust. These updates allow developers to build more secure applications while leveraging modern GraphQL features.

Sentry’s Sourcemap Crate Improves Debug Integration

The Recap: The Sentry-maintained sourcemap crate has been updated to v9.3.0, introducing better support for modern debug tooling and internal performance enhancements. This change aligns the crate with emerging standards for debug information, detailed in the main pull request.

Unpacked:

  • The key update is the serialization of sourcemaps with debugId instead of the older debug_id, improving compatibility with modern debuggers and symbol servers.

  • Internal changes include storing the SourceView linecache as offsets instead of pointers, a move that can improve performance and memory management when processing large sourcemaps.

  • The release also includes code quality improvements, with fixes for clippy lints on the latest Rust versions to ensure the crate remains well-maintained.

Bottom line: This update ensures better integration with the broader JavaScript debugging ecosystem by adopting the debugId standard. The internal optimizations make sourcemap a more efficient and reliable choice for developers building tooling in Rust.

The Shortlist

Flume released version 0.12.0, updating the blazingly fast multi-producer, multi-consumer channel popular in high-performance concurrent applications.

Slotmap shipped version 1.1.0, enhancing its collection of containers that provide persistent, O(1) access keys for high-performance use cases like game engines and graph data structures.

Sqlparser_derive updated to version 0.4.0, continuing to provide the foundational derive macros for the extensible ANSI-compliant SQL parser.