comparison dmd/expression.c @ 420:491264b7cb93

Use == in RealEquals and get rid of the memcmp there entirely.
author Christian Kamm <kamm incasoftware de>
date Mon, 28 Jul 2008 20:50:41 +0200
parents 1a9bdbd4ac60
children 1c65b5477eaa
comparison
equal deleted inserted replaced
419:023fa78c1203 420:491264b7cb93
1496 { 1496 {
1497 return (isnan(x1) && isnan(x2)) || 1497 return (isnan(x1) && isnan(x2)) ||
1498 /* In some cases, the REALPAD bytes get garbage in them, 1498 /* In some cases, the REALPAD bytes get garbage in them,
1499 * so be sure and ignore them. 1499 * so be sure and ignore them.
1500 */ 1500 */
1501 memcmp(&x1, &x2, REAL_T_SIZE - REAL_T_PAD) == 0; 1501 x1 == x2;
1502 } 1502 }
1503 1503
1504 int RealExp::equals(Object *o) 1504 int RealExp::equals(Object *o)
1505 { RealExp *ne; 1505 { RealExp *ne;
1506 1506