Live data from Hacker News

Ask HN: What would be your “perfect” programming language?

news.ycombinator.com

91–100 of 182 posts

Re: Ask HN: What would be your “perfect” programming language?

#92
post #52

Rust with a GC (and therefore without borrow checking). I'll copy the stuff I wrote on a twitter thread recently below: Rust's borrow checker is the most innovative but also most inconvenient bit, and GCs are certainly more convenient. But Rust is much more than that: - Rust traits are like typeclasses, but you can still use dot notation for better discoverability, which IMO makes them even beter (no, hoogle is no su…

...essentially Nim.

Re: Ask HN: What would be your “perfect” programming language?

#93

In my opinion, Rust is what Scala would be if ownership was flagship feature and everything was built around that. Certain combinations just don't match. Let's take an example of Scala. Great language for most business domain problems: easy to write expressive, bug-free and concurrent code. What enables those strengths also enables its weaknesses: steep learning curve, a lot of ways to reduce boilerplate which increa…

It's been a while since I've done much Scala but the "type gymnastics" and slower compilation times is what killed it for me.

Discovering F# solved it for me with less expressivity/surprises like implicits.

Re: Ask HN: What would be your “perfect” programming language?

#94
post #52

Rust with a GC (and therefore without borrow checking). I'll copy the stuff I wrote on a twitter thread recently below: Rust's borrow checker is the most innovative but also most inconvenient bit, and GCs are certainly more convenient. But Rust is much more than that: - Rust traits are like typeclasses, but you can still use dot notation for better discoverability, which IMO makes them even beter (no, hoogle is no su…

...essentially Nim.

Nim lacks certain basics such as algebraic enums, so ...no.

Also responding with a brief "so, Nim" to everyone isn't effective at doing much.

Re: Ask HN: What would be your “perfect” programming language?

#95

C but with the following changes: - Guarantee 8-bit byte and twos complement - No undefined behavior. All behavior is defined even if the ramifications of that behavior are not. Use after free? The data in the memory location is written-to or read-from, not omitted by compiler, and programmer is responsible for the second- and third-order effects thereof. Signed integer overflow? You get the assembly ADD instruction…

Well, let's baseline with Zig. Because that adds build dependency management. Building code has got to work like GO: it needs to be built into the compiler. Let's also add formal methods that's bound up with the implementation language even if it starts 1-way from FM to code. Correctness in any of its several dimensions would be better with pragmatic FM together with the code itself.

Zig, which deals with C/C++ code, has the ultimately eco-system. That's a big plus.

Re: Ask HN: What would be your “perfect” programming language?

#96
Python, but with static typing and compiled to native code.

I love Python's syntax. It's usage of whitespace forces people to have some semblance of proper formatting. Overall, I find Python code extremely easy to read.

But my god is it slow, and I've always assumed a lot of its slowness is due to being interpreted and the duck typing.

Re: Ask HN: What would be your “perfect” programming language?

#97
post #94

Earlier quoted context omitted.

...essentially Nim.

Nim lacks certain basics such as algebraic enums, so ...no. Also responding with a brief "so, Nim" to everyone isn't effective at doing much.

object variants are more flexible than enum types so what you see as a limitation others don't.

Re: Ask HN: What would be your “perfect” programming language?

#98
post #94

Earlier quoted context omitted.

Nim lacks certain basics such as algebraic enums, so ...no. Also responding with a brief "so, Nim" to everyone isn't effective at doing much.

object variants are more flexible than enum types so what you see as a limitation others don't.

No, I want first class algebraic datatypes that don't make easy things hard i.e. https://forum.nim-lang.org/t/904 vs `#[derive(Eq)]`

Re: Ask HN: What would be your “perfect” programming language?

#99

Typescript without the CJS/ESM/tooling BS. Plus a JIT compiler for performance.

This would be nice. I'd also like more traits/protocols/interfaces. I think deno is going in this direction but there is a lot more to do to get there.

Re: Ask HN: What would be your “perfect” programming language?

#100
post #95

C but with the following changes: - Guarantee 8-bit byte and twos complement - No undefined behavior. All behavior is defined even if the ramifications of that behavior are not. Use after free? The data in the memory location is written-to or read-from, not omitted by compiler, and programmer is responsible for the second- and third-order effects thereof. Signed integer overflow? You get the assembly ADD instruction…

Well, let's baseline with Zig. Because that adds build dependency management. Building code has got to work like GO: it needs to be built into the compiler. Let's also add formal methods that's bound up with the implementation language even if it starts 1-way from FM to code. Correctness in any of its several dimensions would be better with pragmatic FM together with the code itself. Zig, which deals with C/C++ code,…

[deleted]
Post reply on HN