Socket
Socket
Sign inDemoInstall

pyscheme

Package Overview
Dependencies
0
Maintainers
1
Alerts
File Explorer

Install Socket

Detect and block malicious and high-risk dependencies

Install

    pyscheme

Minimal r7rs scheme python library with a repl. Made by gpt, maintained by a human.


Maintainers
1

Readme

Minimal r7rs scheme python library with a repl. Made by gpt, maintained by human.

Warning

Under heavy development, use it at your own risk.

Install

pip install pyscheme

You may try latest features by using git to install

pip install git+https://github.com/dbian/pyscheme.git

Implemented Features

  • lexical scope let
  • begin, if, lambda, define... etc.
  • REPL, with clojure like *1 *2 *3 result cache support
  • install_func to extend scheme language, you can use it to install global variables too.
  • single line comment, start with ;
  • more

Usage

import pyscheme.scheme as sc
env = sc.new_env()
assert sc.run("(define bb (lambda (aa) (+ aa 2))) (bb 5)", env) == 7

def str_format_func(f, *args):
    return f % args
sc.install_func("format", str_format_func)

Todo

  • macros system
  • better token parsing
    • string support whitespace ( )
    • quote ' support
  • clojure pipeline operator support
  • module system
  • more

FAQs


Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc