diff options
| author | Andy Russell <arussell123@gmail.com> | 2018-12-20 18:10:46 -0500 |
|---|---|---|
| committer | Andy Russell <arussell123@gmail.com> | 2018-12-31 12:52:30 -0500 |
| commit | dfc326d0e212bd644d04906ca21bb012cf970cb4 (patch) | |
| tree | 6e8e22597c6731a24a95d0201e6654b44000802f /src/test/ui/structs/struct-fields-typo.rs | |
| parent | 79d8a0fcefa5134db2a94739b1d18daa01fc6e9f (diff) | |
| download | rust-dfc326d0e212bd644d04906ca21bb012cf970cb4.tar.gz rust-dfc326d0e212bd644d04906ca21bb012cf970cb4.zip | |
use structured suggestions for nonexistent fields
Diffstat (limited to 'src/test/ui/structs/struct-fields-typo.rs')
| -rw-r--r-- | src/test/ui/structs/struct-fields-typo.rs | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/test/ui/structs/struct-fields-typo.rs b/src/test/ui/structs/struct-fields-typo.rs index b435a0a4777..0e9b2ae5145 100644 --- a/src/test/ui/structs/struct-fields-typo.rs +++ b/src/test/ui/structs/struct-fields-typo.rs @@ -8,7 +8,8 @@ fn main() { foo: 0, bar: 0.5, }; - let x = foo.baa;//~ no field `baa` on type `BuildData` - //~^ did you mean `bar`? + let x = foo.baa; //~ ERROR no field `baa` on type `BuildData` + //~| HELP a field with a similar name exists + //~| SUGGESTION bar println!("{}", x); } |
