[Issue 5409] Disallow (!x & y)
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Oct 19 15:36:53 PDT 2011
http://d.puremagic.com/issues/show_bug.cgi?id=5409
--- Comment #3 from bearophile_hugs at eml.cc 2011-10-19 15:35:52 PDT ---
One more case found here, in the source code of the Chrome browser:
http://www.viva64.com/en/b/0113/
Fragment N3:
#define SEC_ASN1_CHOICE 0x100000
typedef struct sec_ASN1Template_struct {
unsigned long kind;
...
} SEC_ASN1Template;
PRBool SEC_ASN1IsTemplateSimple(
const SEC_ASN1Template *theTemplate)
{
...
if (!theTemplate->kind & SEC_ASN1_CHOICE) {
...
}
A related case (Fragment N4), that I think too is worth catching (probably it's
a less common bug):
bool GetPlatformFileInfo(...) {
...
info->is_directory =
file_info.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY != 0;
...
}
The probably right code for Fragment N4:
info->is_directory =
(file_info.dwFileAttributes & FILE_ATTRIBUTE_DIRECTORY) != 0;
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list