prebindgen_out_dir

Macro prebindgen_out_dir 

Source
prebindgen_out_dir!() { /* proc-macro */ }
Expand description

Proc macro that returns the prebindgen output directory path as a string literal.

This macro generates a string literal containing the full path to the prebindgen output directory. It should be used to create a public constant that can be consumed by language-specific binding crates.

§Panics

Panics if OUT_DIR environment variable is not set. This indicates that the macro is being used outside of a build.rs context.

§Returns

A string literal with the path to the prebindgen output directory.

§Example

use prebindgen_proc_macro::prebindgen_out_dir;

// Create a public constant for use by binding crates
pub const PREBINDGEN_OUT_DIR: &str = prebindgen_out_dir!();