Two modifications to the SIL linker:
Two modifications to the SIL linker:

- First, it now knows how to look through
  PartialApplyInsts in addition to simple
  ApplyInsts when finding functions to link.

- Second, it now consults the external source
  in all cases where CalleeFunction is non-NULL
  rather than just if the CalleeFunction is
  non-NULL and empty.  This allows the external
  source to override functions with pre-existing
  bodies.


Swift SVN r9836

apple/swift,CodaFi/swift,lorentey/swift,tardieu/swift,khizkhiz/swift,ahoppen/swift,adrfer/swift,khizkhiz/swift,gottesmm/swift,jopamer/swift,ahoppen/swift,cbrentharris/swift,shahmishal/swift,KrishMunot/swift,kstaring/swift,natecook1000/swift,Jnosh/swift,natecook1000/swift,mightydeveloper/swift,tkremenek/swift,brentdax/swift,roambotics/swift,manavgabhawala/swift,tinysun212/swift-windows,JGiola/swift,felix91gr/swift,swiftix/swift.old,dduan/swift,gregomni/swift,jopamer/swift,kentya6/swift,IngmarStein/swift,karwa/swift,sschiau/swift,sdulal/swift,hughbe/swift,amraboelela/swift,shahmishal/swift,Ivacker/swift,kperryua/swift,tjw/swift,danielmartin/swift,jtbandes/swift,LeoShimonaka/swift,gribozavr/swift,return/swift,johnno1962d/swift,jckarter/swift,brentdax/swift,JaSpa/swift,kperryua/swift,jmgc/swift,frootloops/swift,kentya6/swift,gribozavr/swift,russbishop/swift,karwa/swift,kentya6/swift,tjw/swift,milseman/swift,kusl/swift,benlangmuir/swift,deyton/swift,SwiftAndroid/swift,Ivacker/swift,felix91gr/swift,MukeshKumarS/Swift,shahmishal/swift,brentdax/swift,kstaring/swift,huonw/swift,harlanhaskins/swift,manavgabhawala/swift,felix91gr/swift,JaSpa/swift,gmilos/swift,karwa/swift,devincoughlin/swift,kstaring/swift,adrfer/swift,IngmarStein/swift,cbrentharris/swift,gmilos/swift,alblue/swift,danielmartin/swift,xwu/swift,tinysun212/swift-windows,jopamer/swift,airspeedswift/swift,gmilos/swift,allevato/swift,devincoughlin/swift,ben-ng/swift,Jnosh/swift,danielmartin/swift,parkera/swift,calebd/swift,brentdax/swift,rudkx/swift,amraboelela/swift,tardieu/swift,IngmarStein/swift,kperryua/swift,nathawes/swift,tardieu/swift,uasys/swift,CodaFi/swift,kperryua/swift,jckarter/swift,russbishop/swift,airspeedswift/swift,adrfer/swift,JaSpa/swift,airspeedswift/swift,uasys/swift,xwu/swift,milseman/swift,huonw/swift,jopamer/swift,nathawes/swift,frootloops/swift,roambotics/swift,practicalswift/swift,swiftix/swift,shajrawi/swift,zisko/swift,manavgabhawala/swift,frootloops/swift,codestergit/swift,apple/swift,huonw/swift,frootloops/swift,jmgc/swift,tkremenek/swift,LeoShimonaka/swift,IngmarStein/swift,amraboelela/swift,felix91gr/swift,ken0nek/swift,SwiftAndroid/swift,mightydeveloper/swift,benlangmuir/swift,OscarSwanros/swift,gregomni/swift,CodaFi/swift,russbishop/swift,adrfer/swift,OscarSwanros/swift,hughbe/swift,kperryua/swift,jtbandes/swift,ken0nek/swift,shajrawi/swift,xwu/swift,airspeedswift/swift,kusl/swift,LeoShimonaka/swift,allevato/swift,alblue/swift,tinysun212/swift-windows,jckarter/swift,johnno1962d/swift,manavgabhawala/swift,JaSpa/swift,jmgc/swift,djwbrown/swift,karwa/swift,hughbe/swift,stephentyrone/swift,sdulal/swift,emilstahl/swift,rudkx/swift,swiftix/swift.old,LeoShimonaka/swift,sdulal/swift,lorentey/swift,kentya6/swift,roambotics/swift,cbrentharris/swift,stephentyrone/swift,JGiola/swift,jopamer/swift,swiftix/swift.old,ahoppen/swift,shahmishal/swift,return/swift,gregomni/swift,huonw/swift,devincoughlin/swift,xedin/swift,bitjammer/swift,danielmartin/swift,parkera/swift,tjw/swift,felix91gr/swift,practicalswift/swift,uasys/swift,swiftix/swift,dduan/swift,tjw/swift,shahmishal/swift,OscarSwanros/swift,bitjammer/swift,dreamsxin/swift,gottesmm/swift,allevato/swift,apple/swift,atrick/swift,hooman/swift,KrishMunot/swift,kusl/swift,natecook1000/swift,modocache/swift,gregomni/swift,xedin/swift,khizkhiz/swift,djwbrown/swift,slavapestov/swift,ken0nek/swift,dduan/swift,airspeedswift/swift,aschwaighofer/swift,nathawes/swift,parkera/swift,alblue/swift,slavapestov/swift,therealbnut/swift,jopamer/swift,danielmartin/swift,rudkx/swift,johnno1962d/swift,amraboelela/swift,gottesmm/swift,hooman/swift,ken0nek/swift,sdulal/swift,modocache/swift,shahmishal/swift,tinysun212/swift-windows,shajrawi/swift,swiftix/swift,natecook1000/swift,emilstahl/swift,austinzheng/swift,tkremenek/swift,allevato/swift,LeoShimonaka/swift,calebd/swift,swiftix/swift,sschiau/swift,kentya6/swift,slavapestov/swift,Jnosh/swift,austinzheng/swift,gottesmm/swift,russbishop/swift,apple/swift,austinzheng/swift,austinzheng/swift,xedin/swift,mightydeveloper/swift,Jnosh/swift,sschiau/swift,xedin/swift,dduan/swift,shajrawi/swift,KrishMunot/swift,jckarter/swift,karwa/swift,practicalswift/swift,aschwaighofer/swift,ben-ng/swift,kusl/swift,kusl/swift,slavapestov/swift,Ivacker/swift,milseman/swift,shajrawi/swift,parkera/swift,modocache/swift,therealbnut/swift,glessard/swift,ahoppen/swift,zisko/swift,jmgc/swift,CodaFi/swift,devincoughlin/swift,cbrentharris/swift,jtbandes/swift,kentya6/swift,practicalswift/swift,kperryua/swift,manavgabhawala/swift,LeoShimonaka/swift,return/swift,gribozavr/swift,devincoughlin/swift,SwiftAndroid/swift,sschiau/swift,stephentyrone/swift,kstaring/swift,zisko/swift,benlangmuir/swift,bitjammer/swift,jtbandes/swift,aschwaighofer/swift,harlanhaskins/swift,xwu/swift,brentdax/swift,tardieu/swift,CodaFi/swift,codestergit/swift,arvedviehweger/swift,natecook1000/swift,zisko/swift,tjw/swift,modocache/swift,khizkhiz/swift,codestergit/swift,ahoppen/swift,return/swift,OscarSwanros/swift,swiftix/swift,ben-ng/swift,jopamer/swift,Jnosh/swift,harlanhaskins/swift,MukeshKumarS/Swift,CodaFi/swift,xwu/swift,swiftix/swift,emilstahl/swift,glessard/swift,benlangmuir/swift,austinzheng/swift,jmgc/swift,jtbandes/swift,modocache/swift,djwbrown/swift,deyton/swift,brentdax/swift,johnno1962d/swift,austinzheng/swift,airspeedswift/swift,IngmarStein/swift,practicalswift/swift,arvedviehweger/swift,gmilos/swift,felix91gr/swift,codestergit/swift,OscarSwanros/swift,MukeshKumarS/Swift,hooman/swift,roambotics/swift,tkremenek/swift,kusl/swift,slavapestov/swift,tardieu/swift,kstaring/swift,bitjammer/swift,tinysun212/swift-windows,MukeshKumarS/Swift,atrick/swift,aschwaighofer/swift,KrishMunot/swift,aschwaighofer/swift,deyton/swift,benlangmuir/swift,bitjammer/swift,dduan/swift,practicalswift/swift,zisko/swift,gottesmm/swift,milseman/swift,khizkhiz/swift,mightydeveloper/swift,roambotics/swift,rudkx/swift,deyton/swift,gottesmm/swift,ken0nek/swift,lorentey/swift,benlangmuir/swift,karwa/swift,modocache/swift,sdulal/swift,alblue/swift,kusl/swift,atrick/swift,natecook1000/swift,tkremenek/swift,KrishMunot/swift,russbishop/swift,harlanhaskins/swift,calebd/swift,IngmarStein/swift,codestergit/swift,arvedviehweger/swift,frootloops/swift,practicalswift/swift,johnno1962d/swift,slavapestov/swift,glessard/swift,kentya6/swift,JGiola/swift,ahoppen/swift,arvedviehweger/swift,devincoughlin/swift,shahmishal/swift,johnno1962d/swift,huonw/swift,xedin/swift,Ivacker/swift,return/swift,sdulal/swift,calebd/swift,JGiola/swift,amraboelela/swift,atrick/swift,tinysun212/swift-windows,JGiola/swift,Jnosh/swift,hooman/swift,arvedviehweger/swift,mightydeveloper/swift,stephentyrone/swift,johnno1962d/swift,glessard/swift,modocache/swift,nathawes/swift,glessard/swift,calebd/swift,tjw/swift,practicalswift/swift,ken0nek/swift,alblue/swift,gribozavr/swift,arvedviehweger/swift,xedin/swift,hughbe/swift,hughbe/swift,amraboelela/swift,ben-ng/swift,parkera/swift,xwu/swift,therealbnut/swift,LeoShimonaka/swift,emilstahl/swift,sdulal/swift,Ivacker/swift,aschwaighofer/swift,codestergit/swift,devincoughlin/swift,allevato/swift,MukeshKumarS/Swift,karwa/swift,Ivacker/swift,jtbandes/swift,allevato/swift,atrick/swift,hughbe/swift,mightydeveloper/swift,uasys/swift,JaSpa/swift,alblue/swift,russbishop/swift,codestergit/swift,xedin/swift,adrfer/swift,rudkx/swift,alblue/swift,jmgc/swift,hooman/swift,djwbrown/swift,gribozavr/swift,deyton/swift,sschiau/swift,nathawes/swift,lorentey/swift,MukeshKumarS/Swift,emilstahl/swift,zisko/swift,SwiftAndroid/swift,sschiau/swift,milseman/swift,tinysun212/swift-windows,lorentey/swift,milseman/swift,harlanhaskins/swift,ben-ng/swift,JaSpa/swift,jckarter/swift,sschiau/swift,slavapestov/swift,zisko/swift,hooman/swift,stephentyrone/swift,shajrawi/swift,therealbnut/swift,dduan/swift,tardieu/swift,KrishMunot/swift,jckarter/swift,arvedviehweger/swift,huonw/swift,khizkhiz/swift,adrfer/swift,stephentyrone/swift,djwbrown/swift,shajrawi/swift,OscarSwanros/swift,Ivacker/swift,karwa/swift,nathawes/swift,airspeedswift/swift,dduan/swift,cbrentharris/swift,swiftix/swift.old,gribozavr/swift,bitjammer/swift,bitjammer/swift,harlanhaskins/swift,gmilos/swift,parkera/swift,return/swift,LeoShimonaka/swift,natecook1000/swift,hughbe/swift,calebd/swift,kusl/swift,Ivacker/swift,parkera/swift,kstaring/swift,ken0nek/swift,shahmishal/swift,tardieu/swift,ben-ng/swift,swiftix/swift.old,gottesmm/swift,xwu/swift,khizkhiz/swift,nathawes/swift,shajrawi/swift,djwbrown/swift,jckarter/swift,harlanhaskins/swift,gmilos/swift,hooman/swift,SwiftAndroid/swift,gmilos/swift,kstaring/swift,mightydeveloper/swift,djwbrown/swift,danielmartin/swift,danielmartin/swift,therealbnut/swift,russbishop/swift,SwiftAndroid/swift,JGiola/swift,xedin/swift,devincoughlin/swift,gregomni/swift,aschwaighofer/swift,OscarSwanros/swift,cbrentharris/swift,gregomni/swift,stephentyrone/swift,sdulal/swift,parkera/swift,rudkx/swift,atrick/swift,cbrentharris/swift,swiftix/swift.old,dreamsxin/swift,sschiau/swift,uasys/swift,KrishMunot/swift,swiftix/swift,emilstahl/swift,emilstahl/swift,ben-ng/swift,cbrentharris/swift,frootloops/swift,tkremenek/swift,apple/swift,uasys/swift,jmgc/swift,swiftix/swift.old,glessard/swift,jtbandes/swift,uasys/swift,apple/swift,huonw/swift,gribozavr/swift,tjw/swift,deyton/swift,lorentey/swift,gribozavr/swift,kentya6/swift,therealbnut/swift,lorentey/swift,therealbnut/swift,tkremenek/swift,calebd/swift,return/swift,Jnosh/swift,SwiftAndroid/swift,manavgabhawala/swift,deyton/swift,mightydeveloper/swift,JaSpa/swift,adrfer/swift,milseman/swift,brentdax/swift,kperryua/swift,allevato/swift,emilstahl/swift,MukeshKumarS/Swift,roambotics/swift,IngmarStein/swift,manavgabhawala/swift,CodaFi/swift,amraboelela/swift,swiftix/swift.old,felix91gr/swift,austinzheng/swift,frootloops/swift,lorentey/swift