3 ms·
Your "sane" language looks quite insane to me, unreadable mess at a glance.
by Mikushi 2y ago
Your "sane" language looks quite insane to me, unreadable mess at a glance.
- lifthrasiir 2y agoIt almost looks like a Rust syntax to me, which is only one way to do that. A concise syntax is always possible if that's prioritized, like `(ctx.get(thing)? == Thing.A) ?? false` or `ctx.get(thing)?.(_ == Thing.A)`. Actual Rust programmers would also prefer to check against the explicit value whenever possible: `thing == Some(Thing.A)`.
- zaptheimpaler 2y agoYes, language design should cater to people who have spent a little bit of time using and learning it, because they represent the majority of hours spent using that language. What a language looks like to someone who's never seen it is sort of irrelevant. That code could also have been written more imperatively, and probably would be by many people for those who don't like the functional style.