rust-python-example
rust-python-example copied to clipboard
Example of using Rust to Extend Python
https://github.com/rochacbruno/rust-python-example/issues/22 Avoid to manually copy and rename dll on windows
``` import os import sys from ctypes import * lib = cdll.LoadLibrary(r'myrustlib.dll') val='tesTTanotheRRtesTTtest' lib.count_doubles(val) ``` errors out: ``` func = self._FuncPtr((name_or_ordinal, self)) AttributeError: function 'count_doubles' not found ```
First, Thank you for this repository! This PR intends to solve #13 please re-run the benchmarks.
When I use ```make compile-rust``` I get multiple warnings ```warning: use of deprecated item 'r#try': use the `?` operator instead```
I'm on macOS and ran into this issue: ``` rustup update git clone https://github.com/rochacbruno/rust-python-example cd rust-python-example make compile-rust ``` then I was greeted by this: which after a lot of...
Is there lost one line as `use std::mem;` in README.md? When I run sample step by step follow README.md,I got same error,but when I add `use std::mem;` ,cargo build successfully,but...
```cython def count_doubles(bytes data): cdef Py_ssize_t count = 0, i cdef char *s = data # no copy for i in range(len(data) - 1): count += (s[i] == s[i +...
we can format this a sa pr later, but it is this thing: ``` unsigned long long count_double(char *str) { char *i, c1, c2; unsigned long long count = 0;...
I would like to see a comparison with https://nim-lang.org/ https://www.youtube.com/watch?time_continue=1017&v=IVgNVJdizHg