Factor is a modern concatenative programming language with FORTH-like syntax and a rich standard library.
http://factorcode.org
#forth #plt #programming #retro #compiler
http://factorcode.org
#forth #plt #programming #retro #compiler
Pika is a bottom-up right to left parsing algorithm based on ideas of the packrat parser. It uses a dynamic programming approach to resolve two well known problems of recursive descent parsers: left recursion and error recovery.
https://arxiv.org/pdf/2005.06444.pdf
#parsing #plt #paper
https://arxiv.org/pdf/2005.06444.pdf
#parsing #plt #paper
An article on an ahead of time binary translator that translates NES ROMs to native x86_64 executables.
https://andrewkelley.me/post/jamulator.html
#nes #plt #virt #system #programming #llvm
https://andrewkelley.me/post/jamulator.html
#nes #plt #virt #system #programming #llvm
Cowgol is a simple programming language inspired by Ada. The language has been greatly simplified to enable easy but effective compilation for small platforms like Zilog Z80, Intel 8080, MOS 6502, Motorola 68K, and others.
The Cowgol compiler is bootstrapped and written in Cowgol itself. It uses a simple table-driven code generator but performs several optimizations. The code of the compiler is very accurate and pleasant to read.
https://github.com/davidgiven/cowgol
#plt #compiler #system #programming
The Cowgol compiler is bootstrapped and written in Cowgol itself. It uses a simple table-driven code generator but performs several optimizations. The code of the compiler is very accurate and pleasant to read.
https://github.com/davidgiven/cowgol
#plt #compiler #system #programming
GitHub
GitHub - davidgiven/cowgol: A self-hosted Ada-inspired programming language for very small systems.
A self-hosted Ada-inspired programming language for very small systems. - davidgiven/cowgol
Camlboot is an attempt to bootstrap the OCaml compiler.
The approach is as follows:
- Compile guile with GCC;
- Run MiniML compiler written in guile;
- Compile OCaml interpreter written in MiniML;
- Run the OCaml interpreter to compile OCaml.
https://github.com/Ekdohibs/camlboot
#plt #fp #ocaml #bootstrap #guile #lisp #gcc
The approach is as follows:
- Compile guile with GCC;
- Run MiniML compiler written in guile;
- Compile OCaml interpreter written in MiniML;
- Run the OCaml interpreter to compile OCaml.
https://github.com/Ekdohibs/camlboot
#plt #fp #ocaml #bootstrap #guile #lisp #gcc
GitHub
GitHub - Ekdohibs/camlboot: Experiment on how to bootstrap the OCaml compiler
Experiment on how to bootstrap the OCaml compiler. Contribute to Ekdohibs/camlboot development by creating an account on GitHub.
I've always been attracted to minimalistic programming languages. Among them were Scheme, TCL, Rebol, Smalltalk and of course Forth. I didn’t write big programs on these languages, but each of them taught me something. Unfortunately, many of them have remained niche and are not widely used in business. Well, okay, the main thing is that programming in these languages makes us a little happier, right? Today I propose to take a look at a modern programming language that develops ideas of Forth.
Retro is a minimalistic modern Forth-like language with a miniature virtual machine implemented in a variety of programming languages. Despite its minimalism, it remains a pragmatic language that allows you to solve real problems.
Just in case, let me remind that I have already written about other Forth-like modern languages, for example, about Factor (1, 2).
#forth #minimalism #plt #programming #retro
Retro is a minimalistic modern Forth-like language with a miniature virtual machine implemented in a variety of programming languages. Despite its minimalism, it remains a pragmatic language that allows you to solve real problems.
Just in case, let me remind that I have already written about other Forth-like modern languages, for example, about Factor (1, 2).
#forth #minimalism #plt #programming #retro
Telegram
Zero Dereference
Factor is a modern concatenative programming language with FORTH-like syntax and a rich standard library.
http://factorcode.org
#forth #plt #programming #retro #compiler
http://factorcode.org
#forth #plt #programming #retro #compiler
I read once that the best programming language is two programming languages. I don’t remember who this phrase belongs to, but it’s true.
There is always code that needs serious optimization. But there is also a code that is used as glue. This code doesn't need to be very fast. Usually, most of the code in a project is glue code.
There is a family of programming languages that are used in cases where high-performance fragments in C or C++ need to be glued together into a single program. Most often, Lua and Python are used for this. Less often, TCL appears on the scene.
Fortunately, progress does not stand still and new languages appear, made specifically for embedding into other programs.
I recently came across Wren, a simple and fast language with support for traditional class-based OOP. Unlike Lua, which uses a metatable-based approach similar to object prototypes.
Wren was created by Robert Nystrom, the author of Crafting Interpreters. Robert is currently working on the Dart language at Google.
Another great embedded language is fe. It was created by rxi, famous for their minimalist libraries and programs. fe is a small lisp-like language designed specifically to run in resource-constrained environments. One may think that such a small language is of little use. But this is not the case. fe is easily extensible with C code and supports macros. Check out what awesome fantasy console rxi has made. The binary image is only 60 kilobytes!
You may remember that I already wrote about another embeddable Lisp-like programming language called Janet.
#plt #minimalism #embedded #c #lisp
There is always code that needs serious optimization. But there is also a code that is used as glue. This code doesn't need to be very fast. Usually, most of the code in a project is glue code.
There is a family of programming languages that are used in cases where high-performance fragments in C or C++ need to be glued together into a single program. Most often, Lua and Python are used for this. Less often, TCL appears on the scene.
Fortunately, progress does not stand still and new languages appear, made specifically for embedding into other programs.
I recently came across Wren, a simple and fast language with support for traditional class-based OOP. Unlike Lua, which uses a metatable-based approach similar to object prototypes.
Wren was created by Robert Nystrom, the author of Crafting Interpreters. Robert is currently working on the Dart language at Google.
Another great embedded language is fe. It was created by rxi, famous for their minimalist libraries and programs. fe is a small lisp-like language designed specifically to run in resource-constrained environments. One may think that such a small language is of little use. But this is not the case. fe is easily extensible with C code and supports macros. Check out what awesome fantasy console rxi has made. The binary image is only 60 kilobytes!
You may remember that I already wrote about another embeddable Lisp-like programming language called Janet.
#plt #minimalism #embedded #c #lisp
GitHub
GitHub - rxi/fe: A tiny, embeddable language implemented in ANSI C
A tiny, embeddable language implemented in ANSI C. Contribute to rxi/fe development by creating an account on GitHub.
PlanckForth is a FORTH-like programming language bootstrapped from a hand-crafted ELF-binary. Just pass
Let me remind you of another minimal FORTH compiler called StoneKnifeForth. It uses one-letter keywords and can be bootstrapped with a tiny interpreter (300 lines) written in Python.
#forth #lowlevel #plt #bootstrap
planck.xxd
through the xxd command-line tool and get an x86 executable. Then bootstrap.fs
can be loaded to get a familiar FORTH environment with long keywords, arrays, hash tables, and strings.Let me remind you of another minimal FORTH compiler called StoneKnifeForth. It uses one-letter keywords and can be bootstrapped with a tiny interpreter (300 lines) written in Python.
#forth #lowlevel #plt #bootstrap
GitHub
GitHub - nineties/planckforth: Bootstrapping a Forth interpreter from hand-written tiny ELF binary. Just for fun.
Bootstrapping a Forth interpreter from hand-written tiny ELF binary. Just for fun. - GitHub - nineties/planckforth: Bootstrapping a Forth interpreter from hand-written tiny ELF binary. Just for fun.
Rochus Keller is a guy who tends to implement various old programming languages. He has lots of projects on GitHub. All of his projects have three things in common:
1. They use LuaJIT bytecode as a target language
2. They include not only compilers but also full-featured IDEs with debuggers
3. They are written in C++ with Qt.
Rochus has created such development environments for Smalltalk-80, Simula, Som, Algol-60, and Oberon+. The last one is an Oberon-like programming language compatible with Oberon, Oberon II, Oberon 07 and extended by some new features like UTF-8, generics, and FFI.
#plt #smalltalk #oberon #compilers #lua
1. They use LuaJIT bytecode as a target language
2. They include not only compilers but also full-featured IDEs with debuggers
3. They are written in C++ with Qt.
Rochus has created such development environments for Smalltalk-80, Simula, Som, Algol-60, and Oberon+. The last one is an Oberon-like programming language compatible with Oberon, Oberon II, Oberon 07 and extended by some new features like UTF-8, generics, and FFI.
#plt #smalltalk #oberon #compilers #lua
GitHub
rochus-keller - Overview
see http://rochus-keller.ch. rochus-keller has 69 repositories available. Follow their code on GitHub.
In his finished series of posts Max Bernstein shows how to write a Lisp interpreter in OCaml. He also has an ongoing series on compiling Lisp to x86 machine code.
#plt #lisp #compilers #ocaml
#plt #lisp #compilers #ocaml
Max Bernstein
Writing a Lisp, Part 0: Fundamentals
So you want to write a Lisp interpreter. I did too, and then I wanted to write about it, so here we are with this post series.