Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
CLS-compliant
Message
General information
Forum:
ASP.NET
Category:
Other
Title:
CLS-compliant
Miscellaneous
Thread ID:
01054054
Message ID:
01054054
Views:
53
From the docs: "The UInt16 type is not CLS-compliant."

Do I want to stay CLS compliant? What if I don't comply?

I have a two byte number (0-65535) and UInt16 would work great to represent this number. I have in the past simply used Int32 and added my own error checking to make sure the number is in the range I want it to be. Should I stick with Int32 or should I go non-compliant and use UInt16? (the motivation for researching this is to potentially save 2 bytes of memory <s>)

Thanks,
Einar
Semper ubi sub ubi.
Next
Reply
Map
View

Click here to load this message in the networking platform