mirror of
https://github.com/ahgamut/rust-ape-example.git
synced 2024-05-28 16:28:08 +00:00
d976dc883b
via panflute and https://github.com/rust-lang/rust-by-example
17 lines
194 B
Rust
17 lines
194 B
Rust
// ./src/attribute/cfg/custom.md
|
|
|
|
|
|
#[cfg(some_condition)]
|
|
fn conditional_function() {
|
|
println!("condition met!");
|
|
}
|
|
|
|
fn part0() {
|
|
conditional_function();
|
|
}
|
|
|
|
pub fn main() {
|
|
part0();
|
|
}
|
|
|