@@ -48,6 +48,14 @@ macro_rules! assert_data_eq {
4848}
4949
5050/// Find the directory for your source file
51+ ///
52+ /// By default, a heuristic is used.
53+ ///
54+ /// To override the heuristic, add to `$WORKSPACE_ROOT/.cargo/config.toml`:
55+ /// ```toml
56+ /// [env]
57+ /// CARGO_RUSTC_CURRENT_DIR = { value = "", relative = true }
58+ /// ```
5159#[ doc( hidden) ] // forced to be visible in intended location
5260#[ macro_export]
5361macro_rules! current_dir {
@@ -60,6 +68,14 @@ macro_rules! current_dir {
6068}
6169
6270/// Find the directory for your source file
71+ ///
72+ /// By default, a heuristic is used.
73+ ///
74+ /// To override the heuristic, add to `$WORKSPACE_ROOT/.cargo/config.toml`:
75+ /// ```toml
76+ /// [env]
77+ /// CARGO_RUSTC_CURRENT_DIR = { value = "", relative = true }
78+ /// ```
6379#[ doc( hidden) ] // forced to be visible in intended location
6480#[ macro_export]
6581macro_rules! current_rs {
@@ -72,6 +88,14 @@ macro_rules! current_rs {
7288}
7389
7490/// Find the base directory for [`std::file!`]
91+ ///
92+ /// By default, a heuristic is used.
93+ ///
94+ /// To override the heuristic, add to `$WORKSPACE_ROOT/.cargo/config.toml`:
95+ /// ```toml
96+ /// [env]
97+ /// CARGO_RUSTC_CURRENT_DIR = { value = "", relative = true }
98+ /// ```
7599#[ doc( hidden) ] // forced to be visible in intended location
76100#[ macro_export]
77101macro_rules! cargo_rustc_current_dir {
0 commit comments