Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add unused variants to ParseError and SyntaxViolation enums #525

Merged
merged 2 commits into from Jul 23, 2019

Conversation

dekellum
Copy link
Contributor

@dekellum dekellum commented Jul 22, 2019

Per discussion in #498 (comment) , this adds a hidden unused variant to each of ParseError and SyntaxViolation enums so as to make future additions non-breaking changes. This is the long standing manual way (e.g. originally used bystd::io::ErrorKind), given lack of a stable feature and acceptable rust MSRV with rust-lang/rust#44109.

Also these types already implemented Display but having been burnt with Debug vs Display versions of the fmt function, I also disambiguated paths in these Display implementations.


This change is Reviewable

@SimonSapin
Copy link
Member

Looks good, thanks!

@bors-servo r+

@bors-servo
Copy link
Contributor

📌 Commit 8cc477f has been approved by SimonSapin

@bors-servo
Copy link
Contributor

⌛ Testing commit 8cc477f with merge 94215af...

bors-servo pushed a commit that referenced this pull request Jul 23, 2019
Add unused variants to ParseError and SyntaxViolation enums

Per discussion in #498 (comment) , this adds a hidden unused variant to each of `ParseError` and `SyntaxViolation` enums so as to make future additions non-breaking changes.   This is the long standing manual way (e.g. originally used by`std::io::ErrorKind`), given lack of a stable feature and acceptable rust MSRV with rust-lang/rust#44109.

Also these types already implemented `Display` but having been burnt with `Debug` vs `Display` versions of the `fmt` function, I also disambiguated paths in these `Display` implementations.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/rust-url/525)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

💔 Test failed - checks-travis

@SimonSapin
Copy link
Member

@bors-servo retry

@bors-servo
Copy link
Contributor

⌛ Testing commit 8cc477f with merge f491cb4...

bors-servo pushed a commit that referenced this pull request Jul 23, 2019
Add unused variants to ParseError and SyntaxViolation enums

Per discussion in #498 (comment) , this adds a hidden unused variant to each of `ParseError` and `SyntaxViolation` enums so as to make future additions non-breaking changes.   This is the long standing manual way (e.g. originally used by`std::io::ErrorKind`), given lack of a stable feature and acceptable rust MSRV with rust-lang/rust#44109.

Also these types already implemented `Display` but having been burnt with `Debug` vs `Display` versions of the `fmt` function, I also disambiguated paths in these `Display` implementations.

<!-- Reviewable:start -->
---
This change is [<img src="https://reviewable.io/review_button.svg" height="34" align="absmiddle" alt="Reviewable"/>](https://reviewable.io/reviews/servo/rust-url/525)
<!-- Reviewable:end -->
@bors-servo
Copy link
Contributor

☀️ Test successful - checks-travis
Approved by: SimonSapin
Pushing f491cb4 to master...

@bors-servo bors-servo merged commit 8cc477f into servo:master Jul 23, 2019
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.

None yet

3 participants