[PATCH] chg: silence warning of unused parameter 'sig'

Pierre-Yves David pierre-yves.david at ens-lyon.org
Wed Jun 29 21:12:31 EDT 2016


I've pushed this based on jun review. Thanks.

On 06/29/2016 02:28 PM, Yuya Nishihara wrote:
> On Tue, 28 Jun 2016 21:21:50 +0100, Jun Wu wrote:
>> Alternative to the GNU extension "__attribute__", there are 2 common
>> patterns to silence the warning:
>>
>>   void handlechildsignal(int /* sig */)
> 
> It's C++.
> 
>> or in the body of the function:
>>   
>>   (void)sig;
> 
> Yes, I sometimes do that if I want to suppress the warning conditionally.
> _______________________________________________
> Mercurial-devel mailing list
> Mercurial-devel at mercurial-scm.org
> https://www.mercurial-scm.org/mailman/listinfo/mercurial-devel
> 

-- 
Pierre-Yves David


More information about the Mercurial-devel mailing list