Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,9 @@ jobs:
- name: Run codegen WASM tests
run: opam exec -- ./tools/run_codegen_wasm_tests.sh

- name: Run face-transformer regression tests
run: opam exec -- ./tools/run_face_transformer_tests.sh

- name: Check formatting
run: opam exec -- dune build @fmt

Expand Down
20 changes: 14 additions & 6 deletions README.adoc
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,16 @@ On top of that core, the language supports _faces_: sugared surface syntaxes tha

A face is not a separate language. It is a different presentation layer over the same core model.

Examples include:
The established faces are:

- *AffineScript* — the canonical face
- *JaffaScript* — a JavaScript-like face
- *RattleScript* — a Python-like face
- *PseudoScript* — a pseudocode-oriented face
- *JaffaScript* — a JavaScript / TypeScript-like face
- *RattleScript* — a Python-like face (also positioned as "Python for the web" via typed-wasm)
- *PseudoScript* — a pseudocode-oriented face for CS pedagogy
- *LucidScript* — a PureScript / Haskell-like face
- *CafeScripto* — a CoffeeScript-like face

Every face shares the canonical `.affine` file extension; the active face is selected by an optional `face:` pragma on the first comment line of the file (e.g. `# face: rattlescript`, `// face: jaffascript`, `-- face: lucidscript`), or by `--face NAME` on the CLI.

This means people can bring familiarity from a language family they already love, while still entering a system with stronger guarantees around ownership, effects, state, and resource usage.

Expand Down Expand Up @@ -312,11 +316,15 @@ face syntax -> AffineScript core AST -> type/effect/ownership checks -> ba

Examples:

- JaffaScript lowers JavaScript-like syntax into the AffineScript core
- JaffaScript lowers JavaScript / TypeScript-like syntax into the AffineScript core
- RattleScript lowers Python-like syntax into the same core
- PseudoScript lowers structured pedagogical pseudocode into the same core
- LucidScript lowers PureScript / Haskell-like syntax into the same core
- CafeScripto lowers CoffeeScript-like syntax into the same core

Side-by-side examples for each face live under `examples/faces/`; you can preview the canonical lowering of any file with `affinescript preview-python` / `preview-js` / `preview-pseudocode` / `preview-lucid` / `preview-cafe`.

So the question is not “which face is the real language?”
So the question is not “which face is the real language?”
The answer is: the core semantics are the language; faces are entrances.

== Backends and Targets
Expand Down
232 changes: 193 additions & 39 deletions bin/main.ml

Large diffs are not rendered by default.

Loading
Loading