Allow dead code, use a macro for importing days

wip
Alpha Chen 9 years ago
parent 2c049bd499
commit f1eea338c3

@ -23,6 +23,7 @@ struct Present {
height: u32, height: u32,
} }
#[allow(dead_code)]
impl Present { impl Present {
fn new(input: &str) -> Self { fn new(input: &str) -> Self {
let dimensions = input.split("x") let dimensions = input.split("x")

@ -1,7 +1,12 @@
pub use day::Day; macro_rules! import_day {
mod day; ( $( $d:ident ),* ) => {
$(
pub use $d::*;
mod $d;
)*
}
}
pub use day_01::Day01; import_day!(day,
pub use day_02::Day02; day_01,
mod day_01; day_02);
mod day_02;

Loading…
Cancel
Save