Commit 5b5e609d by Benjamin Kosnik

[multiple changes]


2001-12-04  Benjamin Kosnik  <bkoz@redhat.com>

	* src/Makefile.am (sources): Add ext-inst.cc.
	* src/Makefile.in: Regenerate.
	* src/ext-inst.cc: New file.
	* include/bits/stl_threads.h: Format.
	* src/globals.cc: Add instantiation for _S_swap_lock.

	* testsuite/18_support/numeric_limits.cc: Add numeric_limits<B>
	instantiation.

2001-12-04  John David Anglin  <dave@hiauly1.hia.nrc.ca>

	* testsuite/22_locale/numpunct_members_wchar_t.cc: Only compile
	and execute test01 if _GLIBCPP_USE_WCHAR_T is defined.
	* testsuite/26_numerics/complex_inserters_extractors.cc: Provide
	for explicit instantiation of class std::basic_string<char,
	gnu_char_traits, std::allocator<char> >.

From-SVN: r47622
parent 344c6d1f
2001-12-04 Benjamin Kosnik <bkoz@redhat.com>
* src/Makefile.am (sources): Add ext-inst.cc.
* src/Makefile.in: Regenerate.
* src/ext-inst.cc: New file.
* include/bits/stl_threads.h: Format.
* src/globals.cc: Add instantiation for _S_swap_lock.
* testsuite/18_support/numeric_limits.cc: Add numeric_limits<B>
instantiation.
2001-12-04 John David Anglin <dave@hiauly1.hia.nrc.ca>
* testsuite/22_locale/numpunct_members_wchar_t.cc: Only compile
and execute test01 if _GLIBCPP_USE_WCHAR_T is defined.
* testsuite/26_numerics/complex_inserters_extractors.cc: Provide
for explicit instantiation of class std::basic_string<char,
gnu_char_traits, std::allocator<char> >.
2001-12-03 Benjamin Kosnik <bkoz@redhat.com>
* testsuite/22_locale/collate.cc: Compile-only.
......
......@@ -64,8 +64,9 @@ sources = \
complex_io.cc functexcept.cc globals.cc ios.cc limits.cc \
locale.cc locale-inst.cc localename.cc \
collate.cc messages.cc moneypunct.cc numpunct.cc time.cc \
vterminate.cc \
misc-inst.cc stdexcept.cc stl-inst.cc string-inst.cc strstream.cc \
valarray-inst.cc wstring-inst.cc concept-inst.cc vterminate.cc
valarray-inst.cc wstring-inst.cc concept-inst.cc ext-inst.cc
VPATH = $(top_srcdir)/src:$(top_srcdir)
......
......@@ -189,8 +189,9 @@ sources = \
complex_io.cc functexcept.cc globals.cc ios.cc limits.cc \
locale.cc locale-inst.cc localename.cc \
collate.cc messages.cc moneypunct.cc numpunct.cc time.cc \
vterminate.cc \
misc-inst.cc stdexcept.cc stl-inst.cc string-inst.cc strstream.cc \
valarray-inst.cc wstring-inst.cc concept-inst.cc vterminate.cc
valarray-inst.cc wstring-inst.cc concept-inst.cc ext-inst.cc
VPATH = $(top_srcdir)/src:$(top_srcdir)
......@@ -266,9 +267,9 @@ LIBS = @LIBS@
libstdc___la_OBJECTS = basic_file.lo bitset.lo c++locale.lo cmath.lo \
codecvt.lo complex_io.lo functexcept.lo globals.lo ios.lo limits.lo \
locale.lo locale-inst.lo localename.lo collate.lo messages.lo \
moneypunct.lo numpunct.lo time.lo misc-inst.lo stdexcept.lo stl-inst.lo \
string-inst.lo strstream.lo valarray-inst.lo wstring-inst.lo \
concept-inst.lo vterminate.lo
moneypunct.lo numpunct.lo time.lo vterminate.lo misc-inst.lo \
stdexcept.lo stl-inst.lo string-inst.lo strstream.lo valarray-inst.lo \
wstring-inst.lo concept-inst.lo ext-inst.lo
CXXFLAGS = @CXXFLAGS@
CXXCOMPILE = $(CXX) $(DEFS) $(INCLUDES) $(AM_CPPFLAGS) $(CPPFLAGS) $(AM_CXXFLAGS) $(CXXFLAGS)
CXXLD = $(CXX)
......
// Explicit instantiation file.
// Copyright (C) 2001 Free Software Foundation, Inc.
//
// 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.
// As a special exception, you may use this file as part of a free software
// library without restriction. Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License. This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.
//
// ISO C++ 14882:
//
#include <ext/rope>
namespace std
{
template const unsigned long rope<char, std::allocator<char> >::_S_min_len;
} // namespace std
......@@ -93,8 +93,9 @@ namespace std
// function call to initialize a mutex. For example, see stl_threads.h.
#if __GTHREADS
#ifdef __GTHREAD_MUTEX_INIT
// This path is not needed since static initialization of mutexs works
// on this platform.
// Need to provide explicit instantiations of static data for
// systems with broken weak linkage support.
template __gthread_mutex_t _Swap_lock_struct<0>::_S_swap_lock;
#elif defined(__GTHREAD_MUTEX_INIT_FUNCTION)
__gthread_once_t _GLIBCPP_once = __GTHREAD_ONCE_INIT;
__gthread_mutex_t _GLIBCPP_mutex;
......
......@@ -21,8 +21,7 @@
// As a special exception, you may use this file as part of a free software
// library without restriction. Specifically, if other files instantiate
// templates or use macros or inline functions from this file, or you compile
// this file and link it with other files to produce an executable, this
// file does not by itself cause the resulting executable to be covered by
// this file and link it with other files to produce an executable, this// file does not by itself cause the resulting executable to be covered by
// the GNU General Public License. This exception does not however
// invalidate any other reasons why the executable file might be covered by
// the GNU General Public License.
......
......@@ -92,7 +92,10 @@ template<typename T>
operator==(int i) { return i == key; }
};
struct B { };
struct B
{
B(int i = 0) { }
};
bool test01()
......@@ -139,6 +142,8 @@ bool test01()
}
// test linkage of the generic bits
template struct std::numeric_limits<B>;
void test02()
{
typedef std::numeric_limits<B> b_nl_type;
......@@ -176,3 +181,9 @@ int main()
return 0;
}
......@@ -26,6 +26,7 @@
// XXX This test is not working for non-glibc locale models.
// { dg-do run { xfail *-*-* } }
#ifdef _GLIBCPP_USE_WCHAR_T
void test01()
{
using namespace std;
......@@ -79,10 +80,12 @@ void test01()
VERIFY( dp2 != dp4 );
VERIFY( th2 != th4 );
}
#endif
int main()
{
#ifdef _GLIBCPP_USE_WCHAR_T
test01();
#endif
return 0;
}
......@@ -106,6 +106,7 @@ struct gnu_char_traits : public std::char_traits<char>
{ };
typedef std::basic_ostringstream<char, gnu_char_traits> gnu_sstream;
template class std::basic_string<char, gnu_char_traits, std::allocator<char> >;
void test02()
{
......@@ -143,3 +144,6 @@ main()
return 0;
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment