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
d004fc81
Kaydet (Commit)
d004fc81
authored
May 27, 2006
tarafından
Martin v. Löwis
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Patch 1494554: Update numeric properties to Unicode 4.1.
üst
d1b6cd7b
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
9 additions
and
5 deletions
+9
-5
concrete.tex
Doc/api/concrete.tex
+1
-1
test_unicodedata.py
Lib/test/test_unicodedata.py
+2
-2
NEWS
Misc/NEWS
+3
-0
unicodedata.c
Modules/unicodedata.c
+2
-2
unicodectype.c
Objects/unicodectype.c
+0
-0
unicodeobject.c
Objects/unicodeobject.c
+1
-0
No files found.
Doc/api/concrete.tex
Dosyayı görüntüle @
d004fc81
...
@@ -965,7 +965,7 @@ These APIs can be used for fast direct character conversions:
...
@@ -965,7 +965,7 @@ These APIs can be used for fast direct character conversions:
\end{cfuncdesc}
\end{cfuncdesc}
\begin{cfuncdesc}
{
double
}{
Py
_
UNICODE
_
TONUMERIC
}{
Py
_
UNICODE ch
}
\begin{cfuncdesc}
{
double
}{
Py
_
UNICODE
_
TONUMERIC
}{
Py
_
UNICODE ch
}
Return the character
\var
{
ch
}
converted to a
(positive)
double.
Return the character
\var
{
ch
}
converted to a double.
Return
\code
{
-1.0
}
if this is not possible. This macro does not raise
Return
\code
{
-1.0
}
if this is not possible. This macro does not raise
exceptions.
exceptions.
\end{cfuncdesc}
\end{cfuncdesc}
...
...
Lib/test/test_unicodedata.py
Dosyayı görüntüle @
d004fc81
...
@@ -16,7 +16,7 @@ encoding = 'utf-8'
...
@@ -16,7 +16,7 @@ encoding = 'utf-8'
class
UnicodeMethodsTest
(
unittest
.
TestCase
):
class
UnicodeMethodsTest
(
unittest
.
TestCase
):
# update this, if the database changes
# update this, if the database changes
expectedchecksum
=
'
a6555cd209d960dcfa17bfdce0c96d91cfa9a9b
a'
expectedchecksum
=
'
c198ed264497f108434b3f576d4107237221cc8
a'
def
test_method_checksum
(
self
):
def
test_method_checksum
(
self
):
h
=
hashlib
.
sha1
()
h
=
hashlib
.
sha1
()
...
@@ -75,7 +75,7 @@ class UnicodeDatabaseTest(unittest.TestCase):
...
@@ -75,7 +75,7 @@ class UnicodeDatabaseTest(unittest.TestCase):
class
UnicodeFunctionsTest
(
UnicodeDatabaseTest
):
class
UnicodeFunctionsTest
(
UnicodeDatabaseTest
):
# update this, if the database changes
# update this, if the database changes
expectedchecksum
=
'
b45b79f3203ee1a896d9b5655484adaff5d4964b
'
expectedchecksum
=
'
4e389f97e9f88b8b7ab743121fd643089116f9f2
'
def
test_function_checksum
(
self
):
def
test_function_checksum
(
self
):
data
=
[]
data
=
[]
...
...
Misc/NEWS
Dosyayı görüntüle @
d004fc81
...
@@ -12,6 +12,9 @@ What's New in Python 2.5 alpha 3?
...
@@ -12,6 +12,9 @@ What's New in Python 2.5 alpha 3?
Core and builtins
Core and builtins
-----------------
-----------------
- Patch #1494554: Update unicodedata.numeric and unicode.isnumeric to
Unicode 4.1.
- Patch #921466: sys.path_importer_cache is now used to cache valid and
- Patch #921466: sys.path_importer_cache is now used to cache valid and
invalid file paths for the built-in import machinery which leads to
invalid file paths for the built-in import machinery which leads to
fewer open calls on startup.
fewer open calls on startup.
...
...
Modules/unicodedata.c
Dosyayı görüntüle @
d004fc81
...
@@ -209,7 +209,7 @@ unicodedata_numeric(PyObject *self, PyObject *args)
...
@@ -209,7 +209,7 @@ unicodedata_numeric(PyObject *self, PyObject *args)
if
(
old
->
category_changed
==
0
)
{
if
(
old
->
category_changed
==
0
)
{
/* unassigned */
/* unassigned */
have_old
=
1
;
have_old
=
1
;
rc
=
-
1
;
rc
=
-
1
.
0
;
}
}
else
if
(
old
->
decimal_changed
!=
0xFF
)
{
else
if
(
old
->
decimal_changed
!=
0xFF
)
{
have_old
=
1
;
have_old
=
1
;
...
@@ -219,7 +219,7 @@ unicodedata_numeric(PyObject *self, PyObject *args)
...
@@ -219,7 +219,7 @@ unicodedata_numeric(PyObject *self, PyObject *args)
if
(
!
have_old
)
if
(
!
have_old
)
rc
=
Py_UNICODE_TONUMERIC
(
*
PyUnicode_AS_UNICODE
(
v
));
rc
=
Py_UNICODE_TONUMERIC
(
*
PyUnicode_AS_UNICODE
(
v
));
if
(
rc
<
0
)
{
if
(
rc
==
-
1
.
0
)
{
if
(
defobj
==
NULL
)
{
if
(
defobj
==
NULL
)
{
PyErr_SetString
(
PyExc_ValueError
,
"not a numeric character"
);
PyErr_SetString
(
PyExc_ValueError
,
"not a numeric character"
);
return
NULL
;
return
NULL
;
...
...
Objects/unicodectype.c
Dosyayı görüntüle @
d004fc81
This diff is collapsed.
Click to expand it.
Objects/unicodeobject.c
Dosyayı görüntüle @
d004fc81
...
@@ -2376,6 +2376,7 @@ PyObject *_PyUnicode_DecodeUnicodeInternal(const char *s,
...
@@ -2376,6 +2376,7 @@ PyObject *_PyUnicode_DecodeUnicodeInternal(const char *s,
end
=
s
+
size
;
end
=
s
+
size
;
while
(
s
<
end
)
{
while
(
s
<
end
)
{
*
p
=
*
(
Py_UNICODE
*
)
s
;
memcpy
(
p
,
s
,
sizeof
(
Py_UNICODE
));
memcpy
(
p
,
s
,
sizeof
(
Py_UNICODE
));
/* We have to sanity check the raw data, otherwise doom looms for
/* We have to sanity check the raw data, otherwise doom looms for
some malformed UCS-4 data. */
some malformed UCS-4 data. */
...
...
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