Implement new Foldable methods for HsPatSynDetails
Implement new Foldable methods for HsPatSynDetails

Summary: Also explicitly define foldl1 and foldr1, which should generally work better with list-specific versions.

Reviewers: austin

Reviewed By: austin

Subscribers: rwbarton, thomie, carter

Differential Revision: https://phabricator.haskell.org/D430

ghc-android/ghc,urbanslug/ghc,TomMD/ghc,green-haskell/ghc,ghc-android/ghc,nkaretnikov/ghc,mcschroeder/ghc,mettekou/ghc,sdiehl/ghc,fmthoma/ghc,sgillespie/ghc,nathyong/microghc-ghc,bitemyapp/ghc,nkaretnikov/ghc,anton-dessiatov/ghc,snoyberg/ghc,ghc-android/ghc,anton-dessiatov/ghc,wxwxwwxxx/ghc,vikraman/ghc,shlevy/ghc,ghc-android/ghc,gridaphobe/ghc,christiaanb/ghc,vTurbine/ghc,snoyberg/ghc,ezyang/ghc,elieux/ghc,mettekou/ghc,GaloisInc/halvm-ghc,da-x/ghc,fmthoma/ghc,forked-upstream-packages-for-ghcjs/ghc,nushio3/ghc,GaloisInc/halvm-ghc,wxwxwwxxx/ghc,gridaphobe/ghc,GaloisInc/halvm-ghc,gcampax/ghc,ghc-android/ghc,olsner/ghc,sgillespie/ghc,TomMD/ghc,da-x/ghc,elieux/ghc,AlexanderPankiv/ghc,nathyong/microghc-ghc,da-x/ghc,vikraman/ghc,fmthoma/ghc,gridaphobe/ghc,mcschroeder/ghc,urbanslug/ghc,urbanslug/ghc,wxwxwwxxx/ghc,tjakway/ghcjvm,olsner/ghc,sgillespie/ghc,mettekou/ghc,jstolarek/ghc,gcampax/ghc,ml9951/ghc,gcampax/ghc,green-haskell/ghc,ml9951/ghc,mfine/ghc,olsner/ghc,nkaretnikov/ghc,siddhanathan/ghc,gcampax/ghc,mfine/ghc,wxwxwwxxx/ghc,vTurbine/ghc,elieux/ghc,tjakway/ghcjvm,fmthoma/ghc,christiaanb/ghc,nushio3/ghc,vikraman/ghc,nushio3/ghc,mcschroeder/ghc,da-x/ghc,AlexanderPankiv/ghc,bitemyapp/ghc,vikraman/ghc,vTurbine/ghc,nathyong/microghc-ghc,siddhanathan/ghc,anton-dessiatov/ghc,olsner/ghc,sgillespie/ghc,ezyang/ghc,oldmanmike/ghc,ml9951/ghc,sgillespie/ghc,TomMD/ghc,mcschroeder/ghc,gridaphobe/ghc,mfine/ghc,sdiehl/ghc,oldmanmike/ghc,oldmanmike/ghc,shlevy/ghc,AlexanderPankiv/ghc,jstolarek/ghc,christiaanb/ghc,ml9951/ghc,bitemyapp/ghc,olsner/ghc,christiaanb/ghc,shlevy/ghc,AlexanderPankiv/ghc,shlevy/ghc,GaloisInc/halvm-ghc,vikraman/ghc,vTurbine/ghc,ezyang/ghc,ezyang/ghc,TomMD/ghc,gridaphobe/ghc,sgillespie/ghc,mfine/ghc,TomMD/ghc,nkaretnikov/ghc,christiaanb/ghc,wxwxwwxxx/ghc,jstolarek/ghc,gridaphobe/ghc,ghc-android/ghc,nushio3/ghc,jstolarek/ghc,mfine/ghc,sdiehl/ghc,shlevy/ghc,forked-upstream-packages-for-ghcjs/ghc,gcampax/ghc,fmthoma/ghc,tjakway/ghcjvm,oldmanmike/ghc,ezyang/ghc,siddhanathan/ghc,acowley/ghc,urbanslug/ghc,ml9951/ghc,jstolarek/ghc,nathyong/microghc-ghc,ml9951/ghc,vikraman/ghc,da-x/ghc,AlexanderPankiv/ghc,tjakway/ghcjvm,anton-dessiatov/ghc,tjakway/ghcjvm,wxwxwwxxx/ghc,acowley/ghc,ezyang/ghc,AlexanderPankiv/ghc,anton-dessiatov/ghc,urbanslug/ghc,sdiehl/ghc,forked-upstream-packages-for-ghcjs/ghc,nushio3/ghc,GaloisInc/halvm-ghc,christiaanb/ghc,snoyberg/ghc,green-haskell/ghc,ghc-android/ghc,gridaphobe/ghc,tjakway/ghcjvm,elieux/ghc,bitemyapp/ghc,nathyong/microghc-ghc,mettekou/ghc,mettekou/ghc,nkaretnikov/ghc,sgillespie/ghc,ml9951/ghc,GaloisInc/halvm-ghc,vTurbine/ghc,forked-upstream-packages-for-ghcjs/ghc,siddhanathan/ghc,green-haskell/ghc,da-x/ghc,sdiehl/ghc,vTurbine/ghc,christiaanb/ghc,mfine/ghc,mcschroeder/ghc,acowley/ghc,mcschroeder/ghc,nushio3/ghc,siddhanathan/ghc,acowley/ghc,snoyberg/ghc,acowley/ghc,mettekou/ghc,acowley/ghc,gcampax/ghc,nkaretnikov/ghc,vikraman/ghc,nathyong/microghc-ghc,mettekou/ghc,elieux/ghc,GaloisInc/halvm-ghc,forked-upstream-packages-for-ghcjs/ghc,AlexanderPankiv/ghc,green-haskell/ghc,olsner/ghc,fmthoma/ghc,wxwxwwxxx/ghc,mcschroeder/ghc,sdiehl/ghc,siddhanathan/ghc,mfine/ghc,anton-dessiatov/ghc,olsner/ghc,oldmanmike/ghc,nathyong/microghc-ghc,snoyberg/ghc,vTurbine/ghc,ml9951/ghc,acowley/ghc,forked-upstream-packages-for-ghcjs/ghc,ezyang/ghc,oldmanmike/ghc,forked-upstream-packages-for-ghcjs/ghc,TomMD/ghc,shlevy/ghc,nkaretnikov/ghc,oldmanmike/ghc,gcampax/ghc,elieux/ghc,da-x/ghc,bitemyapp/ghc,snoyberg/ghc,shlevy/ghc,elieux/ghc,anton-dessiatov/ghc,snoyberg/ghc,sdiehl/ghc,fmthoma/ghc,urbanslug/ghc,siddhanathan/ghc,urbanslug/ghc,TomMD/ghc,nushio3/ghc,tjakway/ghcjvm