Skip to content

Commit be70b13

Browse files
committed
Merged tests/ui/privacy/private-item-simple-2.rs with
tests/ui/privacy/private-item-simple.rs
1 parent 9c52ff9 commit be70b13

File tree

4 files changed

+21
-28
lines changed

4 files changed

+21
-28
lines changed

tests/ui/privacy/private-item-simple-2.rs

Lines changed: 0 additions & 10 deletions
This file was deleted.

tests/ui/privacy/private-item-simple-2.stderr

Lines changed: 0 additions & 15 deletions
This file was deleted.
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,13 @@
1+
//! regression test for issue #3993
2+
13
mod a {
24
fn f() {}
35
}
46

57
fn main() {
68
a::f(); //~ ERROR function `f` is private
79
}
10+
11+
fn foo() {
12+
use a::f; //~ ERROR function `f` is private
13+
}
Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,27 @@
11
error[E0603]: function `f` is private
2-
--> $DIR/private-item-simple.rs:6:8
2+
--> $DIR/private-item-simple.rs:12:12
3+
|
4+
LL | use a::f;
5+
| ^ private function
6+
|
7+
note: the function `f` is defined here
8+
--> $DIR/private-item-simple.rs:4:5
9+
|
10+
LL | fn f() {}
11+
| ^^^^^^
12+
13+
error[E0603]: function `f` is private
14+
--> $DIR/private-item-simple.rs:8:8
315
|
416
LL | a::f();
517
| ^ private function
618
|
719
note: the function `f` is defined here
8-
--> $DIR/private-item-simple.rs:2:5
20+
--> $DIR/private-item-simple.rs:4:5
921
|
1022
LL | fn f() {}
1123
| ^^^^^^
1224

13-
error: aborting due to 1 previous error
25+
error: aborting due to 2 previous errors
1426

1527
For more information about this error, try `rustc --explain E0603`.

0 commit comments

Comments
 (0)