Re: [PATCH 2/2] merge-ort: fix slightly overzealous assertion for rename-to-self

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Elijah Newren <newren@xxxxxxxxx> writes:

> But it might be worth mentioning that having side-effects in
> assertions is a huge no-no, and I understand that when folks have to
> debug one of those (I had to in a separate project years ago which was
> kind of nasty), that they sometimes jump to the conclusion that
> assertions are bad.

Yes, assert() invites such mistakes.  Why not avoid them when there
are better alternatives like "if (condition) BUG()"?





[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux