frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

minikeyvalue

https://github.com/commaai/minikeyvalue/tree/prod
2•tosh•2m ago•0 comments

Neomacs: GPU-accelerated Emacs with inline video, WebKit, and terminal via wgpu

https://github.com/eval-exec/neomacs
1•evalexec•7m ago•0 comments

Show HN: Moli P2P – An ephemeral, serverless image gallery (Rust and WebRTC)

https://moli-green.is/
2•ShinyaKoyano•11m ago•1 comments

How I grow my X presence?

https://www.reddit.com/r/GrowthHacking/s/UEc8pAl61b
2•m00dy•12m ago•0 comments

What's the cost of the most expensive Super Bowl ad slot?

https://ballparkguess.com/?id=5b98b1d3-5887-47b9-8a92-43be2ced674b
1•bkls•13m ago•0 comments

What if you just did a startup instead?

https://alexaraki.substack.com/p/what-if-you-just-did-a-startup
3•okaywriting•20m ago•0 comments

Hacking up your own shell completion (2020)

https://www.feltrac.co/environment/2020/01/18/build-your-own-shell-completion.html
2•todsacerdoti•23m ago•0 comments

Show HN: Gorse 0.5 – Open-source recommender system with visual workflow editor

https://github.com/gorse-io/gorse
1•zhenghaoz•23m ago•0 comments

GLM-OCR: Accurate × Fast × Comprehensive

https://github.com/zai-org/GLM-OCR
1•ms7892•24m ago•0 comments

Local Agent Bench: Test 11 small LLMs on tool-calling judgment, on CPU, no GPU

https://github.com/MikeVeerman/tool-calling-benchmark
1•MikeVeerman•25m ago•0 comments

Show HN: AboutMyProject – A public log for developer proof-of-work

https://aboutmyproject.com/
1•Raiplus•25m ago•0 comments

Expertise, AI and Work of Future [video]

https://www.youtube.com/watch?v=wsxWl9iT1XU
1•indiantinker•26m ago•0 comments

So Long to Cheap Books You Could Fit in Your Pocket

https://www.nytimes.com/2026/02/06/books/mass-market-paperback-books.html
3•pseudolus•26m ago•1 comments

PID Controller

https://en.wikipedia.org/wiki/Proportional%E2%80%93integral%E2%80%93derivative_controller
1•tosh•30m ago•0 comments

SpaceX Rocket Generates 100GW of Power, or 20% of US Electricity

https://twitter.com/AlecStapp/status/2019932764515234159
2•bkls•30m ago•0 comments

Kubernetes MCP Server

https://github.com/yindia/rootcause
1•yindia•32m ago•0 comments

I Built a Movie Recommendation Agent to Solve Movie Nights with My Wife

https://rokn.io/posts/building-movie-recommendation-agent
4•roknovosel•32m ago•0 comments

What were the first animals? The fierce sponge–jelly battle that just won't end

https://www.nature.com/articles/d41586-026-00238-z
2•beardyw•40m ago•0 comments

Sidestepping Evaluation Awareness and Anticipating Misalignment

https://alignment.openai.com/prod-evals/
1•taubek•40m ago•0 comments

OldMapsOnline

https://www.oldmapsonline.org/en
1•surprisetalk•42m ago•0 comments

What It's Like to Be a Worm

https://www.asimov.press/p/sentience
2•surprisetalk•43m ago•0 comments

Don't go to physics grad school and other cautionary tales

https://scottlocklin.wordpress.com/2025/12/19/dont-go-to-physics-grad-school-and-other-cautionary...
2•surprisetalk•43m ago•0 comments

Lawyer sets new standard for abuse of AI; judge tosses case

https://arstechnica.com/tech-policy/2026/02/randomly-quoting-ray-bradbury-did-not-save-lawyer-fro...
5•pseudolus•43m ago•0 comments

AI anxiety batters software execs, costing them combined $62B: report

https://nypost.com/2026/02/04/business/ai-anxiety-batters-software-execs-costing-them-62b-report/
1•1vuio0pswjnm7•43m ago•0 comments

Bogus Pipeline

https://en.wikipedia.org/wiki/Bogus_pipeline
1•doener•45m ago•0 comments

Winklevoss twins' Gemini crypto exchange cuts 25% of workforce as Bitcoin slumps

https://nypost.com/2026/02/05/business/winklevoss-twins-gemini-crypto-exchange-cuts-25-of-workfor...
2•1vuio0pswjnm7•45m ago•0 comments

How AI Is Reshaping Human Reasoning and the Rise of Cognitive Surrender

https://papers.ssrn.com/sol3/papers.cfm?abstract_id=6097646
3•obscurette•45m ago•0 comments

Cycling in France

https://www.sheldonbrown.com/org/france-sheldon.html
2•jackhalford•47m ago•0 comments

Ask HN: What breaks in cross-border healthcare coordination?

1•abhay1633•47m ago•0 comments

Show HN: Simple – a bytecode VM and language stack I built with AI

https://github.com/JJLDonley/Simple
2•tangjiehao•50m ago•0 comments
Open in hackernews

Compiling a Forth

https://healeycodes.com/compiling-a-forth
70•healeycodes•4mo ago

Comments

Quitschquat•4mo ago
I don’t think a tokenizer like that is a good idea for Forth. You’ve got to read the next space separated thing, find out if it’s supposed to be compiled or run.

Eg the naive tokenizer would probably not work for .” for example.

microtherion•4mo ago
I agree. The tokenizer in the article completely misses the point of how Forth works: the tokenization is supposed to be driven by the words themselves, i.e. ." is looking for a " delimiter, ( is looking for a ).

Not to mention that the rest of the compiler also misses the point of how Forth works. This compiles a fixed subset of Forth and entirely misses out on the extensibility of the language.

roggenbuck•4mo ago
This was a well written post! It makes me want to create my own forth-like language
codr7•4mo ago
Forth is a great starting point for designing interpreters/languages.

A while ago I tried to put together a kit to make it easier to get started writing interpreters:

https://github.com/codr7/shi

onetom•4mo ago
> I feel like my Forth-like compiler and VM capture enough of the spirit of Forth!

Being interactive is core to the spirit of Forth, so I think your feeling is off.

The fact that editing, compilation and execution is folded into single, comprehensive workflow, makes it possible for a Forth system to be situated in very resource constrained environments and evolve while it's running, potentially without any dependence on some other, beefier computer somewhere else.

There are tons of problems avoided with bundling all these capabilities together. There is no question of "which version of the compiler to use?", since it's part of your program, because it's so small (few hundred bytes probably), it can be part of it.

It also has the D-lang, Rust or Zig style `comptime` feature via the immediate mode words.

And the list goes on an on...

Here is a starting point for understanding more of these principles: https://www.ultratechnology.com/lowfat.htm

Chuck Moore's ColorForth (https://colorforth.github.io/cf.htm) takes these ideals to some extremes, allowing an ATA IDE disk driver to be a few words of code only: https://colorforth.github.io/ide.html

pjmlp•4mo ago
Another thing of the Forth spirit is that the system is supposed to be fully bootstraped (like most Lisps as well), having a very small of words written in Assembly, and then everything else fully bootstraped in Forth and available for customisation.
blubber•4mo ago
I think it's ok to edit forth code in a modern text editor. Following your definition, many modern forth engines wouldn't qualify as a forth. You don't need an antique screen-based editor to get immediate words.
kragen•4mo ago
Having written a Forth-like native-code compiler (https://github.com/kragen/stoneknifeforth) and also a game in Gforth, I can't claim to be a Forth expert, but I agree. A lot of the weaknesses of the language (such as no compile-time checking of even the number of arguments to a subroutine, much less their types, and its terseness) are shored up by the interactivity of the environment. Some of the short words in Forth like ? only make sense in that context. And some things that might otherwise be weaknesses, like variables being static, become strengths in that context. (If you store into x in a word you're testing, you can see what got stored there with x ?.)

More generally, Forth, considered as a programming language, is not very good compared to other languages of a similar level, such as C or assembly. Its strength is as an interactive environment. (And none of what I've said here implies that you have to use a block editor.)

This is all fairly abstract, but it's not the first time I've talked about it, so I did an ASCIIcast last year demonstrating me writing a square root subroutine: https://asciinema.org/a/621404 I screwed it up in the middle and had to debug it, which is where Forth's interactivity shines. You may want to watch it on double speed, though. You can also get the pleasure of watching me learn that Gforth has readline-like command-line history!

That said, I think you're exaggerating a bit. I haven't seen a Forth compiler that's only a few hundred bytes, and I don't think the blocking PIO in Chuck's IDE driver is a good way to access an IDE disk, although it's adequate for initial bootstrapping.

armitron•4mo ago
Read jonesforth if you want to learn how a Forth can be implemented and bootstrapped simply. Like other comments in this thread point out, this implementation isn’t really Forth and completely misses the point of Forth.