Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
15988fdb
Kaydet (Commit)
15988fdb
authored
Şub 12, 1999
tarafından
Fred Drake
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Documented __complex__(), made sure all the discipline names hit the
index.
üst
72ce8582
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
5 deletions
+8
-5
ref3.tex
Doc/ref/ref3.tex
+8
-5
No files found.
Doc/ref/ref3.tex
Dosyayı görüntüle @
15988fdb
...
...
@@ -1114,6 +1114,7 @@ single colon is used. For slice operations involving extended slice
notation,
\method
{__
getitem
__
()
}
,
\method
{__
setitem
__
()
}
or
\method
{__
delitem
__
()
}
is called.
\subsection
{
Emulating numeric types
\label
{
numeric-types
}}
The following methods can be defined to emulate numeric objects.
...
...
@@ -1182,17 +1183,19 @@ Called to implement the unary arithmetic operations (\code{-}, \code{+},
\function
{
abs()
}
\bifuncindex
{
abs
}
and
\code
{
~
}
).
\end{methoddesc}
\begin{methoddesc}
[numeric interface]
{__
int
__}{
self
}
\methodlineni
{__
long
__}{
self
}
\methodlineni
{__
float
__}{
self
}
\begin{methoddesc}
[numeric interface]
{__
complex
__}{
self
}
\methodline
{__
int
__}{
self
}
\methodline
{__
long
__}{
self
}
\methodline
{__
float
__}{
self
}
Called to implement the built-in functions
\function
{
int()
}
\bifuncindex
{
int
}
,
\function
{
long()
}
\bifuncindex
{
long
}
\function
{
complex()
}
\bifuncindex
{
complex
}
,
\function
{
int()
}
\bifuncindex
{
int
}
,
\function
{
long()
}
\bifuncindex
{
long
}
,
and
\function
{
float()
}
\bifuncindex
{
float
}
. Should return a value of
the appropriate type.
\end{methoddesc}
\begin{methoddesc}
[numeric interface]
{__
oct
__}{
self
}
\methodline
ni
{__
hex
__}{
self
}
\methodline
{__
hex
__}{
self
}
Called to implement the built-in functions
\function
{
oct()
}
\bifuncindex
{
oct
}
and
\function
{
hex()
}
\bifuncindex
{
hex
}
. Should return a string value.
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment