This fixes pr14946. The problem was that the linkage computation was done too early, so things like "extern int a;" would be given external linkage, even if a previous declaration was static. llvm-svn: 172667
linkage rather than the presence of the 'static' storage class specifier. Fixes rdar://problem/8814626. llvm-svn: 125126