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

New lint: zst_offset #4816

Merged
merged 1 commit into from
Nov 23, 2019
Merged

New lint: zst_offset #4816

merged 1 commit into from
Nov 23, 2019

Conversation

llogiq
Copy link
Contributor

@llogiq llogiq commented Nov 14, 2019

This fixes #4813

changelog: add zst_offset lint

@JohnTitor JohnTitor added the S-waiting-on-review Status: Awaiting review from the assignee but also interested parties label Nov 15, 2019
@JohnTitor
Copy link
Member

Seems occurred an ICE on dogfooding

@llogiq
Copy link
Contributor Author

llogiq commented Nov 15, 2019

@flip1995 r?

Copy link
Member

@phansch phansch left a 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

@flip1995
Copy link
Member

@bors r=phansch

@bors
Copy link
Collaborator

bors commented Nov 23, 2019

📌 Commit c21b198 has been approved by phansch

bors added a commit that referenced this pull request Nov 23, 2019
New lint: zst_offset

This fixes #4813

changelog: add `zst_offset` lint
@bors
Copy link
Collaborator

bors commented Nov 23, 2019

⌛ Testing commit c21b198 with merge d15c9c1...

@flip1995
Copy link
Member

@bors retry for queue prio

bors added a commit that referenced this pull request Nov 23, 2019
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`]
@bors bors merged commit c21b198 into master Nov 23, 2019
@flip1995 flip1995 deleted the zst-offset branch November 23, 2019 17:36
@@ -0,0 +1,9 @@
error[E0606]: casting `&i32` as `*const u8` is invalid
Copy link
Contributor

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) };
Copy link
Contributor

Choose a reason for hiding this comment

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

s/offest/offset

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Will do a followup.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
S-waiting-on-review Status: Awaiting review from the assignee but also interested parties
Projects
None yet
Development

Successfully merging this pull request may close these issues.

New lint: NOP pointer arithmetic
7 participants