livingcoder

joined 2 years ago
[–] livingcoder@lemmy.austinwadeheller.com 2 points 2 years ago* (last edited 2 years ago)

I generally avoid this situation. At best I'll create an Rc<HashMap<T, U>> to pass around. I find that having a need for a static variable can be an indication of bad design. It often makes the code that depends on it untestable.

[–] livingcoder@lemmy.austinwadeheller.com 4 points 2 years ago (3 children)

You may be able to use something like lazy_static.

https://docs.rs/lazy_static/latest/lazy_static/

[–] livingcoder@lemmy.austinwadeheller.com 1 points 2 years ago (1 children)

This is very interesting. Why is there a region highlighted (like a large circular paint brush) before the point manipulation occurs? It doesn't seem to restrict the changes in the image to only that region (ex: the dog ears change outside the region).

[–] livingcoder@lemmy.austinwadeheller.com 5 points 2 years ago* (last edited 2 years ago) (2 children)

This is awesome! Thank you!

I have a lot of interest in software development (and the Rust programming language specifically). Any plans to add a software development community? I don't know of any feeds, though.

[–] livingcoder@lemmy.austinwadeheller.com 2 points 2 years ago* (last edited 2 years ago)

My first programming language was QBasic, then Visual Basic, then Java, then C# (most experience with), then C++, then Python, and now Rust. Only when I learned C++ in college did I truly grasp the power of memory management. I think it's important for new programmers to have some understanding of and experience with pointers, but it doesn't need to be your first language. I think it's okay to start with Python or C#, but you'll want to go back and learn the hard stuff at some point (C++ and then Rust). Python will be super easy to learn the basics (data structures, algorithms, etc.). C# is also a good choice, but has you learning a few more things at the same time you're trying to learn the basics.

They share a genealogy, but as programs are created and maintained in different languages, developers come to wish for different syntaxes that would (1) reduce how much code must be written to accomplish a common logical task, (2) make the code that's written easier to read/understand, (3) reduce concerns about variable types until runtime, and/or (4) overly restrict not just the variable types but also if/when variables can be modified. This list is not exhaustive.

There is a partial programming language family tree here, showing which languages influenced other languages: https://www.researchgate.net/figure/Genealogy-of-Programming-Languages_fig36_260447599

[–] livingcoder@lemmy.austinwadeheller.com 2 points 2 years ago (1 children)

I don't miss the endless commercials.

Maybe that's what I should do. I've just recently moved back to VS Code from Neovim due to my constant issues with the LSP I was using. I would open a file, make some changes, and then return to the file tree along with a bunch of LSP warnings (as if the file tree was a file). LazyVim sounds like exactly what I want, if the name is accurate.

[–] livingcoder@lemmy.austinwadeheller.com 1 points 2 years ago (1 children)

I think I'm going to have to buy a wattage meter plug-in to see what my laptops run at with nothing running, a single Docker image of nginx, and then an API image on top of that. I wonder what my RaspberryPi 4 is pulling with my docker images running on there.

[–] livingcoder@lemmy.austinwadeheller.com 1 points 2 years ago* (last edited 2 years ago)

Thanks for sharing your solution. I also would have thought that you could auto-redirect within the nginx config from "www" to the root domain, no? Idk if that would have any impact on the SSL functionality.

[–] livingcoder@lemmy.austinwadeheller.com 3 points 2 years ago* (last edited 2 years ago)

"Buying up Bethesda and trying to acquire Activision Blizzard is, Spencer argues, a way to compete with Sony."

This has the same logic as buying up the largest gasoline chains, making them exclusively pump gas for drivers of your cars, as a way of competing with other car manufacturers. Dangerous.

view more: ‹ prev next ›