Fix dependencies among specialisations for imported Ids
Fix dependencies among specialisations for imported Ids

This was a subtle one (Trac #4903).  See
  Note [Glom the bindings if imported functions are specialised]
in Speclialise.

Fundamentally, a specialised binding for an imported Id was being
declared non-recursive, whereas in fact it can become recursive
via a RULE.  Once it's specified non-recurive the OccAnal pass
treats that as gospel -- and that in turn led to infinite inlining.

Easily fixed by glomming all the specialised bindings in a Rec;
now the OccAnal will sort them out correctly.

ryantm/ghc,hferreiro/replay,ryantm/ghc,olsner/ghc,da-x/ghc,forked-upstream-packages-for-ghcjs/ghc,elieux/ghc,gridaphobe/ghc,gcampax/ghc,nkaretnikov/ghc,snoyberg/ghc,lukexi/ghc,forked-upstream-packages-for-ghcjs/ghc,nomeata/ghc,ekmett/ghc,nkaretnikov/ghc,GaloisInc/halvm-ghc,gridaphobe/ghc,nkaretnikov/ghc,nomeata/ghc,nushio3/ghc,vTurbine/ghc,mcmaniac/ghc,ezyang/ghc,mcmaniac/ghc,shlevy/ghc,tjakway/ghcjvm,sdiehl/ghc,shlevy/ghc,ghc-android/ghc,lukexi/ghc-7.8-arm64,tjakway/ghcjvm,ezyang/ghc,christiaanb/ghc,ezyang/ghc,oldmanmike/ghc,nkaretnikov/ghc,anton-dessiatov/ghc,siddhanathan/ghc,tibbe/ghc,wxwxwwxxx/ghc,ryantm/ghc,sdiehl/ghc,GaloisInc/halvm-ghc,tibbe/ghc,wxwxwwxxx/ghc,lukexi/ghc-7.8-arm64,nathyong/microghc-ghc,tjakway/ghcjvm,mcschroeder/ghc,spacekitteh/smcghc,nathyong/microghc-ghc,hferreiro/replay,gcampax/ghc,elieux/ghc,hferreiro/replay,anton-dessiatov/ghc,wxwxwwxxx/ghc,vikraman/ghc,nushio3/ghc,lukexi/ghc,TomMD/ghc,gcampax/ghc,siddhanathan/ghc,vTurbine/ghc,jstolarek/ghc,snoyberg/ghc,ghc-android/ghc,gcampax/ghc,elieux/ghc,shlevy/ghc,jstolarek/ghc,siddhanathan/ghc,snoyberg/ghc,lukexi/ghc-7.8-arm64,urbanslug/ghc,fmthoma/ghc,wxwxwwxxx/ghc,acowley/ghc,nathyong/microghc-ghc,mfine/ghc,lukexi/ghc-7.8-arm64,forked-upstream-packages-for-ghcjs/ghc,vikraman/ghc,mfine/ghc,green-haskell/ghc,spacekitteh/smcghc,fmthoma/ghc,forked-upstream-packages-for-ghcjs/ghc,lukexi/ghc,spacekitteh/smcghc,lukexi/ghc-7.8-arm64,lukexi/ghc,oldmanmike/ghc,ml9951/ghc,jstolarek/ghc,forked-upstream-packages-for-ghcjs/ghc,gridaphobe/ghc,AlexanderPankiv/ghc,elieux/ghc,acowley/ghc,mettekou/ghc,nkaretnikov/ghc,ghc-android/ghc,AlexanderPankiv/ghc,ghc-android/ghc,bitemyapp/ghc,tibbe/ghc,mcschroeder/ghc,gridaphobe/ghc,hferreiro/replay,green-haskell/ghc,acowley/ghc,shlevy/ghc,holzensp/ghc,mcschroeder/ghc,urbanslug/ghc,mettekou/ghc,mfine/ghc,frantisekfarka/ghc-dsi,sgillespie/ghc,acowley/ghc,ryantm/ghc,snoyberg/ghc,holzensp/ghc,mettekou/ghc,olsner/ghc,da-x/ghc,ekmett/ghc,GaloisInc/halvm-ghc,ilyasergey/GHC-XAppFix,bitemyapp/ghc,wxwxwwxxx/ghc,holzensp/ghc,gcampax/ghc,nomeata/ghc,vikraman/ghc,nushio3/ghc,sdiehl/ghc,wxwxwwxxx/ghc,nathyong/microghc-ghc,tjakway/ghcjvm,mcschroeder/ghc,gcampax/ghc,forked-upstream-packages-for-ghcjs/ghc,olsner/ghc,snoyberg/ghc,anton-dessiatov/ghc,olsner/ghc,fmthoma/ghc,vikraman/ghc,ezyang/ghc,da-x/ghc,GaloisInc/halvm-ghc,urbanslug/ghc,spacekitteh/smcghc,hferreiro/replay,olsner/ghc,mfine/ghc,ghc-android/ghc,oldmanmike/ghc,sdiehl/ghc,frantisekfarka/ghc-dsi,ekmett/ghc,ghc-android/ghc,nushio3/ghc,frantisekfarka/ghc-dsi,GaloisInc/halvm-ghc,nkaretnikov/ghc,ryantm/ghc,shlevy/ghc,ekmett/ghc,ghc-android/ghc,gridaphobe/ghc,mettekou/ghc,christiaanb/ghc,nushio3/ghc,vTurbine/ghc,sgillespie/ghc,ilyasergey/GHC-XAppFix,GaloisInc/halvm-ghc,tjakway/ghcjvm,ezyang/ghc,acowley/ghc,elieux/ghc,AlexanderPankiv/ghc,gridaphobe/ghc,urbanslug/ghc,tjakway/ghcjvm,olsner/ghc,green-haskell/ghc,bitemyapp/ghc,ml9951/ghc,tjakway/ghcjvm,acowley/ghc,olsner/ghc,gridaphobe/ghc,ilyasergey/GHC-XAppFix,ml9951/ghc,vTurbine/ghc,tibbe/ghc,gcampax/ghc,sgillespie/ghc,mcschroeder/ghc,christiaanb/ghc,TomMD/ghc,GaloisInc/halvm-ghc,da-x/ghc,christiaanb/ghc,sdiehl/ghc,siddhanathan/ghc,elieux/ghc,mfine/ghc,bitemyapp/ghc,urbanslug/ghc,urbanslug/ghc,vikraman/ghc,urbanslug/ghc,hferreiro/replay,ml9951/ghc,tibbe/ghc,oldmanmike/ghc,mcmaniac/ghc,vikraman/ghc,TomMD/ghc,anton-dessiatov/ghc,mcschroeder/ghc,fmthoma/ghc,ml9951/ghc,mcschroeder/ghc,vTurbine/ghc,bitemyapp/ghc,sdiehl/ghc,elieux/ghc,holzensp/ghc,vTurbine/ghc,da-x/ghc,sgillespie/ghc,snoyberg/ghc,TomMD/ghc,mettekou/ghc,spacekitteh/smcghc,nathyong/microghc-ghc,fmthoma/ghc,ekmett/ghc,fmthoma/ghc,TomMD/ghc,nkaretnikov/ghc,vikraman/ghc,ml9951/ghc,oldmanmike/ghc,sgillespie/ghc,holzensp/ghc,nomeata/ghc,nomeata/ghc,lukexi/ghc,wxwxwwxxx/ghc,frantisekfarka/ghc-dsi,sgillespie/ghc,ezyang/ghc,christiaanb/ghc,mettekou/ghc,oldmanmike/ghc,anton-dessiatov/ghc,forked-upstream-packages-for-ghcjs/ghc,nushio3/ghc,AlexanderPankiv/ghc,da-x/ghc,siddhanathan/ghc,shlevy/ghc,christiaanb/ghc,acowley/ghc,vTurbine/ghc,mcmaniac/ghc,green-haskell/ghc,mettekou/ghc,AlexanderPankiv/ghc,fmthoma/ghc,nathyong/microghc-ghc,ilyasergey/GHC-XAppFix,siddhanathan/ghc,AlexanderPankiv/ghc,mfine/ghc,shlevy/ghc,nushio3/ghc,sgillespie/ghc,sdiehl/ghc,ml9951/ghc,snoyberg/ghc,TomMD/ghc,mcmaniac/ghc,da-x/ghc,TomMD/ghc,mfine/ghc,jstolarek/ghc,ezyang/ghc,ml9951/ghc,jstolarek/ghc,AlexanderPankiv/ghc,anton-dessiatov/ghc,oldmanmike/ghc,siddhanathan/ghc,hferreiro/replay,green-haskell/ghc,anton-dessiatov/ghc,christiaanb/ghc,nathyong/microghc-ghc,frantisekfarka/ghc-dsi