Giter Club home page Giter Club logo

pancake's Introduction

Pancake

A simple dynamic, concatenative language made for fun, in the course of learning Rust.

The name was supposed to be some kind of joke about stacks.

Apparently somebody made a stack-based esolang with this name in 2013 but it seemed like a meme. The name is up for change if somebody ever complains to me about it.

Fun fact: pancake uses the parser library nom. No, this joke has not gone too far.

Motivation

I want to learn Rust and design a simple programming language. Why not both at the same time?

Concatenative languages are interesting, since, in some sense, they exist at an intersection of functional and imperative programming. We can reason about their semantics as a transformation of a single, global state, with actual changes restricted. However, in implementation, we just push and pop from a stack. Nice and simple.

With that in mind, I have a few basic goals (in rough order of priority):

  • Make the language ergonomic. It should be easy to read and write code in Pancake, given experience corresponding to the complexity of the code.
  • Keep the core language relatively simple and small. Note that this only applies semantically. Concatenative languages require many combinators to be properly ergonomic, but it should be a goal to use a flexible, simple set of them, which can be composed, and it should usually be the case that complex primitives are semantically equivalent to some combination of simple primitives.
  • Make good use of Rust's features and ecosystem for a safe and performant implementation. This is partially a personal goal, as mentioned above, of course. However, a clean implementation is also obviously ideal, and I wouldn't be using Rust if it didn't lend itself to that.

On the other hand, there are explicit non-goals at present.

  • Static compilation / safety guarantees. These are just outside the scope of my interest at the moment, especially for a language which is mostly being designed ad-hoc.
  • Maximizing performance. Performance needs to be kept at a reasonable level, of course. However, making a JIT compiler and/or performing micro-optimizations is difficult, and again, outside the scope of my interest. Wherever the Rust ecosystem makes it relatively easy to get performance wins, I will try to do so.

See Also

pancake's People

Contributors

rationalis avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.