• Kirill Smelkov's avatar
    golang: Teach pychan to work with channels of C types, not only PyObjects · 3121b290
    Kirill Smelkov authored
    Introduce notion of data type (dtype similarly to NumPy) into pychan and
    teach it to accept for send objects only matching that dtype. Likewise
    teach pychan to decode raw bytes received from underlying channel into
    Python object correspodningg to pychan dtype. For C dtypes, e.g.
    'C.int', 'C.double' etc, contrary to chan of python objects, the
    transfer can be done without depending on Python GIL. This way channels
    of such C-level dtypes can be used to implement interaction in between
    Python and nogil worlds.
    3121b290
libgolang.cpp 35.5 KB