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
6f29ff31
Kaydet (Commit)
6f29ff31
authored
Nis 16, 2003
tarafından
Martin v. Löwis
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Support UCS-4 Tcl for UCS-4 Python builds. Fixes #719880.
üst
2cd0a65c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
4 deletions
+8
-4
_tkinter.c
Modules/_tkinter.c
+8
-4
No files found.
Modules/_tkinter.c
Dosyayı görüntüle @
6f29ff31
...
@@ -87,8 +87,12 @@ Copyright (C) 1994 Steen Lumholt.
...
@@ -87,8 +87,12 @@ Copyright (C) 1994 Steen Lumholt.
/* Unicode conversion assumes that Tcl_UniChar is two bytes.
/* Unicode conversion assumes that Tcl_UniChar is two bytes.
We cannot test this directly, so we test UTF-8 size instead,
We cannot test this directly, so we test UTF-8 size instead,
expecting that TCL_UTF_MAX is changed if Tcl ever supports
expecting that TCL_UTF_MAX is changed if Tcl ever supports
either UTF-16 or UCS-4. */
either UTF-16 or UCS-4.
#if TCL_UTF_MAX != 3
Redhat 8 sets TCL_UTF_MAX to 6, and uses wchar_t for
Tcl_Unichar. This is also ok as long as Python uses UCS-4,
as well.
*/
#if TCL_UTF_MAX != 3 && !(defined(Py_UNICODE_WIDE) && TCL_UTF_MAX==6)
#error "unsupported Tcl configuration"
#error "unsupported Tcl configuration"
#endif
#endif
...
@@ -899,7 +903,7 @@ AsObj(PyObject *value)
...
@@ -899,7 +903,7 @@ AsObj(PyObject *value)
int
size
=
PyUnicode_GET_SIZE
(
value
);
int
size
=
PyUnicode_GET_SIZE
(
value
);
/* This #ifdef assumes that Tcl uses UCS-2.
/* This #ifdef assumes that Tcl uses UCS-2.
See TCL_UTF_MAX test above. */
See TCL_UTF_MAX test above. */
#if
def Py_UNICODE_WIDE
#if
defined(Py_UNICODE_WIDE) && TCL_UTF_MAX == 3
Tcl_UniChar
*
outbuf
;
Tcl_UniChar
*
outbuf
;
int
i
;
int
i
;
outbuf
=
(
Tcl_UniChar
*
)
ckalloc
(
size
*
sizeof
(
Tcl_UniChar
));
outbuf
=
(
Tcl_UniChar
*
)
ckalloc
(
size
*
sizeof
(
Tcl_UniChar
));
...
@@ -1030,7 +1034,7 @@ FromObj(PyObject* tkapp, Tcl_Obj *value)
...
@@ -1030,7 +1034,7 @@ FromObj(PyObject* tkapp, Tcl_Obj *value)
if
(
value
->
typePtr
==
app
->
StringType
)
{
if
(
value
->
typePtr
==
app
->
StringType
)
{
#ifdef Py_USING_UNICODE
#ifdef Py_USING_UNICODE
#if
def Py_UNICODE_WIDE
#if
defined(Py_UNICODE_WIDE) && TCL_UTF_MAX==3
PyObject
*
result
;
PyObject
*
result
;
int
size
;
int
size
;
Tcl_UniChar
*
input
;
Tcl_UniChar
*
input
;
...
...
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