For PR1136: Rename GlobalVariable::isExternal as isDeclaration to avoid
confusion with external linkage types.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33663 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/Target/CBackend/CBackend.cpp b/lib/Target/CBackend/CBackend.cpp
index a6d3fb5..785e764 100644
--- a/lib/Target/CBackend/CBackend.cpp
+++ b/lib/Target/CBackend/CBackend.cpp
@@ -305,7 +305,7 @@
   std::map<std::string, GlobalValue*> ExtSymbols;
   for (Module::iterator I = M.begin(), E = M.end(); I != E;) {
     Function *GV = I++;
-    if (GV->isExternal() && GV->hasName()) {
+    if (GV->isDeclaration() && GV->hasName()) {
       std::pair<std::map<std::string, GlobalValue*>::iterator, bool> X
         = ExtSymbols.insert(std::make_pair(GV->getName(), GV));
       if (!X.second) {
@@ -321,7 +321,7 @@
   for (Module::global_iterator I = M.global_begin(), E = M.global_end();
        I != E;) {
     GlobalVariable *GV = I++;
-    if (GV->isExternal() && GV->hasName()) {
+    if (GV->isDeclaration() && GV->hasName()) {
       std::pair<std::map<std::string, GlobalValue*>::iterator, bool> X
         = ExtSymbols.insert(std::make_pair(GV->getName(), GV));
       if (!X.second) {
@@ -1525,7 +1525,7 @@
     Out << "\n\n/* Global Variable Declarations */\n";
     for (Module::global_iterator I = M.global_begin(), E = M.global_end();
          I != E; ++I)
-      if (!I->isExternal()) {
+      if (!I->isDeclaration()) {
         // Ignore special globals, such as debug info.
         if (getGlobalVariableClass(I))
           continue;
@@ -1554,7 +1554,7 @@
     Out << "\n\n/* Global Variable Definitions and Initialization */\n";
     for (Module::global_iterator I = M.global_begin(), E = M.global_end(); 
          I != E; ++I)
-      if (!I->isExternal()) {
+      if (!I->isDeclaration()) {
         // Ignore special globals, such as debug info.
         if (getGlobalVariableClass(I))
           continue;
@@ -1777,7 +1777,7 @@
   FunctionInnards << Mang->getValueName(F) << '(';
 
   bool PrintedArg = false;
-  if (!F->isExternal()) {
+  if (!F->isDeclaration()) {
     if (!F->arg_empty()) {
       Function::const_arg_iterator I = F->arg_begin(), E = F->arg_end();