Commit cbdca7c2 authored by scoder's avatar scoder Committed by GitHub

Merge pull request #2377 from gabrieldemarmiesse/test_string_3

Adding tests for "Unicode and passing strings" part 3
parents 285ca063 da537165
def process_byte_data(unsigned char[:] data):
length = data.shape[0]
first_byte = data[0]
slice_view = data[1:-1]
# ...
......@@ -202,13 +202,7 @@ of byte containers, e.g. :obj:`bytearray` objects or memory views.
Depending on how (and where) the data is being processed, it may be a
good idea to instead receive a 1-dimensional memory view, e.g.
::
def process_byte_data(unsigned char[:] data):
length = data.shape[0]
first_byte = data[0]
slice_view = data[1:-1]
...
.. literalinclude:: ../../examples/tutorial/string/arg_memview.pyx
Cython's memory views are described in more detail in
:doc:`../userguide/memoryviews`, but the above example already shows
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment