News for hackers. Stuff that matters.
Re:Fitting a FORTH in 512 bytes by hyperhopper on Friday June 11, 2021 @05:02PM (#27478449)
I find it amusing how often trying to do complex tasks with simple constraints, always ends up back at stack based languages. Probably why the stack based turing machine is academically important.
Re:Fitting a FORTH in 512 bytes by q-big on Friday June 11, 2021 @06:29PM (#27479274)
> Probably why the stack based turing machine is academically important.

A Turing machine is not stack-based, but tape-based. A pushdown automaton (PDA) is stack-based.

Re:Fitting a FORTH in 512 bytes by bear8642 on Saturday June 12, 2021 @01:04AM (#27481690)
Although turing machine tape emulatable via 2 stacks
Re:Fitting a FORTH in 512 bytes by imode on Friday June 11, 2021 @07:39PM (#27479844)
Two stacks make an automaton Turing Complete. Which is an interesting result.
Re:Fitting a FORTH in 512 bytes by NieDzejkob on Friday June 11, 2021 @06:47PM (#27479448)
I suppose that prior art influences things. In my case, I went "a separate text editor won't fit, I need a REPL", and that basically filtered to just Forth and Lisp. It would be interesting to see what subset of Lisp would fit in a bootsector, but I wouldn't get my hopes up.
Re:Fitting a FORTH in 512 bytes by na85 on Friday June 11, 2021 @07:31PM (#27479779)
There's sectorlisp that appears to fit into two sectors but is yet shy of their single-sector goal: https://github.com/jart/sectorlisp
Re:Fitting a FORTH in 512 bytes by jart on Saturday June 12, 2021 @06:50AM (#27483509)
sectorlisp right now is 800 bytes but it implements LISP well enough that you can use its built-in LISP IDE to implement your own LISP engine on top of sectorlisp using high-level functional programming techniques. https://youtu.be/hvTHZ6E0Abo If we can trim down the code size another 250 bytes then all this will fit in the master boot record.