Skip to main content

Parser combinator library

Project description

Syncraft

Syncraft is a parser/generator combinator library with full round-trip support:

  • Parse source code into AST or dataclasses
  • Generate source code from dataclasses
  • Bidirectional transformations via lenses
  • Convenience combinators: all, first, last, named
  • SQLite syntax support included

Installation

pip install syncraft

TODO

  • Add a collect method to AST to collect all named entries and pack them into a dict or a custom dataclass. This method will be called as the last step of my current bimap. So it shares the signature of bimap and can combine with the current bimap
  • Amend all, first, last, and named helper functions to support bimap and named results.
  • Try the parsing, generation, and data processing machinery on SQLite3 syntax. So that I can have direct feedback on the usability of this library and a fully functional SQLite3 library.
  • Make the library as fast as possible and feasible.

Project details


Download files

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

Source Distribution

syncraft-0.1.25.tar.gz (29.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

syncraft-0.1.25-py3-none-any.whl (30.1 kB view details)

Uploaded Python 3

File details

Details for the file syncraft-0.1.25.tar.gz.

File metadata

  • Download URL: syncraft-0.1.25.tar.gz
  • Upload date:
  • Size: 29.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for syncraft-0.1.25.tar.gz
Algorithm Hash digest
SHA256 3b73777a707ac1cf5d63c4b49d9f89188f76b9dc4f6f45dd1b9f0c69a7dbd30a
MD5 f2a20b804b0c3b7554414dc47fc75dcd
BLAKE2b-256 012db7886c925425544dfdf5ecacfacb712c13164232ba28a2b6fc9a19337480

See more details on using hashes here.

File details

Details for the file syncraft-0.1.25-py3-none-any.whl.

File metadata

  • Download URL: syncraft-0.1.25-py3-none-any.whl
  • Upload date:
  • Size: 30.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for syncraft-0.1.25-py3-none-any.whl
Algorithm Hash digest
SHA256 3ef955a1390c0182f48db8be9214c928c145b69fd20667ae746dba2af1afa166
MD5 a341230b60e8e69d0bb8ee0c85e42ba4
BLAKE2b-256 792be26b7a24db650f254b1f40d90a6df6bc8f0790f3abacd9466ffa1855377b

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