Fix the diagnostic when we are shadowing an external variable and there exists a locally scoped extern with the same name.

llvm-svn: 124580
diff --git a/clang/test/Sema/warn-shadow.c b/clang/test/Sema/warn-shadow.c
index c77bb0c..32aca8d 100644
--- a/clang/test/Sema/warn-shadow.c
+++ b/clang/test/Sema/warn-shadow.c
@@ -49,8 +49,13 @@
 void test6(void (*f)(int i)) {}
 void test7(void *context, void (*callback)(void *context)) {}
 
+extern int bob; // expected-note {{previous declaration is here}}
+
 // rdar://8883302
-extern int bob;
 void rdar8883302() {
   extern int bob; // don't warn for shadowing.
 }
+
+void test8() {
+  int bob; // expected-warning {{declaration shadows a variable in the global scope}}
+}