10 ms·
On top of that Rust might be the ugliest modern language.
by ilrwbwrkhv 4y ago
On top of that Rust might be the ugliest modern language.
- coliveira 4y agoAgreed, using Rust is like switching a monster (C++) for another even worse. And notice that Rust is not even a mature language, it will get much worse. I will stay with C, thank you.
- ok123456 4y ago'constexpr' and 'auto' in modern C++ can eliminate a large portion of the ugliness. In some cases it can be much more ergonomic than the equivalent Rust.
- pjmlp 4y agoIndeed, one gets to write macro like code on the same language.
- spoiler 4y agoYou can write Rust macros in Rust too, if you wish, but it's a bit more involved (https://doc.rust-lang.org/reference/procedural-macros.html https://doc.rust-lang.org/reference/procedural-macros.html). I realise this isn't the same as constexpr, but I'd argue it's nicer. Rust also has const generics (but they are still a bit shabby in places last time I used them). I for one never liked the constexpr semantic and syntax. Always felt like a... Little pebble in my shoe. Didn't quite annoy me enough not to use it since it was useful, but it was never a comfortable experience.
- DeathArrow 4y agoAt least C++ is enormous and you can find a sane subset that you enjoy using. And C++ can be pretty safe with smart pointers.
- pjmlp 4y agoUnfortunately there is always that clever one than can't let go of writing C style code, regardless of what kind of pointers are being used. It is one of my favourite languages, but I also acknowledge that C compatibility is a big pain point for security.
- vore 4y agoThis almost works until you have to integrate with other people's C++ code and find out they picked a different subset to you.
- kaba0 4y agoCan you write a performant, generic vector data structure in C? Until then it is useless in my book.
- coliveira 4y agoSo useless that Linux, gcc, and all UNIX system commands is written in C. But you're probably doing much more important things, right?
- punkbit 4y agoWe should definitely appreciate the craftsmanship. This comment says everything, regardless of how trendy Rust might be, let’s respect the craft, your favourite language doesn’t make you more important. Legends!
- deleted 4y ago[deleted]
- deleted 4y ago[deleted]
- kaba0 4y agoRust is not my favorite language and I didn’t mean to speak anything negative about projects written in C, but I do think that those that become great did so in spite of C, not because of it. No access to performant generic data structures is a major reason why truly performance oriented programs rather choose C++ over C.
- stouset 4y agoPeople keep saying this and I just do not get it. It's just… not that bad?
- ok123456 4y agoThe core language is fine, but when you actually start building things you need to introduce lifetimes, all the traits that you polluted your interface with and then add on async, it gets out-of-hand quickly.
- dimitrios1 4y agoThe top comment gave a perfect example: #![feature(strict_provenance)] These feature enablement blocks drive me crazy. You could go from codebase to codebase and it's almost like you are working in a different language depending on how many of these are enabled or not. I've been trying rust on and off since it's release, and I still have yet to feel like I have a grasp on some "core" subset of the language I can fall back on to solve most of my problems. I always have to scour documentation for the hot new thing to turn on or do, and this isn't to scorn innovation and change, but it does get exhausting at some point. (Please release a spec)
- satvikpendem 4y agoThose feature blocks exist only for nightly/unstable Rust. You don't have those on stable Rust. The most you might have are derive blocks but those just automate what you'd write by hand anyway.
- deleted 4y ago[deleted]
- Rusky 4y agoA spec is not a replacement for #![feature] attributes. It's rather the opposite: #![feature] indicates that you are stepping out of the stable, specified core language and into an area that is still a work in progress and thus cannot have a committed specification yet. You shouldn't need it at all unless you are actively experimenting with some unfinished proposal.
- edflsafoiewq 4y agoIMO Zig isn't exactly a beauty either.
- zamalek 4y agoThat is extremely subjective. I find the syntax extremely easy to read, and there are significantly fewer edge cases than nearly all other mainstream languages: * Why does C# require a break; under switch? * What about the "Most Vexing Parse"? * Why does Zig change capitalization of @import and @TypeOf? Rust is an extremely "guessable" language. It's highly likely that experimenting with syntax will succeed in Rust, which is a syntax feature that I have seen nowhere else.
- edflsafoiewq 4y ago> Why does Zig change capitalization of @import and @TypeOf? TypeOf returns a type. Corresponding to how type names are uppercase.
- somethingor 4y ago@TypeOf returns a type: https://ziglang.org/documentation/master/#Names https://ziglang.org/documentation/master/#Names
- Narishma 4y agoThat's entirely subjective. I personally find Zig, Nim and even Go much uglier than Rust.