| Crates.io | aoc-star-derive |
| lib.rs | aoc-star-derive |
| version | 0.1.1 |
| created_at | 2025-12-15 21:58:20.946491+00 |
| updated_at | 2025-12-16 17:43:32.153481+00 |
| description | Macro to flag functions as Advent of Code solutions |
| homepage | https://github.com/Yag000/aoc-star/tree/main/aoc-star-derive |
| repository | https://github.com/Yag000/aoc-star/tree/main/aoc-star-derive |
| max_upload_size | |
| id | 1986825 |
| size | 26,506 |
Procedural macro crate for aoc-star.
You normally don't use this crate directly. Instead, depend on aoc-star, and
import the star attribute from there:
use aoc_star::star;
#[star(day = 1, part = 1, year = 2024)]
fn solve_day1_part1(input: String) -> String {
// ...
"answer".to_string()
}
The star attribute:
day, part, and optional year.String argument (the puzzle input) and return a String (the answer).inventory crate to make the
solution discoverable at runtime.