news
Programming Leftovers
-
Elias Mårtenson ☛ Variable scope
Here's an interesting language design problem.
When compiling Kap code, whenever you reference a variable that does not exist that variable ends up being locally declared in the scope where it was seen.
-
Dan Q ☛ The Mythical Man-Month in the age of AI
Absolutely understandable when you think about how these clankers actually work, but for people who don't have that level of comprehension of their mechanism of action... and who don't know enough about Shimano sprocket cassettes, might not notice the mistake. And therein lies yet another reminder of what I've been saying for a long while: you can't trust an LLM to do a good job of anything you couldn't do for yourself.
-
Sandor Dargo ☛ C++26 Ranges: Parallel Algorithms and Safer Filters
In part 1 we looked at the new views C++26 adds, and in part 2 we covered the infrastructure improvements. This final part is about the biggest gap in C++20 ranges: you couldn’t run them in parallel. C++17 added execution policies to the classic std:: algorithms, but C++20 ranges never got them. If you wanted parallelism, you had to decompose your ranges pipeline back into iterator pairs. C++26 finally closes this gap - and while it was at it, the committee also fixed a long-standing foot-gun in filter_view that could silently produce undefined behaviour.
-
Nolan Lawson ☛ The AI cost of JavaScript frameworks | Read the Tea Leaves
One of my pet peeves with the web development community is that so many of the decisions we make are vibes-based. Frameworks are “blazing fast,” tools will “supercharge” your development, the right abstraction will benefit both you and your users (DX and UX all in one!). All of this breathless boasting is usually offered with zero evidence. Alex Russell has called this “frontend’s lost decade”, Baldur Bjarnason has called programming a pop culture, and I’ve tried to counter this trend in my blog with facts and benchmarks (at my best, anyway).
-
Brad Cypert ☛ Interfaces in Zig
Zig’s design deliberately avoids baking object-oriented abstractions into the language. Instead, it gives you a small set of powerful primitives — structs, pointers, comptime, and function pointers — and lets you decide when abstraction is worth the cost.
-
Federal News Network ☛ CISA gives agencies days to patch critical PHP bugs
The vulnerabilities could allow attackers to take control of systems without prior access or authorization.
The addition of the vulnerabilities to CISA’s KEV catalog indicates that the cyber agency has confirmed “active exploitation” of the PHP bugs, rather than just scanning or proofs of concept.
-
Perl / Raku
-
Perl ☛ Benchmarking Finishing Order
This blog post was inspired by the Task 1 of Weekly Challenge 396. Let’s start with the actual wording of the task: [...]
-
-
Python
-
Nick ☛ Future PyHSS
A long time ago I started writing a Python based Diameter stack, that eventually became PyHSS, my partner drew a picture of a Snake wrapping around a database, and today PyHSS is the most popular open source HSS solution.
-
-
Shell/Bash/Zsh/Ksh
-
Adam Johnson ☛ Zsh: parse command-line options with zparseopts
Sometimes you want your shell scripts to take options, like --verbose or --help, along with any positional arguments. Handling options is fiddly to do by hand, with the traditional portable approach being a large block of code using a while loop, a case statement, and some shifts. Bash has the getopts builtin, but it only handles single-letter options, like -v. Zsh also has getopts, for compatibility, with the same limitation.
Zsh has a better tool: zparseopts. It handles both short and long options, in one line of declarations.
-
-
Rust
-
Rust Weekly Updates ☛ This Week In Rust: This Week in Rust 675
Hello and welcome to another issue of This Week in Rust!
-
LWN ☛ Redox OS ring buffers project summary
The Redox OS project, which is a Unix-like microkernel-based operating system written in Rust, has published a report on the work that it has done in the last year to implement io_uring-like I/O.
Last year, the Redox team received a grant to develop io_uring-like Ring Buffer support at the system task level, as a first step towards ring buffer communications between the application and the majority of system services. This phase of the work finished up in September, as the last pieces were put in
[...] In addition to implementing the Ring Buffer machinery for our system services and drivers that can support it, an io_uring and liburing-like API for applications was completed and demonstrated. There was also substantial work done on support crates, including an async executor for drivers.
And there was some very exciting work on various performance improvements, to allow much faster switching between applications and their system services. But I will let the team tell you all the technical details.
-