Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cython
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
Kirill Smelkov
cython
Commits
331d9d82
Commit
331d9d82
authored
Jan 05, 2019
by
Jon Dufresne
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Update URLs to https:// in docs and comments
parent
8ab83030
Changes
60
Hide whitespace changes
Inline
Side-by-side
Showing
60 changed files
with
86 additions
and
88 deletions
+86
-88
CHANGES.rst
CHANGES.rst
+2
-2
Cython/Build/Dependencies.py
Cython/Build/Dependencies.py
+2
-2
Cython/Compiler/CmdLine.py
Cython/Compiler/CmdLine.py
+1
-1
Cython/Compiler/Errors.py
Cython/Compiler/Errors.py
+2
-2
Cython/Compiler/Options.py
Cython/Compiler/Options.py
+1
-1
Cython/Compiler/PyrexTypes.py
Cython/Compiler/PyrexTypes.py
+1
-1
Cython/Compiler/Symtab.py
Cython/Compiler/Symtab.py
+1
-1
Cython/Debugger/libpython.py
Cython/Debugger/libpython.py
+3
-3
Cython/Includes/libc/time.pxd
Cython/Includes/libc/time.pxd
+1
-1
Cython/Includes/posix/dlfcn.pxd
Cython/Includes/posix/dlfcn.pxd
+1
-1
Cython/Includes/posix/mman.pxd
Cython/Includes/posix/mman.pxd
+1
-1
Cython/Includes/posix/resource.pxd
Cython/Includes/posix/resource.pxd
+1
-1
Cython/Includes/posix/stdio.pxd
Cython/Includes/posix/stdio.pxd
+1
-1
Cython/Includes/posix/stdlib.pxd
Cython/Includes/posix/stdlib.pxd
+1
-1
Cython/Includes/posix/time.pxd
Cython/Includes/posix/time.pxd
+1
-1
Cython/Includes/posix/wait.pxd
Cython/Includes/posix/wait.pxd
+1
-1
Cython/Utility/Buffer.c
Cython/Utility/Buffer.c
+2
-2
Cython/Utility/ModuleSetupCode.c
Cython/Utility/ModuleSetupCode.c
+1
-1
Cython/Utility/ObjectHandling.c
Cython/Utility/ObjectHandling.c
+1
-1
Cython/Utility/Optimize.c
Cython/Utility/Optimize.c
+1
-1
Demos/benchmarks/bpnn3.py
Demos/benchmarks/bpnn3.py
+1
-1
Demos/benchmarks/nqueens.py
Demos/benchmarks/nqueens.py
+1
-1
Demos/freeze/README.rst
Demos/freeze/README.rst
+2
-2
Doc/s5/cython-ep2008.txt
Doc/s5/cython-ep2008.txt
+3
-3
Doc/s5/ui/default/iepngfix.htc
Doc/s5/ui/default/iepngfix.htc
+1
-1
Doc/s5/ui/default/slides.js
Doc/s5/ui/default/slides.js
+1
-1
LICENSE.txt
LICENSE.txt
+1
-1
README.rst
README.rst
+3
-3
Tools/cython-mode.el
Tools/cython-mode.el
+1
-1
appveyor.yml
appveyor.yml
+1
-1
appveyor/install.ps1
appveyor/install.ps1
+1
-1
docs/README
docs/README
+1
-1
docs/TODO
docs/TODO
+1
-1
docs/index.rst
docs/index.rst
+1
-1
docs/sphinxext/cython_highlighting.py
docs/sphinxext/cython_highlighting.py
+1
-1
docs/src/quickstart/build.rst
docs/src/quickstart/build.rst
+2
-2
docs/src/quickstart/install.rst
docs/src/quickstart/install.rst
+2
-2
docs/src/quickstart/overview.rst
docs/src/quickstart/overview.rst
+3
-3
docs/src/tutorial/profiling_tutorial.rst
docs/src/tutorial/profiling_tutorial.rst
+2
-4
docs/src/tutorial/related_work.rst
docs/src/tutorial/related_work.rst
+1
-1
docs/src/tutorial/strings.rst
docs/src/tutorial/strings.rst
+2
-2
docs/src/userguide/external_C_code.rst
docs/src/userguide/external_C_code.rst
+1
-1
docs/src/userguide/memoryviews.rst
docs/src/userguide/memoryviews.rst
+1
-1
docs/src/userguide/numpy_pythran.rst
docs/src/userguide/numpy_pythran.rst
+2
-2
docs/src/userguide/numpy_tutorial.rst
docs/src/userguide/numpy_tutorial.rst
+3
-3
docs/src/userguide/pypy.rst
docs/src/userguide/pypy.rst
+1
-1
docs/src/userguide/pyrex_differences.rst
docs/src/userguide/pyrex_differences.rst
+1
-1
docs/src/userguide/source_files_and_compilation.rst
docs/src/userguide/source_files_and_compilation.rst
+1
-1
pyximport/pyxbuild.py
pyximport/pyxbuild.py
+1
-1
runtests.py
runtests.py
+1
-1
setup.py
setup.py
+2
-2
tests/memoryview/memoryview.pyx
tests/memoryview/memoryview.pyx
+1
-1
tests/memoryview/relaxed_strides.pyx
tests/memoryview/relaxed_strides.pyx
+3
-3
tests/run/clear_to_null.pyx
tests/run/clear_to_null.pyx
+1
-1
tests/run/no_gc_clear.pyx
tests/run/no_gc_clear.pyx
+1
-1
tests/run/pep448_test_extcall.pyx
tests/run/pep448_test_extcall.pyx
+1
-1
tests/run/test_coroutines_pep492.pyx
tests/run/test_coroutines_pep492.pyx
+4
-4
tests/run/test_fstring.pyx
tests/run/test_fstring.pyx
+1
-1
tests/run/test_unicode.pyx
tests/run/test_unicode.pyx
+1
-1
tests/run/yield_from_pep380.pyx
tests/run/yield_from_pep380.pyx
+1
-1
No files found.
CHANGES.rst
View file @
331d9d82
...
...
@@ -1634,7 +1634,7 @@ Features added
* Generators have new properties ``__name__`` and ``__qualname__``
that provide the plain/qualified name of the generator function
(following CPython 3.5). See http://bugs.python.org/issue21205
(following CPython 3.5). See http
s
://bugs.python.org/issue21205
* The ``inline`` function modifier is available as a decorator
``@cython.inline`` in pure mode.
...
...
@@ -1680,7 +1680,7 @@ Optimizations
evaluation and generally improves the code flow in the generated C code.
* The Python expression "2 ** N" is optimised into bit shifting.
See http://bugs.python.org/issue21420
See http
s
://bugs.python.org/issue21420
* Cascaded assignments (a = b = ...) try to minimise the number of
type coercions.
...
...
Cython/Build/Dependencies.py
View file @
331d9d82
...
...
@@ -792,7 +792,7 @@ def create_extension_list(patterns, exclude=None, ctx=None, aliases=None, quiet=
filepattern
=
cython_sources
[
0
]
if
len
(
cython_sources
)
>
1
:
print
(
"Warning: Multiple cython sources found for extension '%s': %s
\
n
"
"See http://cython.readthedocs.io/en/latest/src/userguide/sharing_declarations.html "
"See http
s
://cython.readthedocs.io/en/latest/src/userguide/sharing_declarations.html "
"for sharing declarations among Cython files."
%
(
pattern
.
name
,
cython_sources
))
else
:
# ignore non-cython modules
...
...
@@ -1073,7 +1073,7 @@ def cythonize(module_list, exclude=None, nthreads=0, aliases=None, quiet=False,
# This is a bit more involved than it should be, because KeyboardInterrupts
# break the multiprocessing workers when using a normal pool.map().
# See, for example:
# http://noswap.com/blog/python-multiprocessing-keyboardinterrupt
# http
s
://noswap.com/blog/python-multiprocessing-keyboardinterrupt
try
:
result
=
pool
.
map_async
(
cythonize_one_helper
,
to_compile
,
chunksize
=
1
)
pool
.
close
()
...
...
Cython/Compiler/CmdLine.py
View file @
331d9d82
...
...
@@ -9,7 +9,7 @@ import sys
from
.
import
Options
usage
=
"""
\
Cython (http
://cython.org
) is a compiler for code written in the
Cython (http
s://cython.org/
) is a compiler for code written in the
Cython language. Cython is based on Pyrex by Greg Ewing.
Usage: cython [options] sourcefile.{pyx,py} ...
...
...
Cython/Compiler/Errors.py
View file @
331d9d82
...
...
@@ -62,7 +62,7 @@ class CompileError(PyrexError):
self
.
reported
=
False
Exception
.
__init__
(
self
,
self
.
formatted_message
)
# Python Exception subclass pickling is broken,
# see http://bugs.python.org/issue1692335
# see http
s
://bugs.python.org/issue1692335
self
.
args
=
(
position
,
message
)
def
__str__
(
self
):
...
...
@@ -110,7 +110,7 @@ class CompilerCrash(CompileError):
message
+=
u'%s: %s'
%
(
cause
.
__class__
.
__name__
,
cause
)
CompileError
.
__init__
(
self
,
pos
,
message
)
# Python Exception subclass pickling is broken,
# see http://bugs.python.org/issue1692335
# see http
s
://bugs.python.org/issue1692335
self
.
args
=
(
pos
,
context
,
message
,
cause
,
stacktrace
)
class
NoElementTreeInstalledException
(
PyrexError
):
...
...
Cython/Compiler/Options.py
View file @
331d9d82
...
...
@@ -33,7 +33,7 @@ class ShouldBeFromDirective(object):
"""
The members of this module are documented using autodata in
Cython/docs/src/reference/compilation.rst.
See http
://www.sphinx-doc.org/en/master/ext
/autodoc.html#directive-autoattribute
See http
s://www.sphinx-doc.org/en/master/usage/extensions
/autodoc.html#directive-autoattribute
for how autodata works.
Descriptions of those members should start with a #:
Donc forget to keep the docs in sync by removing and adding
...
...
Cython/Compiler/PyrexTypes.py
View file @
331d9d82
...
...
@@ -115,7 +115,7 @@ class BaseType(object):
Deduce any template params in this (argument) type given the actual
argument type.
http://en.cppreference.com/w/cpp/language/function_template#Template_argument_deduction
http
s
://en.cppreference.com/w/cpp/language/function_template#Template_argument_deduction
"""
return
{}
...
...
Cython/Compiler/Symtab.py
View file @
331d9d82
...
...
@@ -443,7 +443,7 @@ class Scope(object):
if
type
.
is_buffer
and
not
isinstance
(
self
,
LocalScope
):
# and not is_type:
error
(
pos
,
'Buffer types only allowed as function local variables'
)
if
not
self
.
in_cinclude
and
cname
and
re
.
match
(
"^_[_A-Z]+$"
,
cname
):
# See http://www.gnu.org/software/libc/manual/html_node/Reserved-Names.html#Reserved-Names
# See http
s
://www.gnu.org/software/libc/manual/html_node/Reserved-Names.html#Reserved-Names
warning
(
pos
,
"'%s' is a reserved name in C."
%
cname
,
-
1
)
entries
=
self
.
entries
if
name
and
name
in
entries
and
not
shadow
:
...
...
Cython/Debugger/libpython.py
View file @
331d9d82
...
...
@@ -9,7 +9,7 @@
From gdb 7 onwards, gdb's build can be configured --with-python, allowing gdb
to be extended with Python code e.g. for library-specific data visualizations,
such as for the C++ STL types. Documentation on this API can be seen at:
http://sourceware.org/gdb/current/onlinedocs/gdb/Python-API.html
http
s
://sourceware.org/gdb/current/onlinedocs/gdb/Python-API.html
This python module deals with the case when the process being debugged (the
...
...
@@ -315,7 +315,7 @@ class PyObjectPtr(object):
def
__repr__
(
self
):
# For the NULL pointer, we have no way of knowing a type, so
# special-case it as per
# http://bugs.python.org/issue8032#msg100882
# http
s
://bugs.python.org/issue8032#msg100882
if
self
.
address
==
0
:
return
'0x0'
return
'<%s at remote 0x%x>'
%
(
self
.
tp_name
,
self
.
address
)
...
...
@@ -1451,7 +1451,7 @@ register (gdb.current_objfile ())
# Unfortunately, the exact API exposed by the gdb module varies somewhat
# from build to build
# See http://bugs.python.org/issue8279?#msg102276
# See http
s
://bugs.python.org/issue8279?#msg102276
class
Frame
(
object
):
'''
...
...
Cython/Includes/libc/time.pxd
View file @
331d9d82
# http://en.wikipedia.org/wiki/C_date_and_time_functions
# http
s
://en.wikipedia.org/wiki/C_date_and_time_functions
from
libc.stddef
cimport
wchar_t
...
...
Cython/Includes/posix/dlfcn.pxd
View file @
331d9d82
# POSIX dynamic linking/loading interface.
# http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/dlfcn.h.html
# http
s
://pubs.opengroup.org/onlinepubs/9699919799/basedefs/dlfcn.h.html
cdef
extern
from
"<dlfcn.h>"
nogil
:
void
*
dlopen
(
const
char
*
,
int
)
...
...
Cython/Includes/posix/mman.pxd
View file @
331d9d82
# http://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/mman.h.html
# http
s
://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/mman.h.html
from
posix.types
cimport
off_t
,
mode_t
...
...
Cython/Includes/posix/resource.pxd
View file @
331d9d82
# http://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/resource.h.html
# http
s
://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/resource.h.html
from
posix.time
cimport
timeval
from
posix.types
cimport
id_t
...
...
Cython/Includes/posix/stdio.pxd
View file @
331d9d82
# POSIX additions to <stdio.h>.
# http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/stdio.h.html
# http
s
://pubs.opengroup.org/onlinepubs/9699919799/basedefs/stdio.h.html
from
libc.stdio
cimport
FILE
from
libc.stddef
cimport
wchar_t
...
...
Cython/Includes/posix/stdlib.pxd
View file @
331d9d82
# POSIX additions to <stdlib.h>
# http://pubs.opengroup.org/onlinepubs/9699919799/basedefs/stdlib.h.html
# http
s
://pubs.opengroup.org/onlinepubs/9699919799/basedefs/stdlib.h.html
cdef
extern
from
"<stdlib.h>"
nogil
:
void
_Exit
(
int
)
...
...
Cython/Includes/posix/time.pxd
View file @
331d9d82
# http://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/time.h.html
# http
s
://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/time.h.html
from
posix.types
cimport
suseconds_t
,
time_t
,
clockid_t
,
timer_t
from
posix.signal
cimport
sigevent
...
...
Cython/Includes/posix/wait.pxd
View file @
331d9d82
# http://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/wait.h.html
# http
s
://pubs.opengroup.org/onlinepubs/009695399/basedefs/sys/wait.h.html
from
posix.types
cimport
pid_t
,
id_t
from
posix.signal
cimport
siginfo_t
...
...
Cython/Utility/Buffer.c
View file @
331d9d82
...
...
@@ -224,8 +224,8 @@ fail:;
// the format string; the access mode/flags is checked by the
// exporter. See:
//
// http://docs.python.org/3/library/struct.html
// http
://legacy
.python.org/dev/peps/pep-3118/#additions-to-the-struct-string-syntax
// http
s
://docs.python.org/3/library/struct.html
// http
s://www
.python.org/dev/peps/pep-3118/#additions-to-the-struct-string-syntax
//
// The alignment code is copied from _struct.c in Python.
...
...
Cython/Utility/ModuleSetupCode.c
View file @
331d9d82
...
...
@@ -347,7 +347,7 @@
#endif
#endif
// Work around clang bug http://stackoverflow.com/questions/21847816/c-invoke-nested-template-class-destructor
// Work around clang bug http
s
://stackoverflow.com/questions/21847816/c-invoke-nested-template-class-destructor
template
<
typename
T
>
void
__Pyx_call_destructor
(
T
&
x
)
{
x
.
~
T
();
...
...
Cython/Utility/ObjectHandling.c
View file @
331d9d82
...
...
@@ -1986,7 +1986,7 @@ static PyObject *__Pyx_PyFunction_FastCallDict(PyObject *func, PyObject **args,
// ((char *)(foo) \
// + Py_BUILD_ASSERT_EXPR(offsetof(struct foo, string) == 0))
//
// Written by Rusty Russell, public domain, http://ccodearchive.net/
// Written by Rusty Russell, public domain, http
s
://ccodearchive.net/
#define __Pyx_BUILD_ASSERT_EXPR(cond) \
(sizeof(char [1 - 2*!(cond)]) - 1)
...
...
Cython/Utility/Optimize.c
View file @
331d9d82
...
...
@@ -648,7 +648,7 @@ static PyObject* __Pyx__PyNumber_PowerOf2(PyObject *two, PyObject *exp, PyObject
static
PyObject
*
__Pyx__PyNumber_PowerOf2
(
PyObject
*
two
,
PyObject
*
exp
,
PyObject
*
none
,
int
inplace
)
{
// in CPython, 1<<N is substantially faster than 2**N
// see http://bugs.python.org/issue21420
// see http
s
://bugs.python.org/issue21420
#if !CYTHON_COMPILING_IN_PYPY
Py_ssize_t
shiftby
;
#if PY_MAJOR_VERSION < 3
...
...
Demos/benchmarks/bpnn3.py
View file @
331d9d82
#!/usr/bin/python
# Back-Propagation Neural Networks
#
# Written in Python. See http://www.python.org/
# Written in Python. See http
s
://www.python.org/
#
# Neil Schemenauer <nascheme@enme.ucalgary.ca>
...
...
Demos/benchmarks/nqueens.py
View file @
331d9d82
...
...
@@ -43,7 +43,7 @@ def permutations(iterable):
else
:
return
# From http://code.activestate.com/recipes/576647/
# From http
s
://code.activestate.com/recipes/576647/
@
cython
.
locals
(
queen_count
=
int
,
i
=
int
,
vec
=
list
)
def
n_queens
(
queen_count
):
"""N-Queens solver.
...
...
Demos/freeze/README.rst
View file @
331d9d82
...
...
@@ -106,6 +106,6 @@ Cython 0.11.2 (or newer, assuming the API does not change)
SEE ALSO
========
* `Python <http
://www.python.org
>`_
* `Python <http
s://www.python.org/
>`_
* `Cython <http://www.cython.org>`_
* `freeze.py <http://wiki.python.org/moin/Freeze>`_
* `freeze.py <http
s
://wiki.python.org/moin/Freeze>`_
Doc/s5/cython-ep2008.txt
View file @
331d9d82
...
...
@@ -51,7 +51,7 @@ Cython is
* an Open-Source project
* http
://cython.org
* http
s://cython.org/
* a Python compiler (almost)
...
...
@@ -115,7 +115,7 @@ Major Cython Developers
* many, *many* others - see
* http://cython.org/
* http
s
://cython.org/
* the mailing list archives of Cython and Pyrex
...
...
@@ -398,4 +398,4 @@ Cython
\... use it, and join the project!
http://cython.org/
http
s
://cython.org/
Doc/s5/ui/default/iepngfix.htc
View file @
331d9d82
...
...
@@ -3,7 +3,7 @@
<script>
// IE5.5+ PNG Alpha Fix v1.0 by Angus Turnbull http
://www.twinhelix.com
// IE5.5+ PNG Alpha Fix v1.0 by Angus Turnbull http
s://www.twinhelix.com/
// Free usage permitted as long as this notice remains intact.
// This must be a path to a blank image. That's all the configuration you need here.
...
...
Doc/s5/ui/default/slides.js
View file @
331d9d82
// S5 v1.1 slides.js -- released into the Public Domain
//
// Please see http
://www.
meyerweb.com/eric/tools/s5/credits.html for information
// Please see http
s://
meyerweb.com/eric/tools/s5/credits.html for information
// about all the wonderful and talented contributors to this code!
var
undef
;
...
...
LICENSE.txt
View file @
331d9d82
Apache License
Version 2.0, January 2004
http://www.apache.org/licenses/
http
s
://www.apache.org/licenses/
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
...
...
README.rst
View file @
331d9d82
Welcome to Cython!
Welcome to Cython!
==================
Cython is a language that makes writing C extensions for
...
...
@@ -14,8 +14,8 @@ code from Cython code.
This makes Cython the ideal language for wrapping external C libraries, and
for fast C modules that speed up the execution of Python code.
* Official website: http://cython.org/
* Documentation: http://docs.cython.org/
en/latest/
* Official website: http
s
://cython.org/
* Documentation: http://docs.cython.org/
* Github repository: https://github.com/cython/cython
* Wiki: https://github.com/cython/cython/wiki
...
...
Tools/cython-mode.el
View file @
331d9d82
...
...
@@ -103,7 +103,7 @@
(
defgroup
cython
nil
"Major mode for editing and compiling Cython files"
:group
'languages
:prefix
"cython-"
:link
'
(
url-link
:tag
"Homepage"
"http
://cython.org
"
))
:link
'
(
url-link
:tag
"Homepage"
"http
s://cython.org/
"
))
;;;###autoload
(
defcustom
cython-default-compile-format
"cython -a %s"
...
...
appveyor.yml
View file @
331d9d82
...
...
@@ -5,7 +5,7 @@ environment:
global
:
# SDK v7.0 MSVC Express 2008's SetEnv.cmd script will fail if the
# /E:ON and /V:ON options are not enabled in the batch script interpreter
# See: http
://stackoverflow.com/a/13751649/163740
# See: http
s://stackoverflow.com/questions/11267463/compiling-python-modules-on-windows-x64/13751649#13751649
WITH_ENV
:
"
cmd
/E:ON
/V:ON
/C
.
\\
appveyor
\\
run_with_env.cmd"
matrix
:
...
...
appveyor/install.ps1
View file @
331d9d82
# Sample script to install Python and pip under Windows
# Authors: Olivier Grisel and Kyle Kastner
# License: CC0 1.0 Universal: http://creativecommons.org/publicdomain/zero/1.0/
# License: CC0 1.0 Universal: http
s
://creativecommons.org/publicdomain/zero/1.0/
$PYTHON_BASE_URL
=
"https://www.python.org/ftp/python/"
$GET_PIP_URL
=
"https://bootstrap.pypa.io/get-pip.py"
...
...
docs/README
View file @
331d9d82
...
...
@@ -11,7 +11,7 @@ On windows systems, you only need Sphinx. Open PowerShell and type::
You can then see the documentation by opening in a browser ``cython/docs/build/html/index.html``.
The current Cython documentation files are hosted at
https://cython.readthedocs.io/
en/latest/
https://cython.readthedocs.io/
Notes
...
...
docs/TODO
View file @
331d9d82
...
...
@@ -17,7 +17,7 @@ Eventually, it seems all of the old users manual could be whittled
down into independent tutorial topics. Much discussion of what we'd
like to see is at
http://www.mail-archive.com/cython-dev@codespeak.net/msg06945.html
http
s
://www.mail-archive.com/cython-dev@codespeak.net/msg06945.html
There is currently a huge amount of redundancy, but no one section has
it all.
...
...
docs/index.rst
View file @
331d9d82
...
...
@@ -2,7 +2,7 @@
Welcome to Cython's Documentation
=================================
Also see the `Cython project homepage <http://cython.org/>`_.
Also see the `Cython project homepage <http
s
://cython.org/>`_.
.. toctree::
:maxdepth: 2
...
...
docs/sphinxext/cython_highlighting.py
View file @
331d9d82
...
...
@@ -14,7 +14,7 @@ line_re = re.compile('.*?\n')
class
CythonLexer
(
RegexLexer
):
"""
For `Cython <http
://cython.org
>`_ source code.
For `Cython <http
s://cython.org/
>`_ source code.
"""
name
=
'Cython'
...
...
docs/src/quickstart/build.rst
View file @
331d9d82
...
...
@@ -104,5 +104,5 @@ Using the Sage notebook
functions defined in a Cython cell imported into the running session.
.. [Jupyter] http://jupyter.org/
.. [Sage] W. Stein et al., Sage Mathematics Software, http://www.sagemath.org/
.. [Jupyter] http
s
://jupyter.org/
.. [Sage] W. Stein et al., Sage Mathematics Software, http
s
://www.sagemath.org/
docs/src/quickstart/install.rst
View file @
331d9d82
...
...
@@ -41,7 +41,7 @@ The simplest way of installing Cython is by using ``pip``::
The newest Cython release can always be downloaded from
http
://cython.org
. Unpack the tarball or zip file, enter the
http
s://cython.org/
. Unpack the tarball or zip file, enter the
directory, and then run::
python setup.py install
...
...
@@ -59,4 +59,4 @@ with
.. [Anaconda] https://docs.anaconda.com/anaconda/
.. [Canopy] https://www.enthought.com/product/canopy/
.. [Sage] W. Stein et al., Sage Mathematics Software, http://www.sagemath.org/
.. [Sage] W. Stein et al., Sage Mathematics Software, http
s
://www.sagemath.org/
docs/src/quickstart/overview.rst
View file @
331d9d82
...
...
@@ -44,13 +44,13 @@ thus merges the two worlds into a very broadly applicable programming
language.
.. [Cython] G. Ewing, R. W. Bradshaw, S. Behnel, D. S. Seljebotn et al.,
The Cython compiler, http
://cython.org
.
The Cython compiler, http
s://cython.org/
.
.. [IronPython] Jim Hugunin et al., https://archive.codeplex.com/?p=IronPython.
.. [Jython] J. Huginin, B. Warsaw, F. Bock, et al.,
Jython: Python for the Java platform, http://www.jython.org.
.. [PyPy] The PyPy Group, PyPy: a Python implementation written in Python,
http
://pypy.org
.
http
s://pypy.org/
.
.. [Pyrex] G. Ewing, Pyrex: C-Extensions for Python,
http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
http
s
://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
.. [Python] G. van Rossum et al., The Python programming language,
https://www.python.org/.
docs/src/tutorial/profiling_tutorial.rst
View file @
331d9d82
...
...
@@ -75,8 +75,8 @@ Enabling coverage analysis
--------------------------
Since Cython 0.23, line tracing (see above) also enables support for coverage
reporting with the `coverage.py <http
://coverage.readthedocs.io/>`_ tool.
To
make the coverage analysis understand Cython modules, you also need to enable
reporting with the `coverage.py <http
s://coverage.readthedocs.io/>`_ tool. To
make the coverage analysis understand Cython modules, you also need to enable
Cython's coverage plugin in your ``.coveragerc`` file as follows:
.. code-block:: ini
...
...
@@ -274,5 +274,3 @@ faster than calling pow(x,0.5).
Even so, the result we achieved here is quite satisfactory: we came up with a
solution that is much faster then our original Python version while retaining
functionality and readability.
docs/src/tutorial/related_work.rst
View file @
331d9d82
...
...
@@ -42,7 +42,7 @@ Python modules.
.. [ctypes] https://docs.python.org/library/ctypes.html.
.. there's also the original ctypes home page: http://python.net/crew/theller/ctypes/
.. [Pyrex] G. Ewing, Pyrex: C-Extensions for Python,
http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
http
s
://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
.. [ShedSkin] M. Dufour, J. Coughlan, ShedSkin,
https://github.com/shedskin/shedskin
.. [SWIG] David M. Beazley et al.,
...
...
docs/src/tutorial/strings.rst
View file @
331d9d82
...
...
@@ -440,7 +440,7 @@ characters and is compatible with plain ASCII encoded text that it
encodes efficiently. This makes it a very good choice for source code
files which usually consist mostly of ASCII characters.
.. _`UTF-8`: http://en.wikipedia.org/wiki/UTF-8
.. _`UTF-8`: http
s
://en.wikipedia.org/wiki/UTF-8
As an example, putting the following line into a UTF-8 encoded source
file will print ``5``, as UTF-8 encodes the letter ``'ö'`` in the two
...
...
@@ -553,7 +553,7 @@ above character.
For more information on this topic, it is worth reading the `Wikipedia
article about the UTF-16 encoding`_.
.. _`Wikipedia article about the UTF-16 encoding`: http://en.wikipedia.org/wiki/UTF-16/UCS-2
.. _`Wikipedia article about the UTF-16 encoding`: http
s
://en.wikipedia.org/wiki/UTF-16/UCS-2
The same properties apply to Cython code that gets compiled for a
narrow CPython runtime environment. In most cases, e.g. when
...
...
docs/src/userguide/external_C_code.rst
View file @
331d9d82
...
...
@@ -524,7 +524,7 @@ Acquiring and Releasing the GIL
---------------------------------
Cython provides facilities for acquiring and releasing the
`Global Interpreter Lock (GIL) <http://docs.python.org/dev/glossary.html#term-global-interpreter-lock>`_.
`Global Interpreter Lock (GIL) <http
s
://docs.python.org/dev/glossary.html#term-global-interpreter-lock>`_.
This may be useful when calling from multi-threaded code into
(external C) code that may block, or when wanting to use Python
from a (native) C thread callback. Releasing the GIL should
...
...
docs/src/userguide/memoryviews.rst
View file @
331d9d82
...
...
@@ -652,6 +652,6 @@ object handling. For the details of how to compile and
call functions in C files, see :ref:`using_c_libraries`.
.. _GIL: http://docs.python.org/dev/glossary.html#term-global-interpreter-lock
.. _GIL: http
s
://docs.python.org/dev/glossary.html#term-global-interpreter-lock
.. _NumPy: https://docs.scipy.org/doc/numpy/reference/arrays.ndarray.html#memory-layout
.. _example: https://docs.scipy.org/doc/numpy/reference/arrays.indexing.html
docs/src/userguide/numpy_pythran.rst
View file @
331d9d82
...
...
@@ -20,7 +20,7 @@ Usage example with distutils
----------------------------
You first need to install Pythran. See its `documentation
<http
://pythran.readthedocs.io/en/latest
/>`_ for more information.
<http
s://pythran.readthedocs.io
/>`_ for more information.
Then, simply add a ``cython: np_pythran=True`` directive at the top of the
Python files that needs to be compiled using Pythran numpy support.
...
...
@@ -31,7 +31,7 @@ Here is an example of a simple ``setup.py`` file using distutils:
from distutils.core import setup
from Cython.Build import cythonize
setup(
name = "My hello app",
ext_modules = cythonize('hello_pythran.pyx')
...
...
docs/src/userguide/numpy_tutorial.rst
View file @
331d9d82
...
...
@@ -65,7 +65,7 @@ However there are several options to automate these steps:
excellent support for using Cython and NumPy from an interactive command
line or through a notebook interface (like
Maple/Mathematica). See `this documentation
<http://doc.sagemath.org/html/en/developer/coding_in_cython.html>`_.
<http
s
://doc.sagemath.org/html/en/developer/coding_in_cython.html>`_.
2. Cython can be used as an extension within a Jupyter notebook,
making it easy to compile and use Cython code with just a ``%%cython``
at the top of a cell. For more information see
...
...
@@ -487,8 +487,8 @@ than NumPy!
Where to go from here?
======================
* If you want to learn how to make use of `BLAS <http://www.netlib.org/blas/>`_
or `LAPACK <http://www.netlib.org/lapack/>`_ with Cython, you can watch
* If you want to learn how to make use of `BLAS <http
s
://www.netlib.org/blas/>`_
or `LAPACK <http
s
://www.netlib.org/lapack/>`_ with Cython, you can watch
`the presentation of Ian Henriksen at SciPy 2015
<https://www.youtube.com/watch?v=R4yB-8tB0J0&t=693s&ab_channel=Enthought>`_.
* If you want to learn how to use Pythran as backend in Cython, you
...
...
docs/src/userguide/pypy.rst
View file @
331d9d82
...
...
@@ -2,7 +2,7 @@ Porting Cython code to PyPy
===========================
Cython has basic support for cpyext, the layer in
`PyPy <http://pypy.org/>`_ that emulates CPython's C-API. This is
`PyPy <http
s
://pypy.org/>`_ that emulates CPython's C-API. This is
achieved by making the generated C code adapt at C compile time, so
the generated code will compile in both CPython and PyPy unchanged.
...
...
docs/src/userguide/pyrex_differences.rst
View file @
331d9d82
...
...
@@ -310,7 +310,7 @@ Automatic ``typecheck``
Rather than introducing a new keyword ``typecheck`` as explained in the
`Pyrex docs
<http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/version/Doc/Manual/special_methods.html>`_,
<http
s
://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/version/Doc/Manual/special_methods.html>`_,
Cython emits a (non-spoofable and faster) typecheck whenever
:func:`isinstance` is used with an extension type as the second parameter.
...
...
docs/src/userguide/source_files_and_compilation.rst
View file @
331d9d82
...
...
@@ -582,7 +582,7 @@ The Sage notebook allows transparently editing and compiling Cython
code simply by typing ``%cython`` at the top of a cell and evaluate
it. Variables and functions defined in a Cython cell are imported into the
running session. Please check `Sage documentation
<http://www.sagemath.org/doc/>`_ for details.
<http
s
://www.sagemath.org/doc/>`_ for details.
You can tailor the behavior of the Cython compiler by specifying the
directives below.
...
...
pyximport/pyxbuild.py
View file @
331d9d82
...
...
@@ -103,7 +103,7 @@ def pyx_to_dll(filename, ext=None, force_rebuild=0, build_in_temp=False, pyxbuil
so_path
=
obj_build_ext
.
get_outputs
()[
0
]
if
obj_build_ext
.
inplace
:
# Python distutils get_outputs()[ returns a wrong so_path
# when --inplace ; see http://bugs.python.org/issue5977
# when --inplace ; see http
s
://bugs.python.org/issue5977
# workaround:
so_path
=
os
.
path
.
join
(
os
.
path
.
dirname
(
filename
),
os
.
path
.
basename
(
so_path
))
...
...
runtests.py
View file @
331d9d82
...
...
@@ -115,7 +115,7 @@ def get_distutils_distro(_cache=[]):
distutils_distro
=
Distribution
()
if
sys
.
platform
==
'win32'
:
# TODO: Figure out why this hackery (see http://thread.gmane.org/gmane.comp.python.cython.devel/8280/).
# TODO: Figure out why this hackery (see http
s
://thread.gmane.org/gmane.comp.python.cython.devel/8280/).
config_files
=
distutils_distro
.
find_config_files
()
try
:
config_files
.
remove
(
'setup.cfg'
)
...
...
setup.py
View file @
331d9d82
...
...
@@ -228,7 +228,7 @@ packages = [
setup
(
name
=
'Cython'
,
version
=
version
,
url
=
'http://cython.org/'
,
url
=
'http
s
://cython.org/'
,
author
=
'Robert Bradshaw, Stefan Behnel, Dag Seljebotn, Greg Ewing, et al.'
,
author_email
=
'cython-devel@python.org'
,
description
=
"The Cython compiler for writing C extensions for the Python language."
,
...
...
@@ -253,7 +253,7 @@ setup(
pip install Cython --install-option="--no-cython-compile"
.. _Pyrex: http://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
.. _Pyrex: http
s
://www.cosc.canterbury.ac.nz/greg.ewing/python/Pyrex/
"""
),
license
=
'Apache'
,
classifiers
=
[
...
...
tests/memoryview/memoryview.pyx
View file @
331d9d82
...
...
@@ -1089,7 +1089,7 @@ def optimised_index_of_slice(int[:,:,:] arr, int x, int y, int z):
def
test_assign_from_byteslike
(
byteslike
):
# Once http
://python3statement.org
is accepted, should be just
# Once http
s://python3statement.org/
is accepted, should be just
# >>> test_assign_from_byteslike(bytes(b'hello'))
# b'hello'
# ...
...
...
tests/memoryview/relaxed_strides.pyx
View file @
331d9d82
...
...
@@ -10,12 +10,12 @@ Thanks to Nathaniel Smith and Sebastian Berg.
See also:
Mailing list threads:
http://thread.gmane.org/gmane.comp.python.cython.devel/14762
http://thread.gmane.org/gmane.comp.python.cython.devel/14634
http
s
://thread.gmane.org/gmane.comp.python.cython.devel/14762
http
s
://thread.gmane.org/gmane.comp.python.cython.devel/14634
Detailed discussion of the difference between numpy/cython's current
definition of "contiguity", and the correct definition:
http://thread.gmane.org/gmane.comp.python.cython.devel/14634/focus=14640
http
s
://thread.gmane.org/gmane.comp.python.cython.devel/14634/focus=14640
The PR implementing NPY_RELAXED_STRIDES_CHECKING:
https://github.com/numpy/numpy/pull/3162
...
...
tests/run/clear_to_null.pyx
View file @
331d9d82
...
...
@@ -2,7 +2,7 @@
Check that Cython generates a tp_clear function that actually clears object
references to NULL instead of None.
Discussed here: http://article.gmane.org/gmane.comp.python.cython.devel/14833
Discussed here: http
s
://article.gmane.org/gmane.comp.python.cython.devel/14833
"""
from
cpython.ref
cimport
PyObject
,
Py_TYPE
...
...
tests/run/no_gc_clear.pyx
View file @
331d9d82
...
...
@@ -3,7 +3,7 @@ Check that the @cython.no_gc_clear decorator disables generation of the
tp_clear slot so that __dealloc__ will still see the original reference
contents.
Discussed here: http://article.gmane.org/gmane.comp.python.cython.devel/14986
Discussed here: http
s
://article.gmane.org/gmane.comp.python.cython.devel/14986
"""
cimport
cython
...
...
tests/run/pep448_test_extcall.pyx
View file @
331d9d82
...
...
@@ -474,7 +474,7 @@ def call_builtin_nonempty_dict():
''' Cython: currently just passes empty kwargs into f() while CPython keeps the content
# A corner case of keyword dictionary items being deleted during
# the function call setup. See <http://bugs.python.org/issue2016>.
# the function call setup. See <http
s
://bugs.python.org/issue2016>.
def call_kwargs_modified_while_building():
"""
...
...
tests/run/test_coroutines_pep492.pyx
View file @
331d9d82
...
...
@@ -1075,7 +1075,7 @@ class CoroutineTest(unittest.TestCase):
c
.
close
()
def
test_func_15
(
self
):
# See http://bugs.python.org/issue25887 for details
# See http
s
://bugs.python.org/issue25887 for details
async
def
spammer
():
return
'spam'
...
...
@@ -1092,7 +1092,7 @@ class CoroutineTest(unittest.TestCase):
reader
(
spammer_coro
).
send
(
None
)
def
test_func_16
(
self
):
# See http://bugs.python.org/issue25887 for details
# See http
s
://bugs.python.org/issue25887 for details
@
types_coroutine
def
nop
():
...
...
@@ -1123,7 +1123,7 @@ class CoroutineTest(unittest.TestCase):
reader
.
throw
(
Exception
(
'wat'
))
def
test_func_17
(
self
):
# See http://bugs.python.org/issue25887 for details
# See http
s
://bugs.python.org/issue25887 for details
async
def
coroutine
():
return
'spam'
...
...
@@ -1146,7 +1146,7 @@ class CoroutineTest(unittest.TestCase):
coro
.
close
()
def
test_func_18
(
self
):
# See http://bugs.python.org/issue25887 for details
# See http
s
://bugs.python.org/issue25887 for details
async
def
coroutine
():
return
'spam'
...
...
tests/run/test_fstring.pyx
View file @
331d9d82
...
...
@@ -93,7 +93,7 @@ class TestCase(CythonTest):
self
.
assertEqual
(
type
(
y
).
__format__
(
y
,
''
),
'class'
)
def
__test_ast
(
self
):
# Inspired by http://bugs.python.org/issue24975
# Inspired by http
s
://bugs.python.org/issue24975
class
X
:
def
__init__
(
self
):
self
.
called
=
False
...
...
tests/run/test_unicode.pyx
View file @
331d9d82
...
...
@@ -1771,7 +1771,7 @@ class UnicodeTest(CommonTest,
# Issue #8271: during the decoding of an invalid UTF-8 byte sequence,
# only the start byte and the continuation byte(s) are now considered
# invalid, instead of the number of bytes specified by the start byte.
# See http://www.unicode.org/versions/Unicode5.2.0/ch03.pdf (page 95,
# See http
s
://www.unicode.org/versions/Unicode5.2.0/ch03.pdf (page 95,
# table 3-8, Row 2) for more information about the algorithm used.
FFFD
=
'
\
ufffd
'
sequences
=
[
...
...
tests/run/yield_from_pep380.pyx
View file @
331d9d82
...
...
@@ -4,7 +4,7 @@
Test suite for PEP 380 implementation
adapted from original tests written by Greg Ewing
see <http://www.cosc.canterbury.ac.nz/greg.ewing/python/yield-from/YieldFrom-Python3.1.2-rev5.zip>
see <http
s
://www.cosc.canterbury.ac.nz/greg.ewing/python/yield-from/YieldFrom-Python3.1.2-rev5.zip>
"""
import
sys
...
...
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