Drop bunch of half-working stuff in the ext_weak linkage support.
[oota-llvm.git] / lib / VMCore / AsmWriter.cpp
index 6718da4ca07f9f0e225302ee6c22cdc3efdb5a66..68cf438e29a55ab9c90ac5789e8ea860845023d0 100644 (file)
@@ -1240,10 +1240,7 @@ void AssemblyWriter::printAlias(const GlobalAlias *GA) {
     printType(F->getFunctionType());
     Out << "* ";
 
-    if (F->hasName())
-      PrintLLVMName(Out, F);
-    else
-      Out << "@\"\"";
+    WriteAsOperandInternal(Out, F, TypeNames, &Machine);
   } else if (const GlobalAlias *GA = dyn_cast<GlobalAlias>(Aliasee)) {
     printType(GA->getType());
     Out << " ";
@@ -1310,10 +1307,7 @@ void AssemblyWriter::printFunction(const Function *F) {
     Out <<  Attribute::getAsString(Attrs.getRetAttributes()) << ' ';
   printType(F->getReturnType());
   Out << ' ';
-  if (F->hasName())
-    PrintLLVMName(Out, F);
-  else
-    Out << "@\"\"";
+  WriteAsOperandInternal(Out, F, TypeNames, &Machine);
   Out << '(';
   Machine.incorporateFunction(F);