POP-2000, a lingua-franca POP-2 dialect
Devine and the reporter have been discussing POP-2, a programming language from the 1970s that originally catered to the same circles as early Lisp dialects. The two were intrigued by POP-2's potential as a lingua franca for tiny systems, leading to the creation of POP-2000, a standardized dialect designed to support systems-level features.
POP-2 is a concatenative language, which allows for the creation of new functions and constructs through juxtaposition and composition. The reporter finds the language easy to write an interpreter/compiler for while still providing low-level control. Coming from a background in creating constructed languages, the reporter prioritizes the language development aspect rather than creating practical software.
The goals of language design for POP-2000 align with the original POP-2 papers. The minimal implementation supports declaring multiple variables, defining functions, basic control flow, input/output, and looping via labels and gotos. The language operates on a stack-based system, where values manipulate the stack and operators perform operations on the stack.
To make POP-2000 user-friendly, the reporter aims to add memory management, support for different-width values, and a more universal I/O system. The language is meant to be a social exercise, allowing newcomers to start with an easy-to-learn language that runs on multiple small systems while providing an easy-to-implement compiler for the creators of those systems.
The reporter has been working on the grammar for POP-2000 in EBNF notation and plans to create a Git repository with the standard soon. Initially targeting the ok VM, the reporter hopes to release a reference implementation compiler in C. Once the repository is set up, the reporter will add the standard to their article.
Written by urgent.news from Lobsters's reporting — not their text. Machine-written — may contain errors; check the original before relying on it.