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
fa68a618
Kaydet (Commit)
fa68a618
authored
Haz 07, 2010
tarafından
Mark Dickinson
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Fix naming inconsistency.
üst
2872e5b1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
5 additions
and
5 deletions
+5
-5
longobject.h
Include/longobject.h
+2
-2
datetimemodule.c
Modules/datetimemodule.c
+1
-1
longobject.c
Objects/longobject.c
+2
-2
No files found.
Include/longobject.h
Dosyayı görüntüle @
fa68a618
...
@@ -101,13 +101,13 @@ PyAPI_FUNC(int) _PyLong_Sign(PyObject *v);
...
@@ -101,13 +101,13 @@ PyAPI_FUNC(int) _PyLong_Sign(PyObject *v);
*/
*/
PyAPI_FUNC
(
size_t
)
_PyLong_NumBits
(
PyObject
*
v
);
PyAPI_FUNC
(
size_t
)
_PyLong_NumBits
(
PyObject
*
v
);
/* _PyLong_Divmod
_
Near. Given integers a and b, compute the nearest
/* _PyLong_DivmodNear. Given integers a and b, compute the nearest
integer q to the exact quotient a / b, rounding to the nearest even integer
integer q to the exact quotient a / b, rounding to the nearest even integer
in the case of a tie. Return (q, r), where r = a - q*b. The remainder r
in the case of a tie. Return (q, r), where r = a - q*b. The remainder r
will satisfy abs(r) <= abs(b)/2, with equality possible only if q is
will satisfy abs(r) <= abs(b)/2, with equality possible only if q is
even.
even.
*/
*/
PyAPI_FUNC
(
PyObject
*
)
_PyLong_Divmod
_
Near
(
PyObject
*
,
PyObject
*
);
PyAPI_FUNC
(
PyObject
*
)
_PyLong_DivmodNear
(
PyObject
*
,
PyObject
*
);
/* _PyLong_FromByteArray: View the n unsigned bytes as a binary integer in
/* _PyLong_FromByteArray: View the n unsigned bytes as a binary integer in
base 256, and return a Python long with the same numeric value.
base 256, and return a Python long with the same numeric value.
...
...
Modules/datetimemodule.c
Dosyayı görüntüle @
fa68a618
...
@@ -161,7 +161,7 @@ divide_nearest(PyObject *m, PyObject *n)
...
@@ -161,7 +161,7 @@ divide_nearest(PyObject *m, PyObject *n)
PyObject
*
result
;
PyObject
*
result
;
PyObject
*
temp
;
PyObject
*
temp
;
temp
=
_PyLong_Divmod
_
Near
(
m
,
n
);
temp
=
_PyLong_DivmodNear
(
m
,
n
);
if
(
temp
==
NULL
)
if
(
temp
==
NULL
)
return
NULL
;
return
NULL
;
result
=
PyTuple_GET_ITEM
(
temp
,
0
);
result
=
PyTuple_GET_ITEM
(
temp
,
0
);
...
...
Objects/longobject.c
Dosyayı görüntüle @
fa68a618
...
@@ -4218,7 +4218,7 @@ long__format__(PyObject *self, PyObject *args)
...
@@ -4218,7 +4218,7 @@ long__format__(PyObject *self, PyObject *args)
round-half-to-even. */
round-half-to-even. */
PyObject
*
PyObject
*
_PyLong_Divmod
_
Near
(
PyObject
*
a
,
PyObject
*
b
)
_PyLong_DivmodNear
(
PyObject
*
a
,
PyObject
*
b
)
{
{
PyLongObject
*
quo
=
NULL
,
*
rem
=
NULL
;
PyLongObject
*
quo
=
NULL
,
*
rem
=
NULL
;
PyObject
*
one
=
NULL
,
*
twice_rem
,
*
result
,
*
temp
;
PyObject
*
one
=
NULL
,
*
twice_rem
,
*
result
,
*
temp
;
...
@@ -4363,7 +4363,7 @@ long_round(PyObject *self, PyObject *args)
...
@@ -4363,7 +4363,7 @@ long_round(PyObject *self, PyObject *args)
if
(
result
==
NULL
)
if
(
result
==
NULL
)
return
NULL
;
return
NULL
;
temp
=
_PyLong_Divmod
_
Near
(
self
,
result
);
temp
=
_PyLong_DivmodNear
(
self
,
result
);
Py_DECREF
(
result
);
Py_DECREF
(
result
);
result
=
temp
;
result
=
temp
;
if
(
result
==
NULL
)
if
(
result
==
NULL
)
...
...
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