Add noexcept and constexpr to doxygen to boostbook coversion.

Should really add proper support to boostbook for `=delete`, `=default` and
noexcept, but I'm not feeling that keen right now. I'm not sure I did the right
thing with `BOOST_CONSTEXPR_OR_CONST`.

[SVN r86277]
This commit is contained in:
Daniel James 2013-10-12 20:11:47 +00:00
parent 9eb8e0a68b
commit 78ba0b7b6e
3 changed files with 22 additions and 0 deletions

View File

@ -16,6 +16,12 @@
<method-group name="public member functions"> <method-group name="public member functions">
<method name="virtual_method"><type>virtual int</type></method> <method name="virtual_method"><type>virtual int</type></method>
<method name="method_with_default_value"><type>int</type><parameter name=""><paramtype>int</paramtype><default>default_value</default></parameter></method> <method name="method_with_default_value"><type>int</type><parameter name=""><paramtype>int</paramtype><default>default_value</default></parameter></method>
<method name="trad_noexcept" cv="noexcept"><type>void</type></method>
<method name="boost_noexcept" cv="noexcept"><type>void</type></method>
<method name="trad_constexpr" cv="constexpr"><type>void</type></method>
<method name="boost_constexpr" cv="constexpr"><type>void</type></method>
<method name="boost_constexpr_or_const" cv="constexpr"><type>void</type></method>
<method name="constexpr_noexcept" cv="constexpr noexcept"><type>void</type></method>
<method name="conversion-operator" specifiers="explicit"><type>int</type></method> <method name="conversion-operator" specifiers="explicit"><type>int</type></method>
</method-group> </method-group>
<constructor cv="= default"><parameter name=""><paramtype><classname>example</classname> const &amp;</paramtype></parameter></constructor> <constructor cv="= default"><parameter name=""><paramtype><classname>example</classname> const &amp;</paramtype></parameter></constructor>

View File

@ -37,6 +37,15 @@ namespace example
virtual int virtual_method(); virtual int virtual_method();
int method_with_default_value(int = default_value); int method_with_default_value(int = default_value);
void trad_noexcept() noexcept;
void boost_noexcept() BOOST_NOEXCEPT;
void trad_constexpr() constexpr;
void boost_constexpr() BOOST_CONSTEXPR;
void boost_constexpr_or_const() BOOST_CONSTEXPR_OR_CONST;
void constexpr_noexcept() constexpr noexcept;
int integer; int integer;
static int static_integer; static int static_integer;
mutable int mutable_integer; mutable int mutable_integer;

View File

@ -1071,8 +1071,15 @@
supported in boostbook --> supported in boostbook -->
<!-- The 'substring' trick includes the string if the condition is true --> <!-- The 'substring' trick includes the string if the condition is true -->
<xsl:variable name="cv-qualifiers" select="normalize-space(concat( <xsl:variable name="cv-qualifiers" select="normalize-space(concat(
substring('constexpr ', 1, 999 * (
contains($extra-qualifiers, ' const expr ') or
contains($extra-qualifiers, ' BOOST_CONSTEXPR ') or
contains($extra-qualifiers, ' BOOST_CONSTEXPR_OR_CONST '))),
substring('const ', 1, 999 * (@const=yes)), substring('const ', 1, 999 * (@const=yes)),
substring('volatile ', 1, 999 * (@volatile=yes)), substring('volatile ', 1, 999 * (@volatile=yes)),
substring('noexcept ', 1, 999 * (
contains($extra-qualifiers, ' noexcept ') or
contains($extra-qualifiers, ' BOOST_NOEXCEPT '))),
substring('= delete ', 1, 999 * contains($extra-qualifiers, ' =delete ')), substring('= delete ', 1, 999 * contains($extra-qualifiers, ' =delete ')),
substring('= default ', 1, 999 * contains($extra-qualifiers, ' =default ')), substring('= default ', 1, 999 * contains($extra-qualifiers, ' =default ')),
''))" /> ''))" />