On Jun 11, 2013, at 11:00 AM, Jason Merrill <ja...@redhat.com> wrote:
> On 06/11/2013 12:39 PM, Paolo Carlini wrote:
>> On 06/11/2013 06:27 PM, Mike Stump wrote:
>>> Here is a simple one.  When processing CONST_DECLs after an error, we
>>> can ICE.  This avoid the ICE.
> 
>> No testcase?
> 
> Yep; the patch is fine, but needs a test case.

I don't have a test case, it was found via code where overflow was incorrectly 
set while compiling libstdc++, that test case won't work in the trunk, as the 
trunk sets overflow correctly…

I've tried all sorts of test cases to try and get it to fail, and net result it 
won't.  There are a few major paths into the code and most will transform to 
NULL_TREE or 0.  The test case was something like the below, though this 
version can't be made to show an error that I've found.  I don't see how to get 
it to fail.

I've fixed our code to compute overflow correctly and the crash is of course 
gone.  So, it is possible that it is impossible to get the code to fail.

So, I think I want to withdraw the patch, no need to mess up the code, for 
cases that can't happen.  If it does happen, someone will validly hit it and we 
can fix it at that time.  Thoughts?


namespace std
{
  // 22.2.2  The numeric category.
  class __num_base
  {
  public:
    // NB: Code depends on the order of _S_atoms_out elements.
    // Below are the indices into _S_atoms_out.
    enum
      {
        _S_ominus,
        _S_oplus,
        _S_ox,
        _S_oX,
        _S_odigits,
        _S_odigits_end = _S_odigits + 16,
        _S_oudigits = _S_odigits_end,
        _S_oudigits_end = _S_oudigits + 16,
        _S_oe = _S_odigits + 14,  // For scientific notation, 'e'
        _S_oE = _S_oudigits + 14, // For scientific notation, 'E'
        _S_oend = _S_oudigits_end
      };

  };
}


Reply via email to