2
0
mirror of https://github.com/boostorg/python.git synced 2026-02-01 20:52:13 +00:00

updated documentation of special name support, added documentation of automatic operator export and coercion

[SVN r8283]
This commit is contained in:
Ullrich Köthe
2000-11-21 23:12:22 +00:00
parent caae49861f
commit 511a6e84db
3 changed files with 469 additions and 213 deletions

View File

@@ -126,15 +126,23 @@ namespace scope as Python member functions.
this sense, overload resolution mirrors the C++ mechanism, where a name
in a derived class "hides" all functions with the same name from a base
class.
<p>
<li>Within a name-space context (extension class or module), overloaded
functions are tried in the same order they were
<code>def()</code>ed. The first function whose signature can be made to
match each argument passed is the one which is ultimately called.
<br>
This means in particular that you cannot overload the same function on
both "<code>int</code>" and "<code>float</code>" because Python
automatically converts either of the two types into the other one.
Thus, if the "<code>float</code>"-overload is found first, it is used
also used for arguments of type "<code>int</code>" as well, and the
"<code>int</code>"-Version of the function is never invoked.
</ul>
<p>
Prev: <a href="overloading.html">Function Overloading</a>
Prev: <a href="overriding.html">Overridable Virtual Functions</a>
Next: <a href="inheritance.html">Special Method Names</a>
Up: <a href="py_cpp.html">Top</a>
<p>
@@ -144,6 +152,6 @@ namespace scope as Python member functions.
express or implied warranty, and with no claim as to its suitability
for any purpose.
<p>
Updated: Oct 30, 2000
Updated: Nov 21, 2000
</div>