8000 Lint: remove calls to PhantomData::default by Smaug123 · Pull Request #1296 · rustls/rustls · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Lint: remove calls to PhantomData::default #1296

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

Merged
merged 1 commit into from
May 12, 2023
Merged

Lint: remove calls to PhantomData::default #1296

merged 1 commit into from
May 12, 2023

Conversation

Smaug123
Copy link
Contributor
@Smaug123 Smaug123 commented May 12, 2023

Clippy is currently failing, e.g.:

 error: use of `default` to create a unit struct
   --> rustls/src/server/server_conn.rs:320:30
    |
320 |             side: PhantomData::default(),
    |                              ^^^^^^^^^^^ help: remove this call to `default`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#default_constructed_unit_structs

Clippy was happy with this change for me locally.

Copy link
Member
@ctz ctz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks!

@ctz ctz merged commit 792045b into rustls:main May 12, 2023
Copy link
Member
@cpu cpu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks like nightly clippy in CI has been failing with this finding too.

Thanks for fixing it 👍

@Smaug123 Smaug123 deleted the remove-default-struct branch May 12, 2023 21:07
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.

4 participants
0