mirror of
https://github.com/boostorg/boostbook.git
synced 2025-05-09 15:03:57 +00:00
Avoid confusing arguments with quialifiers from argsstring.
[SVN r86275]
This commit is contained in:
parent
807c6f0c71
commit
0702b53d10
@ -15,6 +15,7 @@
|
||||
<data-member name="static_const_integer" specifiers="static"><type>const int</type></data-member>
|
||||
<method-group name="public member functions">
|
||||
<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="conversion-operator" specifiers="explicit"><type>int</type></method>
|
||||
</method-group>
|
||||
<constructor cv="= default"><parameter name=""><paramtype><classname>example</classname> const &</paramtype></parameter></constructor>
|
||||
|
@ -35,6 +35,7 @@ namespace example
|
||||
example(example const&) = default;
|
||||
example& operator=(example const&) = delete;
|
||||
virtual int virtual_method();
|
||||
int method_with_default_value(int = default_value);
|
||||
|
||||
int integer;
|
||||
static int static_integer;
|
||||
|
@ -1061,8 +1061,13 @@
|
||||
|
||||
<xsl:template name="function.attributes">
|
||||
|
||||
<!-- argsstring = '(arguments) [= delete] [= default] [constexpt]' -->
|
||||
<xsl:variable name="extra-qualifiers" select="concat(' ',
|
||||
normalize-space(substring-after(argsstring/text(), ')')),
|
||||
' ')" />
|
||||
|
||||
<!-- CV Qualifiers -->
|
||||
<xsl:if test="@const='yes' or @volatile='yes' or contains(argsstring/text(),'=delete') or contains(argsstring/text(),'=default')">
|
||||
<xsl:if test="@const='yes' or @volatile='yes' or contains($extra-qualifiers,' =delete ') or contains($extra-qualifiers,' =default ')">
|
||||
<xsl:attribute name="cv">
|
||||
<xsl:if test="@const='yes'">
|
||||
<xsl:text>const</xsl:text>
|
||||
@ -1074,13 +1079,13 @@
|
||||
<xsl:text>volatile</xsl:text>
|
||||
</xsl:if>
|
||||
<!-- Cheat and add deleted and defaulted function markers to the CV qualifiers -->
|
||||
<xsl:if test="contains(argsstring/text(),'=delete')">
|
||||
<xsl:if test="contains($extra-qualifiers,' =delete ')">
|
||||
<xsl:if test="@const='yes' or @volatile='yes'">
|
||||
<xsl:text> </xsl:text>
|
||||
</xsl:if>
|
||||
<xsl:text>= delete</xsl:text>
|
||||
</xsl:if>
|
||||
<xsl:if test="contains(argsstring/text(),'=default')">
|
||||
<xsl:if test="contains($extra-qualifiers,' =default ')">
|
||||
<xsl:if test="@const='yes' or @volatile='yes'">
|
||||
<xsl:text> </xsl:text>
|
||||
</xsl:if>
|
||||
|
Loading…
x
Reference in New Issue
Block a user