A programming language where comments are the first-class citizen and ASCII art flowcharts are the controls!

Overview

regretti github doesn't have this emoji :( 🍝

A programming language where comments are the first-class citizen and ASCII art flowcharts are the controls!


Made for Lang Jam (jam0001) theme: first-class comments in 48 hours.

Summary

What if all those "TODO:" comments and beautiful ASCII art diagrams in your code actually worked? Presenting you the one and only regretti, write your spaghetti and forgetti!

Basically, I took the theme "literally"!

So comments are commands!

You can only run instruction statements inside a comment! πŸ’¬

Table of Contents

Goals

  • Teaching: What initially started as a troll/esoteric language, this language could be used to teach kids "Control Flows" visually.
  • Fast: The existing functionality/examples runs faster than most interpreted languages!
  • Helpful Error Messages: Almost every errors will be catched and prints out a helpful error message as to denote what went wrong. (Inspired from Rust ❀️ )

Installation

NOTE: Please run on Linux.

$ git clone https://github.com/mufeedvh/regretti.git
$ cd regretti/
$ cargo build --release
$ ./target/release/regretti

Hello World

Lo and behold!

main:
    /*
        +----------------------+
        | print "Hello World!" |
        +----------------------+
    */

Loops


main:
    let count = 69420

    /*
        +--------+
        | loop 5 |<----------+
        +--------+           |
             |               v
             |               +-------------+
             |               | print count |
             |               +-------------+
             |               ^
             |               |
             +---------------+
    */
:end

Get more examples below!

Examples

Examples are the best way to learn regretti, these cover all the features and functionalities of the language:

All other examples have not been completely implemented yet.

Also I am pretty sure there are a lot of bugs, this is probably the most obscure syntax for parsing lol...

Flow Charts?

Internals

In a nutshell:

https://xkcd.com/1209/


You might also like...
😱 Dead fast thumbnail library for browser and NodeJs! Built with Rust πŸ¦€ and WebAssembly πŸ•Έ

thumbo-core 😱 Dead fast thumbnail library for browser and NodeJs Built with Rust πŸ¦€ & WebAssembly πŸ•Έ πŸ“– About thumbo-core is a thubnail library for b

Takes a folder of images (as a palette), and an image, and figures out how to tile the palette to resemble the image!
Takes a folder of images (as a palette), and an image, and figures out how to tile the palette to resemble the image!

Takes a folder of images (as a palette), and an image, and figures out how to tile the palette to resemble the image!

Encoding and decoding images in Rust
Encoding and decoding images in Rust

Image Maintainers: @HeroicKatora, @fintelia How to contribute An Image Processing Library This crate provides basic image processing functions and met

Convert and save photomode screenshots from Red Dead Redemption 2 to JPEG format.
Convert and save photomode screenshots from Red Dead Redemption 2 to JPEG format.

RDR2 Screenshot converter Convert and save photomode screenshots from Red Dead Redemption 2 to JPEG format. QuickStart Just download the executable fi

Classical Rainbow Triangle using Rust and Vulkan via vulkano bindings
Classical Rainbow Triangle using Rust and Vulkan via vulkano bindings

Vulkano Rainbow Triangle Classical Rainbow Triangle using Rust and Vulkan via vulkano bindings. Based on the vulkano triangle example Quick Start $ ca

Lust is a static image server designed to automatically convert uploaded image to several formats and preset sizes
Lust is a static image server designed to automatically convert uploaded image to several formats and preset sizes

What is Lust? Lust is a static image server designed to automatically convert uploaded image to several formats and preset sizes with scaling in mind.

A linear algebra and mathematics library for computer graphics.

cgmath-rs A linear algebra and mathematics library for computer graphics. The library provides: vectors: Vector2, Vector3, Vector4 square matrices: Ma

Signed distance field font and image command line tool based on OpenCL.

SDFTool Signed distance field font and image command line tool based on OpenCL. Build Windows Run cargo build --release in Visual Studio developer x64

@Buildspace project creating a Web3 Solana Dapp with React and Rust
@Buildspace project creating a Web3 Solana Dapp with React and Rust

buildspace Solana GIF Portal Project Welcome πŸ‘‹ To get started with this course, clone this repo and follow these commands: Run npm install at the roo

Owner
Mufeed VH
organized chaos.
Mufeed VH
A simple command-line utility (and Rust crate!) for converting from a conventional image file (e.g. a PNG file) into a pixel-art version constructed with emoji

EmojiPix This is a simple command-line utility (and Rust crate!) for converting from a conventional image file (e.g. a PNG file) into a pixel-art vers

Michael Milton 22 Dec 6, 2022
Converts images into textual line art.

img2utf Transform images to textual line art! Images require pre-processing to come out nice. It's expected that users will do the following: Apply ga

Lee 149 Dec 10, 2022
My personal project for generative art.

Generative Art This is my personal project for making Generative Art. Installation There are three ways of getting the binary. You can either download

null 26 Nov 17, 2022
CLI and utilities for converting media files (images/videos) to ascii outputs (output media file or print to console)

CLI and utilities for converting media files (images/videos) to ascii outputs (output media file or print to console). Supports most standard image formats, and some video formats.

Michael 30 Jan 1, 2023
Convert your ascii diagram scribbles into happy little SVG

Svgbob Svgbob can create a nice graphical representation of your text diagrams. Svgbob provides a cli which takes text as an input and creates an svg

Jovansonlee Cesar 3.4k Dec 25, 2022
A Simple Image to Ascii converter in Rust

Image to Ascii A Simple Image to Ascii converter in Rust Brief ?? In my way to learn Rust i decided to make this converter. Challenges ?? new to Rust

WasixXD 7 Sep 16, 2022
Get the first frame of a Gif image.

Gif First Frame Use wasm to capture the first frame of a Gif image.

lijialiang 3 Apr 8, 2022
Rust based breadth first search maze image solver

maze_solver Rust based breadth first search maze image solver Works on black and white images with provided start and end points. Usage: maze_solver

null 0 Jan 31, 2022
Face detection library for the Rust programming language

Rustface SeetaFace detection library for the Rust programming language Example of demo program output SEETAFACE C++ – Github repository for the origin

Andrei Tomashpolskiy 323 Dec 27, 2022
a cute language with a bunch emoji🐢

nylang a cute language with a bunch emoji documentation WIKI usage dependancies rust ( cargo ) install & uninstall install chmod +x scripts/install.sh

jumango pussu 13 Jul 4, 2022