about summary refs log tree commit diff
path: root/src/rustllvm/RustWrapper.cpp
diff options
context:
space:
mode:
authorkennytm <kennytm@gmail.com>2018-06-08 07:05:39 +0800
committerGitHub <noreply@github.com>2018-06-08 07:05:39 +0800
commit26a9d589c8fa46061912497de638f3f523087097 (patch)
tree57bc9392a285c70b1f92d22cacc0617eff554515 /src/rustllvm/RustWrapper.cpp
parent0bc15ed7c0878f9f314bdd1e02175574637602a5 (diff)
parentc9cb806689a9691e2a29836e2c597751cdbcfdc8 (diff)
downloadrust-26a9d589c8fa46061912497de638f3f523087097.tar.gz
rust-26a9d589c8fa46061912497de638f3f523087097.zip
Rollup merge of #51283 - kennytm:fix-51279-preempt-the-warning-song-and-dance, r=nikomatsakis
Deny #[cfg] and #[cfg_attr] on generic parameters.

Fix #51279.

Attributes on generic parameters are not expanded, meaning `#[cfg]`, `#[cfg_attr]` and attribute proc macros are entirely ignored on them.

This PR makes using the first two attributes an error, because if they are correctly expanded will affect the AST and change code behavior.

I'm beta-nominating this, because generic parameter attributes are stabilizing in 1.27, and if we did not reserve their usage, we may never be able to repurpose the meaning of these attributes in the Rust 2015 edition.
Diffstat (limited to 'src/rustllvm/RustWrapper.cpp')
0 files changed, 0 insertions, 0 deletions