frontpage.
newsnewestaskshowjobs

Made with ♥ by @iamnishanth

Open Source @Github

fp.

Open in hackernews

Loon: A functional lang with invisible types, safe ownership, and alg. effects

https://loonlang.com
46•surprisetalk•23h ago

Comments

phpnode•2h ago
The pattern matching example has a type Shape which is never referenced and this seems to conflict with the idea that you never write a type, am I missing something obvious?
KPGv2•1h ago
I think they mean you never write types for your variables or functions. They don't mean you can't create types. That's the reference to Hindley–Milner type system and type inference. You don't have to say

x : Nat x = 5

You just say x = 5

I personally don't like that you don't seem to be able to manually describe the type for a fn/var, because it's very useful when prototyping to write stubs where you provide the typedef but then the actual variable/function is just marked as "todo"

weitendorf•2h ago
Very cool! I’ve been flirting with the idea of biting the bullet and moving more towards language extensions around protobuf/grpc vs just tools so it’s really great to see projects on the other side of that kind of decision shipping and what choices they made

Why the square brackets in particular? Notation is such an annoying part of this stuff, I’m actually leaning towards pushing a lot of structure to the filesystem

luckymate•1h ago
I think I am in love. Clojure + Rust, everything is typed, but I don't need to annotate. And algebraic effects that I really wanted to explore in Ocaml, but now can do it in language with way easier syntax. I might be missing bit of Clojure dynamic nature, but it looks like a bunch of really interesting ideas in one language.
christophilus•57m ago
Yeah. Clojure is by far my favorite dynamic language. But, I love static types. At a glance, a quick glance at Loon- looks like it could just flat out become my favorite language. Loon with a standard library that approaches Go’s would be :chefskiss:
drob518•40m ago
Coming from Clojure, I like types being invisible. Square brackets feels like a needless change. If you want sexprs, just use sexprs. Interesting ideas, as you say.
xigoi•1h ago
Looks great! However, the website is really slow. Every page takes several seconds to load and trying to open the reference freezes my browser.
ethmarks•9m ago
Apparently the site itself is written in Loon. The HTML is just a static shell that loads a `boot.js` script[1] that runs some WASM that compiles and evals the Loon source files. I found the source code here[2].

Definitely cool in concept, but very performance-intensive and slow.

[1]: https://loonlang.com/boot.js

[2]: https://github.com/ecto/loon/tree/main/web

davidee•1h ago
Perhaps relevant: https://campedersen.com/loon

This looks like a really neat project/idea; seeing the road map is exciting too, nearly everything I'd want.

I don't love the brackets syntax, or the [op val1 val2] ([* x x]) style, but I appreciate the attempt at clarity and consistency and none of these things are dealbreakers.

I do wonder why they've leaned so hard into talking about the type system being out of sight. Again, not a dealbreaker, but I feel strongly that explicit typing has a place in codebases beyond "describe something because you have to".

Strongly typed languages strike me as providing detailed hints throughout the codebase about what "shape" I need my data in or what shape of data I'm dealing with (without needing to lean on an LSP). I find it makes things very readable, almost self-documenting when done right.

From their docs about their choices: "The reasoning is simple: types exist to help the compiler catch your mistakes. They do not exist to help you express intent, at least not primarily." This strikes me as unnecessarily pedantic; as someone reading more code than I write (even my own), seeing a type distinctly—particular as part of a function signature—helps me understand (or add strong context) to the original author's goal before I even get to reading the implementation.

I find this doubly so when working through monadic types where I may get a typed error, a value, and have it all wrapped in an async promise of some kind (or perhaps an effect or two).

By the same token many languages allow you to leave out type annotations where they may be simple or clearly implied (and/or inferred by the compiler), so again, I'm not understanding the PoV (or need) for these claims. Perhaps Loon simply does it better? Am I missing something? Can I write return types to stub functions?

From the above blog post: "That's how good type inference feels! You write code. The types are just there. Because the language can see where it's going." Again, it feels strongly geared towards a world where we value writing code over reading/maintaining/understanding code, but maybe that's just my own bias/limitations.

Will follow it closely.

wk_end•51m ago
Yeah, the idea that types exist just to help the compiler catch your mistakes shows a depressingly superficial understanding of the benefits of static typing.

Types exist so that the compiler can reason about your code better - but not incidentally, they also help you reason about your code better!

To wit: even when working in dynamic languages, it's often considered a good practice to write down in docstrings the types of objects a function can operate on, even without static enforcement. Thinking about types is helpful for humans, too.

And it's not even just a thing to help you read code in the future - types help me write code, because as I sit down to write a function I know the possible values and states and capabilities of the object I'm working with. In the best of cases I can analytically handle all the possible cases of the object, almost automatically - the code flows out of the structure of the type.

cptroot•36m ago
Good news, there's a line in the "Coming from Rust"[1] page that says

> You never annotate a function signature unless you want to for documentation purposes.

so it sounds like function annotation is still an option for the purposes of communication, just no longer required in all cases.

[1] https://loonlang.com/concepts/from-rust

cptroot•14m ago
Aha, here's the syntax in case you're curious (using an example lifted from the playground)

  [type Shape
    [Circle f64]
    [Rect f64 f64]
    Point
  ]

  [sig test_sig : Shape -> Float]
  [fn test_sig [shape]
    [match shape
      [Circle r] [* 3.14159 [* r r]]
      [Rect w h] [* w h]
      Point 0.0
    ]
  ]
Unfortunately it seems like this doesn't currently work as expected when I use it in the playground, so I'm going to go file an issue
mapcars•23m ago
> Strongly typed languages strike me as providing detailed hints throughout the codebase about what "shape" I need my data in

I agree that seeing types is helpful, though typing them is also not necessary. Perhaps the solution is an IDE that shows you all the types inferred by the compiler or maybe a linter that adds comments with types on file save.

cptroot•1h ago
Neat! I think the website could use a bit more information about how the "global" Effect handlers work, and whether it's possible to opt-in to that functionality yourself when writing Effects.

That being said I took a look at the roadmap and the next major release is the one that focuses on Effects, so perhaps I'm jumping the gun a tad. Maybe I'll whip this out for AoC this year!

dxdm•9m ago
> Square brackets replace parentheses for a clean, uniform syntax.

Oh dear, why? Abrasive aesthetics aside, this is bad for people with certain non-English keyboard layouts. Not me, but many do exist.

mintplant•6m ago
I got really excited reading this! The docs site is very polished and hypes up lots of features which click with things I've been wanting out of a language. But then I went to the repository [0] and realized that this is a week-old project, with every single commit written by Claude. I went to the playground page [1] and tried the example for effects, a headline feature and what drew me in the most, but it threw an "unbound symbol" error. I thought maybe the example could just be out-of-date, so I tried the example under the "Algebraic effects" heading on the homepage, which shows a different syntax, but that threw a parse error. The "Pattern matching" example is supposed to return 78.5, but it returns 15.700000000000001 when run in the playground.

How much of this is actually real?

[0] https://github.com/ecto/loon

[1] https://loonlang.com/play

EDuke32 – Duke Nukem 3D (Open-Source)

https://www.eduke32.com/
36•reconnecting•1h ago•10 comments

Parse, Don't Validate and Type-Driven Design in Rust

https://www.harudagondi.space/blog/parse-dont-validate-and-type-driven-design-in-rust/
49•todsacerdoti•1h ago•20 comments

I verified my LinkedIn identity. Here's what I handed over

https://thelocalstack.eu/posts/linkedin-identity-verification-privacy/
977•ColinWright•14h ago•368 comments

How an inference provider can prove they're not serving a quantized model

https://tinfoil.sh/blog/2026-02-03-proving-model-identity
38•FrasiertheLion•14h ago•7 comments

I Don't Like Magic

https://adactio.com/journal/22399
23•edent•3d ago•10 comments

How far back in time can you understand English?

https://www.deadlanguagesociety.com/p/how-far-back-in-time-understand-english
228•spzb•3d ago•138 comments

Inputlag.science – Repository of knowledge about input lag in gaming

https://inputlag.science
30•akyuu•1h ago•3 comments

What not to write on your security clearance form (1988)

https://milk.com/wall-o-shame/security_clearance.html
316•wizardforhire•4h ago•116 comments

Personal Statement of a CIA Analyst

https://antipolygraph.org/statements/statement-038.shtml
65•grubbs•3h ago•30 comments

Toyota Mirai hydrogen car depreciation: 65% value loss in a year

https://carbuzz.com/toyota-mirai-massive-depreciation-one-year/
26•iancmceachern•3h ago•53 comments

Canvas_ity: A tiny, single-header <canvas>-like 2D rasterizer for C++

https://github.com/a-e-k/canvas_ity
26•PaulHoule•2h ago•11 comments

CXMT has been offering DDR4 chips at about half the prevailing market rate

https://www.koreaherald.com/article/10679206
100•phront•6h ago•68 comments

Cloudflare outage on February 20, 2026

https://blog.cloudflare.com/cloudflare-outage-february-20-2026/
100•nomaxx117•2h ago•73 comments

Loon: A functional lang with invisible types, safe ownership, and alg. effects

https://loonlang.com
46•surprisetalk•23h ago•16 comments

zclaw: personal AI assistant in under 888 KB, running on an ESP32

https://github.com/tnm/zclaw
17•tosh•8h ago•10 comments

MeshTNC is a tool for turning consumer grade LoRa radios into KISS TNC compatib

https://github.com/datapartyjs/MeshTNC
5•todsacerdoti•1h ago•0 comments

Claws are now a new layer on top of LLM agents

https://twitter.com/karpathy/status/2024987174077432126
114•Cyphase•20h ago•521 comments

Acme Weather

https://acmeweather.com/blog/introducing-acme-weather
147•cryptoz•14h ago•96 comments

Permacomputing

https://wiki.xxiivv.com/site/permacomputing.html
57•tosh•4d ago•11 comments

A solver for Semantle

https://victoriaritvo.com/blog/semantle-solver/
45•evakhoury•3d ago•11 comments

Show HN: Iron-Wolf – Wolfenstein 3D source port in Rust

https://github.com/Ragnaroek/iron-wolf
44•ragnaroekX•5h ago•16 comments

Uncovering insiders and alpha on Polymarket with AI

https://twitter.com/peterjliu/status/2024901585806225723
100•somerandomness•1d ago•87 comments

AI uBlock Blacklist

https://github.com/alvi-se/ai-ublock-blacklist
184•rdmuser•13h ago•76 comments

Padlet (YC W13) Is Hiring in San Francisco and Singapore

https://padlet.jobs
1•coffeebite•9h ago

Microsoft team creates data-storage system that lasts for millennia

https://www.nature.com/articles/d41586-026-00502-2
62•gnabgib•3d ago•54 comments

Be wary of Bluesky

https://kevinak.se/blog/be-wary-of-bluesky
163•kevinak•21h ago•122 comments

A16Z partner says that the theory that we'll vibe code everything is ' wrong'

https://www.aol.com/articles/a16z-partner-says-theory-well-050150534.html
57•paulpauper•22h ago•68 comments

Keep Android Open

https://f-droid.org/2026/02/20/twif.html
1945•LorenDB•1d ago•667 comments

Don't create .gitkeep files, use .gitignore instead (2023)

https://adamj.eu/tech/2023/09/18/git-dont-create-gitkeep/
109•frou_dh•22h ago•65 comments

The Nekonomicon – Nekochan.net Archive, Updated

http://nekonomicon.irixnet.org/
37•ThatGuyRaion•4h ago•8 comments