Debian Codegraph @

debian/rust-vendor/ctor/examples/ctor-basic.rs

raw
1 //! Matches the `ctor` README introduction (`cargo run --example ctor-basic`).
2 use ctor::ctor;
3 use libc_print::*;
4
5 #[ctor(unsafe)]
6 fn foo() {
7 libc_println!("Life before main!");
8 }
9
10 fn main() {
11 libc_println!("main");
12 }