[cfe-commits] r157511 - in /cfe/trunk: docs/ReleaseNotes.html include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/AnalysisBasedWarnings.cpp test/Analysis/uninit-sometimes.cpp test/Sema/uninit-variable

2012-05-25 Thread Richard Smith
Author: rsmith Date: Sat May 26 01:20:46 2012 New Revision: 157511 URL: http://llvm.org/viewvc/llvm-project?rev=157511&view=rev Log: In response to some discussions on IRC, tweak the wording of the new -Wsometimes-uninitialized diagnostics to make it clearer that the cause of the issue may be a co

[cfe-commits] r157510 - /cfe/trunk/lib/Sema/SemaDecl.cpp

2012-05-25 Thread David Blaikie
Author: dblaikie Date: Sat May 26 00:35:39 2012 New Revision: 157510 URL: http://llvm.org/viewvc/llvm-project?rev=157510&view=rev Log: Fix indentation. Modified: cfe/trunk/lib/Sema/SemaDecl.cpp Modified: cfe/trunk/lib/Sema/SemaDecl.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/

Re: [cfe-commits] r157025 - in /cfe/trunk: lib/Sema/SemaDecl.cpp lib/Sema/SemaDeclObjC.cpp test/SemaObjC/related-result-type-inference.m

2012-05-25 Thread Douglas Gregor
On May 24, 2012, at 3:17 AM, Erik Verbruggen wrote: > Quite errr... surprising. I only understood the testcase after reading it > like 3 times. I think we should add a warning for this (possibly off by > default), because I can see a lot of people falling into this trap. I'd be happy to add a

Re: [cfe-commits] [Windows] Properly mangle templates

2012-05-25 Thread John McCall
On May 24, 2012, at 10:03 PM, Charles Davis wrote: > On May 24, 2012, at 5:53 AM, John McCall wrote: >> On May 24, 2012, at 4:35 AM, Timur Iskhodzhanov wrote: >>> On Thu, May 24, 2012 at 2:44 PM, João Matos wrote: >> Attached is a patch that introduces template mangling (at least in the >>

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Chris Lattner
On May 25, 2012, at 3:43 PM, Evan Cheng wrote: > The primary concerns I have seen so far are "it doesn't serve the needs for > all memory safety techniques". Did I miss some other specific concern about > alloc_size attribute? On another note, one part of Nuno's goal for the summer is to impleme

Re: [cfe-commits] [PATCH] Minor improvement for -Wimplicit-fallthrough

2012-05-25 Thread Alexander Kornienko
> > If it looks good, could you commit it? I don't have commit access yet. > No worries, I got commit access and committed it as r157508. -- Regards, Alex ___ cfe-commits mailing list cfe-commits@cs.uiuc.edu http://lists.cs.uiuc.edu/mailman/listinfo/cf

[cfe-commits] r157508 - in /cfe/trunk: lib/Sema/AnalysisBasedWarnings.cpp test/SemaCXX/switch-implicit-fallthrough.cpp

2012-05-25 Thread Alexander Kornienko
Author: alexfh Date: Fri May 25 19:49:15 2012 New Revision: 157508 URL: http://llvm.org/viewvc/llvm-project?rev=157508&view=rev Log: Don't offer '[[clang::fallthrough]];' fix-it when a fall-through occurs to a switch label immediately followed by a 'break;'. Modified: cfe/trunk/lib/Sema/Analy

Re: [cfe-commits] [PATCH] Minor improvement for -Wimplicit-fallthrough

2012-05-25 Thread Alexander Kornienko
Hi Chandler, On Fri, May 25, 2012 at 11:15 PM, Chandler Carruth wrote: > On Fri, May 25, 2012 at 11:15 AM, Alexander Kornienko > wrote: > >> Hi cfe-commits, >> >> This patch handles a specific (but surprisingly common) case when a >> fall-through occurs to a switch label immediately followed by

[cfe-commits] [PATCH] "Soft opt-in" option for -Wimplicit-fallthrough

2012-05-25 Thread Alexander Kornienko
Hi cfe-commits, This patch adds a "soft opt-in" option for -Wimplicit-fallthroughdiagnostics. The reason for it is to provide a way to start using fall-through annotations without breaking (when treating warnings as errors) all code with unannotated fall-throughs. So it's only meant to be used for

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Evan Cheng
The primary concerns I have seen so far are "it doesn't serve the needs for all memory safety techniques". Did I miss some other specific concern about alloc_size attribute? I think I should address the recent discussions the LLVM side wrt to the bounds checking pass. I've been following the di

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Douglas Gregor
On May 25, 2012, at 3:23 PM, Nuno Lopes wrote: > There has been some discussion on both the bounds checking and the alloc_size > proposals on the various mailing lists (dev & commits) for the past month. > Yes, the design is not finished. But I've been making changes to the > implementation to

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Nuno Lopes
There has been some discussion on both the bounds checking and the alloc_size proposals on the various mailing lists (dev & commits) for the past month. Yes, the design is not finished. But I've been making changes to the implementation to accommodate the feedback. Nuno Citando Chandler Ca

[cfe-commits] [libcxx] r157503 - in /libcxx/trunk: include/ test/containers/associative/map/map.cons/ test/containers/associative/map/map.modifiers/ test/containers/associative/multimap/multimap.modif

2012-05-25 Thread Howard Hinnant
Author: hhinnant Date: Fri May 25 17:04:21 2012 New Revision: 157503 URL: http://llvm.org/viewvc/llvm-project?rev=157503&view=rev Log: The rules for emplace in map, multimap, unordered_map and unordered_multimap changed a while back and I'm just now updating to these new rules. In a nutshell, y

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Nuno Lopes
Fixed in r157500. Thanks for the review, Nuno Citando Jordy Rose : > Suggestion: use the stack-based SmallVector instead of std::vector. > Also, a CXXMethodDecl might be a static method, so you'll need to > check isInstance() as well. > > Jordy > > > On May 25, 2012, at 13:04, Nuno Lopes wro

[cfe-commits] r157500 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGenCXX/alloc_size.cpp

2012-05-25 Thread Nuno Lopes
Author: nlopes Date: Fri May 25 16:45:08 2012 New Revision: 157500 URL: http://llvm.org/viewvc/llvm-project?rev=157500&view=rev Log: fix codegen support for alloc_size attribute for static C++ methods add test case for C++ codegen Added: cfe/trunk/test/CodeGenCXX/alloc_size.cpp Modified:

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Chandler Carruth
Nuno, this patch didn't get reviewed before commit. The LLVM review is ongoing, and seems to indicate the solution is not yet ready. Folks have also raised serious concerns about the implementation strategy here. While supporting the alloc_size attribute at least enough to parse it and reject inva

Re: [cfe-commits] [PATCH] Minor improvement for -Wimplicit-fallthrough

2012-05-25 Thread Chandler Carruth
On Fri, May 25, 2012 at 11:15 AM, Alexander Kornienko wrote: > Hi cfe-commits, > > This patch handles a specific (but surprisingly common) case when a > fall-through occurs to a switch label immediately followed by a break;. > In this case it doesn't make sense to suggest a fall-through annotation

Re: [cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Jordy Rose
Suggestion: use the stack-based SmallVector instead of std::vector. Also, a CXXMethodDecl might be a static method, so you'll need to check isInstance() as well. Jordy On May 25, 2012, at 13:04, Nuno Lopes wrote: > Author: nlopes > Date: Fri May 25 12:04:42 2012 > New Revision: 157483 > > UR

[cfe-commits] r157491 - /cfe/trunk/test/Index/index-refs.m

2012-05-25 Thread Argyrios Kyrtzidis
Author: akirtzidis Date: Fri May 25 15:05:57 2012 New Revision: 157491 URL: http://llvm.org/viewvc/llvm-project?rev=157491&view=rev Log: [libclang] Add a test I forgot to commit for r156890. Added: cfe/trunk/test/Index/index-refs.m Added: cfe/trunk/test/Index/index-refs.m URL: http://llvm.o

Re: [cfe-commits] r157362 - in /cfe/trunk: include/clang/AST/Expr.h include/clang/Basic/DiagnosticSemaKinds.td lib/AST/Expr.cpp lib/Sema/SemaExpr.cpp lib/Sema/SemaStmt.cpp test/Sema/unused-expr.c test

2012-05-25 Thread Nico Weber
All good now. Thanks! On Thu, May 24, 2012 at 2:07 PM, Eli Friedman wrote: > On Thu, May 24, 2012 at 9:57 AM, Nico Weber wrote: >> Hi Eli, >> >> someone on IRC reported that this breaks the compiler-rt build. Log at >> http://paste.ubuntu.com/1004855/ , excerpt below: >> >> In file included from

[cfe-commits] [PATCH] Minor improvement for -Wimplicit-fallthrough

2012-05-25 Thread Alexander Kornienko
Hi cfe-commits, This patch handles a specific (but surprisingly common) case when a fall-through occurs to a switch label immediately followed by a break;. In this case it doesn't make sense to suggest a fall-through annotation, almost certainly inserting break; is a good fix-it. Example: switch

[cfe-commits] r157486 - in /cfe/trunk: lib/AST/Decl.cpp test/CodeGenCXX/visibility.cpp

2012-05-25 Thread Rafael Espindola
Author: rafael Date: Fri May 25 12:22:33 2012 New Revision: 157486 URL: http://llvm.org/viewvc/llvm-project?rev=157486&view=rev Log: Don't ignore linkage when ignoring visibility in the instantiation of a method template. Modified: cfe/trunk/lib/AST/Decl.cpp cfe/trunk/test/CodeGenCXX/visi

[cfe-commits] r157483 - in /cfe/trunk: lib/CodeGen/CGCall.cpp test/CodeGen/alloc_size.c

2012-05-25 Thread Nuno Lopes
Author: nlopes Date: Fri May 25 12:04:42 2012 New Revision: 157483 URL: http://llvm.org/viewvc/llvm-project?rev=157483&view=rev Log: add CodeGen support for the alloc_size attribute Added: cfe/trunk/test/CodeGen/alloc_size.c Modified: cfe/trunk/lib/CodeGen/CGCall.cpp Modified: cfe/trunk/

[cfe-commits] r157480 - in /cfe/trunk: lib/AST/Decl.cpp test/CodeGenCXX/visibility.cpp

2012-05-25 Thread Rafael Espindola
Author: rafael Date: Fri May 25 11:41:35 2012 New Revision: 157480 URL: http://llvm.org/viewvc/llvm-project?rev=157480&view=rev Log: Don't ignore linkage when ignoring visibility in the instantiation of a function template. Modified: cfe/trunk/lib/AST/Decl.cpp cfe/trunk/test/CodeGenCXX/vi

Re: [cfe-commits] r157478 - in /cfe/trunk: lib/StaticAnalyzer/Core/ExprEngineC.cpp test/Analysis/cxx11-crashes.cpp

2012-05-25 Thread Jordy Rose
Do we even need to conjure a new value here? reinterpret_cast on a location should be the same as static_cast or C-style casts, right? (At least when we're not dealing with fptr<->ptr conversions or different memory segments.) Of course, I might be missing something. On May 25, 2012, at 12:02,

[cfe-commits] Patch for LineTableInfo to use FileID instead of int for file references

2012-05-25 Thread Tom Honermann
I recently needed to write code to iterate over preprocessing line control directives, identify the originating source file for the directive, and then lookup details for the originating source file. LineTableInfo has begin() and end() methods to iterate over the set of source file IDs and ret

[cfe-commits] r157478 - in /cfe/trunk: lib/StaticAnalyzer/Core/ExprEngineC.cpp test/Analysis/cxx11-crashes.cpp

2012-05-25 Thread Anna Zaks
Author: zaks Date: Fri May 25 11:02:16 2012 New Revision: 157478 URL: http://llvm.org/viewvc/llvm-project?rev=157478&view=rev Log: [analyzer] Don't crash on LValBitCast Modified: cfe/trunk/lib/StaticAnalyzer/Core/ExprEngineC.cpp cfe/trunk/test/Analysis/cxx11-crashes.cpp Modified: cfe/tru

[cfe-commits] [libcxx] r157476 - /libcxx/trunk/include/future

2012-05-25 Thread Howard Hinnant
Author: hhinnant Date: Fri May 25 10:55:46 2012 New Revision: 157476 URL: http://llvm.org/viewvc/llvm-project?rev=157476&view=rev Log: Fix memory corruption bug found and fixed by Andrew C. Morrow. Modified: libcxx/trunk/include/future Modified: libcxx/trunk/include/future URL: http://llvm.

[cfe-commits] r157475 - in /cfe/trunk: lib/AST/Decl.cpp test/CodeGenCXX/visibility.cpp

2012-05-25 Thread Rafael Espindola
Author: rafael Date: Fri May 25 10:51:26 2012 New Revision: 157475 URL: http://llvm.org/viewvc/llvm-project?rev=157475&view=rev Log: Consider the linkage for member class templates even when we have to ignore the visibility. Modified: cfe/trunk/lib/AST/Decl.cpp cfe/trunk/test/CodeGenCXX/v

[cfe-commits] r157470 - in /cfe/trunk: lib/AST/Decl.cpp test/CodeGenCXX/visibility.cpp

2012-05-25 Thread Rafael Espindola
Author: rafael Date: Fri May 25 09:47:05 2012 New Revision: 157470 URL: http://llvm.org/viewvc/llvm-project?rev=157470&view=rev Log: When ignoring visibility in an instantiation, still consider the linkage. Similar fixes for function and member template to follow as I write the testcases. Modifie

[cfe-commits] r157469 - /cfe/trunk/lib/AST/Decl.cpp

2012-05-25 Thread Rafael Espindola
Author: rafael Date: Fri May 25 09:17:45 2012 New Revision: 157469 URL: http://llvm.org/viewvc/llvm-project?rev=157469&view=rev Log: Whitespace fixes. Modified: cfe/trunk/lib/AST/Decl.cpp Modified: cfe/trunk/lib/AST/Decl.cpp URL: http://llvm.org/viewvc/llvm-project/cfe/trunk/lib/AST/Decl.cp

Re: [cfe-commits] r157445 - /cfe/trunk/lib/Frontend/TextDiagnostic.cpp

2012-05-25 Thread Marshall Clow
On May 25, 2012, at 3:26 AM, Joerg Sonnenberger wrote: > On Thu, May 24, 2012 at 05:50:00PM -0700, Marshall Clow wrote: >> On May 24, 2012, at 5:03 PM, Seth Cantrell wrote: >> >>> Author: socantre >>> Date: Thu May 24 19:03:29 2012 >>> New Revision: 157445 >>> >>> URL: http://llvm.org/viewvc/ll

Re: [cfe-commits] r157445 - /cfe/trunk/lib/Frontend/TextDiagnostic.cpp

2012-05-25 Thread Joerg Sonnenberger
On Thu, May 24, 2012 at 05:50:00PM -0700, Marshall Clow wrote: > On May 24, 2012, at 5:03 PM, Seth Cantrell wrote: > > > Author: socantre > > Date: Thu May 24 19:03:29 2012 > > New Revision: 157445 > > > > URL: http://llvm.org/viewvc/llvm-project?rev=157445&view=rev > > Log: > > ensure value pass

Re: [cfe-commits] [llvm-commits] [PATCH] [asan] Use zero-based shadow by default on Android

2012-05-25 Thread Chandler Carruth
On Fri, May 25, 2012 at 3:16 AM, Evgeniy Stepanov wrote: > On Wed, May 23, 2012 at 4:07 PM, Evgeniy Stepanov > wrote: > > Good point. Both patches landed, here is another one that adds a > > driver check for -pie. > > ping w/ a patch > LGTM The diagnostic says that '-pie' is required with ASan

Re: [cfe-commits] [llvm-commits] [PATCH] [asan] Use zero-based shadow by default on Android

2012-05-25 Thread Evgeniy Stepanov
On Wed, May 23, 2012 at 4:07 PM, Evgeniy Stepanov wrote: > Good point. Both patches landed, here is another one that adds a > driver check for -pie. ping w/ a patch > On Wed, May 23, 2012 at 3:04 PM, Chandler Carruth > wrote: >> On Wed, May 23, 2012 at 3:58 AM, Evgeniy Stepanov >> wrote: >>>

Re: [cfe-commits] [llvm-commits] [PATCH] [asan] Use zero-based shadow by default on Android

2012-05-25 Thread Evgeniy Stepanov
On Wed, May 23, 2012 at 4:07 PM, Evgeniy Stepanov wrote: > Good point. Both patches landed, here is another one that adds a > driver check for -pie. ping > On Wed, May 23, 2012 at 3:04 PM, Chandler Carruth > wrote: >> On Wed, May 23, 2012 at 3:58 AM, Evgeniy Stepanov >> wrote: >>> >>> Note t

[cfe-commits] r157462 - /cfe/trunk/www/menu.html.incl

2012-05-25 Thread Manuel Klimek
Author: klimek Date: Fri May 25 03:39:21 2012 New Revision: 157462 URL: http://llvm.org/viewvc/llvm-project?rev=157462&view=rev Log: Links the entry point to the tooling documentation into clang's menu bar. Modified: cfe/trunk/www/menu.html.incl Modified: cfe/trunk/www/menu.html.incl URL:

Re: [cfe-commits] [PATCH] Link docs/Tooling.html into the menu bar

2012-05-25 Thread Chandler Carruth
LGTM On Thu, May 24, 2012 at 10:27 AM, Manuel Klimek wrote: > Proposal to link the tooling docs into the main page. > > Cheers, > /Manuel > > Index: menu.html.incl > === > --- menu.html.incl (revision 157394) > +++ menu.html.in