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
Labels
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Commits
Open sidebar
nexedi
cython
Commits
4077385b
Commit
4077385b
authored
Jun 18, 2018
by
gabrieldemarmiesse
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Moved and extend an example in pure.rst.
parent
5c04c1a8
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
6 additions
and
4 deletions
+6
-4
docs/examples/tutorial/pure/annotations.py
docs/examples/tutorial/pure/annotations.py
+5
-0
docs/src/tutorial/pure.rst
docs/src/tutorial/pure.rst
+1
-4
No files found.
docs/examples/tutorial/pure/annotations.py
0 → 100644
View file @
4077385b
import
cython
def
func
(
foo
:
dict
,
bar
:
cython
.
int
)
->
tuple
:
foo
[
"hello world"
]
=
3
+
bar
return
foo
,
5
docs/src/tutorial/pure.rst
View file @
4077385b
...
@@ -161,10 +161,7 @@ Static typing
...
@@ -161,10 +161,7 @@ Static typing
following example. To avoid conflicts with other kinds of annotation
following example. To avoid conflicts with other kinds of annotation
usages, this can be disabled with the directive ``annotation_typing=False``.
usages, this can be disabled with the directive ``annotation_typing=False``.
::
.. literalinclude:: ../../examples/tutorial/pure/annotations.py
def func(a_pydict: dict, a_cint: cython.int) -> tuple:
...
This can be combined with the ``@cython.exceptval()`` decorator for non-Python
This can be combined with the ``@cython.exceptval()`` decorator for non-Python
return types::
return types::
...
...
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