ekuber,
@ekuber@hachyderm.io avatar

Rust's unexpected super-power is just how flexible it is. It allows you to write very high level looking code on a low level language. That caused people to use it beyond its intended niche. But it is fundamentally a low level programming language. It will continue becoming easier to use (that's my personal goal!) but there are "obvious" changes that would make things easier at the cost of speed or correctness that cannot take.

ekuber,
@ekuber@hachyderm.io avatar

I think there is a Rust-like language that accepts inference at the cost of perf and speed, that has less stringent backwards compatibility assurances, that interacts with Rust natively. But that can't be "Rust".

ekuber,
@ekuber@hachyderm.io avatar

I personally want that "Rust#" to exist if nothing else to use it as a test bed for Rust features with real world usage. I think there are tons of small things we can do that will make Rust easier to use, but some of the issues with "spaghetti of global state" designs will never be not painful in the language. Some of them can be mitigated with better libraries (allowing granular Singleton field access without keeping locks on the global object), but likely not all of them will.

ekuber,
@ekuber@hachyderm.io avatar

An example I can give: Rust doesn't support return type inference. You can use impl Trait for that. You can also write -> _ and the compiler will tell you what type it would have inferred for you to write down there. Global return type inference won't ever be allowed in Rust. But maybe we could allow it inside of a single module? A single crate? I would expect the DX to be crap, but we could technically do it without losing too much on correctness.

kornel,
@kornel@mastodon.social avatar

@ekuber It would be interesting to have a "do-whatever-you-want-Rust" for prototyping, that has a GC/ARC, allows global state, aliased mut and other "dirty" things, but with support for gradual typing that tightens the requirements, so that you could gradually refactor code into Rust proper where it needs more performance or bugfixing.

Ninji,
@Ninji@wuffs.org avatar

@ekuber I hope this does happen, either as a new language, or just by virtue of other languages adopting features that Rust has popularised.

I really enjoy things like discriminated unions and zero-cost abstractions in Rust, and going back to languages without them feels like such a downgrade…

matt,

@ekuber I wonder if the Rust website ought to be clearer about this. With the current marketing slogan, "a language empowering everyone to build reliable and efficient software," it's easy to think, "of course all software should be reliable and efficient, so, Rust is a language for building all kinds of software."

  • All
  • Subscribed
  • Moderated
  • Favorites
  • rust
  • DreamBathrooms
  • magazineikmin
  • Youngstown
  • thenastyranch
  • rosin
  • slotface
  • vwfavf
  • ngwrru68w68
  • PowerRangers
  • kavyap
  • ethstaker
  • tsrsr
  • mdbf
  • everett
  • anitta
  • khanakhh
  • Durango
  • cubers
  • osvaldo12
  • InstantRegret
  • tacticalgear
  • tester
  • GTA5RPClips
  • cisconetworking
  • normalnudes
  • Leos
  • modclub
  • provamag3
  • All magazines