
| -----Original Message----- | From: boost-bounces@lists.boost.org | [mailto:boost-bounces@lists.boost.org] On Behalf Of Robert Ramey | Sent: 17 May 2006 16:43 | To: boost@lists.boost.org | Subject: Re: [boost] Stream input and output of NaN and infinity | | Paul A Bristow wrote: | | >> Please can you tell me if you think my pragmatic proposal (now in | >> version 2) meets these limited objectives. | | A valient effort aimed to deal with a real problem in most | (if not all) stream i/o implementations. | | However, trying to get everyone in sync with this and having the | changes ripple through to compilers, libraries, etc will/would take | years. | | I think that efforts would be more fruitful if directed to fixing | the problem given the tools we currently have. | | I would like to see a couple of sets of num_put/num_get facets | which implement the following: | | a) mapping of Nan's to some agreed upon strings such as you | use in your proposal. | | b) trapping of Nan's on output. | | When users created the a stream, they could do one of the following | | a) nothing - use the current setup | b) use the "standardized mapping facets" | c) use the "trapping facets" | | This would permit one to choose the best behavior for the | current application. | | It's not that I'm against making a submission to the standard, I just | don't think that a "standard" solution is going to really address the | problem - its not one size fits all. | | Robert Ramey I agree strongly - I'd be delighted to see what you suggest, asap. (An exercise for a 'student'?) But I think my 'size' may fit many, so I think trying to get it in the Standard is also a good idea. (It should never have been left as a muddle like this to start IMO. The Standard should have said 'if you want to do this, do it like this'). A working implementation showing its usefulness would be powerful persuader for WG21. (VisualAge appears to come close already - is anyone using it with Boost.Serialization?) (Preparing this was my 'reward' for attending a BSI WG21 meeting - if I'd kept my mouth shut I wouldn't have got a homework job ;-) Paul --- Paul A Bristow Prizet Farmhouse, Kendal, Cumbria UK LA8 8AB +44 1539561830 & SMS, Mobile +44 7714 330204 & SMS