-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
New lint: zst_offset #4816
New lint: zst_offset #4816
Conversation
Seems occurred an ICE on dogfooding |
@flip1995 r? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
r=me once Clippy builds again
@bors r=phansch |
📌 Commit c21b198 has been approved by |
New lint: zst_offset This fixes #4813 changelog: add `zst_offset` lint
@bors retry for queue prio |
Rollup of 4 Pull requests with new lints Rollup of pull requests - #4816 (New lint: zst_offset) - #4814 (New lint: Implement ifs_same_cond_fn) - #4807 (Add `large_stack_arrays` lint) - #4806 (Issue/4623) changelog: add [`zst_offset`] lint changelog: New lint: [`ifs_same_cond_fn`] cahngelog: Add new lint [large_stack_arrays] changelog: added lint [`tabs_in_doc_comments`]
@@ -0,0 +1,9 @@ | |||
error[E0606]: casting `&i32` as `*const u8` is invalid |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
shouldn't there be errors about offset calculations using x
here instead of casting errors for y
?
/// | ||
/// **Example:** | ||
/// ```ignore | ||
/// unsafe { (&() as *const ()).offest(1) }; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
s/offest/offset
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Will do a followup.
This fixes #4813
changelog: add
zst_offset
lint