-
-
Save bluss/2e47edf1b062b8cdc019 to your computer and use it in GitHub Desktop.
perf stat -r5 rustc -Z time-passes --crate-type=lib manyenums.rs >/dev/null
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#![allow(dead_code, non_snake_case)] | |
macro_rules! enum10 { | |
($($m:ident)*) => { | |
$( | |
pub mod $m { | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo1 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo2 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo3 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo4 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo5 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo7 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo8 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo9 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
#[derive(Copy, Clone, PartialEq)] | |
pub enum Foo10 { | |
A = 0, B, C, D, E, F, G, H, I | |
} | |
} | |
)* | |
}; | |
} | |
enum10!{A B C D E F G H I J K L M N} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment