10
$\begingroup$

Since PLDI is designed to help language developers, it's likely a lot of our users have developed or are developing interesting languages.

What languages (practical, golfing, or otherwise) have been created (or implemented) by our users? Make sure to include the following details:

  • Language name and creator
  • Links to resources, like documentation and compiler/interpreter
  • A brief description of the language, some of its main concepts and features, and its history
$\endgroup$
7
  • $\begingroup$ Related discussion on meta - languagedesign.meta.stackexchange.com/questions/334/… $\endgroup$ Jun 16, 2023 at 15:19
  • $\begingroup$ How about contributing to a language without being its (main) creator/implementer? $\endgroup$
    – Adám
    Jun 16, 2023 at 15:27
  • $\begingroup$ @Adám I'd imagine that'd be fine. I mean if it was something like "I PR'd a commit to GCC once" it might be kinda unnecessary, but even then the harm's minimal $\endgroup$ Jun 16, 2023 at 15:31
  • $\begingroup$ I have a feeling that would create too much traffic. What do you count as a contributor? Someone who has had a PR accepted with an implemtation or made a proposal for ISO C++? $\endgroup$ Jun 16, 2023 at 15:33
  • $\begingroup$ OK, but how about me designing core APL primitives? $\endgroup$
    – Adám
    Jun 16, 2023 at 15:37
  • $\begingroup$ It's always going to be a fuzzy line. The ones I listed for me were "I made significant contributions to the language, compiler, and/or standard library over the course of at least 6 months" or "I got paid to develop and maintain it for at least 6 months". That amount of time was arbitrary, but it felt fair to me. $\endgroup$
    – Pseudonym
    Jun 16, 2023 at 23:58
  • 2
    $\begingroup$ If we get too many esolangs we might want to split this into two separate questions. $\endgroup$ Jun 20, 2023 at 20:01

11 Answers 11

8
$\begingroup$

Mercury

Purely declarative logic language with modules, strong types, strong modes, strong determinism, and strong purity.

I am not the "creator" of the language, that was my postgrad supervisor Zoltan Somogyi. I was one of the first developers, working mostly on static analysis and optimisation.

Proprietary stuff

Some proprietary work that you can't see without paying money, so it's not fair to promote it here:

  • Embedded scripting language for a database server (think PL/SQL and you'll get the general idea).

  • Shading language for an offline renderer (pretty close to RenderMan SL circa 2001).

$\endgroup$
5
$\begingroup$

I'm head of language design at Dyalog Ltd, so I've had my hands in quite a few new features and extensions to existing features of Dyalog APL which itself extends the core APL that is more than half a century old. I:

  • was instrumental in adding for Partition (without resorting to changing ⎕ML Migration Level and Nest

  • suggested the A⍨ Contant operator

  • chose the exact design when adding the f⍥g Over and f⍤g Atop operators

  • designed all the X⊆Y Partitoned Enclose extensions

  • was one of the main designers of the ⎕DT Date-Time conversion library which enables conversion between all known date-time formats (let me know if you find one that is missing!)

I designed and implemented several always-available utilities (so kind-of like in a standard library), implemented in APL:

  • ]Get a command to fetch basically anything from basically anywhere (e.g. import a function directly off GitHub, or bring all the CSV files in a ZIP file in as matrices)
  • ]CopyReg a utility to port registry settings between Dyalog installations
  • ]Repr a utility that takes almost any APL value and represents it in a number of formats
  • ]View which shows a result in a pop-up instead of in the REPL
  • ]Format which can indent text and wrap it to fit the available space
  • ]Layout which lays out text by padding with spaces according to rules inferred from existing spaces (e.g. margins and hanging indents with tab stop)
  • ]APLCart and ⎕SE.Dyalog.Utils.APLcart that let users search the APLcart phrase library in various ways
  • ]Config and ⎕SE.Dyalog.Utils.Config providing a nicer way to query configuration parameters (incl. environment variables)
  • ]Help to get help on most any Dyalog subject
  • ⎕SE.Dyalog.ExpandConfig providing template strings for configuration parameters using all known formats

I also came up with the final design for the array notation and the next three new built-ins that will go into Dyalog 20.0:

I'm currently working on the specification for a system to set and dereference names in objects, something that's sorely needed in Dyalog APL.

To play with possible future extensions, I created Extended Dyalog APL and Dyalog APL Vision which I implemented in normal Dyalog APL using transcription to that same language. Extended goes a bit overboard, with various arithmetic functions performing lettercase conversions, an interface to a library, an operator to provide probability functions, a function for template strings, and more. Vision is more realistic and includes few entirely new built-ins.

I came up with the idea for several parts of BQN (a derivative of APL):

  • Array notation
  • Computed axes in Reshape
  • Cross-roles, being able to change syntactic class of a user-defined item by changing the capitalisation of its name

I've also implemented a couple of things that can be used either as utility libraries or stand alone code golf languages. Each one is a relatively thin wrapper on a single Dyalog APL operator:

  • Stencil wraps the Stencil operator and is really good at most tasks that involve cellular automatons. Conway's game of life is just 3∊me in Stencil: m is the count of non-empty cells in the Moore neighbourhood including the cell itself, and e is the count without itself. 3∊ checks if 3 is a member of the set of those two counts.
  • QuadR and QuadS wrap the ⎕R and ⎕S Replace and Search operators and are amazing at regex and other text pattern algorithms, due to handling multiple patterns in parallel. For example can QuadR switch the letters a and b with the following program:
    a
    b
    b
    a
    

All three languages have access to the full power of APL when needed.

$\endgroup$
4
$\begingroup$

I have a few:


Papyrihome page, tutorial, compiler

A programmable markup language which compiles to HTML. It's a (mostly) pure functional language where you can mix declarations and expressions in with literal text, and (most) HTML is valid Papyri.

A lot of the design is inspired by TeX and Python; it's supposed to be useful both for formatting individual snippets or documents, and for full static site generators.


MJrhome page, documentation, playground example

A probabilistic programming language based on rewriting patterns in a 2D grid. It's heavily inspired by MarkovJunior, and designed for writing procedural generation algorithms.

The online examples linked from the home page will do a better job of showing how the language works than I can here in a paragraph or two.


fffffhome page, documentation, REPL

A silly stack-based concatenative language. The main difference to other stack-based languages is that you can create new stacks, and push stacks to other stacks. Also it has dynamic scopes, and scopes are first-class objects.

It's a toy language more than a joke language, but still not meant for actually writing in.

$\endgroup$
3
$\begingroup$

Trilangle

Trilangle is a 2-D esolang that I made in February 2023. Though not designed as a golflang, it ends up being fairly competitive in certain challenges.

It was originally inspired by Hexagony, though it came to be rather different. The biggest differences include:

  • Though the code grid is still hexagonal, its bounding box is triangular.
  • The memory model is a stack rather than a grid.
  • Certain letters and numbers are operations, expanding the instruction set but necessitating a separate "push" instruction.
  • When the IP walks off the edge of the code grid, it continues on the row or diagonal to its left, rather than on the opposite side of the grid.
  • Instead of bigints, the program operates on 24-bit integers.

The fact that it's a stack, and you can only modify the top of the stack, made Turing completeness difficult. See the old proof of TC'ness from Trilangle 1.0. The modern version looks rather different, since the threading operator means you can have multiple stacks. Though I haven't needed this for code golf yet, I use this in my implementation of selection sort (colorized version here).

String processing is a downright pain, though that's not entirely unintentional. Hello, World ends up being a somewhat longer program:

        "
       H o
      o " !
     " o ( o
    e o o o l
   o " " " o "
  " , W r " ! 3
 l o o o d o : o
o " " " o ' ( @ .

Or, condensed (newlines, spaces, and trailing NOPs removed):

"Hoo"!"o(oeooolo"""o"",Wr"!3looodo:oo"""o'(@

To help me design and debug these programs, I've invented an assembly-like syntax for these programs. It represents 2D branches and loops with BNG (branch if negative) and JMP (jump) instructions. For example, the (2-D) source code and assembly for cat are as follows:

    #
   @ .
  . L \
 v i o .
. _ \ , .
0.0:    NOP
0.1:    NOP
0.2:    NOP
0.3:    NOP
0.4:    GTC
0.5:    BNG 2.0
1.0:    NOP
1.1:    PTC
1.2:    NOP
1.3:    POP
1.4:    NOP
1.5:    NOP
1.6:    JMP 0.3
2.0:    EXT

Of course, this contains a lot of extraneous NOPs. Any instruction that unconditionally redirects the IP is represented with NOP by the disassembler, so there's a flag to hide NOPs (-n on the CLI; always on in the online interpreter). With that flag set, the assembly just becomes:

0.4:    GTC
0.5:    BNG 2.0
1.1:    PTC
1.3:    POP
1.6:    JMP 0.3
2.0:    EXT

GTC and PTC stand for "getchar" and "putchar" respectively -- though they use Unicode characters rather than bytes, translating between UTF-8 in the terminal and UTF-32 in the program itself.

For the most part, the instruction set contains a lot of what you'd expect for an integer-only stack-based language -- arithmetic, bitwise operations, branch on sign, and I/O -- but it also contains a few interesting choices. For example, T (get current time) uses a unit of 1/97 second*, so that the full day spans from 0 at midnight to 0x7fffff right before midnight. The threading operator is also heavily overloaded.

Finally, just for fun: here's a program that doesn't halt on weekends.

    <
   ' D
  ' - 2
 2 ' % 7
@ > { # -

*More accurately, there are 97.0903588 time units to the second.

$\endgroup$
3
$\begingroup$

VK

VK means virtual continuation, while VC sounds like Visual C, I usually call her by the nickname Valkyrie.

It aims to provide clearer logic and higher extensibility than existing programming languages.

Extensibility here refers to injecting additional logic without changing the source code.

This is achieved by the following features.

First Class Continuation

VK is a first class continuation language, but closer to traditional procedural languages.

For example, you can directly write:

iter.map { if a { break } }.and_then { ...}

You don't need to rewrite it into flat_map + Result or other strange ways of writing, which is not easy to change when the logic is complex.

In fact, break here contains an implicit call site, and just pass the current continuation directly.

On the other hand, each EffectHandler corresponds to a continuation, but this is hidden by structured programming in VK.

Because of these behaviors, I call it virtual continuation.


Effect System

The effect system can separate the required data and the behavior of providing data, making the code logic clearer.

The effect system has undergone many changes. The current version of effect is an associated method, and all types can be used as effects.

class DivideError: Error {
    numerator: Integer
    # The left side represents the uploaded parameters,
    # and the right side represents the downloaded parameters
    effect divide_zero(numerator: Integer) -> Integer / Pure {
        # Must return Self, must be a Pure function
        new Self { numerator }
    }
}

The type signature part is divided into two parts Type + Effect, both of which can be omitted, the default value of Type is Unit, and the default value of Effect is Pure.

There are two kinds of pattern match, match matches Type, catch matches Effect, raise changes Type to Effect, resume changes Effect to Type.

This part is still very unstable, sometimes works, sometimes loses, there is still a long way to go.


Row Polymorphism

After exploring for a while, I found that subtyping is unavoidable in the effects system.

I found a nice subtyping system called Scoped Row Type, and encoded theses traditional constructs in FP(ADT + type class) and OOP(subclass + interface).

There are a lot of define keywords in VK, but this is for clearer engineering, in fact, they are all syntax sugar of Record.

  • structure + extends: Separate Record's data and implementation.
  • class: A structure automatically implement some interfaces and traits.
  • interfaces: Virtual base class that does not participate in MRO.
  • trait: The interface that every subclass is forced to reimplement.
  • enumerate: A number which various methods are appended.
  • flags: A number used to label different dualistic behaviors.
  • unite: Disjoint union of types, closed subtype.
$\endgroup$
2
$\begingroup$

I guess I’m known for making Kitten, although it was never finished. It’s a statically typed concatenative functional language, whose type system is meant to be basically Hindley–Milner plus algebraic effects, and whose syntax bears a passing resemblance to Python.

Currently I’m working on another language called Calico, which is vaguely similar, but informed by a decade more experience. I’m trying to use modal substructural types to enable lazy functional logic programming without a garbage collector.

As for proprietary stuff, I worked at Groq for a few years, where I designed a couple versions of the chip’s assembly language. It tries to make the VLIW-ish hardware look more RISC-ish and smooth out some of the rough edges of the microarchitecture, so that it’s easier to use as a compiler target.

$\endgroup$
2
$\begingroup$

I worked on a few experimental languages. Some of the published ones:

MBase is a mostly self-hosted DSL for writing compilers, which is not technically a single language, but a growing hierarchy of languages. See documentation here. It contains quite a few small languages inside - a Prolog implementation, a simple ML on top of it, a subset of C# for better CLR interoperability, etc.

The language starts as a tiny Lisp dialect and grow into a host of languages with a complex extensible syntax and a set of features geared mainly towards compiler construction (somewhat resembling the approach of Nanopass).

CLike is one of the languages built with MBase but not targeting it. It compiles via LLVM or using my own subset of LLVM IR compiler. Main application of this language is software-hardware co-design. It is a superset of a subset of C with extensible syntax, allowing to do some really fun stuff.

PyExpert is an experimental Prolog implementation (a similar one is also included into MBase), with a built in tracing that can be used for narrating the path it came to a given result or a set of possible results. It was used for some ad hoc expert systems for natural language narrated decision explanations.

$\endgroup$
2
$\begingroup$

VioletScript is familiar for TypeScript users. It has been developed for years and isn't yet ready for use, but is fully documented and designed. In terms of productivity and performance, it can be compared to C# and Java.

Its major difference from TypeScript is the type system being just a little more simpler and not performing type erasure, however it's very flexible. E.g. you can assign a literal {} to a Map.<K, V> (similiar to TypeScript's Record) and destructure it:

this._sublayer.open({ character });

class Sublayer {
    function open(data: Map.<*, *>): void {
        const { character } = data;
    }
}
$\endgroup$
1
$\begingroup$

DyT

DyT is simple markup language (Dynamic Text).

Variables in DyT


Variables are text between two $. It replaces with the following values.


Simple usage:

Hello $name$!

$name$ is variable, but the name of the variable is name.

If you transform this DyT into text with variable name equals to Bob, you get this text:

Hello, Bob!

And it's all, DyT support only variables now.

Python parser

$\endgroup$
1
$\begingroup$

I (Teo Samaržija) have created a programming language called AEC (ArithmeticExpressionCompiler). The documentation for it is available on my website. Right now, I have made two compilers for it, one compiler targetting x86 (it is written in JavaScript and the core can be run in a browser) and one compiler targetting WebAssembly (written in C++). The compiler targetting WebAssembly has a lot more features and is coded a lot more professionally. AEC is a low-level programming language (designed to be easy to interface with assembly) with a syntax inspired by BASIC and ADA.

I have also implemented PicoBlaze Assembly Language in my PicoBlaze Simulator in JavaScript.

$\endgroup$
1
$\begingroup$

NML

Nicks Markup Language

NML is simple markup language

Grammar:

[<KEYWORD> [<ARGUMENT>, [...]],
[...]]

Example (like go.mod):

module github.com/someone/test

go 1.20

require github.com/anotherone/blablabla
$\endgroup$

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .