Integer conversions too pedantic in 64-bit

Nick Sabalausky a at a.a
Tue Feb 15 14:00:12 PST 2011


"so" <so at so.so> wrote in message news:op.vqyk3emumpw3zg at so-pc...
>> I disagree that the discussion is pointless.
>> On the contrary, the OP pointed out some valid points:
>>
>> 1.  that size_t is inconsistent with D's style guide. the "_t" suffix is 
>> a C++ convention and not a D one. While it makes sense for [former?] C++ 
>> programmers it will confuse newcomers to D from other languages that 
>> would expect the language to follow its own style guide.
>> 2. the proposed change is backwards compatible - the OP asked for an 
>> *additional* alias.
>> 3. generic concepts should belong to the standard library and not user 
>> code which is also where size_t is already defined.
>>
>> IMO, we already have a byte type, it's plain common sense to extend this 
>> with a "native word" type.
>
> Funny thing is the most important argument against size_t got the least 
> attention.
> I will leave it as an exercise for the reader.

That variables of type "size_t" are frequently used to store indicies rather 
than the actual *size* of anything?

That it does nothing to help with 32/64-bit portability until you actually 
compile your code both ways?

That Nick doesn't like it? ;)





More information about the Digitalmars-d mailing list