This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Value not equal to itself


gcc -v; gcc version 4.2.1 20070831 patched [FreeBSD]
uname -srip; FreeBSD 9.0-RELEASE i386 GENERI
Compiler command; gcc47 minimalErroringCode.cpp -o minimalErroringCode
Test; ./minimalErroringCode
Expected; no output
Result; Assertion failed: ((buffer[0] = 0xFF) && buffer[0] == 0xFF),
function main, file minimalErroringCode.cpp, line 4.
#include <cassert>
int main() {
  char buffer[1024];
  assert((buffer[0] = 0xFF) && buffer[0] == 0xFF);
  return 0;
}

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]