[uClibc] uClibc++ update

James A. Beaulieu beaulieu at ti.com
Wed Dec 22 18:22:45 UTC 2004


Greetings.

I believe that I have found a small bug with the string class. It appears that 
the substr method does not compile properly. Adding the following code inside 
of the stringtest.cpp file (and performing "make test") triggers the problem:

 std::cout << "Testing substr\n" << std::endl;
 std::cout << "Substr: \"" << a.substr(5,5) << "\"" << std::endl;

The error reportiing on my system is:
make[1]: Entering directory 
`/home/beaulieu/src/uclibc/uclibc++/uClibc++/tests'
g++ -c  -Wall -Wno-trigraphs -W -pedantic  -Os     -fno-builtin -nostdinc++ 
-ansi -I../include -fPIC -o stringtest.o stringtest.cpp
In file included from stringtest.cpp:58:
../include/string: In member function `std::basic_string<Ch, Tr, A> 
   std::basic_string<Ch, Tr, A>::substr(typename A::size_type, typename 
   A::size_type) const [with Ch = char, Tr = std::char_traits<char>, A = 
   std::allocator<char>]':
../include/ostream:57:   instantiated from here
../include/string:489: error: invalid use of member (did you forget the `&' ?)
make[1]: *** [stringtest.o] Error 1
make[1]: Leaving directory `/home/beaulieu/src/uclibc/uclibc++/uClibc++/tests'


I can reproduce this both on my development machine, as well as with an 
embedded uclibc system.

Thanks

Jim

On Tuesday 30 November 2004 03:53 pm, Garrett Kajmowicz wrote:
> This is a reatively minor update which addresses a bug just found in the
> fstream class.  You can grab the latest version of the code for uClibc++ at
> http://cxx.uclibc.org/download.html
>
> - Garrett Kajmowicz

-- 
James A. Beaulieu
Texas Instruments, Inc.
20450 Century Blvd
Germantown, MD. 20874
301.515.3735
beaulieu at ti.com



More information about the uClibc mailing list