[cfe-dev] clang currently broken?

Timo Sirainen tss at iki.fi
Sat Oct 18 12:14:58 PDT 2008

On Sat, 2008-10-18 at 11:48 -0700, Ted Kremenek wrote:
> Hi Timo,
> This is strange; this error doesn't show up on Mac OS X at all.  

So it seems. I did everything exactly the same as in Debian and it
worked in OS X.

> I  
> even ran it through valgrind (on Mac OS X) and didn't get any user- 
> after-free errors.

Oh, there's a working valgrind for OS X?

> What are the exact arguments you passed to clang?

Nothing really. Either "ccc test2.c -o test" or just "clang test2.c".

Anyway, looks like I figured it out:

--- lib/AST/DeclGroup.cpp       (revision 57766)
+++ lib/AST/DeclGroup.cpp       (working copy)
@@ -54,7 +54,7 @@
 void DeclGroup::Destroy(ASTContext& C) {
-  Decl** Decls = (Decl**) this + 1;
+  Decl** Decls = (Decl**) (this + 1);
   for (unsigned i = 0; i < NumDecls; ++i)

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part
URL: <http://lists.llvm.org/pipermail/cfe-dev/attachments/20081018/6e700375/attachment.sig>

More information about the cfe-dev mailing list