Skip to content

Commit 9de93cd

Browse files
authored
test: update to proc_macro::tracked::path (#16380)
Changed accordingly to rust-lang/rust#149400 This also fix a clippy warning from `clippy::assertions_on_constants`.
2 parents 983e027 + f77d571 commit 9de93cd

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
#[test]
22
fn test() {
3-
assert!(cfg!(did_run_build_script));
3+
const { assert!(cfg!(did_run_build_script)) };
44
}

tests/testsuite/dep_info.rs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -588,7 +588,7 @@ fn no_trailing_separator_after_package_root_build_script() {
588588
);
589589
}
590590

591-
#[cargo_test(nightly, reason = "proc_macro::tracked_path is unstable")]
591+
#[cargo_test(nightly, reason = "proc_macro::tracked::path is unstable")]
592592
fn no_trailing_separator_after_package_root_proc_macro() {
593593
let p = project()
594594
.file(
@@ -626,13 +626,13 @@ fn no_trailing_separator_after_package_root_proc_macro() {
626626
.file(
627627
"pm/src/lib.rs",
628628
r#"
629-
#![feature(track_path)]
629+
#![feature(proc_macro_tracked_path)]
630630
extern crate proc_macro;
631631
use proc_macro::TokenStream;
632632
633633
#[proc_macro]
634634
pub fn noop(_item: TokenStream) -> TokenStream {
635-
proc_macro::tracked_path::path(
635+
proc_macro::tracked::path(
636636
std::env::current_dir().unwrap().to_str().unwrap()
637637
);
638638
"".parse().unwrap()

0 commit comments

Comments
 (0)