Add testcases for item name conflict at the same path level.
This commit is contained in:
parent
241305caab
commit
85a701c8f6
@ -374,6 +374,7 @@ TEST_XFAILS_LLVM := $(addprefix test/run-pass/, \
|
|||||||
i8-incr.rs \
|
i8-incr.rs \
|
||||||
import.rs \
|
import.rs \
|
||||||
inner-module.rs \
|
inner-module.rs \
|
||||||
|
item-name-overload.rs \
|
||||||
large-records.rs \
|
large-records.rs \
|
||||||
lazy-and-or.rs \
|
lazy-and-or.rs \
|
||||||
lazychan.rs \
|
lazychan.rs \
|
||||||
|
8
src/test/compile-fail/item-name-overload.rs
Normal file
8
src/test/compile-fail/item-name-overload.rs
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
// -*- rust -*-
|
||||||
|
|
||||||
|
mod foo {
|
||||||
|
fn bar[T](T f) -> int { ret 17; }
|
||||||
|
type bar[U, T] = tup(int, U, T);
|
||||||
|
}
|
||||||
|
|
||||||
|
fn main() {}
|
11
src/test/run-pass/item-name-overload.rs
Normal file
11
src/test/run-pass/item-name-overload.rs
Normal file
@ -0,0 +1,11 @@
|
|||||||
|
// -*- rust -*-
|
||||||
|
|
||||||
|
mod foo {
|
||||||
|
fn baz() {}
|
||||||
|
}
|
||||||
|
|
||||||
|
mod bar {
|
||||||
|
fn baz() {}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn main() {}
|
Loading…
Reference in New Issue
Block a user