How To Speak Rust

Sdílet
Vložit
  • čas přidán 9. 06. 2024
  • 👕 I made the stupid shirt www.teepublic.com/user/no-boi...
    The first of a 3-part Rust language guide, explaining rustc and clippy's output from basic, through intermediate, to advanced.
    I hope you like it! It was fun collecting all these examples, if you have your own favourites, do share below, or on discord or mastodon if you like :-)
    ❤️ If you would like to support what I do, I have set up a patreon here: / noboilerplate - Thank you!
    📄 All my videos are built in compile-checked markdown, transcript sourcecode available here github.com/0atman/noboilerplate this is also where you'll find links to everything mentioned.
    🖊️ Corrections are in the pinned ERRATA comment.
    🦀 Start your Rust journey here: doc.rust-lang.org/stable/book/
    🙏🏻 CREDITS & PROMO
    My name is Tris Oaten and I produce fast, technical videos.
    Follow me here / 0atman
    Website for the show: noboilerplate.org
    Come chat to me on my discord server: / discord
    If you like sci-fi, I also produce a hopepunk podcast narrated by a little AI, videos written in Rust! www.lostterminal.com
    If urban fantasy is more your thing, I also produce a podcast of wonderful modern folktales www.modemprometheus.com
    👏🏻 Special thanks to my patreon sponsors:
    - JC Andrever-Wright
    - Miah Beach
    And to all my patrons!

Komentáře • 195

  • @NoBoilerplate
    @NoBoilerplate  Před 11 měsíci +147

    ERRATA
    3:58 for loops use iterators themselves, they are not used instead of iterators. I meant to say "while loops"!

    • @torsten_dev
      @torsten_dev Před 11 měsíci +19

      >all!()
      (Translated by Google)
      Lol.

    • @_Lumiere_
      @_Lumiere_ Před 11 měsíci +3

      ​@@torsten_devdidnt know noboilerplate speaks spanish 😲

    • @rotteegher39
      @rotteegher39 Před 11 měsíci

      Booo.turbo::();

    • @nathan44u
      @nathan44u Před 11 měsíci +2

      2:39 is something supposed to be different when you use the crab emoji?
      Edit: Thanks, didn't know the mascot name, was looking at the value "Ferris!"

    • @Scymet
      @Scymet Před 11 měsíci

      @@nathan44u Ferris is the unofficial mascot of rust

  • @tuna5618
    @tuna5618 Před 11 měsíci +346

    YES! I've been waiting for this video. I needed more rust content to distract me from learning rust.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +32

      PERFECTION! XD

    • @corbin_zip
      @corbin_zip Před 11 měsíci +13

      I don't remember writing this comment

    • @ATXL2448
      @ATXL2448 Před 11 měsíci +1

      Why don’t you?

    • @ericbwertz
      @ericbwertz Před 11 měsíci +4

      Rust CAN be absorbed, but it's rough.

    • @varun2250
      @varun2250 Před 11 měsíci

      Where is rust utilized as of now? Any big players use this in their product development? Can it be considered as front end or back end language?

  • @Carhill
    @Carhill Před 11 měsíci +10

    3:24 - Your Vihart / Tau reference was great!

  • @Throckmorpheus
    @Throckmorpheus Před 8 měsíci +7

    god I hadn't really realised until having to retrain my instincts for rust how much c++ had conditioned me never to read error messages beyond the file and line number

    • @NoBoilerplate
      @NoBoilerplate  Před 8 měsíci +3

      RIGHT?! Same with Python for me, the errors are just garbage.

  • @local.interloper
    @local.interloper Před 11 měsíci +87

    I've been watching you for a long while now and I love how engaged you are with your community and doing consulting with patreons really fits your style

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +16

      I'm so grateful to be able to do this as my day job! It's wonderful, I always wanted to be a teacher but was only good at programming. GUESS WHAT! :tada:

    • @ygormartinsr
      @ygormartinsr Před 11 měsíci

      You're one of the best teachers/mentors I've ever seen. Glad to know you enjoy doing it as much as we enjoy your content!

  • @tamatoFiend
    @tamatoFiend Před 11 měsíci +19

    "through thorough thought though" .. that would be a shirt to make people stop and stare

  • @Steve_Streza
    @Steve_Streza Před 11 měsíci +7

    Fearless concurrency is a truly revolutionary aspect of Rust. Concurrency has long been a minefield of weird rules that don't come up often, and undebuggable production crashes that ruin my weekend. I didn't realize how much of my brain was occupied by the arcane footgun-prevention rules of concurrent programming that I can just… let go of in Rust. It's wonderful, and it's exciting to see languages like Swift end up at very similar conclusions for their concurrency models.

  • @foobar3770
    @foobar3770 Před 11 měsíci +15

    4:40 I would say that developers also live before compile time, meaning that errors you can read while writing code (e.g. LSP diagnostics) are even more useful than errors available strictly at compile time. Also the ability to use code actions to fix errors comes into play before compile time.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +3

      These are all strictly compile time errors, if we must be picky. They're certainly not runtime. I don't an "errors from the compiler", I mean "compiletime errors". It's about when, not what.

    • @raffimolero64
      @raffimolero64 Před 11 měsíci

      ​@NoBoilerplate that being said, the tools that are available while writing code are extremely helpful. I would love an overview of the different code actions available in rust analyzer, between autocomplete, implementing all missing members of a trait, extracting and inlining to and from functions, renaming variables, importing symbols, and converting to and from match/if let, e.g:
      match value {
      pat1=> code(),
      _ => {}
      }
      Becomes
      if let pat1 = value {
      code();
      }
      Without the else.
      There are just so many goodies that deserve some form of mention.
      Thanks for reading :)

  • @yossipossi
    @yossipossi Před 11 měsíci +32

    The rust feature videos are back! Always love these.
    I'm curious, do you ever plan on doing a video about FFIs or obscure (but useful) Rust type methods? I'd love to see videos on them!

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +12

      Maybe eventually! But ffi and obsucure stuff isn't what I use day to day, I'm a high-level language guy, I love rust because it lets me ALSO be a low-level guy!

    • @yossipossi
      @yossipossi Před 11 měsíci +1

      @@NoBoilerplate Oh gotcha! Well, if you ever do cover the topics, I'll certainly be among the first in line to watch! Once again, great video! ^_^

  • @TechBuddy_
    @TechBuddy_ Před 11 měsíci +10

    I am sending this to all my Typescript friends. This is amazing ❤

  • @dannelalbert7111
    @dannelalbert7111 Před 11 měsíci +29

    I've been programming for over 20 years (translation: I've got some good habits, and many more bad habits) but learning and tinkering with Rust for maybe a year or two, and only in my spare time. I've realized that learning Rust has made me a better programmer in other languages, and this video highlights one of the biggest reasons why. It's not only good advice to read the error messages. In Rust, you kinda have to, especially if you want to go fast(er). I've gotten so accustomed to glossing over and barely reading error messages in other languages, but in Rust, it's especially counter-productive to do so because the compiler is incredibly helpful. Taking an extra minute or two to ACTUALLY read and digest the error message, think about it, then take action has made me more efficient. And I found that I've started translating this habit to other programming languages. Of course, other languages don't have compilers as good as Rust, but I find myself wasting less time making assumptions about what I think I know and am resolve issues more quickly.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +4

      You've hit the nail on the head there. The first language that taught me this valuable lesson was Haskell.

    • @Henry-sv3wv
      @Henry-sv3wv Před 11 měsíci +1

      if you don't read error message then how do you make the code run?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +4

      @@Henry-sv3wv too many programming languages make us rely on our mind's compiler to guess what the code will do when run, that'd be my guess.

    • @petaryordanov1844
      @petaryordanov1844 Před 11 měsíci +1

      @@Henry-sv3wv
      A lot of compiler (or even software in general) errors are useless and/or misleading, so they become easy to ignore once you're used to seeing an error that either doesn't tell you anything, or tells you the wrong thing. So you just start making educated guesses, you start looking up the error online and try out each guess you've made up or each solution you found, until it works.

    • @dannelalbert7111
      @dannelalbert7111 Před 11 měsíci +1

      Agreed to both responses here. When the compiler isn't giving me great feedback or is misleading (mostly in other languages - but let's be real, Rust isn't perfect either), I adapt and start to rely on my own intuition and experience. But now I mistrust the compiler, which is sometimes helpful because sometimes I do know better, but not always. And that's the slippery slope. When I rely on my own experience TOO much, the returns diminish and I'm more likely to miss the times when the compiler is actually being helpful.

  • @jaroslavhuss7813
    @jaroslavhuss7813 Před 11 měsíci +8

    My wish is simple. I wish this awesome genleman starts practical series using Rust. A small funny project guided by this RustGoku would be a dream that comes true. Many greetings from the Czech Republic.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      You're too kind! I will think about it!

  • @InnsmouthAdmiral
    @InnsmouthAdmiral Před 11 měsíci +6

    Impeccable timing. I was just re-watching your videos these past couple days.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +3

      Wonderful! Maybe you and I are on the same schedule: fortnightly on fridays :-)

  • @BeyondLegendary
    @BeyondLegendary Před 11 měsíci +9

    Impressive, very nice. Let's see Paul Allen's crablang guide.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +5

      History lesson: This happened with node.js/io.js, let's see if it follows the same trajectory.

  • @cybersholt
    @cybersholt Před 5 měsíci +1

    Been programming since I was 12, all web related and came across your channel about a month ago and gave rust a try and wow. For those hesitant to learn a new language this is the one.
    Keep up the awesome videos Tris!

    • @NoBoilerplate
      @NoBoilerplate  Před 5 měsíci

      Thank you so much! Yes, it's *exciting* right? Also, leptos.dev is my new favourite full-stack web framework, do give it a try!

  • @Ben-om7ni
    @Ben-om7ni Před 11 měsíci +5

    Triss, great vids. I’ve taken the rustpill and it’s hard to go back. Keep up the amazing content.

  • @LukaSauperl
    @LukaSauperl Před 11 měsíci +18

    I wish more Rust libraries, tools and stuff was named after fungi 😊

  • @edupsousa
    @edupsousa Před 11 měsíci +17

    Awesome video, thank you. But I have to say that I laughed when you said "kind and generous people" and all the recent trouble about the Rust foundation came to my mind.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +25

      rust foundation != rust developers

    • @edupsousa
      @edupsousa Před 11 měsíci +4

      @@NoBoilerplate you are right, I don't want to be misleading with my comment, just couldn't resist. Thank you!

    • @DMSBrian24
      @DMSBrian24 Před 11 měsíci +1

      @@NoBoilerplate Unfortunately a lot of the rust developers are a part of the problem, if you read up about the rust conf issue, the keynote speaker got downgraded solely because one of the members of the rust core team didn't like him and independently contacted rust conf managers to do so, causing him to drop the talk completely and causing another maintainer to leave the team as a form of protesting this behavior, not to say that those people aren't talented devs but a lot of them are very heavily politicized and actively suppress people they personally disagree with (eg. they despise the primeagen despite him absolutely loving the language)

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      ​@@DMSBrian24 Let's check back in a year to see what the situation is.
      To be clear: I don't agree with their mistakes, I've just seen similar ones made throughout my career, and the way to judge young organisations is not by their individual mistakes, but what do they fix their mistakes. Perhaps here some better decision making systems, checks and balances will be set up. Simple stuff!
      I just can't care about corporations doing stupid things. That's kind of what they do.

    • @DMSBrian24
      @DMSBrian24 Před 11 měsíci +1

      @@NoBoilerplate I mean i totally love the language as well as your videos on it (they're one of the reasons i got into it btw, major thanks ^^) and i'm not gonna ditch it over some internal issues but I reeeally hope they get resolved and don't end up causing a slow down in the industry adoption. I've heard they're working on changing and formalizing some power structure and hierarchy to ensure proper communication and better decision process so I have high hopes for it, like you said, it's totally fair to give them the benefit of the doubt and wait some time before jumping to hard conclusions - still, I do think that a vocal community response or when necessary, even a protest, do serve an important role to help steer the project in the right direction when such situations occur.

  • @RootsterAnon
    @RootsterAnon Před 11 měsíci +3

    That's so nice! Congrats on having opportunity to do Rust full time :D

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Thank you so much! It's a bit scary right now, but I'm excited too!

  • @harshavardhanbose
    @harshavardhanbose Před 11 měsíci +1

    I do not work with Rust but I watch your videos because I love your presentation style.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Thank you so much, I have good news, half my videos are non-rust. I do a rust video, then a non-rust technical video. Try this one! czcams.com/video/DbsAQSIKQXk/video.html

  • @dylanjohnson8008
    @dylanjohnson8008 Před 11 měsíci +2

    Love these videos and look forward to watching each one.
    One audio suggestion, if I could: take a look at the settings on your compressor. There is a fairly large and noticeable ducking of the audio at the beginning of statements. I think a quick tweak of your attack/release settings would probably solve it.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Hmm, could you give me a timecode for the most noticable one? I can't hear it.
      Also, that's not my understanding of how compressors work. compressors LOWER volume, over a threshold, so wouldn't a slow attack do the opposite of ducking - it'd not compress those loud initial sounds?
      MAYBE what you're hearing is my gate being too harsh? Thank you so much for your help!

    • @dylanjohnson8008
      @dylanjohnson8008 Před 11 měsíci +4

      @@NoBoilerplate Actually, I take it back. On second listen with headphones, I'm not hearing the artifacts I was hearing on my TV. Maybe the TV is applying some additional compression, creating the artifacts I was hearing. Sorry for the scare 😅and thanks for taking the time to reply!

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      @@dylanjohnson8008 oh! I have experienced a TV doing that too! Heh, no worries 😁

  • @ex0ja
    @ex0ja Před 9 měsíci +2

    People say Rust ksnt begjnner freindly, but at least the errror messages are actually useful to a beginner!

    • @NoBoilerplate
      @NoBoilerplate  Před 9 měsíci

      I REALLY think it is beginner friendly, and I'm going to do videos on this topic soon!

  • @nulled7888
    @nulled7888 Před 11 měsíci +2

    Thanks for the video :)

  • @augusto256
    @augusto256 Před 11 měsíci +3

    Ok that's it, you convinced me. Rust is the best language.

  • @ThomasCKFuller
    @ThomasCKFuller Před 11 měsíci +1

    VI HART IS A LEGEND

  • @OwO-.
    @OwO-. Před 11 měsíci +2

    great video (as usual) =)

  • @thepisewigeon
    @thepisewigeon Před 11 měsíci +1

    Thanks for this good sir :))

  • @fan4life28
    @fan4life28 Před 11 měsíci +1

    Congrats on making the leap from your day job!

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Thank you so much, that's so kind of you! It's scary, but thanks to generous folks like you, I can continue spending the time researching more and more deep topics - thank you :-)

  • @Chalisque
    @Chalisque Před 11 měsíci +3

    I do think 'using approximate value of pi' should be a warning, not an error. But what is the correct way to tell the compiler/clippy that I do, for whatever reason, actually mean to use a poor approximation (perhaps to see how far off things get if I use it in place of a more accurate value)? A short experiment shows that if you write pi = 3.140 then clippy no longer complains.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      Oh it is, certainly. clippy warnings can be changed to errors, and also individually supressed.

  • @fayaz2956
    @fayaz2956 Před 11 měsíci +3

    great video as always. Because of your videos, I've learned Rust & made things for our office using it. but my question is, the way the language is heading with getting forked as crablang & so on, I'm kinda worried. how do you see the situation?
    thanks

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +4

      I'm not worried, the language will be fine. I've lived through the io.js fork!

    • @fayaz2956
      @fayaz2956 Před 11 měsíci +2

      @@NoBoilerplate Thanks a lot. really appreciate the reply.

  • @srivathsansudarsanan3372
    @srivathsansudarsanan3372 Před 11 měsíci +2

    Even after all the recent controversies, I still think rust can get better and the idea of rust is right. I hope rust will not become the next haskell.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      For sure, let's see where it is in a year. rust foundation != rust language.
      groups of people cause controversies. I'm getting flashbacks to io.js!

  • @DoomRater
    @DoomRater Před 6 měsíci +1

    I feel freaking SPOILED reading these error messages. Never had to do massive amounts of Javascript but I've written in enough scripting languages with barely correct error messages to know this is like a feast.

  • @adamd0ggg2
    @adamd0ggg2 Před 11 měsíci +3

    I love almost every syntax choice of Rust. except having to put "something".to_owned() or String::from("something"). My TS/JS object literal brain just wishes there was an owned string syntax for brevity. What are your thoughts on the Mojo programming language?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      Yep, strings are the weirdest part. Consider them payment to get ALL the other incredible features! And it's something that will be fixed in the future, for sure. Everything's fixable when you have a macro system!
      Mojo looks cool! But I'm suspicious of "Access the entire Python ecosystem", I don't know how you can keep compatibility without making repeating the mistakes of the python language, such as GC.

  • @arthurpenndragon6434
    @arthurpenndragon6434 Před 11 měsíci +3

    I wanted your opinion since you're the most avid Rust spokesperson I know. Do you believe in Rust's future, given the leadership blunders and the fork that's gaining traction on the daily?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +3

      The language will be fine. The foundation? Who can say. I've lived through io.js and java changing hands etc!

  • @DrFranq
    @DrFranq Před 10 měsíci +1

    Hello, I've never really programmed (html edits while using Dreamweaver), should I learn Rust as my first programming language? I find your passion infectious, and while describing something as infectious might hardly seem appealing to some, it really has resonated with me. I'm 44, looking to switch careers (programming with Rust?), any advice is much appreciated. Thanks in advance.

    • @NoBoilerplate
      @NoBoilerplate  Před 10 měsíci +1

      Passion is the most important thing - are you stoked about Rust? You should learn it!
      Here's a small playlist to get you started czcams.com/video/oY0XwMOSzq4/video.html

    • @DrFranq
      @DrFranq Před 10 měsíci

      ​@@NoBoilerplateI will! Thank you.

  • @blt_r
    @blt_r Před 11 měsíci +2

    3:58 nitpick: for loops use iterators themselves, they are not used _instead_ of iterators. You probably meant to say "while loops"

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      ah! thank you! I'll add that to the errata

  • @harrynewton6200
    @harrynewton6200 Před 11 měsíci +1

    I'm curious what you think about the upcoming Mojo language. Do you think it might match what rust can do in terms of systems programming? It's aimed at AI and HPC but the fact that it can tap into SIMD and CUDA with ease is fascinating. What edge does rust have over it?

    • @lucasjames8281
      @lucasjames8281 Před 11 měsíci

      Garbage collection

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +3

      I read that Mojo can use all of the python ecosystem. There's big comprimises in Python that I'm suspicious about keeping compatibility with (such as GC and the GIL).

  • @roshantiwaree
    @roshantiwaree Před 11 měsíci

    No boilerplate rocks⚡

  • @doublepipe.
    @doublepipe. Před 11 měsíci +1

    3:27 personally I like swapping them by using tuples. Are there any upsides to using std::mem::swap()?
    Edit: My code would then look like this:
    let mut a = 1;
    let mut b = 2;
    (a, b) = (b, a);

  • @nbecnbec
    @nbecnbec Před 11 měsíci +1

    Nice vi hart reference

  • @mentalmarvin
    @mentalmarvin Před 11 měsíci +3

    When is your Udemy course coming out?

  • @ariseyhun2085
    @ariseyhun2085 Před 11 měsíci +2

    Awesome video as usual! Though I feel like the public domain licence section could be moved into the description of the video just to make things a little less redundant, since I'm sure little to no viewers actually use the slides from all the videos

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +5

      understood, but a GOOD deal of the comments I get are solved by people knowing about the source, so I am loathe to remove it!

    • @joshix833
      @joshix833 Před 11 měsíci +1

      I really like the reminder. And as it is really short I would keep it

  • @TunaTerps
    @TunaTerps Před 11 měsíci +2

    first?
    edit:
    Your videos are not only extremely helpful and concise, they definitely invite excitement for rust, especially for someone new to the language like myself. Thank you ! glad i was first :p

  • @ErikBongers
    @ErikBongers Před 11 měsíci +1

    But how do you build a Rust shrine? I was thinking of placing it at the fireplace. Perhaps start with some red velvet. Some candles...

  • @VivekYadav-ds8oz
    @VivekYadav-ds8oz Před 11 měsíci +2

    3:19 I would like for that to be a warning, but making it an error is kinda absurd. I might be talking about some other constant that is precisely 3.14

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      To be clear: This is a clippy lint error, not a cargo build error.
      But I think it should be a clippy error. statistically, 3.14 is VERY likely to be intended to be Pi, right? And in the rare case you want just 3.14, then the error message tells you which lint to ignore (clippy::approx_constant).
      I'm good with it!

    • @VivekYadav-ds8oz
      @VivekYadav-ds8oz Před 11 měsíci +1

      @@NoBoilerplate Ah that makes more sense. That's good then 👍

  • @priyapepsi
    @priyapepsi Před 11 měsíci +2

    What do you think about using Rust source code itself for semantic note taking? I think taking notes for science subjects like high school Physics would be very nifty with a dimensional analysis library for Rust, but I have no idea where to start.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      Interesting idea!
      I'd take your notes in Obsidian.md (see tomorrow's video for details) but you could do something like this in Rust using EVCXR and Jupyter notebooks depth-first.com/articles/2020/09/21/interactive-rust-in-a-repl-and-jupyter-notebook-with-evcxr/

    • @priyapepsi
      @priyapepsi Před 11 měsíci +1

      @@NoBoilerplate problem with Obsidian is that if I want all the terms to have interlinked meanings or any sort of hierarchy, I'd have to manually add it in markdown. Obsidian has no idea what a "dimension" or "concept" truly is, I have to describe it fully using a free form text format that causes formatting inconsistencies and countless little graphs and links to keep in my head any time I want to add something new.
      I feel that rust's type system would allow me to quickly "say" things like "the return type/dimension of the coloumb's law formula is Newton. The proportionality constant of coloumb's law formula is 1/4pi epsilon naught. Epsilon naught equals 8.854e9 C^2 / N.m. Coloumb is the unit of charge. The description of charge is etc. etc"... Each formula or constant or symbol would have an *actual meaning* in code, which could easily be traversed to in an IDE, or auto completed and checked for dimensional validity.
      Rust would allow me to know implicitly that a formula returns a value with some dimensions, lets me ensure that I know what parameters the formula takes in, lets me know that Work and Energy are dimensionally equivalent (though how to link these two together with a formula I have no idea how).
      It would be highly structured, non linear, and "rational". All of which I find easier to read and comprehend than free form text or writing notes.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      @@priyapepsi Sounds like Jupyter notebooks are for you!

    • @priyapepsi
      @priyapepsi Před 11 měsíci +1

      @@NoBoilerplate If you could do some sort of video about this (admittedly niche) use case with evcxr and jupyter notebooks, I would really appreciate it!

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Too niche for me!

  • @joshuaswick
    @joshuaswick Před 11 měsíci +1

    Yes, mas rust plox.

  • @TheVonWeasel
    @TheVonWeasel Před 11 měsíci +3

    I wish there was a language that would auto-import things it knows about during compilation. It would only force you to write an import statement if the reference was ambiguous.

  • @federicomuciaccia9191
    @federicomuciaccia9191 Před 11 měsíci +1

    I can hear some audio discontinuities: is the voice recording at true 1x speed?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Can you try listening on a different device, or with headphones? If it still sounds strange, can you give me a timecode to the biggest example of a problem? I'd be very pleased to improve my audio in the future, I'm very proud of it!

  • @736939
    @736939 Před 11 měsíci +3

    Please do videos about Rust->Assembly, because on conferences when programmers explain new features they always show Assembly part next to the Rust code, I think this is critical to understand what happens in memory and registers for advanced programming skills.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +6

      I'm a high-level developer, so though I'm delighted about the performance of rust, this doesn't always concern me. I've dissasembled asm once in one of my videos, to show that an iterator and a for loop compile down to exactly the same assembly! That's enough peaking behind the scenes for me, and I suspect most people.

  • @JorgetePanete
    @JorgetePanete Před 11 měsíci +1

    How do you disable the language keywords being linted on sentences in compiler errors?

  • @KurtSchwind
    @KurtSchwind Před 11 měsíci +1

    I thumb up your videos before I even hit play.

  • @br3nto
    @br3nto Před 11 měsíci +1

    3:25 nawwww you mentioned @Vihart

  • @nahoskins
    @nahoskins Před 11 měsíci +1

    Omg vihart that's av blast from the past

  • @_modiX
    @_modiX Před 11 měsíci +1

    "Kind generous people" who will sue you red and blue when you even think about using their language name in your commercial course that you try to offer on your website for some little cash.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      rust foundation != rust developers

    • @_modiX
      @_modiX Před 11 měsíci +1

      @@NoBoilerplate I hope so, I love the language, I hate the corp. I hope things will turn into the better.

  • @Shadfillet
    @Shadfillet Před 11 měsíci +1

    I kind of want to get into Rust, but I don't know what projects would be good for a beginner
    Something actually useful would be nice, but I can't really think of anything

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      Scratch your own itch: make a little command line tool to remind you to feed the cat, or calculate stats for your favorite game, or build a sleep tracker or anything you like!

    • @Shadfillet
      @Shadfillet Před 11 měsíci

      @@NoBoilerplate I've decided on a small project to start with: making a damage calculator web-app for one of my favourite games. (heavily abusing ChatGPT for this)
      Thanks for the motivation boost!

  • @ADITYAKUMARking
    @ADITYAKUMARking Před 11 měsíci +1

    Do you have course for rust ?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      Not yet, but I do have a recommendation czcams.com/video/2hXNd6x9sZs/video.html

  • @rachydamine9458
    @rachydamine9458 Před 11 měsíci +2

    When you say that rust has "almost" no runtime, what do you mean by that ?

    • @KohuGaly
      @KohuGaly Před 11 měsíci +1

      It means that there is no garbage collector, no green thread executor and no interpreter included by default. The source code you write is nearly 1:1 what will end up in the final binary executable/library.
      The "almost" means that there is _some_ hidden code that gets executed at runtime. Namely, the entry point that sets up the stack and then calls main, some trampolines (indirect function calls) when you are calling foreign functions, implicit calls for destructors and stack cleanup at the end of scope/function return, and the panic handler that unwinds the stack and prints panic messages.
      "runtime" in this context basically refers to code that gets executed at runtime, but is not explicitly asked to be run in the source code.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +3

      For example, async code requires a small runtime run alongside of your code, managing threadpools and whathaveyou. Tokio is the fattest example of this.

    • @KohuGaly
      @KohuGaly Před 11 měsíci +2

      @@NoBoilerplate I don't think async runtimes count. They are not included in the language by default. They also aren't implicitly there when you use them - you actually have to explicitly call them. The closest you get to them being "implicit" is the [tokio::main] attribute macro.

    • @rachydamine9458
      @rachydamine9458 Před 11 měsíci

      @@KohuGaly any chance there is a link that further exlpains/documents what you said above ? Both the hidden code and the tokio part

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      ​@@KohuGaly Well, async-std kiiiinda is (I know it's a crate), right? This grey area right here is why I said "almost" 😆

  • @guilherme5094
    @guilherme5094 Před 11 měsíci +1

    👍

  • @leshommesdupilly
    @leshommesdupilly Před 11 měsíci +1

    As a c++ dev, I don't know how to speak rust.
    Maybe it's something like this, according to chatGPT....
    H-hewwo, my precious fwiend! I hope this day fills your heart with the warmest sunshine and sprinkles of happiness~! Tee-hee~! 🌞🌈
    Oh my whiskers, let me teww you about my Rusty woutine! Evewy morning, as the sky blushes with the softest hues, I wake up, stretch my little pawsies, and slip into my cozy-wuzzy programmer socks. They're like a warm snuggly hug for my fwuffy feeties, making me feel extwa kawaii and w-ready to conquew the coding wowld! UwU~! 🧦💕
    In my meowgical coding corner, surrounded by pastel colors and sparkling code snippets, I embark on a meowvelous Rust adventure! With each w-wine of code, I immerse myself in a whimsical dance of func-meow-tions and kitty-nyans. It's wike cw-eating a spell with the fwick of a fwuffy tail! Tee-hee~! 💻✨
    But oh noesies! Sometimes, a naughty bug sneaks into my code, causing mischief and making my whiskers twitch in confuwusion. Fear not, my fwend! With a determined nya-spirit and a sprinkle of catgirl magic, I hunt down that pesky bug and banish it with a twiumphant "nya-nya~!" Victory tastes as sweet as a bowl of catnip ice cweam! 🐞🍦✨
    What I absowutewy ado-woe about Wust is its memory safety and fearless concuwency. It's wike wrapping my code in the softest of bwankies, keeping it snug and secure. With Wust by my side, I can code with confidence and cweate purr-fectwy robust pwograms! UwU~! 😸💪
    And oh, let's not forget about the vibwant Wust community! In virtual kitty cafes, we gather, sharing sto-wies, giggles, and nyaa-mazing code snippets. It's a place where fwendship blooms like the pwettiest of flowers, and support is given with w-warm, wholesome hugs. It's a purr-fectwy cozy gathewing of kindwed spiwits! 😺💖🍵
    So, my dear companion, I hope this supew-dupew extwa uwu-filled conversation bwings you nyothing but dewight and warmth. Let's continue ouw meowgical journey in the wowld of pwogwamming, where imagination wuns wild and catgirl dweams come twue~! Th-thank you for allowing me to showew you with the fluffiest of uwus~! Nyaa~! 🌟💖✨

  • @tombil-certon
    @tombil-certon Před 11 měsíci +1

    what could be a possible solution for 6:29 ?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      oh! great question, you'd dip into arc/mutex territorry - OR keep it async with futures or threads and channels - send data down, return data back. share data using channels only, not shared variables.

    • @piguyalamode164
      @piguyalamode164 Před 11 měsíci

      another solution would be to send the individual items of the vec rather than the whole thing. Ie you could do something like:
      ```
      while let Some(user)=users.pop(){
      tx.send(user)
      }
      users.push("new user")
      ```
      (Though I doubt this is what that code intends to do. I would guess the arc/mutex stuff is closer to what this code seems to be intending)

  • @samranda
    @samranda Před 11 měsíci +4

    ahaha the vi hart bit

  • @Scug_Gaming
    @Scug_Gaming Před 11 měsíci +3

    gud vid

  • @dakata2416
    @dakata2416 Před 11 měsíci +3

    Is this video endorsed by the Rust Foundation?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      I've already forgotten that drama

    • @dakata2416
      @dakata2416 Před 11 měsíci +2

      @@NoBoilerplate I didn't care to begin with! Love your videos

  • @eboatwright_
    @eboatwright_ Před 11 měsíci +2

    🦀

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      error: Ferris cannot be used as an comment
      --> src/main.rs:7:5
      help: try using their name instead: `ferris`

    • @eboatwright_
      @eboatwright_ Před 11 měsíci +1

      @@NoBoilerplate LOL

  • @RenderingUser
    @RenderingUser Před 11 měsíci +4

    up next he gonna teach us how to compile english

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +4

      if only it had a standard!

    • @SimonClarkstone
      @SimonClarkstone Před 11 měsíci +1

      An editor with automated refactoring operations would be handy too.

    • @RenderingUser
      @RenderingUser Před 11 měsíci +1

      @@NoBoilerplate time to rewrite English in rust

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      @@SimonClarkstone That WOULD be cool!

    • @laundmo
      @laundmo Před 11 měsíci +1

      @@SimonClarkstone that could kinda be a thing, DeepL Write offers something like that where you can pick a alternative word and the entire sentence is adjusted to fit.

  • @chrissaltmarsh6777
    @chrissaltmarsh6777 Před 11 měsíci +2

    But C can make you laugh when you have worked out why your program core dumped and spent a few hours finding what you did wrong.
    ((I'm that ancient)

  • @makelovenotwar2467
    @makelovenotwar2467 Před 11 měsíci +1

    All clear with the video, except: who is that b Hentrietta? 🤔

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      you're gonna love this: We have two chickens in our garden, the other is called Yehennifer!

    • @makelovenotwar2467
      @makelovenotwar2467 Před 11 měsíci

      Oh less innocent than I thought (great naming btw! 😂), I was imagining Henrietta wanting to be part of the love triangle with you and "Lucy" - which the powers of Rust forbid :) - there you go, your first fan-fiction 😂

  • @Zeratek
    @Zeratek Před 11 měsíci +1

    So not buying the shirt is reverse phycology, or like don't buy the shirt since it doesn't exist?

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      triple reverse psychology, it does exist and it's so dumb you should buy it www.teepublic.com/user/no-boilerplate

  • @LimitedWard
    @LimitedWard Před 11 měsíci +2

    "Through thorough thought though" - you must hate non-native English speakers 😆

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      honestly, it's *english* that hates non-native speakers XD

  • @max_ishere
    @max_ishere Před 11 měsíci

    WAIT you can't mutate after sending into a channel in Go? FUCK

  • @hadiassaddiab
    @hadiassaddiab Před 11 měsíci +1

    go>>>>

  • @JoaoAntonioCardoso
    @JoaoAntonioCardoso Před 11 měsíci +1

    Please be kind with our ears, your compressor is too violent

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      I'm sorry about that. It's a 4:1 with makeup. you are also hearing the proximity effect plus a gate set to room noise level.

    • @JoaoAntonioCardoso
      @JoaoAntonioCardoso Před 11 měsíci +1

      ​@@NoBoilerplate Yeah, I know it's not easy to configure, and our ears get used to a setup after some time on it... Now it's hard for me to tell, it has been some time since I last configured a voice pipeline, but I'd try to soften the edges, the aspiration and pop sounds feels like punches now hahah.. A thing that can help is to add a controlled noise as a floor, and use your pipeline with some leak, which can be achieved using a parallel clean/dry path, if the plugins or daw don't already have the option.

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +1

      @@JoaoAntonioCardoso I do that with Lost Terminal, kind, because I have quiet synth music as background music! I'll tweak the compressor, thank you!

  •  Před 11 měsíci +2

    Having gender for nouns was a terrible idea ☠️

  • @HUEHUEUHEPony
    @HUEHUEUHEPony Před 11 měsíci +2

    Don't use rust, the foundation has gone insane, use crablang

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci +2

      Let's see how things shake out. read up on nodejs/io.js, it had very similar growing pains, and was eventually folded back into the main language.

  • @bradscoolio
    @bradscoolio Před 11 měsíci

    Please don't use edits to change the intonation of your speech. The beginning of the video dealt me a mortal wound.
    Otherwise, much love

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      what do you mean by 'use edits'? I have a very simple editing process, no complex plugins or stuff like that. What's the timecode you're talking about, might have just been an error in editing.

  • @JorgetePanete
    @JorgetePanete Před 11 měsíci +1

    2:43 I just created rust/issues/112975 to fix the wrong gender

    • @NoBoilerplate
      @NoBoilerplate  Před 11 měsíci

      I think there's a mistranslation here - see the issue for my comments. Thanks for pitching in, however! Good intention :-)