[llvm-commits] [llvm] r143970 - /llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp

Devang Patel dpatel at apple.com
Mon Nov 7 10:38:34 PST 2011


On Nov 7, 2011, at 10:10 AM, Eric Christopher wrote:

> Author: echristo
> Date: Mon Nov  7 12:10:17 2011
> New Revision: 143970
> 
> URL: http://llvm.org/viewvc/llvm-project?rev=143970&view=rev
> Log:
> Allow for the case where the name of the subprogram is "".
> 
> Fixes a self-host error.

StringRef.startswith() is handy.

Thanks!
-
Devang

> 
> Modified:
>    llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
> 
> Modified: llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp
> URL: http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp?rev=143970&r1=143969&r2=143970&view=diff
> ==============================================================================
> --- llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp (original)
> +++ llvm/trunk/lib/CodeGen/AsmPrinter/DwarfDebug.cpp Mon Nov  7 12:10:17 2011
> @@ -525,6 +525,7 @@
> }
> 
> static bool isObjCClass(StringRef Name) {
> +  if (Name == "") return false;
>   return Name[0] == '+' || Name[0] == '-';
> }
> 
> 
> 
> _______________________________________________
> llvm-commits mailing list
> llvm-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits




More information about the llvm-commits mailing list