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:

Popular General Dev topics Top

AstonJ
The obligatory speed test thread :smiley: Check here: https://www.speedtest.net When complete, click on the share link and copy and pas...
New
PragmaticBookshelf
A book on mazes? Seriously? Yes! Because it’s fun. Remember when programming used to be fun? Explore a dozen algorithms for generating th...
New
AstonJ
I really like our #general-developer-forum:in-the-news section and am wondering whether we could automate some of the cross-posting of th...
New
AstonJ
We have a thread about the keyboards we have, but what about nice keyboards we come across that we want? If you have seen any that look n...
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
foxtrottwist
A few weeks ago I started using Warp a terminal written in rust. Though in it’s current state of development there are a few caveats (tab...
New
First poster: dimitarvp
Rails is not written in Ruby. I’m born and raised in Kraków, a beautiful city in Poland, maybe you’ve heard about it, maybe you’ve even ...
New
First poster: bot
Developing Godot Projects with Neovim. When I started using Godot Engine, what surprised me the most is the built-in Language Server Pro...
New
CommunityNews
9 fintech engineering mistakes. Read this list unless you want to build a money dissappearing system
New
harwind
I’m working on a Spring Boot project and I have a controller where I want to map multiple request paths to a single method. Let’s say I h...
New

Other popular topics Top

Devtalk
Hello Devtalk World! Please let us know a little about who you are and where you’re from :nerd_face:
New
ohm
Which, if any, games do you play? On what platform? I just bought (and completed) Minecraft Dungeons for my Nintendo Switch. Other than ...
New
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
Exadra37
Please tell us what is your preferred monitor setup for programming(not gaming) and why you have chosen it. Does your monitor have eye p...
New
PragmaticBookshelf
“Finding the Boundaries” Hero’s Journey with Noel Rappin @noelrappin Even when you’re ultimately right about what the future ho...
New
AstonJ
In case anyone else is wondering why Ruby 3 doesn’t show when you do asdf list-all ruby :man_facepalming: do this first: asdf plugin-upd...
New
PragmaticBookshelf
A Hero’s Journey with Chris Pine @chrispine Chris Pine, author of Learn to Program, Third Edition, discusses his journey to beco...
New
Margaret
Hello everyone! This thread is to tell you about what authors from The Pragmatic Bookshelf are writing on Medium.
1126 25188 745
New
AstonJ
Biggest jackpot ever apparently! :upside_down_face: I don’t (usually) gamble/play the lottery, but working on a program to predict the...
New
AstonJ
Was just curious to see if any were around, found this one: I got 51/100: Not sure if it was meant to buy I am sure at times the b...
New

Latest in General Dev