Commit 8eead16e by Benjamin Kosnik Committed by Benjamin Kosnik

user.cfg.in: Regenerate, add files.

2009-11-09  Benjamin Kosnik  <bkoz@redhat.com>

	* doc/doxygen/user.cfg.in: Regenerate, add files.
	* libsupc++/eh_ptr.cc: Format.
	* libsupc++/exception_ptr.h: Same.
	* libsupc++/cxxabi.h(recursive_init_error): Move declaration here.
	* libsupc++/guard.cc: From here.
	* libsupc++/nested_exception.h: Add markup.

From-SVN: r154054
parent 3f08607c
2009-11-09 Benjamin Kosnik <bkoz@redhat.com>
* doc/doxygen/user.cfg.in: Regenerate, add files.
* libsupc++/eh_ptr.cc: Format.
* libsupc++/exception_ptr.h: Same.
* libsupc++/cxxabi.h(recursive_init_error): Move declaration here.
* libsupc++/guard.cc: From here.
* libsupc++/nested_exception.h: Add markup.
2009-11-09 Johannes Singler <singler@kit.edu>
* include/parallel/multiway_merge.h (multiway_merge_*,
......
# Doxyfile 1.5.8
# Doxyfile 1.6.1
# This file describes the settings to be used by the documentation system
# doxygen (www.doxygen.org) for a project
......@@ -54,11 +54,11 @@ CREATE_SUBDIRS = NO
# information to generate all constant output in the proper language.
# The default language is English, other supported languages are:
# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional,
# Croatian, Czech, Danish, Dutch, Farsi, Finnish, French, German, Greek,
# Hungarian, Italian, Japanese, Japanese-en (Japanese with English messages),
# Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, Polish,
# Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak, Slovene,
# Spanish, Swedish, and Ukrainian.
# Croatian, Czech, Danish, Dutch, Esperanto, Farsi, Finnish, French, German,
# Greek, Hungarian, Italian, Japanese, Japanese-en (Japanese with English
# messages), Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian,
# Polish, Portuguese, Romanian, Russian, Serbian, Serbian-Cyrilic, Slovak,
# Slovene, Spanish, Swedish, Ukrainian, and Vietnamese.
OUTPUT_LANGUAGE = English
......@@ -69,11 +69,10 @@ OUTPUT_LANGUAGE = English
BRIEF_MEMBER_DESC = NO
# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will
# prepend the brief description of a member or function before the
# detailed description. Note: if both HIDE_UNDOC_MEMBERS and
# BRIEF_MEMBER_DESC are set to NO, the brief descriptions will be
# completely suppressed.
# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend
# the brief description of a member or function before the detailed description.
# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the
# brief descriptions will be completely suppressed.
REPEAT_BRIEF = YES
......@@ -183,10 +182,10 @@ TAB_SIZE = 4
ALIASES = "doctodo=@todo\nDoc me! See doc/doxygen/TODO and http://gcc.gnu.org/ml/libstdc++/2002-02/msg00003.html for more. " \
"isiosfwd=One of the @link ios I/O @endlink "
# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of
# C sources only. Doxygen will then generate output that is more
# tailored for C. For instance, some of the names that are used will
# be different. The list of all members will be omitted, etc.
# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C
# sources only. Doxygen will then generate output that is more tailored for C.
# For instance, some of the names that are used will be different. The list
# of all members will be omitted, etc.
OPTIMIZE_OUTPUT_FOR_C = NO
......@@ -209,15 +208,14 @@ OPTIMIZE_FOR_FORTRAN = NO
OPTIMIZE_OUTPUT_VHDL = NO
# Doxygen selects the parser to use depending on the extension of the
# files it parses. With this tag you can assign which parser to use
# for a given extension. Doxygen has a built-in mapping, but you can
# override or extend it using this tag. The format is ext=language,
# where ext is a file extension, and language is one of the parsers
# supported by doxygen: IDL, Java, Javascript, C#, C, C++, D, PHP,
# Objective-C, Python, Fortran, VHDL, C, C++. For instance to make
# doxygen treat .inc files as Fortran files (default is PHP), and .f
# files as C (default is Fortran), use: inc=Fortran f=C
# Doxygen selects the parser to use depending on the extension of the files it parses.
# With this tag you can assign which parser to use for a given extension.
# Doxygen has a built-in mapping, but you can override or extend it using this tag.
# The format is ext=language, where ext is a file extension, and language is one of
# the parsers supported by doxygen: IDL, Java, Javascript, C#, C, C++, D, PHP,
# Objective-C, Python, Fortran, VHDL, C, C++. For instance to make doxygen treat
# .inc files as Fortran files (default is PHP), and .f files as C (default is Fortran),
# use: inc=Fortran f=C. Note that for custom extensions you also need to set FILE_PATTERNS otherwise the files are not read by doxygen.
EXTENSION_MAPPING =
......@@ -235,20 +233,18 @@ BUILTIN_STL_SUPPORT = NO
CPP_CLI_SUPPORT = NO
# Set the SIP_SUPPORT tag to YES if your project consists of sip
# sources only. Doxygen will parse them like normal C++ but will
# assume all classes use public instead of private inheritance when no
# explicit protection keyword is present.
# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only.
# Doxygen will parse them like normal C++ but will assume all classes use public
# instead of private inheritance when no explicit protection keyword is present.
SIP_SUPPORT = NO
# For Microsoft's IDL there are propget and propput attributes to
# indicate getter and setter methods for a property. Setting this
# option to YES (the default) will make doxygen to replace the get and
# set methods by a property in the documentation. This will only work
# if the methods are indeed getting or setting a simple type. If this
# is not the case, or you want to show the methods anyway, you should
# set this option to NO.
# For Microsoft's IDL there are propget and propput attributes to indicate getter
# and setter methods for a property. Setting this option to YES (the default)
# will make doxygen to replace the get and set methods by a property in the
# documentation. This will only work if the methods are indeed getting or
# setting a simple type. If this is not the case, or you want to show the
# methods anyway, you should set this option to NO.
IDL_PROPERTY_SUPPORT = YES
......@@ -267,29 +263,27 @@ DISTRIBUTE_GROUP_DOC = YES
SUBGROUPING = YES
# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union,
# or enum is documented as struct, union, or enum with the name of the
# typedef. So typedef struct TypeS {} TypeT, will appear in the
# documentation as a struct with name TypeT. When disabled the typedef
# will appear as a member of a file, namespace, or class. And the
# struct will be named TypeS. This can typically be useful for C code
# in case the coding convention dictates that all compound types are
# typedef'ed and only the typedef is referenced, never the tag name.
# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum
# is documented as struct, union, or enum with the name of the typedef. So
# typedef struct TypeS {} TypeT, will appear in the documentation as a struct
# with name TypeT. When disabled the typedef will appear as a member of a file,
# namespace, or class. And the struct will be named TypeS. This can typically
# be useful for C code in case the coding convention dictates that all compound
# types are typedef'ed and only the typedef is referenced, never the tag name.
TYPEDEF_HIDES_STRUCT = NO
# The SYMBOL_CACHE_SIZE determines the size of the internal cache use
# to determine which symbols to keep in memory and which to flush to
# disk. When the cache is full, less often used symbols will be
# written to disk. For small to medium size projects (<1000 input
# files) the default value is probably good enough. For larger
# projects a too small cache size can cause doxygen to be busy
# swapping symbols to and from disk most of the time causing a
# significant performance penality. If the system has enough physical
# memory increasing the cache will improve the performance by keeping
# more symbols in memory. Note that the value works on a logarithmic
# scale so increasing the size by one will rougly double the memory
# usage. The cache size is given by this formula:
# The SYMBOL_CACHE_SIZE determines the size of the internal cache use to
# determine which symbols to keep in memory and which to flush to disk.
# When the cache is full, less often used symbols will be written to disk.
# For small to medium size projects (<1000 input files) the default value is
# probably good enough. For larger projects a too small cache size can cause
# doxygen to be busy swapping symbols to and from disk most of the time
# causing a significant performance penality.
# If the system has enough physical memory increasing the cache will improve the
# performance by keeping more symbols in memory. Note that the value works on
# a logarithmic scale so increasing the size by one will rougly double the
# memory usage. The cache size is given by this formula:
# 2^(16+SYMBOL_CACHE_SIZE). The valid range is 0..9, the default is 0,
# corresponding to a cache size of 2^16 = 65536 symbols
......@@ -412,6 +406,10 @@ SORT_MEMBER_DOCS = YES
SORT_BRIEF_DOCS = YES
# If the SORT_MEMBERS_CTORS_1ST tag is set to YES then doxygen will sort the (brief and detailed) documentation of class members so that constructors and destructors are listed first. If set to NO (the default) the constructors will appear in the respective orders defined by SORT_MEMBER_DOCS and SORT_BRIEF_DOCS. This tag will be ignored for brief docs if SORT_BRIEF_DOCS is set to NO and ignored for detailed docs if SORT_MEMBER_DOCS is set to NO.
SORT_MEMBERS_CTORS_1ST = YES
# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the
# hierarchy of group names into alphabetical order. If set to NO (the default)
# the group names will appear in their defined order.
......@@ -473,9 +471,9 @@ MAX_INITIALIZER_LINES = 0
SHOW_USED_FILES = YES
# If the sources in your project are distributed over multiple
# directories then setting the SHOW_DIRECTORIES tag to YES will show
# the directory hierarchy in the documentation. The default is NO.
# If the sources in your project are distributed over multiple directories
# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy
# in the documentation. The default is NO.
SHOW_DIRECTORIES = YES
......@@ -492,24 +490,22 @@ SHOW_FILES = YES
SHOW_NAMESPACES = YES
# The FILE_VERSION_FILTER tag can be used to specify a program or
# script that doxygen should invoke to get the current version for
# each file (typically from the version control system). Doxygen will
# invoke the program by executing (via popen()) the command <command>
# <input-file>, where <command> is the value of the
# FILE_VERSION_FILTER tag, and <input-file> is the name of an input
# file provided by doxygen. Whatever the program writes to standard
# output is used as the file version. See the manual for examples.
# The FILE_VERSION_FILTER tag can be used to specify a program or script that
# doxygen should invoke to get the current version for each file (typically from
# the version control system). Doxygen will invoke the program by executing (via
# popen()) the command <command> <input-file>, where <command> is the value of
# the FILE_VERSION_FILTER tag, and <input-file> is the name of an input file
# provided by doxygen. Whatever the program writes to standard output
# is used as the file version. See the manual for examples.
FILE_VERSION_FILTER =
# The LAYOUT_FILE tag can be used to specify a layout file which will
# be parsed by doxygen. The layout file controls the global structure
# of the generated output files in an output format independent
# way. The create the layout file that represents doxygen's defaults,
# run doxygen with the -l option. You can optionally specify a file
# name after the option, if omitted DoxygenLayout.xml will be used as
# the name of the layout file.
# The LAYOUT_FILE tag can be used to specify a layout file which will be parsed by
# doxygen. The layout file controls the global structure of the generated output files
# in an output format independent way. The create the layout file that represents
# doxygen's defaults, run doxygen with the -l option. You can optionally specify a
# file name after the option, if omitted DoxygenLayout.xml will be used as the name
# of the layout file.
LAYOUT_FILE =
......@@ -568,10 +564,10 @@ WARN_LOGFILE =
# configuration options related to the input files
#---------------------------------------------------------------------------
# The INPUT tag can be used to specify the files and/or directories
# that contain documented source files. You may enter file names like
# "myfile.cpp" or directories like "/usr/src/myproject". Separate the
# files or directories with spaces.
# The INPUT tag can be used to specify the files and/or directories that contain
# documented source files. You may enter file names like "myfile.cpp" or
# directories like "/usr/src/myproject". Separate the files or directories
# with spaces.
INPUT = @srcdir@/doc/doxygen/doxygroups.cc \
@srcdir@/libsupc++/cxxabi.h \
......@@ -579,6 +575,7 @@ INPUT = @srcdir@/doc/doxygen/doxygroups.cc \
@srcdir@/libsupc++/exception \
@srcdir@/libsupc++/exception_ptr.h \
@srcdir@/libsupc++/initializer_list \
@srcdir@/libsupc++/nested_exception.h \
@srcdir@/libsupc++/new \
@srcdir@/libsupc++/typeinfo \
include/algorithm \
......@@ -843,10 +840,10 @@ FILTER_SOURCE_FILES = NO
# configuration options related to source browsing
#---------------------------------------------------------------------------
# If the SOURCE_BROWSER tag is set to YES then a list of source files
# will be generated. Documented entities will be cross-referenced with
# these sources. Note: To get rid of all source code in the generated
# output, make sure also VERBATIM_HEADERS is set to NO.
# If the SOURCE_BROWSER tag is set to YES then a list of source files will
# be generated. Documented entities will be cross-referenced with these sources.
# Note: To get rid of all source code in the generated output, make sure also
# VERBATIM_HEADERS is set to NO.
SOURCE_BROWSER = YES
......@@ -951,6 +948,11 @@ HTML_HEADER =
HTML_FOOTER =
# If the HTML_TIMESTAMP tag is set to YES then the generated HTML
# documentation will contain the timesstamp.
HTML_TIMESTAMP = NO
# The HTML_STYLESHEET tag can be used to specify a user-defined cascading
# style sheet that is used by each HTML page. It can be used to
# fine-tune the look of the HTML output. If the tag is left blank doxygen
......@@ -976,21 +978,20 @@ HTML_DYNAMIC_SECTIONS = NO
# If the GENERATE_DOCSET tag is set to YES, additional index files
# will be generated that can be used as input for Apple's Xcode 3
# integrated development environment, introduced with OSX 10.5
# (Leopard). To create a documentation set, doxygen will generate a
# Makefile in the HTML output directory. Running make will produce the
# docset in that directory and running "make install" will install the
# docset in ~/Library/Developer/Shared/Documentation/DocSets so that
# Xcode will find it at startup. See
# http://developer.apple.com/tools/creatingdocsetswithdoxygen.html for
# more information.
# integrated development environment, introduced with OSX 10.5 (Leopard).
# To create a documentation set, doxygen will generate a Makefile in the
# HTML output directory. Running make will produce the docset in that
# directory and running "make install" will install the docset in
# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find
# it at startup.
# See http://developer.apple.com/tools/creatingdocsetswithdoxygen.html for more information.
GENERATE_DOCSET = NO
# When GENERATE_DOCSET tag is set to YES, this tag determines the name
# of the feed. A documentation feed provides an umbrella under which
# multiple documentation sets from a single provider (such as a
# company or product suite) can be grouped.
# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the
# feed. A documentation feed provides an umbrella under which multiple
# documentation sets from a single provider (such as a company or product suite)
# can be grouped.
DOCSET_FEEDNAME = "Doxygen generated docs"
......@@ -1045,11 +1046,10 @@ BINARY_TOC = NO
TOC_EXPAND = NO
# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and
# QHP_VIRTUAL_FOLDER are set, an additional index file will be
# generated that can be used as input for Qt's qhelpgenerator to
# generate a Qt Compressed Help (.qch) of the generated HTML
# documentation.
# If the GENERATE_QHP tag is set to YES and both QHP_NAMESPACE and QHP_VIRTUAL_FOLDER
# are set, an additional index file will be generated that can be used as input for
# Qt's qhelpgenerator to generate a Qt Compressed Help (.qch) of the generated
# HTML documentation.
GENERATE_QHP = NO
......@@ -1071,23 +1071,20 @@ QHP_NAMESPACE = org.doxygen.Project
QHP_VIRTUAL_FOLDER = doc
# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom
# filter to add. For more information please see
# If QHP_CUST_FILTER_NAME is set, it specifies the name of a custom filter to add.
# For more information please see
# http://doc.trolltech.com/qthelpproject.html#custom-filters
QHP_CUST_FILTER_NAME =
# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of
# the custom filter to add.For more information please see <a
# href="http://doc.trolltech.com/qthelpproject.html#custom-filters">Qt
# Help Project / Custom Filters</a>.
# The QHP_CUST_FILT_ATTRS tag specifies the list of the attributes of the custom filter to add.For more information please see
# <a href="http://doc.trolltech.com/qthelpproject.html#custom-filters">Qt Help Project / Custom Filters</a>.
QHP_CUST_FILTER_ATTRS =
# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes
# this project's filter section matches. <a
# href="http://doc.trolltech.com/qthelpproject.html#filter-attributes">Qt
# Help Project / Filter Attributes</a>.
# The QHP_SECT_FILTER_ATTRS tag specifies the list of the attributes this project's
# filter section matches.
# <a href="http://doc.trolltech.com/qthelpproject.html#filter-attributes">Qt Help Project / Filter Attributes</a>.
QHP_SECT_FILTER_ATTRS =
......@@ -1111,21 +1108,19 @@ ENUM_VALUES_PER_LINE = 4
# The GENERATE_TREEVIEW tag is used to specify whether a tree-like index
# structure should be generated to display hierarchical information.
# If the tag value is set to FRAME, a side panel will be generated
# If the tag value is set to YES, a side panel will be generated
# containing a tree-like index structure (just like the one that
# is generated for HTML Help). For this to work a browser that supports
# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+,
# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are
# probably better off using the HTML help feature. Other possible values
# for this tag are: HIERARCHIES, which will generate the Groups, Directories,
# and Class Hierarchy pages using a tree view instead of an ordered list;
# ALL, which combines the behavior of FRAME and HIERARCHIES; and NONE, which
# disables this behavior completely. For backwards compatibility with previous
# releases of Doxygen, the values YES and NO are equivalent to FRAME and NONE
# respectively.
# JavaScript, DHTML, CSS and frames is required (i.e. any modern browser).
# Windows users are probably better off using the HTML help feature.
GENERATE_TREEVIEW = YES
# By enabling USE_INLINE_TREES, doxygen will generate the Groups, Directories,
# and Class Hierarchy pages using a tree view instead of an ordered list.
USE_INLINE_TREES = NO
# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be
# used to set the initial width (in pixels) of the frame in which the tree
# is shown.
......@@ -1140,6 +1135,13 @@ TREEVIEW_WIDTH = 250
FORMULA_FONTSIZE = 10
# When the SEARCHENGINE tag is enable doxygen will generate a search box for the HTML output. The underlying search engine uses javascript
# and DHTML and should work on any modern browser. Note that when using HTML help (GENERATE_HTMLHELP) or Qt help (GENERATE_QHP)
# there is already a search function so this one should typically
# be disabled.
SEARCHENGINE = NO
#---------------------------------------------------------------------------
# configuration options related to the LaTeX output
#---------------------------------------------------------------------------
......@@ -1216,6 +1218,10 @@ LATEX_BATCHMODE = NO
LATEX_HIDE_INDICES = NO
# If LATEX_SOURCE_CODE is set to YES then doxygen will include source code with syntax highlighting in the LaTeX output. Note that which sources are shown also depends on other settings such as SOURCE_BROWSER.
LATEX_SOURCE_CODE = NO
#---------------------------------------------------------------------------
# configuration options related to the RTF output
#---------------------------------------------------------------------------
......@@ -1449,11 +1455,10 @@ PREDEFINED = __cplusplus \
__glibcxx_class_requires3=// \
__glibcxx_class_requires4=//
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES
# then this tag can be used to specify a list of macro names that
# should be expanded. The macro definition that is found in the
# sources will be used. Use the PREDEFINED tag if you want to use a
# different macro definition.
# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then
# this tag can be used to specify a list of macro names that should be expanded.
# The macro definition that is found in the sources will be used.
# Use the PREDEFINED tag if you want to use a different macro definition.
EXPAND_AS_DEFINED =
......@@ -1545,15 +1550,14 @@ HIDE_UNDOC_RELATIONS = NO
HAVE_DOT = YES
# By default doxygen will write a font called FreeSans.ttf to the
# output directory and reference it in all dot files that doxygen
# generates. This font does not include all possible unicode
# characters however, so when you need these (or just want a
# differently looking font) you can specify the font name using
# DOT_FONTNAME. You need need to make sure dot is able to find the
# font, which can be done by putting it in a standard location or by
# setting the DOTFONTPATH environment variable or by setting
# DOT_FONTPATH to the directory containing the font.
# By default doxygen will write a font called FreeSans.ttf to the output
# directory and reference it in all dot files that doxygen generates. This
# font does not include all possible unicode characters however, so when you need
# these (or just want a differently looking font) you can specify the font name
# using DOT_FONTNAME. You need need to make sure dot is able to find the font,
# which can be done by putting it in a standard location or by setting the
# DOTFONTPATH environment variable or by setting DOT_FONTPATH to the directory
# containing the font.
DOT_FONTNAME = FreeSans
......@@ -1697,19 +1701,10 @@ DOT_MULTI_TARGETS = YES
# generate a legend page explaining the meaning of the various boxes and
# arrows in the dot generated graphs.
GENERATE_LEGEND = NO
GENERATE_LEGEND = YES
# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will
# remove the intermediate dot files that are used to generate
# the various graphs.
DOT_CLEANUP = YES
#---------------------------------------------------------------------------
# Options related to the search engine
#---------------------------------------------------------------------------
# The SEARCHENGINE tag specifies whether or not a search engine should be
# used. If set to NO the values of all tags below this one will be ignored.
SEARCHENGINE = NO
......@@ -100,7 +100,7 @@ namespace __cxxabiv1
void
__cxa_vec_cleanup(void* __array_address, size_t __element_count,
size_t __element_size, __cxa_cdtor_type destructor) _GLIBCXX_NOTHROW;
size_t __s, __cxa_cdtor_type destructor) _GLIBCXX_NOTHROW;
// Destruct and release array.
void
......@@ -601,6 +601,27 @@ namespace __cxxabiv1
*/
namespace abi = __cxxabiv1;
namespace __gnu_cxx
{
/**
* @brief Exception thrown by __cxa_guard_acquire.
* @ingroup exceptions
*
* 6.7[stmt.dcl]/4: If control re-enters the declaration (recursively)
* while the object is being initialized, the behavior is undefined.
*
* Since we already have a library function to handle locking, we might
* as well check for this situation and throw an exception.
* We use the second byte of the guard variable to remember that we're
* in the middle of an initialization.
*/
class recursive_init_error: public std::exception
{
public:
recursive_init_error() throw() { }
virtual ~recursive_init_error() throw ();
};
}
#endif // __cplusplus
#pragma GCC visibility pop
......
......@@ -35,41 +35,30 @@
using namespace __cxxabiv1;
std::__exception_ptr::exception_ptr::exception_ptr() throw()
: _M_exception_object(0)
{
}
: _M_exception_object(0) { }
std::__exception_ptr::exception_ptr::exception_ptr(void* obj) throw()
: _M_exception_object(obj)
{
_M_addref();
}
: _M_exception_object(obj) { _M_addref(); }
std::__exception_ptr::exception_ptr::exception_ptr(__safe_bool) throw()
: _M_exception_object(0)
{
}
: _M_exception_object(0) { }
std::__exception_ptr::exception_ptr::exception_ptr(
const exception_ptr& other) throw()
: _M_exception_object(other._M_exception_object)
{
_M_addref();
}
std::__exception_ptr::
exception_ptr::exception_ptr(const exception_ptr& other) throw()
: _M_exception_object(other._M_exception_object)
{ _M_addref(); }
std::__exception_ptr::exception_ptr::~exception_ptr() throw()
{
_M_release();
}
{ _M_release(); }
std::__exception_ptr::exception_ptr&
std::__exception_ptr::exception_ptr::operator=(
const exception_ptr& other) throw()
std::__exception_ptr::
exception_ptr::operator=(const exception_ptr& other) throw()
{
exception_ptr(other).swap(*this);
return *this;
......@@ -109,15 +98,11 @@ std::__exception_ptr::exception_ptr::_M_release() throw()
void*
std::__exception_ptr::exception_ptr::_M_get() const throw()
{
return _M_exception_object;
}
{ return _M_exception_object; }
void
std::__exception_ptr::exception_ptr::_M_safe_bool_dummy() throw ()
{
}
std::__exception_ptr::exception_ptr::_M_safe_bool_dummy() throw () { }
void
......@@ -132,9 +117,7 @@ std::__exception_ptr::exception_ptr::swap(exception_ptr &other) throw()
// Retained for compatibility with CXXABI_1.3.
bool
std::__exception_ptr::exception_ptr::operator!() const throw()
{
return _M_exception_object == 0;
}
{ return _M_exception_object == 0; }
// Retained for compatibility with CXXABI_1.3.
......@@ -154,16 +137,12 @@ std::__exception_ptr::exception_ptr::__cxa_exception_type() const throw()
bool std::__exception_ptr::operator==(const exception_ptr& lhs,
const exception_ptr& rhs) throw()
{
return lhs._M_exception_object == rhs._M_exception_object;
}
{ return lhs._M_exception_object == rhs._M_exception_object; }
bool std::__exception_ptr::operator!=(const exception_ptr& lhs,
const exception_ptr& rhs) throw()
{
return !(lhs == rhs);
}
{ return !(lhs == rhs);}
std::exception_ptr
......@@ -185,7 +164,7 @@ std::current_exception() throw()
static void
__gxx_dependent_exception_cleanup (_Unwind_Reason_Code code,
__gxx_dependent_exception_cleanup(_Unwind_Reason_Code code,
_Unwind_Exception *exc)
{
// This cleanup is set only for dependents.
......@@ -236,7 +215,7 @@ std::rethrow_exception(std::exception_ptr ep)
// Some sort of unwinding error. Note that terminate is a handler.
__cxa_begin_catch (&dep->unwindHeader);
std::terminate ();
std::terminate();
}
#undef _GLIBCXX_EH_PTR_COMPAT
......
......@@ -48,42 +48,28 @@ namespace std
* @addtogroup exceptions
* @{
*/
// Hide the free operators from other types
namespace __exception_ptr
{
/**
* @brief An opaque pointer to an arbitrary exception.
*/
class exception_ptr;
}
using __exception_ptr::exception_ptr;
/** Obtain an %exception_ptr to the currently handled exception. If there
/** Obtain an exception_ptr to the currently handled exception. If there
* is none, or the currently handled exception is foreign, return the null
* value.
*/
exception_ptr current_exception() throw();
/// Throw the object pointed to by the %exception_ptr.
/// Throw the object pointed to by the exception_ptr.
void rethrow_exception(exception_ptr) __attribute__ ((__noreturn__));
/// Obtain an %exception_ptr pointing to a copy of the supplied object.
template<typename _Ex>
exception_ptr
copy_exception(_Ex __ex) throw();
namespace __exception_ptr
{
bool
operator==(const exception_ptr&, const exception_ptr&)
throw() __attribute__ ((__pure__));
bool
operator!=(const exception_ptr&, const exception_ptr&)
throw() __attribute__ ((__pure__));
/**
* @brief An opaque pointer to an arbitrary exception.
* @ingroup exceptions
*/
class exception_ptr
{
void* _M_exception_object;
......@@ -140,16 +126,24 @@ namespace std
#endif
friend bool
operator==(const exception_ptr&, const exception_ptr&)
throw() __attribute__ ((__pure__));
operator==(const exception_ptr&, const exception_ptr&) throw()
__attribute__ ((__pure__));
const type_info*
__cxa_exception_type() const throw() __attribute__ ((__pure__));
};
bool
operator==(const exception_ptr&, const exception_ptr&) throw()
__attribute__ ((__pure__));
bool
operator!=(const exception_ptr&, const exception_ptr&) throw()
__attribute__ ((__pure__));
} // namespace __exception_ptr
/// Obtain an exception_ptr pointing to a copy of the supplied object.
template<typename _Ex>
exception_ptr
copy_exception(_Ex __ex) throw()
......
......@@ -136,20 +136,6 @@ __set_and_release (__cxxabiv1::__guard *g)
namespace __gnu_cxx
{
// 6.7[stmt.dcl]/4: If control re-enters the declaration (recursively)
// while the object is being initialized, the behavior is undefined.
// Since we already have a library function to handle locking, we might
// as well check for this situation and throw an exception.
// We use the second byte of the guard variable to remember that we're
// in the middle of an initialization.
class recursive_init_error: public std::exception
{
public:
recursive_init_error() throw() { }
virtual ~recursive_init_error() throw ();
};
recursive_init_error::~recursive_init_error() throw() { }
}
......
......@@ -51,9 +51,11 @@ namespace std
* @{
*/
/// nested_exception
/// Exception class with exception_ptr data member.
class nested_exception
{
exception_ptr _M_ptr;
public:
nested_exception() throw() : _M_ptr(current_exception()) { }
......@@ -70,16 +72,12 @@ namespace std
exception_ptr
nested_ptr() const
{ return _M_ptr; }
private:
exception_ptr _M_ptr;
};
template<typename _Except>
struct _Nested_exception : public _Except, public nested_exception
{
explicit
_Nested_exception(_Except&& __ex)
explicit _Nested_exception(_Except&& __ex)
: _Except(static_cast<_Except&&>(__ex))
{ }
};
......@@ -89,9 +87,7 @@ namespace std
{
static const nested_exception*
_S_get(const _Ex& __ex)
{
return dynamic_cast<const nested_exception*>(&__ex);
}
{ return dynamic_cast<const nested_exception*>(&__ex); }
};
template<typename _Ex>
......@@ -99,17 +95,13 @@ namespace std
{
static const nested_exception*
_S_get(const _Ex* __ex)
{
return dynamic_cast<const nested_exception*>(__ex);
}
{ return dynamic_cast<const nested_exception*>(__ex); }
};
template<typename _Ex>
inline const nested_exception*
__get_nested_exception(const _Ex& __ex)
{
return __get_nested_helper<_Ex>::_S_get(__ex);
}
{ return __get_nested_helper<_Ex>::_S_get(__ex); }
template<typename _Ex>
void
......@@ -126,21 +118,19 @@ namespace std
template<typename _Ex>
inline void
__throw_with_nested(_Ex&& __ex, const nested_exception* = 0)
{
throw __ex;
}
{ throw __ex; }
template<typename _Ex>
inline void
__throw_with_nested(_Ex&& __ex, ...)
{
throw _Nested_exception<_Ex>(static_cast<_Ex&&>(__ex));
}
{ throw _Nested_exception<_Ex>(static_cast<_Ex&&>(__ex)); }
template<typename _Ex>
void
throw_with_nested(_Ex __ex) __attribute__ ((__noreturn__));
/// If @p __ex is derived from nested_exception, @p __ex.
/// Else, an implementation-defined object derived from both.
template<typename _Ex>
inline void
throw_with_nested(_Ex __ex)
......@@ -150,6 +140,7 @@ namespace std
__throw_with_nested(static_cast<_Ex&&>(__ex), &__ex);
}
/// If @p __ex is derived from nested_exception, @p __ex.rethrow_nested().
template<typename _Ex>
inline void
rethrow_if_nested(const _Ex& __ex)
......@@ -158,12 +149,10 @@ namespace std
__nested->rethrow_nested();
}
// see n2619
/// Overload, See N2619
inline void
rethrow_if_nested(const nested_exception& __ex)
{
__ex.rethrow_nested();
}
{ __ex.rethrow_nested(); }
// @} group exceptions
} // namespace std
......
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