df_changeable_flags use in combine.c

Matt matt@use.net
Mon Jan 4 23:12:00 GMT 2010


Hi,

I'm fixing some compiler errors when configuring with 
--enable-build-with-cxx, and ran into a curious line of code that may 
indicate a bug:

static unsigned int
rest_of_handle_combine (void)
{
   int rebuild_jump_labels_after_combine;

   df_set_flags (DF_LR_RUN_DCE + DF_DEFER_INSN_RESCAN);
  // ...
}

The DF_* values are from the df_changeable_flags enum, whose values are 
typically used in logical and/or operations for masking purposes. As such, 
I'm guessing the author may have meant to do:
   df_set_flags (DF_LR_RUN_DCE & DF_DEFER_INSN_RESCAN);

I could have just added the explicit cast necessary to silence the 
gcc-as-cxx warning I was running into, but I wanted to be a good citizen 
:)

Any pointers are appreciated,
Thanks!




--
tangled strands of DNA explain the way that I behave.
http://www.clock.org/~matt



More information about the Gcc mailing list