{"push_id":703445635,"size":2,"distinct_size":0,"ref":"refs/heads/auto","head":"cffaf0e7a82e7b95bf76f37ad074451409a995e9","before":"a8dbd71fc8dcf106eaedca6e52f55b0dcc82b7c1","commits":[{"sha":"a006a82724d1efec712f0f0d337aeeaf3f14258c","author":{"email":"56bdb3ed5af1cf49e9e476a65cd1d245e9a9c96c@gmail.com","name":"Gulshan Singh"},"message":"Suggest missing trait bounds when a method exists but the bounds aren't satisfied","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/a006a82724d1efec712f0f0d337aeeaf3f14258c"},{"sha":"cffaf0e7a82e7b95bf76f37ad074451409a995e9","author":{"email":"3a2c29237f73c7cf88424b80e427b1884f346b35@rust-lang.org","name":"bors"},"message":"Auto merge of #26435 - gsingh93:master, r=nikomatsakis\n\nWhen a method exists in an impl but can not be used due to missing trait bounds for the type parameters, we should inform the user which trait bounds are missing.\r\n\r\nFor example, this code\r\n```\r\n// Note this is missing a Debug impl\r\nstruct Foo;\r\n\r\nfn main() {\r\n    let a: Result<(), Foo> = Ok(());\r\n    a.unwrap()\r\n}\r\n```\r\nNow gives the following error:\r\n```\r\n/home/gulshan/tmp/tmp.rs:6:7: 6:15 error: no method named `unwrap` found for type `core::result::Result<(), Foo>` in the current scope\r\n/home/gulshan/tmp/tmp.rs:6     a.unwrap()\r\n                                 ^~~~~~~~\r\n/home/gulshan/tmp/tmp.rs:6:7: 6:15 note: The method `unwrap` exists but the following trait bounds were not satisfied: `Foo : core::fmt::Debug`\r\nerror: aborting due to previous error\r\n```\r\n\r\nFixes https://github.com/rust-lang/rust/issues/20941.","distinct":false,"url":"https://api.github.com/repos/rust-lang/rust/commits/cffaf0e7a82e7b95bf76f37ad074451409a995e9"}]}