Don't allow references to an enum element via an instance of the enum.
Don't allow references to an enum element via an instance of the enum.

Fixes <rdar://problem/15252954>.


Swift SVN r10388

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