]> git.lizzy.rs Git - rust.git/blobdiff - src/librustc_typeck/check/method/suggest.rs
Split TyBareFn into TyFnDef and TyFnPtr.
[rust.git] / src / librustc_typeck / check / method / suggest.rs
index e7d84efdaa2f7a50f1051ff08aaf1dd286699051..e63366966636a7d7a493ce21805b6653189f8ab6 100644 (file)
@@ -101,7 +101,7 @@ macro_rules! span_did_you_mean {
                     match field_ty.sty {
                         // Not all of these (e.g. unsafe fns) implement FnOnce
                         // so we look for these beforehand
-                        ty::TyClosure(..) | ty::TyBareFn(..) => {
+                        ty::TyClosure(..) | ty::TyFnDef(..) | ty::TyFnPtr(_) => {
                             span_stored_function!();
                         }
                         // If it's not a simple function, look for things which implement FnOnce