]> git.lizzy.rs Git - rust.git/commit
Merge #6421
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>
Tue, 3 Nov 2020 07:36:49 +0000 (07:36 +0000)
committerGitHub <noreply@github.com>
Tue, 3 Nov 2020 07:36:49 +0000 (07:36 +0000)
commit65b44d2ba5145c354f03423222992e212a8e93e0
tree2aaaf2f4e3fb8b58f61be04ece95e00cc8fda922
parent245e1b533b5be5ea4a917957fb02d7f57e6b4661
parentdd2febf05a4ceca23679bb664848cc15fce2f0e9
Merge #6421

6421: Check for allow(..) attributes in case check diagnostic r=popzxc a=popzxc

Resolves #6348

This is not a full-fledged solution, as it doesn't looks up for parent elements (e.g. function -> module -> parent module -> crate root), but it does at least checks attributes of item being checked.
I played a bit with code, and it seems that implementing a proper solution (which will also check for `deny` / `warn` attributes overriding values for `allow`s from above).

So, this solution should fix all the macros which intentionally do "weird" naming and wrap it with `allow`, such as `lazy_static`.

cc @ArifRoktim

Co-authored-by: Igor Aleksanov <popzxc@yandex.ru>