3 ms·
Its all very well writing an evidently biased blog as to why Rust is the future. However, the elephant in the room is Rust's sheer complexity. I will give you
by traceroute66 5y ago
Its all very well writing an evidently biased blog as to why Rust is the future.
However, the elephant in the room is Rust's sheer complexity.
I will give you my anecdotal experience ...
About two years ago, I was getting tired of shell scripts. Not because I didn't know how to write them properly, but because it was always invariably a messy kludge of fixes and hacks strung together in a safe(ish) manner.
Python, the cool-kid of the day was ruled out. Both for personal reasons (I think the space-sentsive nature of Python is dumb), and for practical reasons (dependencies in python is a mess).
So it was between Go and Rust. Both of which could compile into cross-platform dependency-free binaries for ease of distribution around infrastructure.
As it happens, I had a Real World (TM) project, and so what better opportunity than to hack together some spaghetti code for a proof of concept.
My first call was Rust. I wanted to like Rust, I really did. But I found it simply impenetrable as a language, hard to make progress, even in "spaghetti" mode. "The book" was well written, but it was hard to translate it into "real world". I also disliked the "everything is a dependency" and really felt a lot more should be included in "core".
I then went to Go. With Go, I found an approachable language with a more substancial "core" library. The tooling was good (even better with GoLand IDE). And I was able to hack together a not insubstancial "spaghetti" project in less than a week, which then encouraged me to start learning how to tidy it up into something more professional looking.
Yes, Go is not perfect, e.g. I particularly dislike the repetitive and verbose error handling ("if err !=nil") and can't help feeling there could be a "better way". But now I've done a number of projects with it, using all sorts of complexities such as cloud and crypto, I feel Go's benefits outweigh any minor disadvantages.
- gautamdivgi 5y ago>>> Python, the cool-kid of the day was ruled out. Both for personal reasons (I think the space-sentsive nature of Python is dumb), and for practical reasons (dependencies in python is a mess). You can use pyinstaller or Nutika for python. I've used pyinstaller but I'm not sure of the cross platform part of pyinstaller. I have not tried Nutika out (hopefully soon). Pyinstaller creates a binary with the python executable in it. Nutika compiles to native binary code. Either way you have a single file to deploy and run.
- friedman23 5y agoIf your choice of language is restricted to what you can learn to use in a couple of hours your options will be limited and sub optimal. So yes, if you don't know Rust and you only have 2 hours to learn the tool you need for the job Rust is a bad choice. However if you are planning to program as a career and building software is your trade, Rust is an excellent choice. Rust helps you build programs that are correct. Go lets people that expect languages should be able to be learned in an afternoon program.