Overview
Examples
Screenshots
Comparisons
Applications
Download
Documentation
Tutorials
Bazaar
Status & Roadmap
FAQ
Authors & License
Forums
Funding Ultimate++
Search on this site
Search in forums












SourceForge.net Logo
Home » U++ Library support » U++ Core » int16 support in Value?
int16 support in Value? [message #15656] Fri, 02 May 2008 11:35 Go to next message
mrjt is currently offline  mrjt
Messages: 705
Registered: March 2007
Location: London
Contributor
Would it be possible to add 'operator int16' to Value? I often want to read directly from a ctrl into a data structure containing shorts and writing (short)(int) everywhere is ugly and annoying. Converting the other way works fine as it's an up-cast.

I've added it to my version without issue, but is there some subtle problem I'm missing?
Re: int16 support in Value? [message #15730 is a reply to message #15656] Tue, 06 May 2008 19:48 Go to previous messageGo to next message
mirek is currently offline  mirek
Messages: 13975
Registered: November 2005
Ultimate Member
I have to say I am hesitating about this a lot... (that is why I did not reply yet).

I guess we do not want to support all numeric types in Value... And int16 does not have a Null...

I do not know.

Mirek
Re: int16 support in Value? [message #15760 is a reply to message #15730] Wed, 07 May 2008 11:05 Go to previous message
mrjt is currently offline  mrjt
Messages: 705
Registered: March 2007
Location: London
Contributor
luzr wrote on Tue, 06 May 2008 18:48

I have to say I am hesitating about this a lot... (that is why I did not reply yet).

I guess we do not want to support all numeric types in Value... And int16 does not have a Null...

I do not know.

Mirek

Okay, it's no biggy and I guess most people don't have the need anyway. I was mainly curious about why it wasn't there to begin with, I'd forgotten about Nulls.
Previous Topic: cout, cin etc. question
Next Topic: StaticMutex::Get does not compile in svn
Goto Forum:
  


Current Time: Mon Apr 29 07:40:48 CEST 2024

Total time taken to generate the page: 0.02011 seconds