Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion include_dir/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,6 @@ pub use crate::metadata::Metadata;
pub use crate::{dir::Dir, dir_entry::DirEntry, file::File};
pub use include_dir_macros::include_dir;

#[doc = include_str!("../README.md")]
#[doc = include_str!("../../README.md")]
#[allow(dead_code)]
fn check_readme_examples() {}
6 changes: 3 additions & 3 deletions macros/src/lib.rs
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
//! Implementation details of the `include_dir`.
//!
//! You probably don't want to use this crate directly.
#![cfg_attr(feature = "nightly", feature(track_path, proc_macro_tracked_env))]
#![cfg_attr(feature = "nightly", feature(proc_macro_tracked_path, proc_macro_tracked_env))]

use proc_macro::{TokenStream, TokenTree};
use proc_macro2::Literal;
Expand Down Expand Up @@ -252,7 +252,7 @@ fn take_while(s: &str, mut predicate: impl FnMut(char) -> bool) -> (&str, &str)

#[cfg(feature = "nightly")]
fn get_env(variable: &str) -> Option<String> {
proc_macro::tracked_env::var(variable).ok()
proc_macro::tracked::env_var(variable).ok()
}

#[cfg(not(feature = "nightly"))]
Expand All @@ -262,7 +262,7 @@ fn get_env(variable: &str) -> Option<String> {

fn track_path(_path: &Path) {
#[cfg(feature = "nightly")]
proc_macro::tracked_path::path(_path.to_string_lossy());
proc_macro::tracked::path(_path);
}

#[cfg(test)]
Expand Down