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.24.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.24-py3-none-any.whl (30.0 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: syncraft-0.1.24.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.24.tar.gz
Algorithm Hash digest
SHA256 76728f2439eb5f2e4c33e45adc2b893bc5e8a39aab7b738228962bc07b2927c8
MD5 3830f969d02a00ef48b5a4915f53d5e6
BLAKE2b-256 42d52b38cdc7d9f3170cc2662307e513f56dd72159521dc1890be5656b28e5f2

See more details on using hashes here.

File details

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

File metadata

  • Download URL: syncraft-0.1.24-py3-none-any.whl
  • Upload date:
  • Size: 30.0 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.24-py3-none-any.whl
Algorithm Hash digest
SHA256 132c5a8c89fbbfa5b9cdde87988d7b3765554b9a4bcd58542e2b001bc7f608f5
MD5 88012cbda6cb7ec45583f48e4309530b
BLAKE2b-256 ea9069a33e2e11f5c2585bcd74c569ff2219173c52f17d7fc54a7c878a09374f

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