We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3bc767e commit a612e73Copy full SHA for a612e73
tests/ui/lexical-scoping.rs renamed to tests/ui/resolve/type-param-local-var-shadowing.rs
@@ -1,8 +1,13 @@
1
+//! Test that items in subscopes correctly shadow type parameters and local variables
2
+//!
3
+//! Regression test for https://github.com/rust-lang/rust/issues/23880
4
+
5
//@ run-pass
-// Tests that items in subscopes can shadow type parameters and local variables (see issue #23880).
6
7
#![allow(unused)]
-struct Foo<X> { x: Box<X> }
8
+struct Foo<X> {
9
+ x: Box<X>,
10
+}
11
impl<Bar> Foo<Bar> {
12
fn foo(&self) {
13
type Bar = i32;
0 commit comments