Crate aoc_star_derive

Crate aoc_star_derive 

Source
Expand description

§aoc-star-derive

Procedural macro to define Advent of Code solution functions. This crate should never be used directly, but rather through the aoc-star crate.

The star macro allows you to annotate functions as solutions for specific days and parts of Advent of Code challenges.

§Example

use aoc_star_derive::star;

#[star(day = 1, part = 1, year = 2024)]
fn solve_day1_part1(input: String) -> String {
  // solution code here
  "solution".to_string()
  }

Attribute Macros§

star
Attribute macro to mark a function as an Advent of Code solution