As discussed earlier [1] (apologies for the delay), the attached patch
introduces CharUnits, an opaque value class for quantities with
character units.

It uses an int64_t to represent the quantity, has a named constructor, a
single explicit conversion to a int64_t, and basic arithmetic,
comparison, and relational operators. It is intended as a return type
for ASTContext::getTypeSizeInBytes() and other methods that return
sizes, offsets and alignments in character units.

Comments welcome.

-Ken


[1]
http://lists.cs.uiuc.edu/pipermail/cfe-commits/Week-of-Mon-20091123/0243
36.html

Attachment: CharUnits.r91240.patch
Description: CharUnits.r91240.patch

_______________________________________________
cfe-commits mailing list
[email protected]
http://lists.cs.uiuc.edu/mailman/listinfo/cfe-commits

Reply via email to