Save out a correct lookup table if a lookup table entry is stale (it contains
an out-of-date external decls list). This happens if we declare some names,
force the lookup table for the decl context to be built, import a module that
adds more decls for the name, then write out our module without looking up the
name.

llvm-svn: 204694
diff --git a/clang/test/Modules/Inputs/namespaces-left.h b/clang/test/Modules/Inputs/namespaces-left.h
index fa93af2..787fe75 100644
--- a/clang/test/Modules/Inputs/namespaces-left.h
+++ b/clang/test/Modules/Inputs/namespaces-left.h
@@ -2,6 +2,11 @@
   enum E { e };
 }
 
+namespace AddAndReexportBeforeImport {
+  struct S {};
+  extern struct S t;
+}
+
 @import namespaces_top;
 
 namespace RedeclAcrossImport {