Is it impossible to define for example i as long o s as short?
As far as i know they are CLS compliant so there should be no problem.... but compiler is not of the same opinion... are these types unused in Cobra? Obvs. no problem but i am somewhat in trouble trying to understand the cooperation between Cobra e .Net
Forums
long and short
7 posts
• Page 1 of 1
long and short
Last edited by relez on Fri Sep 19, 2008 6:08 am, edited 1 time in total.
- relez
- Posts: 69
Re: long and short
Try:
int8, int16, int32, int64
uint8, uint16, uint32, uint64
int and uint default to int32 and uint32
I dislike standalone type names such as "short" and "long" because they are adjectives that could apply to other things like floating points, characters, pointers, etc. Also, the naming scheme above is easy to grow, e.g., int128 and uint128.
int8, int16, int32, int64
uint8, uint16, uint32, uint64
int and uint default to int32 and uint32
I dislike standalone type names such as "short" and "long" because they are adjectives that could apply to other things like floating points, characters, pointers, etc. Also, the naming scheme above is easy to grow, e.g., int128 and uint128.
- Charles
- Posts: 2515
- Location: Los Angeles, CA
Re: long and short
Always speaking about types: why Byte begin with capital letter and so is Boolean? int, char, float ... lowercase...Byte, Boolean...uppercase.
I apologize if i am somewhat boring with uppercase-lowercase questions...
I apologize if i am somewhat boring with uppercase-lowercase questions...
- relez
- Posts: 69
Re: long and short
All the built-in types have corresponding structs in the System namespace which are capitalized. This is true of the other .NET languages as well.
You don't have to say Byte and Int64. You can say: int8, uint8, int64, bool, etc.
You don't have to say Byte and Int64. You can say: int8, uint8, int64, bool, etc.
- Charles
- Posts: 2515
- Location: Los Angeles, CA
Re: long and short
Hey, no problem. These are natural questions and will help others.
- Charles
- Posts: 2515
- Location: Los Angeles, CA
7 posts
• Page 1 of 1
Who is online
Users browsing this forum: No registered users and 81 guests