On Tue, Jul 22, 2014 at 5:38 PM, Aaron Ballman <[email protected]>
wrote:

> How do these sound to you?
>
> On Tue, Jul 22, 2014 at 8:13 PM, Richard Smith <[email protected]>
> wrote:
> > +def err_integer_literal_too_large : Error<
> > +  "integer literal is a value that cannot be represented as
> %select{a|an}0
> > "
> > +  "%select{signed|unsigned}0 integer">;
> >
> > I don't think the "is a value that" adds anything here. Also, I'd like to
> > see something that more directly says we don't have a signed/unsigned
> > integer type large enough.
>
> "integer literal is too large to be represented in %select{a|an}0
> %select{signed|unsigned}0 integer type"


Perhaps "... to be represented in any %select{signed |}0integer type"?


> >  def err_integer_too_large : Error<
> > -  "integer constant is larger than the largest %0-bit unsigned integer
> > type">;
> > -def ext_integer_too_large_for_signed : ExtWarn<
> > -  "integer constant is larger than the largest %0-bit signed integer
> > type">,
> > +  "integer constant evaluates to value %0 that cannot be represented as
> a "
> > +  "%1-bit %select{signed|unsigned}2 integer">;
> >
> > Please rename this to something about ICEs, and move it to
> > DiagnosticSemaKinds next to the existing err_ice_ diagnostics. (This is
> > pretty similar to ext_cce_narrowing...)
> >
> >
> > +def ext_integer_literal_too_large_for_signed : ExtWarn<
> > +  "integer literal is a value that cannot be represented as a signed
> > integer, "
> > +  "and will instead be interpreted as unsigned">,
> >
> > Again, mentioning integer types and not just integers would make this
> > clearer.
>
> "integer literal is too large to be represented in a signed integer
> type, and will instead be interpreted as unsigned integer type"
>

Can we specify the type here? I think it's always 'unsigned long long' when
we reach this diagnostic.
_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to