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

stronger deprecations. #48

Merged
merged 2 commits into from
Apr 20, 2023
Merged

stronger deprecations. #48

merged 2 commits into from
Apr 20, 2023

Conversation

cpu
Copy link
Member

@cpu cpu commented Apr 20, 2023

time: hard deprecate Time::try_from.

Adds a #[deprecated] annotation. Updates tests to allow deprecated usage of existing approach and to add usage of the preferred trait.

subject_name: deprecate From for DnsName.

As mentioned in the commit comment we can't outright #[deprecate] this one because it's a trait impl.

Instead, promote the deprecation note to the rustdoc comment, add a TODO to remove it outright, and switch our own tests to call to_owned() directly in preparation of an eventual removal.

Resolves #47

cpu added 2 commits April 20, 2023 09:55
As mentioned in the comment we can't outright `#[deprecate]` this one
because it's a trait impl.

Instead, promote the deprecation note to the rustdoc comment, add a TODO
to remove it outright, and switch our own tests to call `to_owned()`
directly in preparation of an eventual removal.
@codecov
Copy link

codecov bot commented Apr 20, 2023

Codecov Report

Merging #48 (0380181) into main (6dd4a44) will not change coverage.
The diff coverage is n/a.

@@           Coverage Diff           @@
##             main      #48   +/-   ##
=======================================
  Coverage   94.17%   94.17%           
=======================================
  Files          14       14           
  Lines        2505     2505           
=======================================
  Hits         2359     2359           
  Misses        146      146           
Impacted Files Coverage Δ
src/subject_name/dns_name.rs 90.42% <ø> (ø)
src/time.rs 100.00% <ø> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

src/subject_name/dns_name.rs Show resolved Hide resolved
@cpu cpu merged commit 15acd62 into rustls:main Apr 20, 2023
@cpu cpu deleted the cpu-47-deprecations branch April 20, 2023 21:15
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.

Upgrade "soft" deprecations
2 participants