[Issue 9565] Index of static array should not print literal suffix

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Mar 1 02:36:01 PST 2013


http://d.puremagic.com/issues/show_bug.cgi?id=9565



--- Comment #3 from Kenji Hara <k.hara.pg at gmail.com> 2013-03-01 02:35:57 PST ---
(In reply to comment #2)
> (In reply to comment #0)
> > Index type of static array is always size_t, so suffix is not only just
> > redundant, but also is harmful for platform independent diagnostic message.
> 
> I think the reason it's there is to make the actual literal valid, because
> AFAIK you actually need to append "LU" for some big literals. But maybe we
> could remove the suffixes for small literals.

You are right. if the dimension is in (long.max, ulong.max], "LU" suffix is
necessary. (If LU is not there, "signed integer overflow" error will occur in
lexer).

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------


More information about the Digitalmars-d-bugs mailing list