Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
pygolang
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Carlos Ramos Carreño
pygolang
Commits
859a55eb
Commit
859a55eb
authored
Oct 09, 2022
by
Kirill Smelkov
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
golang_str: Cosmetics
parent
c0a53847
Changes
1
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
4 deletions
+4
-4
golang/_golang_str.pyx
golang/_golang_str.pyx
+4
-4
No files found.
golang/_golang_str.pyx
View file @
859a55eb
...
...
@@ -54,6 +54,7 @@ cdef extern from "Python.h":
from
libc.stdint
cimport
uint8_t
from
libc.stdio
cimport
FILE
pystrconv
=
None
# = golang.strconv imported at runtime (see __init__.py)
import
string
as
pystring
...
...
@@ -902,8 +903,7 @@ def _udata(obj): # -> unicode
# Do it only on python2, because python3 does not use tp_print at all.
# NOTE pyustr does not need this because on py2 str(pyustr) returns pybstr.
IF
PY2
:
# NOTE Cython does not define tp_print for PyTypeObject - do it ourselves
from
libc.stdio
cimport
FILE
# Cython does not define tp_print for PyTypeObject - do it ourselves
cdef
extern
from
"Python.h"
:
ctypedef
int
(
*
printfunc
)(
PyObject
*
,
FILE
*
,
int
)
except
-
1
ctypedef
struct
_PyTypeObject_Print
"PyTypeObject"
:
...
...
@@ -1904,7 +1904,7 @@ else:
# _xunichr returns unicode character for an ordinal i.
#
# it works correctly even on ucs2 python builds, where ordinals >= 0x10000 are
# represented as 2 unicode point
e
.
# represented as 2 unicode point
s
.
if
not
_ucs2_build
:
_xunichr
=
unichr
else
:
...
...
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