News for hackers. Stuff that matters.

rami3l

I was immediately reminded of this old piece on water quality issues and local politics...

> An Enemy of the People [..] is an 1882 play [..] that [..] centers on Dr. Thomas Stockmann, who discovers a serious contamination issue in his town's new spas, endangering public health. His courageous decision to expose this truth brings severe backlash from local leaders [..]

https://en.wikipedia.org/wiki/An_Enemy_of_the_People

Re:Zig: What to Expect from Release Month on Friday January 17, 2025 @09:44PM (#42745345)
I've been playing around with Zig as a potential C alternative in my stack, and I think that it's pretty good at least for toy/learning projects actually. I especially like the way `comptime` gives me superpowers.

Before Rust and Zig, I thought I disliked systems programming, while as it turned out, I mostly just disliked C.

However, when it comes to actively maintaining a serious project you do need to take extra care, since using a pre-v1 language does require a lot more efforts, since even in a post-v1 language you need to handle lib updates and such...

Also, even though I believe I'm no longer afraid of manual memory management, explicit allocators, etc. for writing regular userland applications, I still think Zig can be too low-level for certain problem domains from time to time (the same thing for C, and I believe Zig is there specifically to target C programmers), so it's really about finding out which tools would be a great fit for you in which scenarios.

Re:A Developer's Review of a Snapdragon X Laptop on Tuesday July 16, 2024 @01:41PM (#40978610)
The site's source code is already updated, but unfortunately the website itself is refreshed per Rustup release, so we might have to wait for a bit longer...
Re:A Developer's Review of a Snapdragon X Laptop on Monday July 15, 2024 @10:20PM (#40973200)
Thanks for sharing the experience! At Rustup we're also getting ARM64 Windows-related requests recently, so I'm very curious about how well these machines actually do as a daily dev workstation. Looks like your Yoga 7x performs even better than I thought it would!

I'd like to add that actually there is an official prebuilt Rustup binary available for you at https://win.rustup.rs/aarch64, maybe that will lead to less translation overhead for your Rust workflow :)

Re:GitHub now provides Arm-based runners on Thursday June 06, 2024 @05:56AM (#40595569)
This reminds me of one issue that I've encountered at Rustup. Early versions of ARM64 Pi OS actually use a 32-bit userland. As a result, this has caused user complaints since our installer sees a 64-bit kernel and will happily download a 64-bit binary (which will then refuse to run): https://github.com/rust-lang/rustup/issues/3307#issuecomment...
As a current Rustup maintainer with a bit of Ada background I gotta say: nice work!

I do feel Ada as a language is way ahead of its time, but when I was learning it (a while before the first Alire release) I was also puzzled by dev environment setup. I guess the Rust experience has shown the importance of a friendly onboarding experience, so I’m very glad to see Ada is going this direction as well with Alire and now Getada :)

Re:Think Python, 3rd Edition on Sunday February 18, 2024 @05:42AM (#39417979)
Many thanks for this book! Think Python 2nd is the first book I've ever read in order to teach myself programming.

Now I've come a long way to become an actual developer shipping real products and have certainly learned a whole lot more on the topic, but I still think the first steps are the most important/difficult ones. Although I've moved away from Python towards other platforms such as Rust, the basic concepts covered in this book are still very much relevant.

I'm really excited to learn that Think Python has become more modern and interactive with this update!

Re:Fourteen Years of Go on Saturday November 11, 2023 @09:52AM (#38230765)
Rust dev here.

I really love the fact that most of the time people from the Golang community would like to say "look what I've made with Golang!" That's the sign of success: the users (here I mean general devs) should not care too much about the language per se, they still have applications to ship!

Rustaceans tend to talk more about cool new language features. They are critical to what Rust does, but maybe they have also got too much attention.

Re:Advanced Python Mastery – A Course by David Beazley on Wednesday July 19, 2023 @11:34AM (#36788109)
I have also encountered this quite often. I'll say the ideal solution would be "postfix streaming methods" like `.filter` and `.map`. Unfortunately, Python doesn't have those (prefix `filter`s and `map`s are not even close), and you have comprehension expressions at best. To make things worse, complex comprehensions can also create confusion, so for your particular example I'll probably say it's acceptable. It could be better if you use unpacking instead of indexing though, as others have pointed out.
Re:Why your F# evangelism isn't working on Wednesday May 31, 2023 @09:02AM (#36137875)
The last time I gave F# a shot, I tried to write a simple Telegram bot in it.

Just to test how much I would actually benefit from the .NET ecosystem, I chose to use a C# wrapper for the Telegram API. Suddenly I had to handle null references and exceptions everywhere (it's in this regard even worse than Rust, where I'm guaranteed to get Options and Results).

I know proper support for C# T? type interop is in the works (https://github.com/dotnet/fsharp/pull/15181), but really it seemed to me that too few cared about F# to get it landed in a reasonable timeframe.

I'd really love to see a pragmatic FP language with a reasonable amount of libs to choose from (both natively and via interop without much effort), but F# was a bit far from that description IMO.

Re:Writing Python like it's Rust on Sunday May 21, 2023 @07:37AM (#36019906)
Indeed, that has been a real problem, so now you can probably write `private Dictionary<RoadPlate, List<RoadPlate>> road = new();`.
Re:Ligatures in programming fonts: hell no on Saturday May 13, 2023 @01:27PM (#35930560)
Exactly. I recently started to write some LEAN which uses a ton of Unicode characters and I still use JetBrains Mono with ligatures on. ≠ is 1 unit wide but != is 2 units wide, so it's not that confusing as one might think.

Besides, if someone insists, it's also possible to make a language-specific setting in the editor to disable ligatures in those languages :)

As a PDM enthusiast for quite a while, I'm sorry to inform you that PEP 582 has been officially abandoned (which doesn't mean that it won't be revived someday, just not so easily). https://discuss.python.org/t/pep-582-python-local-packages-d...
Re:The Lone Developer Problem on Tuesday February 28, 2023 @10:22AM (#34970283)
Agreed. It seems to me that doctests (i.e. code examples in docs that also count as tests, common in Python and Rust codebases) can possibly cover parts of this.
Re:Fish (shell) porting to Rust from C++ on Tuesday January 31, 2023 @08:14AM (#34594624)
However the borrow checker is not only about new/delete, it also prevents other forms of reference invalidations (e.g. when holding a reference to a vector element while appending to the vector, that reference can become invalid when the vector gets resized).
Re:Emacs Org Mode for Visual Studio Code on Sunday October 16, 2022 @03:10AM (#33221718)
With VSCode there doesn't seem to be such a technical limit. See: https://marketplace.visualstudio.com/items?itemName=sean10.m...
Re:Helix: A Neovim inspired editor, written in Rust on Tuesday October 11, 2022 @10:23PM (#33172001)
* nain -> nvim
Re:Helix: A Neovim inspired editor, written in Rust on Monday October 10, 2022 @05:57AM (#33149580)
I love to see that Helix tries its best to ensure an out-of-the-box experience, as well as to add so many interactive hints for key combinations (for example when you want to paste in insert mode with C-R it’ll immediately list a set of registers that you can paste from).

However Vim is much more to me. It’s not just an editor, but a keybinding that I can use not only in nain, but also in VSCode, in fish shell, and even in GHCi REPL.

How long would it take to make them all support (some reasonable subset of) Helix?

Re:Things I hate about Rust, redux on Thursday March 10, 2022 @06:30PM (#30634074)
Instead of enums, how about something similar to Scala's sealed trait syntax to tell the compiler that I'm actually doing a static dispatch?