7.cc: New.

2003-07-01  Jerry Quinn  <jlquinn@optonline.net>

	* 22_locale/num_put/put/char/7.cc: New.
	* 22_locale/num_put/put/wchar_t/7.cc: New.

From-SVN: r68762
This commit is contained in:
Jerry Quinn 2003-07-01 05:44:42 +00:00 committed by Jerry Quinn
parent e97ee22ea5
commit 5ee78c21f1
3 changed files with 88 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2003-07-01 Jerry Quinn <jlquinn@optonline.net>
* 22_locale/num_put/put/char/7.cc: New.
* 22_locale/num_put/put/wchar_t/7.cc: New.
2003-06-30 Jerry Quinn <jlquinn@optonline.net>
* src/locale.cc (__use_cache<numpunct>): Revert previous relocation.

View File

@ -0,0 +1,41 @@
// 2003-06-30 peturr02@ru.is
// Copyright (C) 2003 Free Software Foundation
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING. If not, write to the Free
// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
// USA.
#include <iostream>
#include <locale>
// libstdc++/9828
void test01()
{
using namespace std;
typedef num_put<char> np_t;
ostringstream stream;
const np_t& np = use_facet<np_t>(stream.getloc());
np.put(stream, wcout, ' ', static_cast<long>(10));
VERIFY( stream.str() == ' ');
}
int main()
{
test01();
return 0;
}

View File

@ -0,0 +1,42 @@
// 2003-06-30 peturr02@ru.is
// Copyright (C) 2003 Free Software Foundation
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
// terms of the GNU General Public License as published by the
// Free Software Foundation; either version 2, or (at your option)
// any later version.
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
// GNU General Public License for more details.
// You should have received a copy of the GNU General Public License along
// with this library; see the file COPYING. If not, write to the Free
// Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307,
// USA.
#include <sstream>
#include <iostream>
#include <locale>
// libstdc++/9828
void test01()
{
using namespace std;
typedef num_put<wchar_t> npw_t;
wostringstream stream;
const npw_t& npw = use_facet<npw_t>(stream.getloc());
npw.put(stream, cout, L' ', static_cast<long>(10));
VERIFY( stream.str() == L' ');
}
int main()
{
test01();
return 0;
}