#include "gdbsupport/selftest.h"
#include "rust-lang.h"
#include "gdbsupport/pathstuff.h"
+#include "count-one-bits.h"
/* When == 1, print basic high level tracing messages.
When > 1, be more verbose.
unsigned_enum = 0;
flag_enum = 0;
}
- else if ((mask & value) != 0)
- flag_enum = 0;
else
- mask |= value;
+ {
+ if (count_one_bits_ll (value) >= 2)
+ flag_enum = 0;
+ else if ((mask & value) != 0)
+ flag_enum = 0;
+ else
+ mask |= value;
+ }
/* If we already know that the enum type is neither unsigned, nor
a flag type, no need to look at the rest of the enumerates. */