[llvm-commits] [llvm] r116785 - /llvm/trunk/lib/System/Win32/ThreadLocal.inc

Bill Wendling wendling at apple.com
Tue Oct 19 19:49:02 PDT 2010


Hi Nakamura,

The patch looks fine. Go ahead and apply it. If you want to tackle the other places where the ATTRIBUTE_UNUSED can be used, please do. :-)

ありがとうございます。
-bw

On Oct 19, 2010, at 7:33 PM, NAKAMURA Takumi wrote:

> Bill san, Jim san,
> 
> Thank you to give me comments.
> I am sorry I remembered only the fixup in lib/System/RWMutex.cpp at 110667,
> and I commited similarly.
> 
> I think it would be better to take Bill's way. May I fix up 2 files
> with attached patch?
> 
> ...Takumi
> 
> ps. I can still see some points with grep -nri '(void)[A-Z][0-9A-Z]*;'
> | fgrep -iv warning
> 
> 
> 2010/10/20 Bill Wendling <wendling at apple.com>:
>> Or better yet, use the ATTRIBUTE_UNUSED attribute in
>> llvm/Support/Compiler.h.
>> -bw
>> On Oct 19, 2010, at 9:16 AM, Jim Grosbach wrote:
>> 
>> Can you add a comment saying why that line is necessary? Otherwise some well
>> meaning person may remove the "unusued" statement.
>> 
>> -Jim
>> 
>> On Oct 18, 2010, at 6:22 PM, NAKAMURA Takumi wrote:
>> 
>> Author: chapuni
>> 
>> Date: Mon Oct 18 20:22:01 2010
>> 
>> New Revision: 116785
>> 
>> URL: http://llvm.org/viewvc/llvm-project?rev=116785&view=rev
>> 
>> Log:
>> 
>> lib/System/Win32/ThreadLocal.inc: Suppress "unused" warning on -Asserts.
>> 
>> Modified:
>> 
>>   llvm/trunk/lib/System/Win32/ThreadLocal.inc
>> 
>> Modified: llvm/trunk/lib/System/Win32/ThreadLocal.inc
>> 
>> URL:
>> http://llvm.org/viewvc/llvm-project/llvm/trunk/lib/System/Win32/ThreadLocal.inc?rev=116785&r1=116784&r2=116785&view=diff
>> 
>> ==============================================================================
>> 
>> --- llvm/trunk/lib/System/Win32/ThreadLocal.inc (original)
>> 
>> +++ llvm/trunk/lib/System/Win32/ThreadLocal.inc Mon Oct 18 20:22:01 2010
>> 
>> @@ -44,6 +44,7 @@
>> 
>>  DWORD* tls = static_cast<DWORD*>(data);
>> 
>>  int errorcode = TlsSetValue(*tls, const_cast<void*>(d));
>> 
>>  assert(errorcode != 0);
>> 
>> +  (void)errorcode;
>> 
>> }
>> 
>> void ThreadLocalImpl::removeInstance() {
>> 
>> 
>> _______________________________________________
>> 
>> llvm-commits mailing list
>> 
>> llvm-commits at cs.uiuc.edu
>> 
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>> 
>> 
>> _______________________________________________
>> llvm-commits mailing list
>> llvm-commits at cs.uiuc.edu
>> http://lists.cs.uiuc.edu/mailman/listinfo/llvm-commits
>> 
>> 
> <unused-var.diff.txt>

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20101019/9bf4f9dc/attachment.html>


More information about the llvm-commits mailing list