ports/devel/llvm-devel/files/patch-tools_clang_lib_Sema_SemaDeclAttr.cpp
Brooks Davis 45e5bc018a Update to r65948.
Add printf0 support. [1]

Install the clang C headers (excluding std*.h since we have our own) now
that the installer puts them somewhere sane.

Submitted by:	ed
2009-03-03 18:12:02 +00:00

17 lines
592 B
C++

$FreeBSD$
--- tools/clang/lib/Sema/SemaDeclAttr.cpp.orig
+++ tools/clang/lib/Sema/SemaDeclAttr.cpp
@@ -1011,7 +1011,10 @@
default: break;
case 5: Supported = !memcmp(Format, "scanf", 5); break;
case 6: Supported = !memcmp(Format, "printf", 6); break;
- case 7: Supported = !memcmp(Format, "strfmon", 7); break;
+ case 7:
+ Supported = (!memcmp(Format, "strfmon", 7) ||
+ !memcmp(Format, "printf0", 7));
+ break;
case 8:
Supported = (is_strftime = !memcmp(Format, "strftime", 8)) ||
(is_NSString = !memcmp(Format, "NSString", 8)) ||