Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.
Sign upLint against lowercase static mut #37162
Conversation
rust-highfive
assigned
arielb1
Oct 14, 2016
This comment has been minimized.
This comment has been minimized.
|
r? @arielb1 (rust_highfive has picked a reviewer for you, use r? to override) |
matklad
force-pushed the
matklad:static-mut-lint
branch
from
99fb4fe
to
bfe267a
Oct 14, 2016
matklad
force-pushed the
matklad:static-mut-lint
branch
2 times, most recently
from
5147918
to
6f216f6
Oct 14, 2016
matklad
force-pushed the
matklad:static-mut-lint
branch
from
6f216f6
to
72399f2
Oct 14, 2016
jseyfried
reviewed
Oct 15, 2016
|
Thanks! r=me with the comment addressed. |
src/librustc_lint/bad_style.rs
Outdated
| hir::ItemStatic(_, hir::MutImmutable, _) => { | ||
| NonUpperCaseGlobals::check_upper_case(cx, "static constant", it.name, it.span); | ||
| } | ||
| hir::ItemStatic(_, hir::MutMutable, _) => { | ||
| NonUpperCaseGlobals::check_upper_case(cx, "static variable", it.name, it.span); | ||
| } |
This comment has been minimized.
This comment has been minimized.
jseyfried
Oct 15, 2016
•
Contributor
I think the above two arms could be merged into a single arm:
hir::ItemStatic(..) => {
NonUpperCaseGlobals::check_upper_case(cx, "static variable", it.name, it.span);
}
This comment has been minimized.
This comment has been minimized.
|
@bors r+ |
This comment has been minimized.
This comment has been minimized.
|
|
This comment has been minimized.
This comment has been minimized.
|
|
bors
added a commit
that referenced
this pull request
Oct 17, 2016
This comment has been minimized.
This comment has been minimized.
|
This may produce new warnings. Should the relnotes label be applied? |
This comment has been minimized.
This comment has been minimized.
|
Yeah, let's tag |
alexcrichton
added
the
relnotes
label
Oct 17, 2016
bors
referenced this pull request
Oct 17, 2016
Merged
Fix ICE: inject bitcast if types mismatch for invokes/calls/stores #37112
This comment has been minimized.
This comment has been minimized.
bors
merged commit 066d62d
into
rust-lang:master
Oct 17, 2016
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
matklad commentedOct 14, 2016
Closes #37145.
Lint for non mut statics was added in #7523, and it explicitly did not cover mut statics. I am not sure why.