Closed teskje closed 4 years ago
Thanks for your pull request. It looks like this may be your first contribution to a Google open source project (if not, look below for help). Before we can look at your pull request, you'll need to sign a Contributor License Agreement (CLA).
:memo: Please visit https://cla.developers.google.com/ to sign.
Once you've signed (or fixed any issues), please reply here with @googlebot I signed it!
and we'll verify it.
ℹ️ Googlers: Go here for more info.
@googlebot I signed it!
Thanks for your comments @plusvic! I addressed them and also added a test for matching against a memoryview
.
I created this PR from the master branch of my fork and there seems to be no way to change the source branch except for opening a new PR. So I'm closing this one in favor of #152.
This makes rules matching compatible with data objects
PyArg_ParseTuple
does not consider read-only (even though they might actually be), such a memoryviews. The main change is replacing thes#
formatter withs*
and replacing the(pointer, length)
pair with aPy_buffer
object accordingly. Additional care must be taken to release thePy_buffer
on every error path.Solves #147