summaryrefslogtreecommitdiffstats
path: root/src/tools/clippy/tests/ui/author/blocks.rs
blob: 164f7d0d9d6c521cb4c8c17c8f53e479854ae1d4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
//@edition:2018

#![allow(redundant_semicolons, clippy::no_effect)]
#![feature(stmt_expr_attributes)]
#![feature(async_closure)]

#[rustfmt::skip]
fn main() {
    #[clippy::author]
    {
        let x = 42i32;
        let _t = 1f32;

        -x;
    };
    #[clippy::author]
    {
        let expr = String::new();
        drop(expr)
    };

    #[clippy::author]
    async move || {};
}