Skip to content

Commit

Permalink
latex3: new implementation
Browse files Browse the repository at this point in the history
Self hosting fails at step4 because of exceeded TeX capacity.
  • Loading branch information
asarhaddon committed Aug 7, 2024
1 parent 65166b2 commit f41b891
Show file tree
Hide file tree
Showing 20 changed files with 3,906 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Makefile.impls
Original file line number Diff line number Diff line change
Expand Up @@ -36,13 +36,14 @@ wasm_MODE = wasmtime

IMPLS = ada ada.2 awk bash basic bbc-basic c c.2 chuck clojure coffee common-lisp cpp crystal cs d dart \
elisp elixir elm erlang es6 factor fantom fennel forth fsharp go groovy gnu-smalltalk \
guile haskell haxe hy io janet java java-truffle js jq julia kotlin livescript logo lua make mal \
guile haskell haxe hy io janet java java-truffle js jq julia kotlin latex3 livescript logo lua make mal \
matlab miniMAL nasm nim objc objpascal ocaml perl perl6 php picolisp pike plpgsql \
plsql powershell prolog ps purs python python.2 r racket rexx rpython ruby ruby.2 rust scala scheme skew sml \
swift swift3 swift4 swift5 tcl ts vala vb vhdl vimscript wasm wren yorick xslt zig

step5_EXCLUDES += bash # never completes at 10,000
step5_EXCLUDES += basic # too slow, and limited to ints of 2^16
step5_EXCLUDES += latex3 # no iteration, limited native stack
step5_EXCLUDES += make # no TCO capability (iteration or recursion)
step5_EXCLUDES += mal # host impl dependent
step5_EXCLUDES += matlab # never completes at 10,000
Expand Down Expand Up @@ -145,6 +146,7 @@ js_STEP_TO_PROG = impls/js/$($(1)).js
jq_STEP_PROG = impls/jq/$($(1)).jq
julia_STEP_TO_PROG = impls/julia/$($(1)).jl
kotlin_STEP_TO_PROG = impls/kotlin/$($(1)).jar
latex3_STEP_TO_PROG = impls/latex3/$($(1)).tex
livescript_STEP_TO_PROG = impls/livescript/$($(1)).js
logo_STEP_TO_PROG = impls/logo/$($(1)).lg
lua_STEP_TO_PROG = impls/lua/$($(1)).lua
Expand Down
13 changes: 13 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,6 +87,7 @@ FAQ](docs/FAQ.md) where I attempt to answer some common questions.
| [jq](#jq) | [Ali MohammadPur](https://github.com/alimpfard) |
| [Julia](#julia) | [Joel Martin](https://github.com/kanaka) |
| [Kotlin](#kotlin) | [Javier Fernandez-Ivern](https://github.com/ivern) |
| [LaTeX3](#latex3) | [Nicolas Boulenguez](https://github.com/asarhaddon) |
| [LiveScript](#livescript) | [Jos van Bakel](https://github.com/c0deaddict) |
| [Logo](#logo) | [Dov Murik](https://github.com/dubek) |
| [Lua](#lua) | [Joel Martin](https://github.com/kanaka) |
Expand Down Expand Up @@ -684,6 +685,18 @@ make
java -jar stepX_YYY.jar
```

### LaTeX3

The LaTeX3 implementation of mal has been tested with pdfTeX
3.141592653-2.6-1.40.24.

Self hosting is too slow for any sensible timeout, and crashes in
step4, apparently because of hard-coded limitations.

Anybody working on this should uncomment the two lines of (slow)
debugging options in the step file, and export DEBUG=1 (for more
output than tests accept).

### LiveScript

The LiveScript implementation of mal has been tested with LiveScript 1.5.
Expand Down
22 changes: 22 additions & 0 deletions impls/latex3/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
FROM ubuntu:20.04
MAINTAINER Joel Martin <[email protected]>

##########################################################
# General requirements for testing or common across many
# implementations
##########################################################

RUN apt-get -y update

# Required for running tests
RUN apt-get -y install make python3
RUN ln -fs /usr/bin/python3 /usr/local/bin/python

RUN mkdir -p /mal
WORKDIR /mal

##########################################################
# Specific implementation requirements
##########################################################

RUN apt-get -y install texlive-latex-base
3 changes: 3 additions & 0 deletions impls/latex3/Makefile
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
all:
clean:
rm -f *~ *.aux *.dvi *.log argv
Loading

0 comments on commit f41b891

Please sign in to comment.