frontpage.
newsnewestaskshowjobs

Open Source @Github

fp.

Open in hackernews

Tail-call optimization in C is relatively recent

https://lwn.net/Articles/1034703/
25•prakashqwerty•1h ago

Comments

mmsc•37m ago
and TCO was added then removed from js! https://stackoverflow.com/a/54721813

This leads to fun stack-overflow bugs too in a lot of js code (one solution is to flatten: https://joshua.hu/javascript-infinite-tail-call-recursion-st...)

pfdietz•35m ago
Lack of TCO is also a common footgun for Scheme programmers using Common Lisp.
tialaramex•16m ago
This footgun is the reason I'm so enthusiastic about the Rust `become` keyword.

This proposal would give Rust a specific keyword which says that you intend TCO and so two things happen: 1. The compiler goes to more length to deliver TCO even where it wouldn't "just work" and 2. If it cannot deliver TCO your code doesn't compile, because you asked for TCO.

StilesCrisis•10m ago
Sounds like clang::must_tail?
guenthert•9m ago
Only if they are using an insufficiently smart compiler. SBCL handles TCO just fine, as do a number of other implementations, see : https://0branch.com/notes/tco-cl.html
kenjin4096•33m ago
I think Anton is replying to me in that LWN article IIRC. I personally didn't know C only had tail calls that late and learnt something new there!

On the other hand, I am pretty new to the compiler space myself, and I count early 2000s as a pretty long time ago, though again it is not that far back considering how long other language implementations had tail calls like in ML or variants since 1980-90s.

messe•31m ago
> In 2001 Mark Probst implemented tail-call optimization in GCC with a separate calling convention; he lists the limitations of the then-existing tail-call optimization in GCC in section 6.4, among them: "It cannot handle indirect calls" (which would have been used in tail calls for interpreter dispatch).

Relatively recent being a quarter of century? Or at least a fifth of a century for indirect calls[1] (GCC 3.4.6 is the earliest I see on Compiler Explorer, released March 2006).

[1]: https://godbolt.org/z/vvcnn54oM

nyeah•30m ago
>That quote is the article, and it's a little surprising that it's buried so far into the content

Is it really surprising in 2026? Today's online writing style is not designed to communicate. It's designed to keep the reader 'engaged' for as long as possible. The reader's time is a resource to be extracted.

I'm absolutely not poking this author individually. It's the writing style of the net.

Meta Muse Glimmer – open weights 30B local coding model

https://research.meta.ai/blog/introducing-muse-glimmer-open-agentic-model
276•riordan•2h ago•107 comments

Because It's Not Fun Enough: why languages fail

https://bytecode.news/posts/2026/08/because-it-s-not-fun-enough
42•jottinger•1h ago•17 comments

Docker Sandboxes – Disposable, isolated sandboxes for AI agents

https://www.docker.com/products/docker-sandboxes/
321•etoxin•6h ago•185 comments

Tail-call optimization in C is relatively recent

https://lwn.net/Articles/1034703/
25•prakashqwerty•1h ago•10 comments

Squeak/Smalltalk 6.1 Release Notes

https://squeak.org/release_notes/6.1/
5•fniephaus•38m ago•0 comments

What Happened to HackerOne?

https://blog.teknogeek.io/posts/what-happened-to-hackerone/
281•hipparchus•10h ago•142 comments

Parametron: 50s Japanese computer that uses neither transistors nor vacuum tubes

https://ethw.org/Milestones:Parametron,_1954
13•xeonmc•2h ago•1 comments

A 'bananas' order for 5000 obscure book titles fuels suspicion

https://www.irishtimes.com/world/europe/2026/08/10/a-mysterious-buying-spree-is-unsettling-europe...
44•ohaodha•1h ago•36 comments

Run Android ARM64 VR APKs on Apple Vision Pro

https://github.com/shinyquagsire23/Klepton
114•LorenDB•9h ago•16 comments

Tail-Call Interpreters in Rust – Jimmy Ostler

https://lordgoati.us/blog/tail-call/
44•amatheus•3d ago•15 comments

An Interesting Fourier Transform – 1/F Noise

https://www.dsprelated.com/showarticle/40.php
67•q7m•3d ago•15 comments

Show HN: Voice driven murder mystery, Interview AI suspects with your voice

https://www.whodunnitai.com/
124•MrRowTheBoat•9h ago•52 comments

DeepSeek costs OpenCode Go user $1.14/day; dual DGX breaks even in 24 years

https://twitter.com/thdxr/status/2086599224674681242
10•delduca•29m ago•2 comments

How I use LLMs to learn complex topics

https://laurentiugabriel.github.io/blog/articles/how-i-use-llms-to-learn/
703•laurentiurad•17h ago•442 comments

How Blackwing Pencils are Made [video]

https://www.youtube.com/watch?v=fow-LsdaH2E
29•NaOH•4d ago•11 comments

Taxi drivers rarely die of Alzheimer's

https://theconversation.com/taxi-drivers-rarely-die-of-alzheimers-how-complex-mental-maps-and-spa...
320•jader201•21h ago•227 comments

Findphone: Locate a nearby Bluetooth device by signal strength

https://github.com/ben-z/findphone
5•helsinkiandrew•5d ago•0 comments

How We Pushed CDC into Postgres

https://www.snowflake.com/en/blog/engineering/postgres-to-snowflake-replication-mirroring/
108•craigkerstiens•11h ago•18 comments

Ask HN: What are you working on? (August 2026)

269•david927•19h ago•931 comments

Cool URIs Don't Change (1998)

https://www.w3.org/Provider/Style/URI
255•Klaster_1•22h ago•62 comments

ATProto for Distributed Systems Engineers

https://atproto.com/articles/atproto-for-distsys-engineers
101•LelouBil•3d ago•18 comments

An alias-based formulation of the borrow checker (2018)

https://smallcultfollowing.com/babysteps/blog/2018/04/27/an-alias-based-formulation-of-the-borrow...
17•parksb•2d ago•1 comments

Picophysics: Single file physics for games on platforms like N64, PSX, DC

https://gitlab.com/Kazade/picophysics
68•klaussilveira•5d ago•22 comments

Tuxedo No. 2 – Cocktail recipes

https://tuxedono2.com
108•smartmic•16h ago•35 comments

Nearest Pint

https://knowwhereconsulting.co.uk/maps/pubs/
40•bookofjoe•5d ago•22 comments

Everything you do is being recorded

https://www.theatlantic.com/technology/2026/05/ai-wearable-surveillance-countermeasures/687203/
343•ike_usawa•1d ago•292 comments

I made tinnitus my friend, then it disappeared [video]

https://mynoise.net/vlog.php?ep=20260803
173•gregsadetsky•18h ago•138 comments

Meta's new open-weight model targets local agentic AI

https://twitter.com/finkd/status/2086754845218726027
16•bakigul•1h ago•2 comments

New Zealand lost its music media, and what we're building to replace it

https://propelmusic.co.nz/articles/the-sound-went-quiet-nz-music-media
121•berghoffer•16h ago•82 comments

Auto mode is now the default in Claude Code

https://claude.com/blog/auto-mode-default-in-claude-code
249•sbehere•9h ago•258 comments