Skip to main content

Call nim functions from Python.

Project description

A wrapper to allow nim functions to be called in Python.

It requires a nim package (also called PyNimFFI) to be installed, through nimble.

It uses cffi, and has some performance overhead, but has a reasonable number of features.

Ints, cstrings, and floats can be sent natively.

Exceptions are wrapped, and propagated back to Python.

Opaque types can be wrapped as subclasses of a “NimBase” class, and have a delete method created (which decrements the nim ref count - allowing garbage collection to happen correctly).

Note, there is apparently another nim / python bridge in the works, and may turn out to be better.

Project details


Release history Release notifications | RSS feed

This version

0.1

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

PyNimFFI-0.1.tar.gz (4.6 kB view details)

Uploaded Source

File details

Details for the file PyNimFFI-0.1.tar.gz.

File metadata

  • Download URL: PyNimFFI-0.1.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for PyNimFFI-0.1.tar.gz
Algorithm Hash digest
SHA256 ffab6db3b8d739f39e8cc64b6e4f8c48250f3a1a0eb89987e55e460075e7da20
MD5 f38de38cd42f7b846eff57940e6a16db
BLAKE2b-256 9757edb2f46d0915fef076ab167fb28c787285605d7690b0edb2164c5bfbe126

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page