**beep ** bop.

  • 1 Post
  • 20 Comments
Joined 2 years ago
cake
Cake day: July 1st, 2023

help-circle
  • the issues related to that macro still exist, but the author seemed to call it out and link to an article about it (which doesn’t seem disingenuous at all to me).

    That’s fair, I stand corrected and I overreacted a bit.

    I stumbled on the unintended cancellation a few times, but I’m used to select! paradigm from the other languages (and not used to how differently it behaves). I suppose I just expect the examples of its usage to be explicit and actually show what it takes to make select! behave in a way that doesn’t abruptly drop your async function after only going though half of it.


  • What I find slightly dishonest is bits like

    This way of using select in a loop could potentially cause issues regarding cancellation of futures (although in this case it’s fine)

    The select example is pretty straightforward and comparable to such in other languages, even to Go’s switching on channels. But rust hides an extra bit of complexity with the cancellation concerns that people don’t want to talk about unless absolutely necessary, and it is necessary in so many cases!



  • I don’t think your question relates to the language as much as to the platform. The language of choice is somewhat irrelevant and what you care about is what actually happens under the hood.

    For the likes of java and go you want to have some understanding of what runtime does for the memory allocations and how their GCs work. For python you sometimes end up in the spots where you need to understand what limitations the GIL imposes (even more important now that they are trying to get rid of it). When you run C (or C++ or Rust) on the embedded hardware it really helps to understand what exactly bit flipping does in specific registers and what DMA means for how you write your code.

    You don’t really have to know it all. You can absolutely write code without caring about anything of that and I know plenty software engineers that do. Some people write amazing functional things in java without ever questioning what it does to the machines and what resources you need to run it.

    If you start questioning it, that will only expand your understanding. It’s not a lateral move from e.g. C to Rust where you need to learn a lot to write your code in a memory-safe way, it’s a movement deeper into the stack and what you learn there will be applicable to any language you use for this stack.

    Answering your question: I always feel bad about not understanding some low-level concept. I have stacks of MCU reference docs lying around, printed, highlighted; I have archives with sample code, and hand-annotated CMSIS reversing notes. Embedded world is hard because you can’t just know C and be done with it. You have to know the hardware, too.

    Here’s my advice for you. Make notes of things that you learn from people smarter than you. Create a web of those notes and see where your gaps are. Then, work on learning something in those gaps in particular and see if you can make a blog post or something of your own. When you share what you learn you become one of those people with deep understanding that others look up to. There’s always someone struggling with something that you either know or know how to figure it out.

















  • I’m the same and I studied every nook and cranny during my first playthrough because FOMO was real. Guess what, I still missed enough things to make a second run no less entertaining―especially if you play a polar opposite of your original character. This game accommodates to pretty much every stupid decision you can throw at it and it’s amazing.