Logo
Explore Help
Register Sign In
rust-lang/rust
1
0
Fork 0
You've already forked rust
Code Issues Pull Requests Actions 1 Packages Projects Releases Wiki Activity
Files
ba6fe58095f98f070d161ffdc6c59b51b59d41db
rust/tests/ui/pattern/pattern-ident-path-generics.rs

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

7 lines
123 B
Rust
Raw Normal View History

libsyntax: Don't strip types and lifetimes from single-segment paths in patterns. This breaks code like: fn main() { match Some("foo") { None::<int> => {} Some(_) => {} } } Change this code to not contain a type error. For example: fn main() { match Some("foo") { None::<&str> => {} Some(_) => {} } } Closes #16353. [breaking-change]
2014-08-12 10:33:16 -07:00
fn main() {
match Some("foo") {
Update compile fail tests to use isize.
2015-01-08 21:54:35 +11:00
None::<isize> => {} //~ ERROR mismatched types
libsyntax: Don't strip types and lifetimes from single-segment paths in patterns. This breaks code like: fn main() { match Some("foo") { None::<int> => {} Some(_) => {} } } Change this code to not contain a type error. For example: fn main() { match Some("foo") { None::<&str> => {} Some(_) => {} } } Closes #16353. [breaking-change]
2014-08-12 10:33:16 -07:00
Some(_) => {}
}
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 5015ms Template: 2ms
English
Bahasa Indonesia Deutsch English Español Français Gaeilge Italiano Latviešu Magyar nyelv Nederlands Polski Português de Portugal Português do Brasil Suomi Svenska Türkçe Čeština Ελληνικά Български Русский Українська فارسی മലയാളം 日本語 简体中文 繁體中文(台灣) 繁體中文(香港) 한국어
Licenses API