5 unstable releases

0.3.2 Aug 5, 2024
0.3.1 Sep 5, 2023
0.3.0 Sep 5, 2023
0.2.0 Sep 5, 2023
0.1.0 Jun 20, 2023

#545 in Rust patterns

Download history 38/week @ 2024-07-15 42/week @ 2024-07-22 36/week @ 2024-07-29 137/week @ 2024-08-05 4/week @ 2024-08-12 21/week @ 2024-08-19 14/week @ 2024-08-26 9/week @ 2024-09-02 23/week @ 2024-09-09 65/week @ 2024-09-16 19/week @ 2024-09-23 22/week @ 2024-09-30 28/week @ 2024-10-07 14/week @ 2024-10-14 11/week @ 2024-10-21 27/week @ 2024-10-28

80 downloads per month
Used in 2 crates

MIT license

5KB
117 lines

code-path

License Crates.io Docs.rs

A code path macro

Usage


fn foo() {
    fn bar() {
        assert_eq!(
            code_path::code_path!(),
            "rust_out::main::_doctest_main_src_lib_rs_10_0::foo::bar, src/lib.rs:9:13".into(),
        );
    }
    bar()
}
foo()

Contributing

  • please run [.pre-commit.sh] before sending a PR, it will check everything

License

This project is licensed under the MIT license.

No runtime deps