From 41cb98d4b3313c8abe166473b931b515e64cf1a2 Mon Sep 17 00:00:00 2001 From: Marshall Lochbaum Date: Wed, 21 Jul 2021 22:08:15 -0400 Subject: Revise main implementation README --- docs/implementation/index.html | 12 ++++++------ docs/implementation/primitive/index.html | 1 + 2 files changed, 7 insertions(+), 6 deletions(-) (limited to 'docs') diff --git a/docs/implementation/index.html b/docs/implementation/index.html index ccfaa132..4cf1d1dc 100644 --- a/docs/implementation/index.html +++ b/docs/implementation/index.html @@ -5,16 +5,16 @@

BQN implementation notes

-

Notes about how BQN is implemented. There's not too much here yet.

+

Notes about how BQN is or could be implemented.

+

This repository's BQN implementation is written mainly in BQN: the bytecode compiler is completely self-hosted, and the majority of the runtime (r0, r1) is written in BQN except that it is allowed to define primitives; some preprocessing (pr) turns the primitives into identifiers.

+

The remaining part, a Virtual Machine (VM), can be implemented in any language to obtain a version of BQN running in that language. The VM used for the online REPL is the Javascript implementation, while CBQN is a more advanced VM in C. There are platform-specific and generic tests in the test directory.

-

This repository's BQN implementation is written mainly in BQN: the bytecode compiler is completely self-hosted, and the majority of the runtime (r0, r1) is written in BQN except that it is allowed to define primitives; some preprocessing turns the primitives into identifiers. The remaining part, a VM, can be implemented in any language to obtain a version of BQN running in that language.

-

The VM used for the online REPL is the Javascript implementation. The bytecode matches dzaima/BQN's format, and an extension to the compiler adjusts the slightly different block declarations to target dzaima+reference BQN. An earlier experiment targetting WebAssembly works only on a very small subset of BQN. All versions have automated tests in the test directory.

-

I have also held some forum discussions on the actual workings of the compiler, but aborted these because the interactive format wasn't doing too much. I haven't yet started on non-interactive replacements.

+

I held a few early forum discussions on the workings of the self-hosted compiler, but aborted these because the interactive format wasn't doing too much. I haven't yet started on non-interactive replacements.