Skip to content

Commit dac88fa

Browse files
committed
Remove transitional path2 attribute
1 parent 78dc226 commit dac88fa

File tree

3 files changed

+12
-18
lines changed

3 files changed

+12
-18
lines changed

src/librustc/rustc.rc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -104,7 +104,7 @@ mod middle {
104104
mod ty;
105105
#[legacy_exports]
106106
mod resolve;
107-
#[path2 = "typeck/mod.rs"]
107+
#[path = "typeck/mod.rs"]
108108
pub mod typeck;
109109
#[legacy_exports]
110110
mod check_loop;
@@ -114,7 +114,7 @@ mod middle {
114114
mod check_const;
115115
#[legacy_exports]
116116
mod lint;
117-
#[path2 = "borrowck/mod.rs"]
117+
#[path = "borrowck/mod.rs"]
118118
pub mod borrowck;
119119
#[legacy_exports]
120120
mod mem_categorization;

src/libsyntax/parse/parser.rs

Lines changed: 8 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -3038,23 +3038,17 @@ impl Parser {
30383038
let prefix = prefix.dir_path();
30393039
let mod_path = Path(".").push_many(self.mod_path_stack);
30403040
let default_path = self.sess.interner.get(id) + ~".rs";
3041-
// XXX path2 and path are synonyms. Remove path2 after snapshot
30423041
let file_path = match ::attr::first_attr_value_str_by_name(
3043-
outer_attrs, ~"path2") {
3044-
3045-
Some(ref d) => mod_path.push(*d),
3046-
None => match ::attr::first_attr_value_str_by_name(
3047-
outer_attrs, ~"path") {
3048-
Some(ref d) => {
3049-
let path = Path(*d);
3050-
if !path.is_absolute {
3051-
mod_path.push(*d)
3052-
} else {
3053-
path
3054-
}
3042+
outer_attrs, ~"path") {
3043+
Some(ref d) => {
3044+
let path = Path(*d);
3045+
if !path.is_absolute {
3046+
mod_path.push(*d)
3047+
} else {
3048+
path
30553049
}
3056-
None => mod_path.push(default_path)
30573050
}
3051+
None => mod_path.push(default_path)
30583052
};
30593053
30603054
self.eval_src_mod_from_path(prefix, file_path,

src/libsyntax/syntax.rc

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ mod fold;
5555
mod util {
5656
#[legacy_exports];
5757
#[legacy_exports]
58-
#[path2 = "interner.rs"]
58+
#[path = "interner.rs"]
5959
mod interner;
6060
}
6161

@@ -110,7 +110,7 @@ mod ext {
110110
mod source_util;
111111

112112
#[legacy_exports]
113-
#[path2 = "pipes/mod.rs"]
113+
#[path = "pipes/mod.rs"]
114114
mod pipes;
115115

116116
#[legacy_exports]

0 commit comments

Comments
 (0)