Auto merge of #25632 - alexcrichton:dt-dir, r=brson
Auto merge of #25632 - alexcrichton:dt-dir, r=brson

This "fast path" in `DirEntry::file_type` on Unix wasn't turning out to be so
much of a fast path as the `DT_DIR` case wasn't handled, so directories fell
back to using `lstat` instead. This commit adds the missing case to return
quickly if a path is a directory and `DirEntry::file_type` is used.

gifnksm/rust,omasanori/rust,jroesch/rust,robertg/rust,krzysz00/rust,andars/rust,andars/rust,mihneadb/rust,aepsil0n/rust,aepsil0n/rust,KokaKiwi/rust,krzysz00/rust,kwantam/rust,aepsil0n/rust,seanrivera/rust,mvdnes/rust,robertg/rust,l0kod/rust,zubron/rust,l0kod/rust,l0kod/rust,XMPPwocky/rust,zubron/rust,TheNeikos/rust,seanrivera/rust,KokaKiwi/rust,nwin/rust,robertg/rust,sae-bom/rust,aepsil0n/rust,zachwick/rust,GBGamer/rust,aidancully/rust,dwillmer/rust,seanrivera/rust,aidancully/rust,philyoon/rust,pelmers/rust,ejjeong/rust,TheNeikos/rust,pshc/rust,pelmers/rust,TheNeikos/rust,dwillmer/rust,reem/rust,graydon/rust,jashank/rust,pshc/rust,zachwick/rust,zachwick/rust,krzysz00/rust,pelmers/rust,jroesch/rust,KokaKiwi/rust,zubron/rust,graydon/rust,andars/rust,XMPPwocky/rust,vhbit/rust,kwantam/rust,jroesch/rust,omasanori/rust,mvdnes/rust,GBGamer/rust,philyoon/rust,zachwick/rust,reem/rust,sae-bom/rust,andars/rust,zubron/rust,philyoon/rust,sae-bom/rust,XMPPwocky/rust,vhbit/rust,l0kod/rust,dwillmer/rust,vhbit/rust,jroesch/rust,aidancully/rust,vhbit/rust,andars/rust,dwillmer/rust,aneeshusa/rust,jroesch/rust,aneeshusa/rust,robertg/rust,sae-bom/rust,philyoon/rust,vhbit/rust,GBGamer/rust,zubron/rust,nwin/rust,mvdnes/rust,GBGamer/rust,aneeshusa/rust,nwin/rust,jashank/rust,omasanori/rust,ejjeong/rust,pshc/rust,mvdnes/rust,jashank/rust,kwantam/rust,ejjeong/rust,omasanori/rust,kwantam/rust,krzysz00/rust,sae-bom/rust,XMPPwocky/rust,aidancully/rust,jashank/rust,aneeshusa/rust,gifnksm/rust,l0kod/rust,TheNeikos/rust,pelmers/rust,pshc/rust,philyoon/rust,robertg/rust,jroesch/rust,reem/rust,vhbit/rust,jroesch/rust,graydon/rust,KokaKiwi/rust,zubron/rust,mvdnes/rust,TheNeikos/rust,graydon/rust,gifnksm/rust,reem/rust,vhbit/rust,mihneadb/rust,aneeshusa/rust,ejjeong/rust,GBGamer/rust,philyoon/rust,jashank/rust,l0kod/rust,mihneadb/rust,nwin/rust,gifnksm/rust,zubron/rust,l0kod/rust,aneeshusa/rust,mihneadb/rust,seanrivera/rust,aidancully/rust,pshc/rust,mihneadb/rust,l0kod/rust,pshc/rust,GBGamer/rust,ejjeong/rust,dwillmer/rust,nwin/rust,GBGamer/rust,seanrivera/rust,robertg/rust,krzysz00/rust,TheNeikos/rust,aepsil0n/rust,KokaKiwi/rust,aidancully/rust,gifnksm/rust,GBGamer/rust,mvdnes/rust,aepsil0n/rust,graydon/rust,omasanori/rust,ejjeong/rust,reem/rust,XMPPwocky/rust,reem/rust,dwillmer/rust,jashank/rust,pshc/rust,zachwick/rust,dwillmer/rust,pelmers/rust,graydon/rust,krzysz00/rust,KokaKiwi/rust,nwin/rust,jashank/rust,dwillmer/rust,pelmers/rust,nwin/rust,zachwick/rust,kwantam/rust,gifnksm/rust,andars/rust,kwantam/rust,nwin/rust,jroesch/rust,pshc/rust,mihneadb/rust,sae-bom/rust,omasanori/rust,jashank/rust,vhbit/rust,XMPPwocky/rust,seanrivera/rust,zubron/rust