GCC Bugzilla – Attachment 11912 Details for
Bug 19664
libstdc++ headers should have pop/push of the visibility around the declarations
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
Remember
[x]
|
Forgot Password
Login:
[x]
[patch]
viz patch part one
p.20060718-2 (text/plain), 7.31 KB, created by
Benjamin Kosnik
on 2006-07-19 02:52:10 UTC
(
hide
)
Description:
viz patch part one
Filename:
MIME Type:
Creator:
Benjamin Kosnik
Created:
2006-07-19 02:52:10 UTC
Size:
7.31 KB
patch
obsolete
>2006-07-18 Benjamin Kosnik <bkoz@redhat.com> > > * include/bits/c++config (_GLIBCXX_VISIBILITY): New. > (_GLIBCXX_BEGIN_NAMESPACE): Use it. > (_GLIBCXX_END_NAMESPACE): Use it. > (_GLIBCXX_BEGIN_NESTED_NAMESPACE): Use it. > (_GLIBCXX_END_NESTED_NAMESPACE): Use it. > * src/debug.cc: Mark __gnu_internal namespace with hidden > visibility attribute. > * src/ext-inst.cc: Same. > * src/globals_io.cc: Same. > * src/globals_locale.cc: Same. > * src/ios_init.cc: Same. > * src/locale.cc: Same. > * src/mt_allocator.cc: Same. > * src/pool_allocator.cc: Same. > >Index: include/bits/c++config >=================================================================== >--- include/bits/c++config (revision 115576) >+++ include/bits/c++config (working copy) >@@ -40,6 +40,9 @@ > // The current version of the C++ library in compressed ISO date format. > #define __GLIBCXX__ > >+// Macros for namespace visibility. >+#define _GLIBCXX_VISIBILITY(V) __attribute__ ((__visibility__ (#V))) >+ > // Macros for controlling various namespace association schemes and modes. > #ifdef _GLIBCXX_DEBUG > # define _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG 1 >@@ -53,15 +56,15 @@ > // _GLIBCXX_BEGIN_NESTED_NAMESPACE > // _GLIBCXX_END_NESTED_NAMESPACE > #if _GLIBCXX_NAMESPACE_ASSOCIATION_VERSION >-# define _GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y) namespace X { namespace Y { >+# define _GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y) namespace X { namespace Y _GLIBCXX_VISIBILITY(default) { > # define _GLIBCXX_END_NESTED_NAMESPACE } } > # define _GLIBCXX_BEGIN_NAMESPACE(X) _GLIBCXX_BEGIN_NESTED_NAMESPACE(X, _6) > # define _GLIBCXX_END_NAMESPACE _GLIBCXX_END_NESTED_NAMESPACE > #else >-# define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X { >+# define _GLIBCXX_BEGIN_NAMESPACE(X) namespace X _GLIBCXX_VISIBILITY(default) { > # define _GLIBCXX_END_NAMESPACE } > # if _GLIBCXX_NAMESPACE_ASSOCIATION_DEBUG >-# define _GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y) namespace X { namespace Y { >+# define _GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y) namespace X { namespace Y _GLIBCXX_VISIBILITY(default) { > # define _GLIBCXX_END_NESTED_NAMESPACE } } > # else > # define _GLIBCXX_BEGIN_NESTED_NAMESPACE(X, Y) _GLIBCXX_BEGIN_NAMESPACE(X) >Index: src/globals_locale.cc >=================================================================== >--- src/globals_locale.cc (revision 115576) >+++ src/globals_locale.cc (working copy) >@@ -1,4 +1,4 @@ >-// Copyright (C) 2001, 2002, 2003, 2004 Free Software Foundation, Inc. >+// Copyright (C) 2001, 2002, 2003, 2004, 2006 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 >@@ -43,7 +43,7 @@ > // In macro form: > // _GLIBCXX_ASM_SYMVER(currentname, oldname, GLIBCXX_3.2) > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > using namespace std; > >Index: src/pool_allocator.cc >=================================================================== >--- src/pool_allocator.cc (revision 115576) >+++ src/pool_allocator.cc (working copy) >@@ -1,6 +1,6 @@ > // Allocator details. > >-// Copyright (C) 2004, 2005 Free Software Foundation, Inc. >+// Copyright (C) 2004, 2005, 2006 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 >@@ -35,7 +35,7 @@ > #include <cstdlib> > #include <ext/pool_allocator.h> > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > static __glibcxx_mutex_define_initialized(palloc_init_mutex); > } >Index: src/mt_allocator.cc >=================================================================== >--- src/mt_allocator.cc (revision 115576) >+++ src/mt_allocator.cc (working copy) >@@ -1,6 +1,6 @@ > // Allocator details. > >-// Copyright (C) 2004, 2005 Free Software Foundation, Inc. >+// Copyright (C) 2004, 2005, 2006 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 >@@ -35,7 +35,7 @@ > #include <bits/concurrence.h> > #include <ext/mt_allocator.h> > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > #ifdef __GTHREADS > struct __freelist >Index: src/locale_init.cc >=================================================================== >--- src/locale_init.cc (revision 115576) >+++ src/locale_init.cc (working copy) >@@ -1,4 +1,4 @@ >-// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 >+// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006 > // Free Software Foundation, Inc. > // > // This file is part of the GNU ISO C++ Library. This library is free >@@ -35,7 +35,7 @@ > #include <bits/atomicity.h> > #include <bits/concurrence.h> > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > // Defined in globals.cc. > extern std::locale c_locale; >Index: src/locale.cc >=================================================================== >--- src/locale.cc (revision 115576) >+++ src/locale.cc (working copy) >@@ -35,7 +35,7 @@ > #include <bits/atomicity.h> > #include <bits/concurrence.h> > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > // Mutex object for cache access > static __glibcxx_mutex_define_initialized(locale_cache_mutex); >Index: src/globals_io.cc >=================================================================== >--- src/globals_io.cc (revision 115576) >+++ src/globals_io.cc (working copy) >@@ -1,4 +1,5 @@ >-// Copyright (C) 2001, 2002, 2003, 2004, 2005 Free Software Foundation, Inc. >+// Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006 >+// 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 >@@ -75,7 +76,7 @@ > > _GLIBCXX_END_NAMESPACE > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > using namespace std; > using namespace __gnu_cxx; >Index: src/ext-inst.cc >=================================================================== >--- src/ext-inst.cc (revision 115576) >+++ src/ext-inst.cc (working copy) >@@ -1,6 +1,6 @@ > // Explicit instantiation file. > >-// Copyright (C) 2001, 2002, 2004 Free Software Foundation, Inc. >+// Copyright (C) 2001, 2002, 2004, 2006 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 >@@ -34,7 +34,7 @@ > #include <ext/rope> > #include <ext/stdio_filebuf.h> > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > const int min_len = __gnu_cxx::_Rope_constants::_S_max_rope_depth + 1; > } >Index: src/ios_init.cc >=================================================================== >--- src/ios_init.cc (revision 115576) >+++ src/ios_init.cc (working copy) >@@ -40,7 +40,7 @@ > #include <ext/stdio_filebuf.h> > #include <ext/stdio_sync_filebuf.h> > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > using namespace __gnu_cxx; > >Index: src/debug.cc >=================================================================== >--- src/debug.cc (revision 115576) >+++ src/debug.cc (working copy) >@@ -39,7 +39,7 @@ > > using namespace std; > >-namespace __gnu_internal >+namespace __gnu_internal _GLIBCXX_VISIBILITY(hidden) > { > static __glibcxx_mutex_define_initialized(iterator_base_mutex); > } // namespace __gnu_internal
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 19664
:
8908
|
8909
|
8934
|
10085
|
10094
|
10120
| 11912