Ada subtypes and base types

Robert Dewar dewar@adacore.com
Tue Feb 21 19:17:00 GMT 2006


>> Indeed.  Ada should in this case generate
>>
>>   R = (T)( (basetype)100 + (basetype)X - (basetype)X )

It does!
>>
>> i.e. carry out all arithmetic explicitly in the basetype and only for stores
>> and loads use the subtype.
> I'd tend to agree, furthermore, if a pass starts wiping out those
> type conversions, then we've got a bug. 

Right, the type conversions must not be wiped out, that's a
real issue!



More information about the Gcc mailing list