News for hackers. Stuff that matters.
Re:Rust vs. Go in 2023 by anyfactor on Sunday August 13, 2023 @03:58AM (#37107666)
I don't get paid to write code in these languages; my enthusiasm in exploring them is limited by the amount of energy I have over the weekend. Honestly, I don't see Rust as anything but a code-rewrite language.

I find Rust to be unintuitive, and I don't think it is a language designed to be a "problem solver.

So, what do I mean by a problem solver? If you have a problem and you write code by exploring different solutions, continuously improve, and write hacky stuff where the goal is to simply solve a problem.

Rust is not a problem solver; it is going to fight you all the way through because of its emphasis on programmatic correctness. With Rust, you have to have the solution first, consider the language-specific caveats, and write something in such a way that you don't go back and have to improve it. I suppose that is how programming is supposed to be done - in a clear and structured manner. But let's admit it, nobody does that.

On the other hand, Go is a language that sits between Python and Rust. Python is THE problem solver language, and Rust is an elegant and good etiquette language. Go just works as a hackable language with the benefits of a compiled language and type support.

My plan with Rust vs Go for the time being:

- If I need to solve a problem and can do continuous improvement on the codebase → Go - If I have the problem solved, I have the resources to do a rewrite → Rust

Re:Rust vs. Go in 2023 by deaddodo on Sunday August 13, 2023 @04:14AM (#37107754)
While I hear you and grok+understand you; I think this 100% comes from your background and what problems you are trying to solve. As someone that does a ton of systems (traditional definition; e.g. embedded, OS, emudev, etc) development in my hobby time, Rust (and Zig, more often these days [for me]) is perfectly conducive to my use cases and improves my development flow; while using Go would get in the way far too often.

But when I do work Go excels in (web architecture, especially), I'm not particularly keen on using Rust or Zig in it's place. While it's perfectly possible to build a Postgres-fronting, redis-cached microservice to manage users, auth, etc in Rust, it's going to be an exercise in frustration compared to something more streamlined for that task.

Re:Rust vs. Go in 2023 by berkes on Sunday August 13, 2023 @09:46AM (#37110006)
I disagree here. Anvd also disagree with grandparent.

It's fine to explore with- and write proofs of concepts in- Rust.

In many ways, it's better suited than Python, Ruby, JS or PHP for this, for several reasons. I have too little production experience with go to know how it does here.

The Rust type checker, and easy, built-in test framework, make refactoring easy and certain. Much more than the common "fingers crossed let's deploy" refactoring I've experienced with Ruby and Python. And way more than the Yolo methodology commonly employed in JS and PHP. And fearless refactoring is a requirement for me to experiment and explore. Because once I know what and how I want it, refactoring is needed.

A good, fast testing framework helps me explore. Efficient and iterative. Rust (and Go) have much to offer here, whereas in Python, Ruby and even more so in PHP or JS, testing is an afterthought, third party, bring your own setup. In rust I can start writing a test immediately after 'cargo init experiment'. But I understand not for everyone exploration==tests.

The rediculous ease of deployment of both Rust and Go compared to Python, JS, PHP and worst, Ruby, is crucial when I'm figuring out if people need what I'm building. 'cargo build --release && scp target/build/foo example.com:/use/bin' and I'm hosted and deployed. It's less work than getting a Heroku connected to GitHub. For me, releasing fast, early and often is a crucial feature when exploring. Rust (and Go) have solved this. In fact, this is my main reason to build in Rust: I'm just fed up managing complex and ever breaking runtimes, (pip-, rb-, nv) envs, complex and ever breaking CI.

With rust, my initial versions just have ARCs, Box-es, unwrap()s and clone()s all over the place. It's how I circumvent the frustration, yet know the app is 'correct'. All those clones, unwraps, boxes, Arcs etc act as TODO's, bit without the "this will probably cause corrupted data, fix me!", that my TODOs in Ruby or Python came with when exploring.

Re:Rust vs. Go in 2023 by satvikpendem on Sunday August 13, 2023 @04:29AM (#37107840)
Not really. I use unwrap and clone everywhere and I can do everything as if Rust were then a garbage collected language, and I can then test out different solutions, hack my way through, just as I would in Go or Python. Then once I have a good solution, even if I don't optimize it, it is leagues faster than Python and even faster than Go. If I do decide to optimize it, then, it's fast, really fast.

IMO those who say Rust isn't suitable for hacking seem to try to conform to best practices right away when really, dealing with lifetimes and excessive clones should be part of the optimization step, not the ideation and experimentation steps. Rust is as high level as you want it to be. Hell, I write web backends and sometimes even frontends in just Rust and I never worry about memory until I want to optimize, if I even want to optimize.

Re:Rust vs. Go in 2023 by hannofcart on Sunday August 13, 2023 @04:59AM (#37108014)
> Not really. I use unwrap and clone everywhere and I can do everything as if Rust were then a garbage collected language, and I can then test out different solutions, hack my way through, just as I would in Go or Python.

This part of the comment deserves to be highlighted and mentioned more. I think this exactly the way to "hack something together quickly" in rust.

After that, incorporating correctness seems to be as simple as grepping with each unwrap and "dealing with it".

With the above approach, Rust is a great prototyping language as well.

Re:Rust vs. Go in 2023 by bryanlarsen on Sunday August 13, 2023 @10:07AM (#37110168)
The thing about clone and to a lesser extent unwrap is that 90% of the time, just leaving in the clone is fine. It might be suboptimal, but if it's not in the main loop, who cares?

With unwrap, replacing the unwrap with an expect signals you've accepted that an unwrap is ok in that piece of code. I'd like a similar convention for clone.

Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @10:29AM (#37110354)
If that’s the case, then Scala and similar should also enter the question. That is at least an expressive language compared to Go, and if you don’t need rust’s performance it may be a good tradeoff.
Re:Rust vs. Go in 2023 by peterfirefly on Sunday August 13, 2023 @04:03AM (#37107694)
My first (and so far only) Rust program was an 8088 disassembler. Rust made it easy for me to try "different solutions, continuously improve, and write hacky stuff".

Perhaps it's more a question of background? Rust contains many features I already know from the ML family + it formalizes the way I've already been thinking about memory since the early 90's.

Re:Rust vs. Go in 2023 by brabel on Sunday August 13, 2023 @04:11AM (#37107737)
Now try that on some domain you're not familiar with...

If you ever have to change lifetimes of existing functions/structs on a non-trivial Rust code base, you're screwed.

Re:Rust vs. Go in 2023 by baq on Sunday August 13, 2023 @04:34AM (#37107867)
Observation: Lifetimes are Rust’s checked exceptions in that regard. Changes propagate in the wrong direction - from leafs of the import tree down to the root. Solutions though… can’t really imagine one that makes sense.
Re:Rust vs. Go in 2023 by peterfirefly on Sunday August 13, 2023 @05:55AM (#37108340)
I haven't really had to use lifetime annotations yet, but again, they are just a formalization of the way I already think.

I forgot that I had also written a small cycle-by-cycle emulator of a simple CPU (8-bit data bus, 16-bit addr bus, 8 16-bit GPRs + a 16-bit PC + a single condition flag + an interrupt flag, timer interrupts, conditional jumps, call, ret, iret, mov, add, terminal I/O). That was also surprisingly easy.

I would like to use generators or something similar for a more realistic cycle-by-cycle emulator but I haven't gotten around to playing with that yet.

Generators and various kinds of coroutines are, yet again, just formalizations of the way I have been thinking for years.

Maybe other domains would be more challenging but I seriously doubt it. I do know that it will take me a couple more months before I'm really proficient in Rust -- including multi-threading -- and no longer fear macros.

Re:Rust vs. Go in 2023 by thumbuddy on Sunday August 13, 2023 @06:21AM (#37108497)
You probably shouldn't deal with lifetimes outside of first order use cases in 9/10 cases when a project is in its early stages. A clone or wrapper type isn't all that expensive in many applications. Just because something can be optimized doesn't mean it should be, especially early on in a project.
Re:Rust vs. Go in 2023 by ssokolow on Monday August 14, 2023 @02:16PM (#37124511)
*nod* Rust's "make costs explicit" design does have a bit of a problem with encouraging premature optimization where something like Python would encourage sloppiness.
Re:Rust vs. Go in 2023 by thumbuddy on Monday August 14, 2023 @08:24PM (#37128580)
I'll take obvious jank over hidden jank any day personally.
Re:Rust vs. Go in 2023 by ssokolow on Monday August 14, 2023 @08:48PM (#37128753)
I agree... you need discipline either way. It's just easier to wind up not realizing that you don't need to spend so much time on up-front optimization with Rust to produce a perfectly serviceable program. (Especially if you haven't internalized the whole "fearless refactoring" angle.)
Re:Rust vs. Go in 2023 by thumbuddy on Wednesday August 16, 2023 @05:42AM (#37144732)
We'd probably be good on a team together. Nice to see like like-minded people in here.
Re:Rust vs. Go in 2023 by bibabaloo on Sunday August 13, 2023 @04:08AM (#37107722)
I think it's one of those things where you need to drink the coolaid. Once you get over the learning hump and fighting against you, you won't want to go back to languages with poorer and less strict type systems. There a lot of value in letting the compiler do it for you
Re:Rust vs. Go in 2023 by toasted-subs on Sunday August 13, 2023 @04:18AM (#37107770)
Kind of funny, the experience I’ve had with go was ripping my hair out trying to get dependencies installed. Cargo was incredibly helpful and made the process painless.

If I’m doing something for fun I always go to Python though. Just makes everything seem incredibly natural, and given all the fancy interpreters it can be pretty fast.

Re:Rust vs. Go in 2023 by thumbuddy on Sunday August 13, 2023 @06:23AM (#37108508)
Isn't it just "go mod install" or something? Oh you probably tried it when golang changes where it cached packages. I feel you that was a super crappy time to learn Go.
Re:Rust vs. Go in 2023 by LambdaComplex on Sunday August 13, 2023 @04:05AM (#37107705)
> Rust is not a problem solver; it is going to fight you all the way through because of its emphasis on programmatic correctness. With Rust, you have to have the solution first, consider the language-specific caveats, and write something in such a way that you don't go back and have to improve it.

You just described my reasons for switching from Rust to Go better than I ever have.

Re:Rust vs. Go in 2023 by madiele on Sunday August 13, 2023 @04:33AM (#37107858)
Rust is great for writing stuff that needs to be stable with little downtime, for anything that needs to change a lot rust is not there yet, it has lots of sharp corners like not being able to make a factory interface that returns another interface (thogh this is coming in a few months), in general it's hard to do non-leaky abstractions in rust ATM, I do think it will get there in a few years once the few sharp corners are gone.

But having made a microservice in rust it is the most stable software I ever written, you are basically paying upfront any null reference and thread safety issue I would have needed to debug. It probably did not save me time, but it definitely was a better experience to write

Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @04:22AM (#37107797)
Go is more verbose than Java, which you may very well consider overly verbose. The only reason it is between Python and Rust is that the two languages are two extremes of low-high level languages. Go is as expressive as C, which is a negative.
Re:Rust vs. Go in 2023 by threeseed on Sunday August 13, 2023 @04:26AM (#37107818)
> Go is more verbose than Java

In real world use ridiculously so.

The lack of exceptions, Option type or ability to chain or manipulate errors means every line ends up wrapped in a 90s style "if error" check. Which ends up making code less robust than languages with more modern approaches like Rust, Scala, Swift etc.

Re:Rust vs. Go in 2023 by xyproto on Sunday August 13, 2023 @04:34AM (#37107866)
You can look at "if err == nil" and tell what is going on, but who knows which layer of exception handling will catch that "throws".
Re:Rust vs. Go in 2023 by threeseed on Sunday August 13, 2023 @04:37AM (#37107881)
In JVM languages it is easy to know what is catching what.

The method type signatures clearly specify what exceptions will be thrown.

And the compiler requires you to deliberately handle those exceptions.

But I wouldn't consider Java to be the best approach for error handling anyway.

Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @04:47AM (#37107936)
Which is the only sane thing in most cases. What can you do inside the helper function of a helper function with an incorrect user data? The only sane place to handle it is n levels up, so bubbling up is the correct default. At least rust has a handy macro for it, but go’s error handling is catastrophic, not a proper sum type, nor some form of propagation… it is literally the bad errno from C burned into the language.
Re:Rust vs. Go in 2023 by Aditya_Garg on Sunday August 13, 2023 @12:41PM (#37111551)
In go, you should manually propagate the errors up by returning them. At the n levels up, you handle the error. It's a bit cumbersome during write time but a life saver during read/debug time.
Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @01:30PM (#37112049)
So manually obscuring the control flow/business logic with boilerplate bubbling up is more readable at debug/read time than it being implicitly, trivially there?
Re:Rust vs. Go in 2023 by memefrog on Sunday August 13, 2023 @05:07AM (#37108065)
>90s style "if error" check

What makes it '90s style' other than you don't like it?

Calling something "90s style" and its alternative "modern" is a thought-terminating cliche.

Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @05:51AM (#37108320)
There have been many discussions on the topic of go’s error handling, the main gripes of people can be summarized as:

- it returns both a return value and the error value, not xor. The convention is to use the error value only if returned, but sometimes the other “slot” is also used. If you squint a bit, this is exactly what errno does in C. The better, ML-y or exception-y way gives you a sum type instead, which can’t be mishandled.

- you have to handle it in-place with no convenient shorthand allowing for handling it at another layer (and usually that’s the only meaningful way forward). Also, error handling is a cross-cutting concern, squeezing it inside your business logic is (in my opinion) a bad thing.

Re:Rust vs. Go in 2023 by memefrog on Sunday August 13, 2023 @08:04AM (#37109116)
It's not what errno does in C. errno in C is a thread-local variable which means accessing it is inefficient (it uses thread-local storage, which is much more expensive than a local variable) and you have to do awful things like save errno at the beginning of signal handlers if you call a function in the signal handler that can set errno (basically: any library function).

Whether or not it's better to have a sum type (IMO it isn't), what Go has isn't anything like errno. errno is an ugly wart on the POSIX interface, which is otherwise quite nice. For example, Linux system calls directly return negative error codes, which is a much better way of handling errors, and then the libc has to set errno and return -1. Awful.

>- you have to handle it in-place with no convenient shorthand allowing for handling it at another layer (and usually that’s the only meaningful way forward). Also, error handling is a cross-cutting concern, squeezing it inside your business logic is (in my opinion) a bad thing.

That you say this and then advocate for optional<T>/result<t,e> is insane. That's exactly what a sum type does: it squeezes error handling into your business logic. And no, papering over that with ugly ? operators everywhere is not a solution, it is syntactic sugar. Error handling is part of the logic of your program. It is not just some 'ah we'll return it' thing. Many operations can fail and many errors are recoverable.

Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @08:55AM (#37109549)
> errno in C is a thread-local variable which means accessing it is inefficient

Which is an implementation detail, has nothing to with its semantics what we discuss here. Certain C compilers do wild things with errno as well.

I’m not advocating for optional/result types, I personally believe that checked exceptions are the ideal solution, but it is a thoroughly underutilized tool in PL designs (Java has it, though it has many warts, but that is not inherent to the concept). Hopefully with the wake of effect-typed languages it could change.

With that said, in Rust’s low-level case it makes sense to avoid exceptions, and sum types are an okay solution, especially if it has a handful macro for bubbling up. What go has is just straight up wrong.

Re:Rust vs. Go in 2023 by ssokolow on Monday August 14, 2023 @02:55PM (#37125163)
Java's ecosystem is moving away from checked exceptions because their "bolted onto the return type as a sidecar" design doesn't compose well with functional-style APIs.

Monadic error handling (Rust's Option<T>/Result<T, E>) avoids that issue by putting the error inside the return type as a normal value.

(Which is why, on multiple occasions, I've seen people call Result<T, E> "checked exceptions done right/properly".)

Re:Rust vs. Go in 2023 by kaba0 on Monday August 14, 2023 @03:53PM (#37125990)
> checked exceptions done right/properly

But they fail at including a stacktrace, autobubbling up, auto-unwrap and customizable "hit radius" with a try-catch block (okay, I'm sure some Monadic construct allows for that, but e.g. Rust's version does not).

Re:Rust vs. Go in 2023 by steveklabnik on Monday August 14, 2023 @04:17PM (#37126254)
Try blocks exist in Rust nightly, but given that an IIFE closure gives nearly the same results, there hasn't been a ton of pressure to stabilize them. I wish the team would though.
Re:Rust vs. Go in 2023 by ssokolow on Monday August 14, 2023 @06:49PM (#37127762)
1. Remember that Rust takes a Minimum Viable Product approach to 1.0 releases. There are experiments in adding stack traces in third-party error-handling crates that could eventually lead to additions to the standard library, but we've already gone through at least three iterations (error-chain, failure, anyhow, and possibly eyre) and already have two deprecated methods forever stuck on the standard library Error trait, so they're taking it slowly.

(Plus, true exception handling is messy for a language that cares so much about FFI. Look at the discussions surrounding how panic! unwinding should behave at FFI boundaries.)

2. I think completely automatic bubbling would be a misfeature, and the `?` operator is a good balance between concise ease-of-use and the Rust focus on "code is read far more often than it's written".

3. Again, the `?` operator. I think completely automatic unwrap would also be a massive footgun and comprehension hazard.

4. As mentioned in the other reply, try blocks are in development. (See my previous comment about Rust adopting a Minimum Viable Product approach to v1.0)

https://caniuse.rs/ is a great illustration of how far we've already come and how minimal Rust 1.0 was.

Re:Rust vs. Go in 2023 by erik_seaberg on Sunday August 13, 2023 @05:57AM (#37108361)
That's when automated error handling began to be widely supported in early versions of mainstream languages: C++ (1985), Perl (1987), Python (1991), Java (1995). As time passes, I think it's healthy for us to expect new languages to learn from history and launch with more complete feature sets.
Re:Rust vs. Go in 2023 by memefrog on Sunday August 13, 2023 @07:55AM (#37109049)
'Automated error handling' is a misfeature in a language where correctness matters. Perl and Python can use exceptions and there it makes sense. It makes no sense for a language without garbage collection and frankly the only system where it actually works well is Common Lisp, which has restarts. Without restarts, exceptions are just error codes but with spooky action at a distance.
Re:Rust vs. Go in 2023 by kaba0 on Sunday August 13, 2023 @08:48AM (#37109479)
What does having/not-having a GC have to do with correctness?
Re:Rust vs. Go in 2023 by ssokolow on Monday August 14, 2023 @02:48PM (#37125031)
It's been said many times that Go feels like a language written by people who stopped paying attention to programming language research after the 1990s, as well as that it was written by people who look at C and think the only things that are less than perfect about it in the modern world are memory-safety and lack of a first-class concurrency story.

Some examples (not an exhaustive list):

1. Fibers/stackful coroutines (See "Fibers under the magnifying glass" by Gor Nishanov for why they were hugely popular in the 90s and then got abandoned by all the major OSes and programming languages → http://www.open-std.org/JTC1/SC22/WG21/docs/papers/2018/p136...)

2. Garbage collection (The 90s were the height of GC hype, to the point that the JVM still struggles with "Don't worry. GC research will make it fast." design decisions.)

3. Error handling that feels like "Well, we know that exceptions were a mistake, so the only other option is C-style return values... but, hey, we can at least follow 90s Python's lead in supporting returning tuples." (Granted, exceptions DO bake in a fundamental assumption that all the world can be treated as single-threaded execution amenable to transactional rollback. → https://www.lighterra.com/papers/exceptionsharmful/)

4. No generics until they were pushed into it by things like people writing preprocessors that use the Canadian Aboriginal Syllabics characters that look like angle brackets. (https://www.reddit.com/r/rust/comments/5penft/parallelizing_...)

5. No sum types (Bear in mind that sum types have been around since ALGOL 68 and, on many fronts, C was a step backward that the entire industry copied)

6. Dependency management that was only a hair above "just `git clone` it into your project" for most of Go's lifetime

An example of such a reference would be this quote by rfiat at https://news.ycombinator.com/item?id=31603329

> It's interesting that you find Go to be Rust-adjacent. Setting aside the USPs of each language (goroutines and borrow checker respectively) and just speaking about the general experience of writing code, I find Go painful for all the reasons that I find Rust pleasant.

> The best summary I can give of Rust is that it was designed by people who learned from the mistakes of the programming languages that came before it. The best summary I can give of Go is to quote Rob Pike's response [0] to a request for syntax highlighting in the Go playground:

>> Syntax highlighting is juvenile. When I was a child, I was taught arithmetic using colored rods (http://en.wikipedia.org/wiki/Cuisenaire_rods). I grew up and today I use monochromatic numerals.

> [0] https://groups.google.com/g/golang-nuts/c/hJHCAaiL0so/m/kG3B...

dgunay's reply in that same thread ended on the summarization "I like Go and I feel very productive in it, but its commitment to simplicity is dogmatic in many ways and it very much is missing milestone advancements in PLs from the past several decades. It could easily have been made in the 90s."

Re:Rust vs. Go in 2023 by ssokolow on Monday August 14, 2023 @02:27PM (#37124673)
> Go is more verbose than Java

This. It's Rust, not Go, that has replaced Python for me in any use-case more than a few lines long where the ecosystem is ready (i.e. when I don't need a GUI (PyQt/PySide), SQL (SQLAlchemy+Alembic and Django ORM autogenerate draft migrations by diffing the schema against the DB), or complex web stuff (Django's giant ecosystem of reusable components)), because...

1. Boilerplate like `if err == nil` is demotivating

2. "If it compiles, it works" is very motivating and, aside from having `#[test]`, a type system constraint is worth a thousand unit tests.

Heck, as efforts continue toward things like making LLD the default linker (40-50% reduction in link times) and making an official/stock interpretation of the rust-script utility (https://rust-script.org/), and as I work toward replacing my dual-core AMD CPU from 2011, Rust is going to push even further into being what I use to write "shell scripts" because "It works. Don't ** with it" is the number one psychological effect I have to push back against in other languages.

Re:Rust vs. Go in 2023 by forrestthewoods on Sunday August 13, 2023 @04:33AM (#37107862)
My experience is the opposite. Refactoring Python code is all but impossible. Dynamic types and runtime errors is nightmare fuel for a refactor.

Rust code lets be confident that when I make changes as I explore the problem/solution space that my program will actually work.

Re:Rust vs. Go in 2023 by dannersy on Sunday August 13, 2023 @04:57AM (#37107992)
Like someone else has said, I hear and understand what you're saying but I could not disagree more.

I write Rust professionally and what you hate about Rust is opposite to why I love it so much. Especially in larger projects, I have never in all my career had an easier time hacking and iterating. I'm infinitely more confident in writing a ton of lines that will work once I compile. In Python and Go, I could end up chasing silly bugs and waste time debugging and tracing to find that I made a typo or ran into a language quirk that gave me an unexpected nil pointer. That situation is almost non-existent in Rust, it's just me and the problem. Rust is honest and upfront about its quirks and will yell at you about it before you have a hard to find bug in production.

Those last two sentences aren't 100% true. Advanced Rust can be tough and you absolutely will fight with it. But to be perfectly honest, this gets rare over time and usually it comes from a lack of understanding. When you finally do understand, it's another tool to add to your belt that makes you a better programmer.

Re:Rust vs. Go in 2023 by thumbuddy on Sunday August 13, 2023 @06:18AM (#37108479)
Hard agree here. Once people understand rust, not read some bullet points on a blog they start to understand how useful even the tooling is.

Only thing I'll add is. 8 times out of 10 if you are reaching for advanced rust, you are over engineering. Most software projects don't require it and when they do, you should always question whether there's a simpler more maintainable way or make a other design decision. There is no award for least lines of code, or most utilized compiler. Software is social.

That's Go's biggest strength over Rust and Scala. Good luck getting job security in that language. It takes a few years to really know what I'm saying but in my opinion it's the difference between a senior engineer and a non senior.

Re:Rust vs. Go in 2023 by littlestymaar on Sunday August 13, 2023 @05:14AM (#37108112)
> With Rust, you have to have the solution first, consider the language-specific caveats, and write something in such a way that you don't go back and have to improve it. I suppose that is how programming is supposed to be done - in a clear and structured manner. But let's admit it, nobody does that.

And that's absolutely not how you do it in Rust either. Once you've internalized the Rules of the language, you can definitely grok your solution in Rust the same way you'd do in Python, the biggest difference being that Rust will help you a lot more when refactoring your code to the next iteration, so you'd be more efficient over a few days of work in Rust than in Python.

The big caveat being that you need to actually learn the language first instead of pretending you're a polyglot developer and you can write code in any language without having to spend time learning it, but maybe you'd argue that nobody does that either…

Re:Rust vs. Go in 2023 by alpaca128 on Sunday August 13, 2023 @05:30AM (#37108202)
I get why you think that, but I can assure you Rust is perfectly fine for experimentation with enough familiarity. It cannot match Python in the short term, but it doesn't take much hacking with Python until I wish I had started with a more maintainable language. It is really easy to introduce bugs in Python code that would be caught instantly by a compiler and the debugging time adds up quickly.
Re:Rust vs. Go in 2023 by wendyshu on Sunday August 13, 2023 @11:30AM (#37110882)
Can you give an example?
Re:Rust vs. Go in 2023 by thumbuddy on Sunday August 13, 2023 @06:10AM (#37108424)
If you spent more time with rust your opinion of it would change. It's strength has nothing to do with rewriting software. It's easy to maintain, and pretty fast to write.

I prefer go for cloud integrations because they tend to have the best implementations and most solid APIs. That's about it though.

Python is a good bash replacement, but I don't like writing large projects in it. It's hard to maintain and the errors that come from production are never straightforward. Good for some medium scale mathy compute projects though.

C++ is where I write most math code after prototyping it elsewhere(R or Python)

Rust for me is the answer to most things except, it's ecosystem is a bit weak, and it's a bit of a clout chaser language(not as bad as others though)

Re:Rust vs. Go in 2023 by bryanlarsen on Sunday August 13, 2023 @10:17AM (#37110254)
IME, Rust is the best language for doing major refactors of your code. You can make a major change, and if it compiles you can be relatively confident that you didn't miss a side effect of your change. So it's an excellent language for continuous improvement.