This is the mail archive of the gcc-patches@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]

Re: [C/C++ PATCH] shift with negative or too big count warning (PR c/48418)


On Tue, 8 Jan 2013, Jakub Jelinek wrote:

> Hi!
> 
> As discussed in the PR, on the following testcase we've regressed with the
> introduction of c_fully_fold, when the C FE normally warns the argument
> isn't folded yet.  Fixed by also warning in c_fully_fold_internal, if before
> that function the shift count wasn't INTEGER_CST and after it it is.
> 
> The testcase also revealed a regression on the C++ FE side, caused by
> SIZEOF_EXPR folding deferral.
> 
> Bootstrapped/regtested on x86_64-linux and i686-linux, ok for trunk?

The C front-end changes are OK.  Properly diagnostic messages inside ? : 
conditionals should be marked up with G_() to ensure that both cases are 
extracted for translation, though in this case it doesn't matter much 
given that the message wording should stay identical to other copies of 
the same messages.

-- 
Joseph S. Myers
joseph@codesourcery.com


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