A Matter of Style: Aliases or Not?

As stated earlier, the C# reserved words for built-in types are simply aliases for the corresponding underlying BCL types. There’s no semantic difference whatsoever, so you can use either one.

Sometimes people start long-winded discussions on what’s the preferred style. I deliberately don’t participate in such discussion, but instead have one rule of thumb: consistency. Mixing aliases and raw BCL type names can yield only more confusion. But, objectively, both have their merits:

Image The BCL type names clearly indicate the range of numeric types in terms of bit width, but in a decimal-centric world that doesn’t tell ...

Get C# 5.0 Unleashed now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.