Skip to content

Expose static descriptions for parser errors - #226

Open
jadenfix wants to merge 1 commit into
seanmonstar:masterfrom
jadenfix:feat/public-error-description
Open

jadenfix wants to merge 1 commit into
seanmonstar:masterfrom
jadenfix:feat/public-error-description

Conversation

@jadenfix

Copy link
Copy Markdown

Make the existing Error::description_str accessor public so callers can obtain the display message without allocating or relying on the deprecated std::error::Error::description method. Parser behavior and error messages remain unchanged.

Fixes #116.

Validation:

  • Public integration tests fail to compile on the baseline with E0624 (private method).
  • cargo test and cargo test --no-default-features each pass: 99 unit, 2 new error-description integration, 263 URI integration, and 7 documentation tests.
  • cargo clippy --all-targets --all-features passes without warnings.
  • A separate #![no_std] public consumer compiles against cargo build --no-default-features, returning a static message from an actual request parse error without allocation.

Prepared with Codex assistance and independently reviewed by a separate Codex agent. No human review is claimed.

Make the existing Error::description_str accessor public so callers can obtain the display message without allocating or relying on the deprecated std::error::Error::description method. Cover every variant through the public API and exercise a description surviving a parsed error.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

expose static Error str

1 participant