All Topics
All Topics
Technology
Technology
Design
Design
Programming
Programming
Science
Science
News
News
Gaming
Gaming
Entertainment
Entertainment
Business
Business
Finance
Finance
Sports
Sports
Health
Health
Food
Food
Travel
Travel
Art
Art
Music
Music
Books
Books
Education
Education
Politics
Politics
Personal
Personal
No algorithm. No AI slop. No ads. Just RSS. Pro-human. Indie writers. Real journalism. Open web. Chronological. Hand toasted.

How Function Coloring Creates Problems in Programming Languages

By

tosh

5d ago· 17 min readenInsight

Summary

A satirical programming language critique that examines how different programming languages handle asynchronous operations, using the metaphor of "colored functions" to describe how some languages (like C#, JavaScript, Dart) color their functions as either sync or async, while others (like Ruby, Go, Lua) do not. The article argues that function coloring creates significant practical problems: it's contagious (async functions can only call other async functions), it splits the ecosystem, and it makes code harder to refactor. The author contrasts languages with colored functions against those without, ultimately suggesting that the ideal solution is to have concurrency handled transparently through mechanisms like fibers or coroutines that don't require explicit async/await markers.

Key quotes

· 5 pulled
I don't know about you, but nothing gets me going in the morning quite like a good old fashioned programming language rant.
A red function can call other red functions. A blue function can call other blue functions. But a red function cannot call a blue function.
The color of a function is a property that infects all of the code that calls it.
If you have a blue function and you want to call a red function, you have to change your function to be red too. But now all of your callers have to change too.
The ideal language would let you have all of the performance and scalability of asynchronous I/O without having to paint any of your functions a particular color.
Snippet from the RSS feed
I don’t know about you, but nothing gets me going in the morning quite like a good old fashioned programming language rant. It stirs the blood to see someone skewer one of those “blub” languages the plebians use, muddling through their day with it between

You might also wanna read