Rust makes cents

แชร์
ฝัง
  • เผยแพร่เมื่อ 23 พ.ย. 2024

ความคิดเห็น • 500

  • @NoBoilerplate
    @NoBoilerplate  2 ปีที่แล้ว +299

    ERRATA
    Tauri hasn't yet release mobile app bundling, though its in their roadmap. Desktop only for now!
    2:31 Though the "80%" header is right, the table below is only for 128MB lambdas
    4:53 The heading reads "Hander" instead of "Handler"

    • @redcrafterlppa303
      @redcrafterlppa303 2 ปีที่แล้ว +11

      Then for now we will just write it in wasm and use a webapp infrastructure. Rust has always a way ; )

    • @FinaISpartan
      @FinaISpartan 2 ปีที่แล้ว +20

      We do have Rust in our kernels now too.

    • @AceofSpades5757
      @AceofSpades5757 2 ปีที่แล้ว +1

      Can't wait. Really wanted to check out Rust's mobile feasibility, but couldn't find anything particularly easy to get the feet wet.

    • @rumplstiltztinkerstein
      @rumplstiltztinkerstein 2 ปีที่แล้ว +3

      Plus we can write Python dynamic libraries in Rust using PyO3

    • @DJenriqez
      @DJenriqez 2 ปีที่แล้ว +1

      yeah, I'm really waiting for it because it will cover all my project needs with it (windows, android, linux, ios, macintosh, oculus quest (I hope)).

  • @DoomKaiserGliders
    @DoomKaiserGliders 2 ปีที่แล้ว +90

    "oxidizing your entire stack" what a great line, cheers

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +32

      Here's another, if you've not heard of it: Rust is named so because it's close to the metal!

  • @foobar3770
    @foobar3770 2 ปีที่แล้ว +96

    These videos convinced me to write my latest project in rust. At first I thought the project was too big, too many states to model and too many breaking changes. But having written something once, it never broke. Whenever I added a new thing, I first extended the valid states by changing the type of a variable from String to a parsed struct - and the compiler told me where I had to fix stuff. When there were no more compiler errors, I was done. It's fun to write code like this.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +44

      "When there were no more compiler errors, I was done." this is my experience every time I write Rust too! Isn't it relaxing!

    • @keashavnair3607
      @keashavnair3607 2 ปีที่แล้ว +3

      Can you please explain what do you mean by “added a new thing”. It’s so hard to understand what you are working on.

    • @guigazalu
      @guigazalu 2 ปีที่แล้ว +5

      Oh! The same for me!
      I rewrote an old project that never leaves my mind, and now it works at a decent speed and memory usage, while doing what I want it to do.
      It was strange at first, seeing errors and warns I didn't even know the meaning, but with time (just 2 days), once there were no more errors, it was beautiful (actually, as it's image processing, and I have a bad taste, it was ugly, but conceptually working)!

  • @EdissonReinozo
    @EdissonReinozo 2 ปีที่แล้ว +335

    This is becoming a must watch channel. I don't even read the title anymore. I know it is my reliable rust content.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +28

      Thank you! Keep checking the ERRATA comment to make sure it's actually accurate!

    • @wihma97a
      @wihma97a 2 ปีที่แล้ว +1

      Completely agree. Started watching just a couple of weeks ago and now I click as fast as I can when I see a new video

    • @Kiaulen
      @Kiaulen 2 ปีที่แล้ว +1

      Same, this channel is always amazing

    • @BikramKumar-uy8nl
      @BikramKumar-uy8nl 2 ปีที่แล้ว +5

      @@NoBoilerplate The fact that you mention this also makes you worth the praise. Thank you for the content.

    • @PandaNuker
      @PandaNuker 2 ปีที่แล้ว +1

      oui

  • @tuskiomisham
    @tuskiomisham 2 ปีที่แล้ว +61

    I read that energy efficiency paper. The reason Java is so high up is because they used Java to execute the power analysis function, and instead of launching the program externally like they did for literally every other language, they just ran the Java program inside the same VM, cutting corners significantly.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +37

      Rude!

    • @tuskiomisham
      @tuskiomisham 2 ปีที่แล้ว +12

      @@NoBoilerplate indeed, but so is academically misleading many people

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +46

      @@tuskiomisham oh I'm so sorry, I meant that them misleading people is rude, not you!

    • @pixelsam123
      @pixelsam123 2 ปีที่แล้ว +17

      Public static void main string args amirite

    • @natew4724
      @natew4724 ปีที่แล้ว +4

      @@pixelsam123 say it again, public static void main string args
      also you forgot the class

  • @enque01
    @enque01 2 ปีที่แล้ว +194

    The production quality of this is so high. The message is a complex thing made simple, using rudimentary graphics done well, overlaid with a voice that is so pleasant this guy should voice audiobooks. Very much appreciate the level of quality in this!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +12

      You're too kind! I honed my production skills on a hopepunk, scifi podcast, and I'd love to know what you think! th-cam.com/video/p3bDE9kszMc/w-d-xo.html

    • @laundmo
      @laundmo 2 ปีที่แล้ว +6

      i mean, he does a fiction podcast, so audiobooks kinda. it's also really good

    • @raymanovich3254
      @raymanovich3254 2 ปีที่แล้ว +3

      @@NoBoilerplate I always wondered why you opted for calling it a podcast.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@raymanovich3254 what, Lost Terminal? Isn't it a podcast?

    • @iippari7
      @iippari7 2 ปีที่แล้ว +5

      @@NoBoilerplate It is - but the meaning of _podcast_ has been lost over time - I certainly found it surprising that a podcast meant _any_ digitally distributed programme, and did not specifically refer to the format of several hosts having a recorded conversation...
      P.s. Lost Terminal is amazing! It's the first podcast I've listened to in a long time (read: ever) and I love it.

  • @jameslugenga9454
    @jameslugenga9454 2 ปีที่แล้ว +319

    will he ever make a video that isn’t amazing probably not

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +27

      You're too kind! I'm always improving.

    • @nicolashumbert8344
      @nicolashumbert8344 2 ปีที่แล้ว +8

      @@NoBoilerplate This one is right. You seem to just not be able to not be amazing.
      Your videos are a real source of inspiration for a lot of us.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +4

      @@nicolashumbert8344 Thank you so much, I'm so grateful!

    • @znefas
      @znefas ปีที่แล้ว +3

      @@NoBoilerplate As others have said, the quality of your videos is high, and I feel like that's also part of why you love Rust so much, because you too care about correctness. And with such, you keep your videos correct, which in the context of YT vids would be considered videos that achieve their goals well and nothing else, and since you're teaching us about Rust, you're fast, concise, and to the point with no meaningless detours.
      This video quality is amazing, and I'm very thankful to have stumbled onto this channel. Thanks for your amazing work!

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      @@znefas That's so kind of you to say, thank you 🙂

  • @the_kovic
    @the_kovic ปีที่แล้ว +42

    You've mentioned execution time and memory usage but there is an area you didn't mention: disk usage.
    Rust's compiler is a powerful tool that does a lot of checking for you. This takes a lot of time. The first build in Rust takes a long time, easily in the order of minutes. The authors knew this and so, just like C's object files, the compiler produces a lot of artifacts to remember its progress. And this is where the cost of Rust manifests because nothing in the world is ever completely free. Rust consumes a lot of persistent memory on the developer side to power its magic. Even a simple hello world project will take a couple hundred megabytes, real projects easily number in gigabytes of compile-time artifact data.
    There is a argument to be made that persistent memory is pretty cheap today and that this single-time, developer-side cost of space is a small price to pay for all the good stuff - and I would agree with that. But I felt it necessary to mention it for the sake of completeness.

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +20

      Very good take, it's certainly an are that could be optimised more isn't it? Running a Rust CI pipeline is very different to other languages for this particular reason!

    • @pexoto5093
      @pexoto5093 ปีที่แล้ว +2

      wait kovic? the_kovic, the one that made the doom eternal ost remaster? You a rustacean too? life is crazy! cheers m8

  • @dixaba
    @dixaba 2 ปีที่แล้ว +19

    When I first tried Rust in 2016, I was repelled by its weird syntax and borrow checker - C++ seemed much more familiar. Later (in 2019) I decided to try it once more, maybe write something small and simple. And it clicked. Since then I'm using Rust for all my personal projects. I don't remember last time when my program crashed NOT on my own unwrap(), which is just quick dirty hack to make program compile. But unlike said C++, I know that I can just grep for unwrap()s and replace them with proper error handling, not re-reading whole code 50 times.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +12

      THIS IS EXACTLY IT
      Rust can panic like other languages, but you can SEE when it's going to. Fantastic!

  • @angeldude101
    @angeldude101 ปีที่แล้ว +17

    In exchange for making code fast, you generally have to sacrifice some space to hold the compiled binary. While your code may not get to the size of a shell-script one-liner, Rust has plenty of tools available that let you get down to an absurdly small binary, even forgoing the entire C runtime, while still being confident that things won't break.

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +4

      17k on windows, is the record I've seen!

    • @Heater-v1.0.0
      @Heater-v1.0.0 7 หลายเดือนก่อน

      I'm not sure what you mean by "In exchange for making code fast, you generally have to sacrifice some space to hold the compiled binary." Whilst it is true that sometimes one can optimise a compilation for speed and get a bigger binary as a result or vice-versa, I would say that in general the differences are not very big. More common is things like Java, Javascript, Python where one gets extra memory usage, thanks to the way they maintain variables and use garbage collection and at the same time slow performance, for much the same reasons. That's before we have added on the memory consumed by their run-rime systems/interpreters. Anyway, yes, Rust can produce binaries that are as small and performant as C or C++ can, there are many embedded projects running on micro-controllers to test to that. By the way, what do yo mean "forgoing the entire C runtime, "? C pretty much does not have a run time beyond what is needed to initialise the stack and such before jumping to main(), but even that is not running once your program is started.

    • @angeldude101
      @angeldude101 7 หลายเดือนก่อน

      @@Heater-v1.0.0 That comment was largely in reference to replacing a shell invocation that took a few dozen bytes with a 2kiB binary (which was optimized for size). And yes, C _does_ have a runtime and Rust by default links to it, and the dynamic linking alone actually increased the size of the binary more than reimplementing the necessary parts myself.

    • @Heater-v1.0.0
      @Heater-v1.0.0 7 หลายเดือนก่อน

      @@angeldude101 Well certainly it nice to be able to write one line of shell to get some quite complex task done. The comparison with a 2K compiled binary is of little relevance usually. I mean, that line of shell script can be dependent on millions of lines of code, in the shell interpreter, in the commands it is invoking, in the libraries they depend on, in the operating system the whole thing runs on. Perhaps if you wanted to do that same task on a memory constrained system, like a micro-controller, the 2K compiled binary would be the way to go.
      No, C does not have a run-time. Sure your C code may depend on library functions defined in the standard library. Or it may depend on other libraries. Or it mat depend on syscalls to the operating system. It mat even achieve all that via dynamic linked libraries. Non of that is a language run-time. That is just library dependencies. After all consider the kernel of your operating system, often written in C, there is no language run-time underneath that, it is running on the bare metal. In fact that kernel provides run time facilities that all your applications need. Yeah, I know there is often something called "crt" something or other, as in "C run time" that is typically very small and only initialises the stack, processor registers, static variable, etc before jumping to your main(). It can be as small as a handful of instructions. It's also not running when your C code is.
      Whilst it is true that Rust links to the standard functions provided by lib C on Linux, Windows, Mac etc, that is not actually necessary to run Rust programs. Many people are using Rust on bare metal systems that have none of that.

  • @shreyasjejurkar1233
    @shreyasjejurkar1233 2 ปีที่แล้ว +20

    As Mark (CTO of Azure) correctly tweeted, C/C++ should be declared as retired languages and instead use Rust.
    Am pretty sure, going forward most of the cloud services and data centre infrastructure code will be written in Rust. Fast, energy efficient and of course cheap!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +5

      All that is required is for people to understand the power that we have today with rust. I'm making progress on that goal 😊

    • @tayustgemil9285
      @tayustgemil9285 ปีที่แล้ว

      Rust is very new to me, and I wonder: Do you use unwrap()s if you are certein that a variable is Some or Ok?

  • @piguyalamode164
    @piguyalamode164 ปีที่แล้ว +6

    Another thing about rust that makes it very good for writing code: I often find that if I understand what a struct is, I can very often tell what a method does just by its name and type signature. I can also very often find the method I want quickly by looking through the autogenerated documentation

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +2

      This is something you find in Haskell too, rich types are amazing!

  • @cylian8422
    @cylian8422 2 ปีที่แล้ว +83

    Can we get a complete Rust tutorial for begginers?
    You have an amazing writing style and your voice is very pleasant to listen. I'd love to see a good Rust tutorial series

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +43

      Thank you! I did that once, have you seen this th-cam.com/video/br3GIIQeefY/w-d-xo.html
      My focus for the moment is shining a light on all the incredible features of Rust. Once you're excited, The Book is all you need to learn, it's written brilliantly!
      doc.rust-lang.org/stable/book/

    • @zakstephens9297
      @zakstephens9297 2 ปีที่แล้ว +16

      @@NoBoilerplate This is low value and high effort, but the Rust Book with your radio voice would probably come out like a fun bedtime story.

    • @RMy4v5aPte
      @RMy4v5aPte 2 ปีที่แล้ว +2

      @@zakstephens9297 It's ridiculous to call the rust lang book "low value", meanwhile learning any language is going to be high effort if you want to be fluent in it. The rust lang book is probably the single highest quality resource I've come across learning ANY language, with an imbedded compiler and multiple examples and explanations for every single rust concept.

    • @zakstephens9297
      @zakstephens9297 2 ปีที่แล้ว +16

      @@RMy4v5aPte Nah, I mean getting old mate to read it out is low value. The Rust Book is fantastic, I have a copy on my desk right now.

    • @yasintonge823
      @yasintonge823 2 ปีที่แล้ว +5

      @@NoBoilerplate The Book is my bible for the past month.. What an amazing doc is that!

  • @SimGunther
    @SimGunther 2 ปีที่แล้ว +8

    Jean Young's talk on Strange Loop was amazing for bringing attention to system rationality and not just saying "your local program is the only system you ought to be concerned about" knowing there's plenty of tooling for proving local state to not only be correct, but for invalid state to not be representable. Proving that our code can be glued together to talk to other systems correctly would be a huge win in my book for engineers everywhere! :)

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Nice! I'll watch, thank you

    • @joachimfrank4134
      @joachimfrank4134 2 ปีที่แล้ว +1

      Some projects use pact for this when the language is JavaScript. It is used to shard type definition, test cases and mock code between systems. Ones systems mock code are the expected values for the test cases of the other system. This shows that a rich type system together with sharing the type definition goes a long way to securing compatibility. Perhaps there's something like pact for rust, which would also share the tests.

    • @LowestofheDead
      @LowestofheDead 2 ปีที่แล้ว +4

      You can see the full talk here: "Building Observability for 99% Developers" by Jean Yang (Strange Loop 2022)
      th-cam.com/video/UJA4PGKny2k/w-d-xo.html

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +3

      @@LowestofheDead Nice, thanks for the link!

  • @LukaSauperl
    @LukaSauperl 2 ปีที่แล้ว +52

    That feeling when he says "Hi friends" and for a moment you feel like you actually have a friend ... and then the video ends.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +16

      Plenty of friends on the noboilerplate.org discord :-)

    • @The88shrimp
      @The88shrimp 2 ปีที่แล้ว +7

      Just program a friend in Rust.

    • @somedooby
      @somedooby 2 ปีที่แล้ว +4

      Rust is my best friend

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      @@somedooby honestly it feels like that when working with the compiler - amazing!

  • @SharukhKhan-sd7xg
    @SharukhKhan-sd7xg 2 ปีที่แล้ว +1

    Hi it was such a great video man loved it 🤙
    I have a question🙋
    I am a web developer more specialized in frontend development and nodejs( I love js/ts 😄)
    I am thinking about learning rust but confused between rust and go.
    What do you think I should go with that will help in my career.
    Thanks in advance. 🙏

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Both! Go is a fine language that if rust didn't exist, I'd be writing. These are not the last two languages you'll be learning in your career either, so start today 😊
      Try rocket.rs and yew.rs, and go through Rustlings and the Book. Hit up my discord and ask for help in there. Good luck!

  • @leegeorg08
    @leegeorg08 2 ปีที่แล้ว +12

    I'd love to see how one might take formal specification (such as TLA+/PlusCal) and bring it over to the invariants and typing of Rust

  • @yey0072
    @yey0072 2 ปีที่แล้ว +13

    You can definitely see the improvements in information quality by the number of items in ERRATA decreasing each video. Keep it up!

  • @SochetraNOV
    @SochetraNOV 2 ปีที่แล้ว +7

    The voices, the script is so fascinating to watch & listen. 😊😊 you are the one who inspire me to try rust.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Thank you so much! If you want something relaxing to listen to in my voice, I recently started season 10 of my hopepunk scifi podcast, Lost Terminal th-cam.com/video/p3bDE9kszMc/w-d-xo.html

  • @miguelguthridge
    @miguelguthridge 2 ปีที่แล้ว +17

    I've been learning Rust for a few weeks now and one of the things I've spotted is how well the type checker helps you prevent errors you didn't even realise were possible.
    For example, I recently got a compiler error because converting a character to uppercase returns an integrator of characters rather than a single character - it turns out that in some languages, converting some letters to uppercase gives two letters as a result.
    Without Rust's type checker and its spectacular support for Unicode I never would have considered that edge case, which for some kinds of code is going to lead to massive bugs - you've probably heard of all the crashes on iOS and Android due to text rendering issues (if not, Tom Scott has great videos on it). I wonder how many crashes would have been prevented if the text-rendering engines for our operating systems were written in a safe language like Rust.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      Right! The whole community cares about correctness, this is SUCH a huge force!

  • @penguindrummaster
    @penguindrummaster 2 ปีที่แล้ว +12

    Everytime I see your videos, it inspires me to push forward with Rust. It beats me up everytime I try to journey forth, but I'm sure it'll all click eventually.
    Some of the development experience with Rust isn't perfect. An example is the examples.provided with Yew, where I spent 2-3 hours debugging a framework I had never used before to just get their example (written for an older version) working with the latest.
    Ultimately, I'm hopeful for the future of Rust, but I'm also held back by my colleagues that are scared away by the unfamiliar nature of Rust. I'm hoping I can forge a new chapter in my company's history, and move to a bright future in which much of our infrastructure is written in Rust.

    • @sumofat4994
      @sumofat4994 2 ปีที่แล้ว

      Sound like Stockholm syndrome to me. Getting beat up and coming back for more.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +7

      You and me both my friend!
      Yeah, I hit that problem with Yew too, their documentation could be better :-( But once I got it working, I LOVED hot-reloading in-browser. That was an unexpected treat!

    • @enque01
      @enque01 2 ปีที่แล้ว +4

      I too had this experience, with all the tutorials being so simple it gives you the idea that all will be simple from now on. But then when you try making your own thing that is not a tutorial, the compiler beats you up! It is frustrating - "I just wanna use the thing I just created! Why can't I even REFER to it, you silly compiler?!"
      But I find, now after a while, that stops happening. I kind-of just started placing things in memory more consciously, more deliberately, and when I mutate things i tend to do it in a more structured way than before. And slowly the compiler stopped being an annoying brat. Now I even prefer doing "quick and small" tools in Rust, over Python.

  • @defnlife1683
    @defnlife1683 ปีที่แล้ว +6

    “5x faster… If you single thread them.”
    Vito Corleone “ Look at what they did to my boy.”

  • @user-qw9yf6zs9t
    @user-qw9yf6zs9t ปีที่แล้ว +4

    the rust compiler is a real friend, instead of hiding things from you, it shows your mistakes in a comprehensible way.

  • @sadikkadom9566
    @sadikkadom9566 2 ปีที่แล้ว +9

    Currently in the process of learning speed (coming from a Javascript background). I do find it quite challenging, but I hope it'll all pay off in the end. When I do get something write, I feel like I just wrote a magic spell.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      It's a tough start, you're doing well so far! I recommend:
      - fasterthanli.me/articles/a-half-hour-to-learn-rust
      - My rust series (10 other videos)
      - The Book doc.rust-lang.org/stable/book/
      Good luck! Ask for help on my discord if you need it, loads of nice people there! links on noboilerplate.org!

    • @sadikkadom9566
      @sadikkadom9566 2 ปีที่แล้ว

      @@NoBoilerplate Thank you very much for the recommendations. I'll stick with it. I know I'll be turning to nice people like you when in need of help!!

  • @youpie
    @youpie 10 หลายเดือนก่อน +1

    no boilerplate is the not just bikes of the programming world

  • @xXJM01Xx
    @xXJM01Xx 2 ปีที่แล้ว +2

    "Oxidizing your entire stack" I like that! :) Great channel, just found this today. I have been looking to see if any languages out there have been picking up traction in the coding space and Rust keeps popping up for me. I will definitely be learning Rust as soon as I can.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Fantastic! Do check out my other videos for incredible features to get excited about. You'll need that to get over the initial learning curve! 😁

  • @atreusduvelll600
    @atreusduvelll600 2 ปีที่แล้ว +3

    Another great video! I love that "oxidization of the stack" is a term. Very clever :D

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Rust is close to the metal XD

  • @Dominik-K
    @Dominik-K 2 ปีที่แล้ว +2

    Very interesting and actually the main reason I'm learning Rust currently. If I need a highly efficient language, especially as cloud providers will charge you for all inefficiencies too, for critical code it's imperative to be efficient. Otherwise the whole system can become unnecessarily slow or Ressource hungry

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      That's it! And, unlike C++, we get this with a pleasant to use high-level language too!

  • @encapsulatio
    @encapsulatio 2 ปีที่แล้ว +3

    Roc language is probably going to be in 3-4 years my main "productive language" while still being "safe enough".
    Every time Feldman makes a new video about it's progress I am quite amazed. He takes ELM unrivaled developer experience and "faster than GO" as his main objectives for his pure functional language. My hope is that he can go in terms of speed more to rivaling C# and Java. Then it's truly going to be an incredible language.
    His full type inference approach is very interesting.
    - Richard Feldman, Pushing Boundaries with Roc - latest talk is the reason I'm so excited about it.
    Most of the comparisons in his video are with Rust and Typescript.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Very impressive! But, so is Haskell, and as you say, Elm.
      I'm excited by Haskell not just because of it's technical qualities, but because it's *popular* and I can hire a team and get working with it TODAY.
      When Roc passes Common Lisp (dead center) I will start to pay attention. redmonk.com/sogrady/2022/03/28/language-rankings-1-22/

  • @tordjarv3802
    @tordjarv3802 2 ปีที่แล้ว +1

    Just to clarify, it is very possible to write logic errors in rust that will compile. Just because the types match in a statement doesn't mean that it is logically sound. You can for example accidentally write "or" instead of "and", the compiler wouldn't be able to see that that one is incorrect just from the types, it would have to know the programmers intention, which it do not.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      Very true, of course. It's much easier to find these errors, when you don't have to wade through the marsh of uncertainty that other languages have, however!

  • @PaleyBlog
    @PaleyBlog 2 ปีที่แล้ว +6

    Thank you for the video. The style of your videos feel like a breath of fresh air. Interesting topics presented in a simple to understand and short enough format. No boilerplate indeed.
    I wish other content creators would learn from you

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      You're very kind! I try to make it as good as I can.

  • @BsktImp
    @BsktImp 2 ปีที่แล้ว +2

    This man's delivery could convince you night is day.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      I promise to only use my powers for awesome

  • @vildemare
    @vildemare 2 ปีที่แล้ว +3

    Great and exciting vid! Really like the channel format!

  • @asdfghyter
    @asdfghyter ปีที่แล้ว +1

    The downside I can see with the "correct now" principle is that it can harm velocity when prototyping and iterating. You often don't know what product you need to build, so it's important to get some kind of prototype in the hands of a user as quick as possible, so you don't waste time building a product that no-one needs. In those cases it usually doesn't matter if there are bugs in edge cases, since you just want to know if the entire idea is crap or not.
    There are of course still shortcuts you can use in Rust like using unwrap and clone liberally and there's also the risk of prototypes ending up in production, but I still think this is a real downside to using languages like Rust and Haskell, which forces your programs to be correct from the start.

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      I don't think your concerns actually manifest in practice. Once you know Ruby on Rails, you can rapidly prototype, once you know React you can rapidly prototype, and once you know Rust, you can rapidly prototype.
      A newbie in any of these would be slower at first.
      And even on top of that: Compiler-driven development has the potential to be FASTER than iterating in traditional tools because so much more is checked for you by the compiler. I've got a draft video on this topic coming soon!

  • @doktoracula7017
    @doktoracula7017 2 ปีที่แล้ว +2

    5:42 This makes me wonder, how many things we could automate and improve to make dev lives better, but we never thought about doing it? Automated upgrade of code to new library versions? Maybe graph based documentation that is compile time checked, so it's never out of date? Maybe automated scaling where code works without changes no matter if it runs on one cpu, multiple cpus, multiple local network machines or cloud?
    There are many ideas coming to mind, though most are taken from "Features of a dream programming language 2nd draft"

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      If you made just one of these, I'd buy it :-D

  • @jordixboy
    @jordixboy ปีที่แล้ว +1

    "You can trust compilers" Meh, debatable, I've read a very interesting paper that was saying that compilers could inject malware or bad code into your code, take care of what compilers you download. But I get the point! great vid as usual

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      Oh sure, everything is possible, but I'll take my chances with an extremely well-reviewed piece of open source software ;-)

  • @wChris_
    @wChris_ 2 ปีที่แล้ว +2

    Rust in the kernel is really exciting, to finally see another language in the kernel that is memory safe! But there are still a lot of problems, mainly the use of unstable features in kernel rust. That is to say that rust is not yet mature enough to be stable for kernel needs. But what is most exciting is the comparison of the NVME driver which is just as fast the C implementation, thwarting any concerns about speed!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      "mainly the use of unstable features in kernel rust."
      I'm not sure that's quite right there.
      Unsafe isn't any worse than C, it just means you can defeference a raw pointer, plus 4 other pointer-related superpowers. (see the book for them).
      ...C can do all these unsafe operations with no oversight already, and we already write the linux kernel in that XD

    • @wChris_
      @wChris_ 2 ปีที่แล้ว +2

      @@NoBoilerplate Im not talking about unsafe, i mean feature like 'global_asm' or 'allocator_api' which are currently unstable that means the build could break in any verison which is a huge nogo. There are talks of having a dedicated kernel rust version, but that would lead to stagnation, like with C, where they had C89 for the longest time as the kernel C version, they only updated it because of a speculation bug, which couldnt be fixed in the version they had, so they went straight to C11 Wich is also a decade old but its atleast more modern than what they had.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      @@wChris_ oh! sorry I read 'unstable' as 'unsafe'. My bad!
      Unstable features get stabilised pretty quickly, even in the short time I've been following things. The Editions system perhaps could help here?

  • @OoXNikoXoO
    @OoXNikoXoO 2 ปีที่แล้ว +8

    Can you talk about the implications of adding Rust to the Linux Kernel and how it affects code safety e.g. when a kernel panic occurs from whatever cause
    could Rust handle that better than existing C implementations?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      I too am looking forward to the discussion on this topic. I'm not a kernel developer, so I'm not the right person to talk about it I'm afraid!

    • @lucky-segfault
      @lucky-segfault 2 ปีที่แล้ว +5

      rust doesn't inherently handle panics better, but it does require programmers to clearly mark everywhere where a panic can occur using the `panic!()` macro, the `.unwrap()` method, or something similar.
      In theory, if a programmer can replace all `panic!()`s and such with code that compensates for the issue, you code can become panic-proof. You can even use a macro called `no-panic` to make sure a method is incapable of panicking or it will fail to compile.
      In practice, I suspect panics will still happen sometimes, but they may be so rare as to only effect driver developers with non-rust languages and the like.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@lucky-segfault Indeed, I did a video on this very topic! th-cam.com/video/sbVxq7nNtgo/w-d-xo.html

    • @olestrohm
      @olestrohm 2 ปีที่แล้ว +3

      I haven't looked at the latest iteration in detail, but as far as I'm aware the kernel doesn't panic. That's not a thing it wants to ever do. In light of this one of the things that were required to put rust into the kernel was to provide better support for non-panicking data structures/functions. For example Box::try_new tries to allocate a new Box, but if it runs out of memory and the allocator can't do that, then it gives an Err instead. So Rust's normal enum and rich type system actually makes the same patterns even better. In C you would perform the allocation and simply receive a null pointer in the cases where it runs out of memory, and it's up to the developer to check each pointer returned by malloc.
      In Rust that's as easy as ?

    • @olestrohm
      @olestrohm 2 ปีที่แล้ว +3

      In fact Asahi Lina (whose live streams are on youtube) has just written a GPU driver for the M1 mac in Rust, which is where I saw these patterns

  • @hc1770
    @hc1770 2 ปีที่แล้ว +6

    After using Rust for a project and spending the time to understand new concepts like borrowing, lifetimes, I started to enjoy coding in Rust.
    The start was frustrating as the compiler just doesn't compile! It was very different with how development was with NodeJS. Which even if the code or syntax was wrong, NodeJS compiles and only when you execute that function it fails. I can totally relate with the narrative in the video whereby in Rust, if the compiler compiles, it just works.
    Unfortunately I'm working on a NodeJS project (not typescript) and always thinking about the type system, enums and lifetime.
    Writing in Rust really changed the way I handle my codes now.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Rest is good for our mental health isn't it!

  • @sputnick1
    @sputnick1 2 ปีที่แล้ว +6

    Can we get a video describing your workflow when creating a video like this if you have time? what software do you use. Why and how do you do things?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      Have a look at the middle of my 'lightsaber' video - I use obsidian.md!

    • @theninjascientist689
      @theninjascientist689 2 ปีที่แล้ว

      @@NoBoilerplate Rust and obsidian! Tis a beautiful way to live

  • @noblenetdk
    @noblenetdk 2 ปีที่แล้ว +1

    Short precise and to the point - hard to be anything than Impressed.

  • @porky1118
    @porky1118 2 ปีที่แล้ว +2

    8:45 "Look how simple a hello world" is in Rust. At least compared to more popular languages like Java/C#.
    No need to use classes, static methods, string arrays, return types.
    In the beginning you wouldn't need to know static, arrays, string types, and any class specific stuff. You only want to know functions, maybe.
    And that's basically what a "hello world" in Rust looks like. Just a function, and a macro. No types at all.
    I still think, a simple hello world has some value.

    • @CristiNeagu
      @CristiNeagu ปีที่แล้ว

      Now compare that with Python...

    • @porky1118
      @porky1118 ปีที่แล้ว

      @@CristiNeagu Same for scopes. Probably shorter. It's just this line:
      print "Hello World"

  • @DavidsKanal
    @DavidsKanal 2 ปีที่แล้ว +3

    Hey, awesome content as always. Was just wondering: I have a hard time differentiating your videos from afar when I see them appear in my recommended, mainly because they're so similar visually (thumbnail). I'm sure you're aware, so have you thought about how you could have more diversity in your thumbnails apart from keeping the same icon and changing the text? I mean, your thumbnails *are* recognizable, I immediately know it's your video, so I guess that's good, and given they're not really about any visual topic, I also struggle to come up with a good alternate design without making them annoyingly clickbaity or cluttered. I don't know! What are your thoughts?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      My rust series won't go on forever. I will eventually run out of features to hype up! :-) And then, I might try a different colour logo.
      It's entirely possible I'll need to figure out the art of a YT thumbnail later on, and you might find big changes!
      I'd welcome any and all suggestions.

  • @somegeneralist
    @somegeneralist 2 ปีที่แล้ว +4

    Another great video - one of my favorites yet! I mainly write of Typescript for work, but have to admit that you got me to read up on Rust and I love it. Starting Rust for Rustaceans now. Just wish GCP had integrations with rust (apart from running containerized in Cloud Run or GKE).

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Google back Go, of course, and have made a carbon copy of Rust, called Carbon. I'm deeply suspicious of their motives there! -.-

    • @somegeneralist
      @somegeneralist 2 ปีที่แล้ว

      ​@@NoBoilerplate 😆😆

  • @IronCandyNotes
    @IronCandyNotes 2 ปีที่แล้ว +16

    "The human cost of writing Rust" 😆

  • @maxpursian
    @maxpursian 2 ปีที่แล้ว +3

    Your Videos always make me want to try Rust out even more! I started a lot of smaller tests with rust here and there, but I still need to work myself up to work through the Rust Book to get fully started with the language.
    What is your stance on "the right tool for the job" with Rust? Would there still be Projects you wouldn't recommend Rust for?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      I think the biggest category where Rust wouldn't be the right choice is applications where having a big runtime is an asset, not a feature.
      The one that comes to mind first is Data Science. Playing around with datasets in a repl is a huge part of doing data science, and it's not the types that matter but the values, so a rich compiler won't be as much help as building a larger app.
      Julia is a language i'm excited about for this sort of work!

    • @maxpursian
      @maxpursian 2 ปีที่แล้ว

      @@NoBoilerplate Oh absolutely, especially doing Uni work, it’s nice to just script things and play around with data. I’m using Python for that :) But Julia or R are also present in some fields. There’s really a lot of languages to choose from haha

  • @eboubaker3722
    @eboubaker3722 2 ปีที่แล้ว +30

    It's a good day whenever he uploads 😀

    • @vildemare
      @vildemare 2 ปีที่แล้ว +1

      Yep, always feels such a long wait for the next one..

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      I feel the same! So nice to chat to everyone :-)

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Currently it's fortnightly, but if the Patreon takes off...!

  • @picklypt
    @picklypt 2 ปีที่แล้ว +7

    You got me into rust and now I'm building two project with it. Thank you so much!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      I'm so pleased! This is why I started this series!

  • @m.hosseinmahmoodi
    @m.hosseinmahmoodi 2 ปีที่แล้ว +1

    I agree that rust is “Good Fast Cheap” but as an C\C++ I have 2 problems that make it hard for me to use rust:
    1. No support for C++ libraries (as far as I know)
    2. Rusts syntax is just too different, and I don't know, for me, it feels weird to write a type of variable right of it instead of left.
    Thing that I probably would like if I switch:
    1. Compiler errors
    2. More memory protection
    BUT in my case, “no support for C++ libraries” out weights every other thing.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      1. You're right, though Rust's C support is excellent (doc.rust-lang.org/nomicon/ffi.html) calling C++ functions requires a C wrapper. This is how C++ libraries are wrapped (such as GTK crates.io/crates/gtk)
      So it's not impossible, certainly easier than with Python, it's not as direct as with C.
      Check crates.io, you may find that someone has done the work for you for the library you want to use!
      2. Syntax is syntax. Some people prefer type on the left, some on the right. Many people have it even harder, and are coming from dynamic languages and ask me why it needs to be there at all! This is a matter of style, and one you may have to get used to if you want to try new languages, as it appears to be the prevailing style.
      My take is that the NAME of the variable is something I look at much more often than the type.
      Because the Rust compiler does type inference based on both sides of the = sign, in most cases, only the function signature needs to be typed.
      I am sure that you will have no problem learning Rust, coming from a C++ background you're already familiar with many of the low-level features I had to learn (My background was Python).
      This article was revolutionary for me
      fasterthanli.me/articles/a-half-hour-to-learn-rust.md
      So much so that I got permission from the author to make a video version th-cam.com/video/br3GIIQeefY/w-d-xo.html (though the article is better)
      I have written about 10 other Rust videos showing the remarkable features of this language. The playlist is here th-cam.com/video/Q3AhzHq8ogs/w-d-xo.html
      I'd give them a watch, and I hope you will see that small differences in syntax will seem like a small price to pay :-)

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Oh! I just found cxx.rs - which seems to do what you want! There's also bindgen, but I don't know much about that.
      Come and chat to me and the community on my discord if you like, the people over in #programming would be delighted to talk C++ / Rust integration discord.gg/mCY2bBmDKZ

  • @JohnnysaidWhat
    @JohnnysaidWhat 2 ปีที่แล้ว +1

    Ok damn that answers my question about aws. Thanks for linking this in your comment!

  • @DaxSudo
    @DaxSudo ปีที่แล้ว +1

    Listening while at Costco this is fun. I love these videos.

  • @fischi9129
    @fischi9129 2 ปีที่แล้ว +1

    I still can't see the advantages of lifetimes. I can def see the need for them considering how the compiler overall works, but I still can't see a single scenario where the lifetime allows me to do something I wouldn't be able to do without.
    Something that should be told, till you aren't proeficient in rust, rust is a headache cause you spend 20 hours on compiler errors for every 1 hour without. But once you are fluent in it, everything you said is pretty correct.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      No denying the learning curve, but that's why I'm here to get you (and me!) excited enough to push through to that point you mentioned, where you're fluent in it. It's a hard road initially, though. I crashed out twice in 2020. Glad I pushed through!
      The benefit of lifetimes (to us, not to the compiler) I can't yet explain clearly enough, though I'm nearly there. I'm writing the video, stay tuned!
      The tldr is that if your type system has lifetimes, you can model not just what your data is, but WHEN. (what sequences of your data are valid). Come ask on my discord, links on noboilerplate.org, and those smarter than me may give a better answer!

    • @fischi9129
      @fischi9129 2 ปีที่แล้ว

      @@NoBoilerplate Thx

  • @rajm.5819
    @rajm.5819 ปีที่แล้ว +1

    The best Rust videos live here. Great accented voice over. ❤

  • @ujjawalsinha8968
    @ujjawalsinha8968 2 ปีที่แล้ว +1

    What are your thoughts of Clojure, a dynamically typed functional programming language that runs on JVM. Rich Hickey, the creator of Clojure, have very strong opinions about why to not use static typed language. I am curious. What are your thoughts?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Love it. Before I discovered Rust, I was a professional clojure developer for 2 years, I even made a video about it! th-cam.com/video/k_4rLyqQeAA/w-d-xo.html
      Rust has taken so many of the features i love from Clojure:
      - Expression-based language
      - Real lisp macros
      - fluent interfaces everywhere
      - Instant feedback (albeit from the compiler instead of repl)
      I searched for years for a way to make typing work with clojure. Typed clojure just never clicked for me, it was so much overhead, no-one really uses it, and it wasn't very powerful, clearly an after-thought.
      Finding Rust (which is Lisp in C's clothing with Haskell's type system) has been revolutionary!

  • @ameypendokhare3832
    @ameypendokhare3832 2 ปีที่แล้ว +2

    Hello Mr.Tris , here's a thing for you : when Joe Armstrong said Erlang is 'write once, run forever' and as Erlang's main strength is support for concurrency
    (also its functional ❤️) .
    And as far the journey had we knew Rust⚙️ is known for the FEARLESS CONCURRENCY ⚡.
    Could you please make a next video on concurrency and the parallel stuffs ... taking Rust and other buddies in comparison.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Love it, good comparison topic erlang-rust. Thank you!

  • @TimeConvolution
    @TimeConvolution 2 ปีที่แล้ว +1

    How does rust targeting arm on lambda compare to rust targeting wasm-wasi. I think I remember a blog post saying wasm was way faster

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      I don't understand your question, this sounds like Apples and oranges. Do explain more?

  • @Honken
    @Honken 2 ปีที่แล้ว +1

    Building a large project with any Rust framework is extremely energy intensive though.
    Just the initial Yew/Rocket/what have you build downloads ~400-500 dependencies, spinning all cores at 100% for 5-15 minutes depending on how new your computer is. That number shoots insanely high once you get everything else you need (db drivers, auth, caching etc).
    I would use Rust a lot more if it wasn't for tiny one off projects taking ~6 gigabytes of storage after draining my battery by 20% before I even get to open my editor.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Compile times are a huge focus for the core team. And maybe you're a little out of date? I remember such compile times when I first started using Rust in 2020, but every version they get faster and faster!
      I just tried the Rocket hello world demo, and it uses ~100 crates. On an M1 mac this takes 10s to compile cold, and 0.1s to recompile.
      Do try the same and let me know how you get on!

    • @Honken
      @Honken 2 ปีที่แล้ว +1

      ​@@NoBoilerplate
      I don't know about Rocket now, I used it around the same year you mentioned.
      Yew however comes at this size, presumably for all the wasm deps.
      Following the Yew tutorial, it took me ~30 minutes before I could open my editor, downloading and install trunk, wasm, bindgen, yew and what not.
      Those 30 minutes were 80-100% CPU usage on all cores, and drained a fifth of my battery. This has been my experience with all Rust frameworks 2019-2021 (ish).
      But happy to hear! I know there's been some fuzz around linkers and debug builds coming down. That is awesome news.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      @@Honken Yeah, do try out Rocket again, you'll be pleasantly surprised!
      Yew did take a lot to set up didn't it? Trunk was especially weird too when I set it up, downloading some binary blobs that I wasn't keen on . HOWEVER I don't actually mind those setup costs - they're one-time. They should be faster, you're right, and they're getting better, but at least they're one time.
      Once I got yew installed for the last video, and started playing around with it, the experience was SO FAST, even hot-loading code into the browser when sourcecode changed and compiled. WOW!
      Please don't let the long compile times put you off, and if they still do, just try again in 2 months, they're getting better every release 🙂

    • @Honken
      @Honken 2 ปีที่แล้ว +1

      @@NoBoilerplate Thank you for always being so positive and encouraging in your comments. I'll take you up on that, and subscribe :)

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@Honken My pleasure! I'm trying to help people out with the videos, it'd be weird if I didn't also do that in the comments 🙂
      There's 10 other videos in the series right now, have you seen them? Here's the playlist th-cam.com/video/Q3AhzHq8ogs/w-d-xo.html

  • @TheEvertw
    @TheEvertw 11 หลายเดือนก่อน +1

    While Rust forces you to prevent errors, the compiler usually tells you exactly how to fix the problem, and gives pointers explaining the problem very clearly.
    The problem with learning Rust is on the level one up from getting the syntax right. It is getting rid of unsafe constructs that other languages advocate. Like callbacks or back-pointers etc. But it are exactly those structures that make our software so brittle.

    • @NoBoilerplate
      @NoBoilerplate  11 หลายเดือนก่อน +1

      Agreed, and rust's unsafe system makes this process as easy as it can be!

  • @ericng8807
    @ericng8807 2 ปีที่แล้ว +2

    Was that blue line at the bottom always there? I can't unsee it anymore

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      It's a progress bar for people who watch in full screen.
      Reveal.js has it as a feature, and I quite like it!

  • @adamd0ggg2
    @adamd0ggg2 2 ปีที่แล้ว +2

    Was able to write a rust rocket app today. It was 100% a challenge but I learned a lot. What advice do you have for writing good idiomatic rust? I find myself cloning strings and objects often to get it to compile. It works, but it feels like I'm taking the easy way our or not thinking rusty enough.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Adam, you're doing it right, cloning strings and objects is absolutely fine when you are getting started. Rust is 80x faster than Python, you'll get fine performance XD
      Come ask questions on the noboilerplate.org discord - there's a channel #newbie-advice just for this!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      "most apps should be written in a higher level language until you can no longer do so" Telling a newbie this is very mean and closed-minded. Please learn more.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      ​@Christopher Grant Chris, look at the context of your statements:
      You're commenting in a thread where a newbie is excited about Rust and has written a simple web app and is starting to ask intermediate questions about cloneing.
      You're too late with all this advice! Adam is excited about Rust and has already breezed past the problems that that paper's authors seem to think are too difficult. They're not, ownership is easy.
      Python's a fine langauge to learn to code in, so is javascript or ruby.
      For me, Python was my boat. It's got me to the other side of the river, but I'm not taking it with me as I climb the mountain.

  • @fabiobregasi5290
    @fabiobregasi5290 ปีที่แล้ว +1

    I'm currently learning Go as I think it has more appeal on the market right now, but I can't wait to start writing some Rust, your amazing videos really convinced me to buy the Rust book. I will ASAP

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      Go's a great language too, you'll have a good time! Absolutely no harm in learning both, as developers, that's what we do!
      The book (also in epub) is free, don't forget doc.rust-lang.org/stable/book/
      (dead tree formats don't have working links ;-) )

    • @fabiobregasi5290
      @fabiobregasi5290 ปีที่แล้ว +2

      @@NoBoilerplate I agree 100% :) thanks for the link!

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      @@fabiobregasi5290 HAVING SAID THAT here's two features that you can't get in Go ;-) th-cam.com/video/PuMXWc0xrK0/w-d-xo.html

  • @cerulity32k
    @cerulity32k 2 ปีที่แล้ว +1

    Rust's learning curve is about the same learning curve it takes to write safe C++ code on/near the level of Rust, only it's steeper due to the language enforcing safety onto you. You need to know ownership, borrowing, lifetimes, etc. before you can write a sizeable Rust project, while in C++, you need to learn pass by value, reference or pointer, null checking properly, and lifetimes. However, because it's not required, you don't need to do it, making the learning curve for general C++ code much shallower, at the large cost of possibly segfaulting/crashing code.

    • @KohuGaly
      @KohuGaly 2 ปีที่แล้ว +2

      The way I like to put it is Rust has V-shaped difficulty curve. It's hard to learn, easy to get proficient and hard to fully master. With C++ it's an ever-steepening hill all the way up.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Ooh, that's very interesting. I think of it like this:
      In most languages Easy things are Easy, and hard things are possible. In Rust, Easy things are possible, hard things are Easy.

  • @magfal
    @magfal 2 ปีที่แล้ว +2

    How does rust and native compiled dart code compare on arm for performance?
    My company's Flutter app is already fast enough to not appear on our heavy users' battery monitors.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Most languages are fast enough. Even Python's 80x slower than C doesn't hold it back from being the #2 language in the world!
      I don't know of ARM benchmarks, but according to the paper referenced in this video, Dart is 6.67x slower than C, just behind Javascript. For comparison, Rust is 1.04x slower than C, and C++ was 1.56 slower.
      So your dart app uses probably a similar amount of power to a javascript app, but the CPU-bound parts use 6x more than Rust.
      This is only pure cpu tasks, most app time is waiting for IO, which is why most languages seem fast enough - they're not executing most of the time!

    • @magfal
      @magfal 2 ปีที่แล้ว +1

      @@NoBoilerplate Flutter projects are compiled to native arm machine code for mobile devices. It also leverages GPU acceleration a lot for the GUI layer
      The near JS performance is likely when it's transpiled from dart to JS for use as a JS alternative like typescript.
      We're actually doing a lot of heavy lifting in the Flutter client.

    • @magfal
      @magfal 2 ปีที่แล้ว +1

      By the way your videos are great!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@magfal Oh cool! I didn't know that. I hear only good things about Flutter.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@magfal Oh thank you so much! I'm learning every day 🙂

  • @dylanstrudwick1226
    @dylanstrudwick1226 2 ปีที่แล้ว +5

    hi friends. my name is tris and this is no boilerplate, focusing on fast, technical videos.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      you should have your own show! :-D

  • @mika2666
    @mika2666 2 ปีที่แล้ว +1

    Another great video, I always look forward to the next video!

  • @TehGettinq
    @TehGettinq 2 ปีที่แล้ว +1

    Anyone knows what's the font used in the examples?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      It's defined in the first line of the source code.
      (it's FiraCode Nerd Font)

  • @FelixTheAnimator
    @FelixTheAnimator 2 หลายเดือนก่อน

    As a person whose never coded in their life, how does one go from "hello world" to translating their favorite open source program written in C+ into Rust?
    I have a hunch OpenToonz's "buggy" reputation is mostly memory errors. Because it works fine for me (with ancient quad channel memory) but crashes fairly frequently for everyone else.

  • @PandaNuker
    @PandaNuker 2 ปีที่แล้ว +2

    I just looove your channel so much. I wish I could work with Rust in my day-to-day job.
    The reality I've gotten used to is that for fullstack web dev (+ serverless), using e2e typescript in a monorepo saves incredible amounts of time: shared types, strong generics (close to rust), linters, shared libs, and one language design.
    But ngl I just love rust and wish I could use it professionally

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      I too take what I've learned from Rust into my day job to improve the Ruby we write!

  • @tsalVlog
    @tsalVlog 2 ปีที่แล้ว +3

    I urge the Rustaceans to give Lost Terminal a try - it's gonna be up the alley of most of you!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      You're too kind! I also think so!

    • @serioustr
      @serioustr 2 ปีที่แล้ว +1

      The podcast? Not sure if I am looking at the right thing

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@serioustr This is Lost Terminal, written by a geek for geeks 🙂
      th-cam.com/video/p3bDE9kszMc/w-d-xo.html

  • @akiko8102
    @akiko8102 2 ปีที่แล้ว +1

    Looks like a good written promotion) but honestly, everything you are saying is totally true imo

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      I should hope so! I'm certainly making hype videos

  • @AceofSpades5757
    @AceofSpades5757 2 ปีที่แล้ว +1

    Another eloquent video. Thanks for the excellent work!

  • @cerulity32k
    @cerulity32k 2 ปีที่แล้ว +1

    11:08 Flesh is unpredictable, silicon is certain.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      You've been listening to Lost Terminal haven't you XD
      th-cam.com/video/p3bDE9kszMc/w-d-xo.html

  • @benjacook3771
    @benjacook3771 2 ปีที่แล้ว +1

    Like how you mentioned Neovide I've been using it recently it's so awesome :)

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Nice! Did you see my setup video for it? (my 'lightsaber' video)

  • @Hohmlec
    @Hohmlec 2 ปีที่แล้ว +1

    Could you guide me for building microservices with rust?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Come chat to the community on the discord, links in the description!

  • @mankaranbedi8927
    @mankaranbedi8927 2 ปีที่แล้ว +1

    Alright you got me. I'm learning Rust today

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Fantastic! Do watch my other videos on Rust, there's astonishingly good features there that you'll NEED to know about!
      Start here fasterthanli.me/articles/a-half-hour-to-learn-rust
      Then hit The Rust Book, and Rustlings. Good luck!

  • @mehtubbhai9709
    @mehtubbhai9709 ปีที่แล้ว +1

    you have convinced me to learn rust

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว

      Wonderful! Honestly this language sells itself! Have you seen my video on how to learn Rust? th-cam.com/video/2hXNd6x9sZs/w-d-xo.html

  • @arthurpenndragon6434
    @arthurpenndragon6434 2 ปีที่แล้ว +1

    As a complete newcomer to low-ish level languages from python who doesn't even know what the use cases for Rust are, is the Rust book still a good place to start, or do I build my beginner level experience elsewhere first? I want to be future-proof, since I hear a lot of buzz about Rust replacing C++ in the years to come.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      You've got a very similar background to me!
      I'd recommend:
      - fasterthanli.me/articles/a-half-hour-to-learn-rust
      (or my video made on this article)
      - github.com/rust-lang/rustlings
      and the book.
      Come ask in #newbie-advice on my discord server, there's a thousand lovely people who can help! (me too!)

  • @SeresHotes25
    @SeresHotes25 2 ปีที่แล้ว +3

    Your channel is just a giant Rust advertising. And it's working freaking well!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      This is intentional.
      I've noticed a lack of clear, well-explained introductory videos to Rust topics. There's loads of people making really great technical tutorials, but not stuff to get EXCITED about.
      I crashed out of writing Rust TWICE in 2020, and I only came back because I had a mentor to help me. Most people don't have this luxury.
      Rust has a BRUTAL learning curve, compared to other popular languages (though not as bad as Haskell et al), and so you need to know ALL of the great features that you simply can't get elsewhere, in order to push yourself through the initial learning period.
      Have you tried Rust? Thanks for your comment!

    • @SeresHotes25
      @SeresHotes25 2 ปีที่แล้ว +2

      @@NoBoilerplate I actually started learning because of you. Moreover, I watch your videos sometimes when I lose my motivation. It really helps! :3

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@SeresHotes25 I'm so pleased, thank you 🙂

    • @mwanikimwaniki6801
      @mwanikimwaniki6801 ปีที่แล้ว

      ​@@SeresHotes25 And imma start because of this guy

  • @fra4897
    @fra4897 2 ปีที่แล้ว +2

    I just want to say, I love your content man. Cheers from Switzerland

  • @ex0ja
    @ex0ja ปีที่แล้ว +1

    What do you actually use rust for yourself, do you use it for work? Hobbies? What kinds of projects do you work on?

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      I built critical national infrastructure in it while working at the Government Digital Service, here in the UK, in 2020, that was my first taste. The experience was really profound for me: the whole first day nothing was compiling, and I thought the language was insane, but at 4pm we got it compiling and then no further changes were required and it's currently sitting in production, receiving dependabot security updates, code passing tests in CI and building with no changes.
      I genuinely think it could run for ever, this language is so focussed on uncompromising rock-solid backwards and forward compatibility.
      This commenter said it better than I ever could: th-cam.com/video/ZFDqh3slQfU/w-d-xo.html

  • @kelvinpraises
    @kelvinpraises 2 ปีที่แล้ว +1

    Can someone please explain what the (c) (v) (i) before each language mean in the table at 1:20 sure looks like roman numerals but without context.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Oh good spot. My guess is Compiled, Interpreted, and ... something else. Check my markdown sourcecode for the link to the paper!

    • @kelvinpraises
      @kelvinpraises 2 ปีที่แล้ว +1

      ​@@NoBoilerplate Thanks! I couldn't find a free version of the paper to check the reference so I did the next sensible thing-pasted each language and a trailing v into Google search and they ended up having virtual machines in common. Java should have been a dead giveaway😄

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@kelvinpraises Genius!

  • @J0R1AN
    @J0R1AN 2 ปีที่แล้ว +1

    Thanks for motivating me to keep learning rust :)

  • @drsensor
    @drsensor 2 ปีที่แล้ว +1

    Looking forward for "When not to use Rust". Currently I'm curating some references about when Rust become problematic for my study and amusements because making technical decision is hard and sometime biased.
    (keyword: Rust is not Panacea)

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      I won't be making that video. However I can get you started: The biggest domain where you shouldn't use rust is where a large runtime is an asset, not a liability. Data science is a huge field where this is true. Julia is a really exciting language for these applications!

  • @dr-maybe
    @dr-maybe 2 ปีที่แล้ว +3

    I’m already convinced that rust is amazing, and use it for pretty much all of my new projects. Still I really like these videos, as they help me articulate why I actually like rust as much. Great content!

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +3

      My goal is to get as many people excited about rust as possible, and while they're learning, to stay excited 😊

  • @landonmackey1091
    @landonmackey1091 2 ปีที่แล้ว +1

    #1 reason why I want to learn Rust:
    Not because of any of the great things you’ve talked about on this channel.
    But because since macros are denoted by a !, the macro to terminate the program because of a detected bug is *panic!*

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      I wonder if there is a calm! crate...

  • @bruhe_moment
    @bruhe_moment 2 ปีที่แล้ว +4

    This channel is the reason I finally decided to learn Rust. Since then, every new project I have language choice over has been in Rust and I could not be happier!
    Coming from primarily Python, I tend to echo your statement that the language's simplicity causes more problems than solutions at scale

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +2

      And the less we talk about the GIL the better!

  • @johnwick2018
    @johnwick2018 2 ปีที่แล้ว +1

    I don't know rust.
    I don't write rust.
    I don't plan to learn rust in the near future.(maybe i would learn when i get some free time)
    All i have is small experience with python.
    But your videos are therapeutic to watch.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Thank you so much! I hope to inspire people to try it out!
      If you like my style of video, perhaps you'd like Lost Terminal: th-cam.com/video/p3bDE9kszMc/w-d-xo.html

  • @PetrSUsername
    @PetrSUsername ปีที่แล้ว +1

    07:56 I kind of miss the proposed example in rust about lifetimes. Would make it easier to understand what you mean and what it would look like to better compare. Thanks.

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      Come ask that on my discord server in #newbie-advice !
      My advice for learning Rust is here: th-cam.com/video/2hXNd6x9sZs/w-d-xo.html

  • @JBBell
    @JBBell 2 ปีที่แล้ว +2

    Great stuff. Keeps this cranky old Python programmer motivated to continue learning Rust and to use it. There's something especially optimistic and soothing about the delivery, too.🙂

    • @herrpez
      @herrpez 2 ปีที่แล้ว +2

      Just don't buy into the "70x more efficient" part from right at the beginning. It's perhaps 70x faster to run, but what are Python scripts generally for? The language not meant for heavy lifting, so those comparisons are unfair, so to speak, unless you do come across a Python script that ends up crunching numbers at max speed for minutes (or higher) on end.
      But yes, do learn Rust! It's a great language. Just don't forget about scope and scale.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      "python scripts" is not what we call the second most popular language in the world. Despite what you or I think about Python's applicability, people are using it for EVERYTHING!
      Also 70x slower than C speed, is Python's pure cpu single-threaded benchmark. It utterly crumbles in multithreaded benchmarks due to the GIL.
      Yes speed doesn't really matter. But when it's HUNDREDS of times slower, it starts to matter.
      As I said in the video, unit tests are 100% cpu with no waiting for IO, so it's especially noticeable there.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Thank you so much! Perhaps you'd like my delivery of Lost Terminal too? th-cam.com/video/p3bDE9kszMc/w-d-xo.html

    • @herrpez
      @herrpez 2 ปีที่แล้ว +2

      @@NoBoilerplate No, python scripts are what you create with Python. And if you want more performance with similar ease, Nim is a fine alternative. If you want actual performance you go for a more suitable language.
      I don't think we'd disagree on this.
      I write Python for things where bash doesn't cut it, but still in the same domain as bash scripts. Beyond that, other languages are far more suitable.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      @@herrpez I am aware of nim, I am a maintainer of inim, the most popular repl th-cam.com/video/Qa_9vut4TzQ/w-d-xo.html
      Please understand most people don't use python in the way you do. It's not the second most popular language in the world because people write scripts "where bash doesn't cut it".

  • @1337cookie
    @1337cookie 2 ปีที่แล้ว +1

    When you said there is nothing to stop you oxidizing your entire stack I realized why its called Rust; It's inevitable...

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      Oooh! that's a good one.
      I heard recently that 'rust is close to the metal'

  • @edems131
    @edems131 ปีที่แล้ว +2

    Nice video, i hope now I can finally convince my boss to use Rust in the next project after i will force him watch this video :D

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว

      This is EXACTLY why I made this video! I have a few others that are also very boss-compatible too, check them out!

    • @edems131
      @edems131 ปีที่แล้ว

      @@NoBoilerplate Nice :D, good job!!!

    • @edems131
      @edems131 ปีที่แล้ว +1

      ​​​@@NoBoilerplate it would be nice if you made playlist called something like "For boss" where in right order all reletad videos would be to convince him :D

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว

      @@edems131 DONE th-cam.com/video/4dvf6kM70qM/w-d-xo.html

    • @edems131
      @edems131 ปีที่แล้ว

      @@NoBoilerplate :D awesome

  • @danyldavidiuk9507
    @danyldavidiuk9507 2 ปีที่แล้ว +1

    with your videos i feel myself as some rust aristocrat... thank you for video

  • @OJeyjunior
    @OJeyjunior ปีที่แล้ว +1

    "what does a developer do?" -- made me waste 5 minutes wondring... found out 90% of my mental stamina goes to waste into dealing with the anxiety of not knowing what I don't know yet but will get me stuck mid project. For I quite enjoy thinking about the problem and the route I will approach it, but I cringe to the thought of everything crashing in front of me

    • @NoBoilerplate
      @NoBoilerplate  ปีที่แล้ว +1

      Developers are paid to think, managers are paid to worry.

  • @StefanH
    @StefanH 4 หลายเดือนก่อน

    "You can always trust the compiler" he says totally not paid by big compiler. Remember to live in fear everybody!!

    • @NoBoilerplate
      @NoBoilerplate  3 หลายเดือนก่อน

      I *wish* I was getting that big compiler money (mozilla call me! 🤙)

  • @CODEDSTUDIO
    @CODEDSTUDIO 2 ปีที่แล้ว +3

    Great videos always

  • @TheRandalf90
    @TheRandalf90 2 ปีที่แล้ว

    Why isn't it considered a safe operation to pass an object to a function provided that that function gives an object of the same type back (do not destroy the object)?

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว +1

      I'm not sure what you mean, please provide an example?

  • @marcusrehn6915
    @marcusrehn6915 2 ปีที่แล้ว +1

    I guess the only place it wont be efficient would be in CI/CD pipelines. If compilation is required 😅
    I know it's probably not the most important aspect. I just found it funny.

    • @NoBoilerplate
      @NoBoilerplate  2 ปีที่แล้ว

      Yeah, that's a problem we experience with docker images too - in an idea world, it's compiled once and the compiled artifact is moved through CI.
      On dynamic languages, the codebase is the artifact.

  • @clicker9534
    @clicker9534 ปีที่แล้ว +1

    "Our web frontend could be written in you" - 12:20

  • @chillydill4703
    @chillydill4703 2 ปีที่แล้ว +1

    I like that JS is not even on the Mb list.

  • @lectromoe
    @lectromoe 2 ปีที่แล้ว +1

    great video, as always!