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
2fcea9fb68c8e04f10e5cb15bbfb486de9800afa
rust/tests/ui/traits/bound/on-structs-and-enums-static.rs

17 lines
184 B
Rust
Raw Normal View History

Fallout: tests. As tests frequently elide things, lots of changes here. Some of this may have been poorly rebased, though I tried to be careful and preserve the spirit of the test.
2015-02-12 10:29:52 -05:00
trait Trait {
fn dummy(&self) { }
}
librustc: Allow trait bounds on structures and enumerations, and check them during kind checking. This implements RFC #11. Closes #15759.
2014-08-11 17:12:01 -07:00
struct Foo<T:Trait> {
x: T,
}
Update compile fail tests to use usize.
2015-01-08 22:02:42 +11:00
static X: Foo<usize> = Foo {
suggest adding a where-clause when that can help suggest adding a where-clause when there is an unmet trait-bound that can be satisfied if some type can implement it.
2016-03-29 20:12:31 +03:00
//~^ ERROR E0277
Check that return type is WF in typeck Without it non-WF types could pass typeck and then later fail in MIR/const eval
2024-03-06 16:51:17 +05:30
//~| ERROR E0277
Work around the fact that `check_mod_type_wf` may spuriously return `ErrorGuaranteed`, even if that error is only emitted by `check_modwitem_types`
2023-10-25 10:49:24 +00:00
x: 1, //~ ERROR: E0277
librustc: Allow trait bounds on structures and enumerations, and check them during kind checking. This implements RFC #11. Closes #15759.
2014-08-11 17:12:01 -07:00
};
fn main() {
}
Reference in New Issue Copy Permalink
Powered by Gitea Version: 1.24.6 Page: 6285ms 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