CommunityNews

CommunityNews

What a better rust would look like

What a better Rust would look like.
The Hare programming language was announced a few days ago, and, at first glance, its syntax looks similar to Rust. So, why would people bother to create a new language which aims to fulfill the same niche as Rust (system programming), with a similar syntax? Rust is often described by

Read in full here:

This thread was posted by one of our members via one of our news source trackers.

Most Liked

OvermindDL1

OvermindDL1

Yeeeeaaaah, HN, reddit, and unending IRC and Discord and Forum servers have utterly ripped this article apart… I’ll do a quick summarization:

In 2022, a standard library should at least contain the following packages:

DearGodNo! In short by making those things in the standard library means you are no longer able to iterate and advance on it, the API is then stuck forever more if you care about backwards compatibility at all, in addition no single instantiation of those is acceptable for all purposes, this is utterly inane to even suggest.

I don’t like centralized package repositories. They add complexity and obfuscation, all while supply chain attacks are increasing.

A useful ecosystem is useful, in addition you are not beholden to crates.io at all, you can make your own package server (even import things from crates.io or others into it statically), or vendor things in (cargo can even do that for you), or a variety of other things. But having a good default is good.

Forcing people to, as the article says, follow the Go model: centralized discovery but decentralized distribution is horrible from a maintenance standpoint because depending on a random git repo can suddenly vanish, has no reliability in long term availability, etc… etc… And that’s not even mentioning the other horrors of the go model that it didn’t even scratch on.

Due to how modules and packages work in Rust, I create dependency cycles more often than with some other languages.

…it’s not possible to have dependency cycles in rust, soooo… wut?

I think that Go got it right: modules are scoped by folder instead of files.

Yeah… modules are scoped by filename, so you actually can know what file something you are requesting from without needing to jump all over the place.

Again, I think that Go nailed it: Using the case (lowercase for private, uppercase for public) of the first letter of the identifier is perfect for lazy developers like me.

AnotherGoodFreakingGod, no, doesn’t matter if erlang does it or go does it, specializing visible by initial-case is stupid, just outright. First of all in go something is either public or private, there’s no other visibility modifiers (of which rust has many).

Yet, I don’t think that lexical lifetimes are the answer.

I’m far from an expert in this field, still, from a programmer’s perspective, I would love to see a mix of compile-time lifetime analysis, Automatic Reference Counting (like in the lobster programming language), and manual memory management (marked as unsafe) when extreme performance is needed. How to solve leaks due to cycles? I’m not sure.

But I’m sure that I no longer want to see lifetime annotations pollute our code ever :slight_smile:

At least the person mentions they are not an expert in this because it’s obvious they’ve never had to deal with long lasting system maintenance. And they seem to do the very what-on-earth thing that a lot of people who don’t seem to know much in thinking that ownership is for handling memory, it’s not, it’s for handling all resources, which yes includes memory but that’s a surprisingly small amount of what it manages, of which in go you still have to manage all that stuff manually still, the only thing go does is handle memory via a (very poor) GC, no other resource.

Thus features only accumulate, and complexity compounds over time.

Which is why rust has every-3-year versions that actively deprecate and add things in a backwards incompatible way, with an auto-migration tool included with the compiler system.

Governance

Related to features bloat: Who is in charge of refusing new features added to the language to avoid its collapse?

That would indeed be the Rust Governance Committee, which is one of the most well set up of any language anywhere with a very well set process.


Among lots of other… interesting things people have said. This article is exceedingly obviously made by someone who does not have long term work in maintainability of backend services in the industry.

chikega

chikega

So many new systems level programming languages ( Zig, Odin , Vlang, Nim, Hare), so little time. :cowboy_hat_face:

faust

faust

I guess the author just likes Go and can’t stand the idea of another language being better :sweat_smile:

Where Next?

Popular Backend topics Top

New
New
New
First poster: bot
C++ Programming - The State of Developer Ecosystem in 2021 Infographic. The State of Developer Ecosystem 2021 is a detailed report about...
New
First poster: bot
In recent months I use Go for the implementation of Proof of Concept in my leisure time, partly to study of Go programming language itsel...
/go
New
CommunityNews
GitHub - mthom/scryer-prolog: A modern Prolog implementation written mostly in Rust… A modern Prolog implementation written mostly in Ru...
New
First poster: bot
Where is the Ruby language headed? At RubyConf 2021, the presentations about the language focused on static typing and performance—where ...
New
CommunityNews
By the end of this guide we’ll have a minimal, working implementation of a small part of Lua from scratch.
New
New
CommunityNews
The History of Franz and Lisp. In 1984, while a graduate student in mathematics and in the relatively new Computer Science Department at...
New

Other popular topics Top

DevotionGeo
I know that these benchmarks might not be the exact picture of real-world scenario, but still I expect a Rust web framework performing a ...
New
brentjanderson
Bought the Moonlander mechanical keyboard. Cherry Brown MX switches. Arms and wrists have been hurting enough that it’s time I did someth...
New
DevotionGeo
The V Programming Language Simple language for building maintainable programs V is already mentioned couple of times in the forum, but I...
New
New
husaindevelop
Inside our android webview app, we are trying to paste the copied content from another app eg (notes) using navigator.clipboard.readtext ...
New
New
PragmaticBookshelf
Develop, deploy, and debug BEAM applications using BEAMOps: a new paradigm that focuses on scalability, fault tolerance, and owning each ...
New
PragmaticBookshelf
Get the comprehensive, insider information you need for Rails 8 with the new edition of this award-winning classic. Sam Ruby @rubys ...
New
RobertRichards
Hair Salon Games for Girls Fun Girls Hair Saloon game is mainly developed for kids. This game allows users to select virtual avatars to ...
New
PragmaticBookshelf
Fight complexity and reclaim the original spirit of agility by learning to simplify how you develop software. The result: a more humane a...
New