Skip to content

feat[ignore]: Add path() to error - #3461

Open
tmccombs wants to merge 1 commit into
BurntSushi:masterfrom
tmccombs:error-path
Open

feat[ignore]: Add path() to error#3461
tmccombs wants to merge 1 commit into
BurntSushi:masterfrom
tmccombs:error-path

Conversation

@tmccombs

@tmccombs tmccombs commented Jul 4, 2026

Copy link
Copy Markdown
Contributor

Add a path() method to Error, which allows getting the path without needing to pattern match on WithPath.

Add a path() method to Error, which allows getting the path without
needing to pattern match on WithPath.
@BurntSushi

Copy link
Copy Markdown
Owner

Hmmm I'm not so sure about this one. This is omitting Error::Io and Error::Loop and Error::Partial. In the latter two cases, it's not clear what Path should be provided. I think this one might be better as a helper function defined as needed for your specific use case.

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.

2 participants