Boost logo

Boost Users :

From: Tom Matelich (tmatelich_at_[hidden])
Date: 2003-03-28 16:36:28


Well, actually, looks like it lies elsewhere. I rolled back to 1.29.0 and
its still broken :(

> -----Original Message-----
> From: Terje Slettebų [mailto:tslettebo_at_[hidden]]
> Sent: Wednesday, March 26, 2003 9:15 PM
> To: Boost-Users_at_[hidden]
> Subject: Re: [Boost-Users] Problem with 1.30.0 lexical_cast
>
>
> >From: "Tom Matelich" <tmatelich_at_[hidden]>
>
> > Compiler: gcc 3.2 and 3.2.2
> >
> > I believe this is actually a bug in gcc, but I'm going to
> post it hopes
> that
> > someone can help me. We have a handy little tool for
> generating enums
> with
> > associated string conversion and stream
> insertion/extraction functions.
> > When we upgraded to boost 1.30.0, lexical_cast'ing one of
> these enums to
> > std::string started behaving incorrectly, rather than the
> name, it is
> giving
> > me the integral value. It seems that the lexical_stream is
> being used.
> > Unfortunately, my test case is working fine. The complete test case
> > (including definition of ZAcquisition::PPG) is appended at
> the end. The
> > code I am seeing failure with looks like:
> >
> > void foo(ZAcquisition::PPG::Type gt)
> > {
> > ...
> > std::string str;
> > str = boost::lexical_cast<std::string>(gt);
> > std::cerr << "DEBUG, storing encode for PPG: " << str <<
> ", aka " << gt
> > << std::endl;
> > ...
> > }
> >
> > This outputs (for example):
> > DEBUG, storing encode for PPG: 0, aka ONE
> >
> > I tried boost::lexical_cast<std::string,
> ZAcquisition::PPG::Type>(gt) as
> > well.
> >
> > Anyone have any ideas? For now I'm going to back out to 1.29.0's
> > lexical_cast.
>
> > It happens on my Windows/Intel 7.0 box as well.
>
> It's a little difficult when you don't have a failing test
> case. If you had
> that, I could have looked into it. The above code works
> correctly on Intel
> C++ 7.0 (Windows), here.
>
>
> Regards,
>
> Terje
>
>
> ------------------------ Yahoo! Groups Sponsor
> ---------------------~-->
> Get 128 Bit SSL Encryption!
> http://us.click.yahoo.com/xaxhjB/hdqFAA/xGHJAA/EbFolB/TM
> --------------------------------------------------------------
> -------~->
>
> Info: <http://www.boost.org>
> Wiki: <http://www.crystalclearsoftware.com/cgi-bin/boost_wiki/wiki.pl>
> Unsubscribe: <mailto:boost-users-unsubscribe_at_[hidden]>
>
>
> Your use of Yahoo! Groups is subject to
> http://docs.yahoo.com/info/terms/
>
>
-----------------------------------------------------------------------
DISCLAIMER: Information contained in this message and/or
attachment(s) may contain confidential information of Zetec, Inc.
If you have received this transmission in error, please notify
the sender by return email.
-----------------------------------------------------------------------


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net