This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: PATCH: Re: iostream changes locale to format a number


Sorry, I sent the wrong testcase (redundant #ifdef). This is what I have 
tested:

#include <clocale>
#include <sstream>
#include <cassert>

void
test0x()
{
  using namespace std;

  bool test = true;

  ostringstream oss;
  string loc1 = setlocale(LC_ALL, "de_DE");
  oss << 1;
  string loc2 = setlocale(LC_ALL, NULL);
  assert( loc1 == loc2 );
}

int main()
{
  test0x();
}

Ciao,
Paolo.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]