tech-userlevel archive

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

Problem with include/bitstring.h



While looking at some other stuff, I noticed that the operations described in bitstring(3) and implement as macros in include/bitstring.h can have a multiple-evaluation problem if the macro arguments have side effects (such as a ++ on the bit-number).

Shouldn't we include a warning about this, both in the man page and in the code?

+------------------+--------------------------+----------------------------+
| Paul Goyette     | PGP Key fingerprint:     | E-mail addresses:          |
| (Retired)        | FA29 0E3B 35AF E8AE 6651 | paul at whooppee dot com   |
| Kernel Developer | 0786 F758 55DE 53BA 7731 | pgoyette at netbsd dot org |
+------------------+--------------------------+----------------------------+


Home | Main Index | Thread Index | Old Index