HNHacker News
TopNewBestAskShowJobs

wpollock

383 karma · joined June 18, 2023

submissionscomments
wpollock··on IPv6 zones in URLs are a mistake
I wonder how many readers realized your joke here. For the ones who didn't, the 4-byte "magic number" that identifies Java .class files, in hex, spell "CAFEBABE".
wpollock··on I was recently diagnosed with anti-NMDA receptor encephalitis
This. Today, well-meaning doctors cannot spend more than 5-10 minutes between seeing patients. Medical shows on TV show teams of physicians working on one or two patients per week. The reality in my part of the world is that each doctor sees 10 or so patients each day, and are not available for phone calls. (Even in 2026 my parents can reach their doctors by phone, and they spend the time to chat. But they are in New York and I live in Florida. )

I have seen my current PC doctor for 25 years now and he knows me well enough to spot significant changes. But he's retiring in a few months and I have no idea how to find a new doctor. My current doctor has no recommendations for me. (I'm not asking here for any if that's what this sounds like.)

wpollock··on Nobody cracks open a programming book anymore
> Do you know how to operate a punch card?

I remember! You created a control card, with tab stops and other controls, wrapped it around a control drum, and then had an easy time punching your source FORTRAN!

I just looked and found my old control drum, in the back of my junk drawer. But I can't find an old punch card machine in there, most have lost it somehow.

wpollock··on Migrating from Go to Rust
Very nice write up! I am a fan of Rust and have little exposure to Go. That said, a couple of very minor points:

cargo audit is not built-in, it is 3rd party. (The comparison table near the top isn't clear about that, and the following text stating more is built-in for Rust than for Go might be confusing. I would suggest adding an asterisk to mark built-ins in that table.)

cargo watch has been in "maintenance mode" for some time. The author of that suggests cargo bacon instead.

wpollock··on Deno 2.8
> Typescript is only a linter...

I never thought of Typescript (TS) that way. I believe TS is a language addition that enabled smarter JavaScript linters; TS is not a linter program per se.

However, TS is more than that now. The extra annotations enable optimizing transpilers and even compilers (to WASM, for instance). This makes TS much more than just a better linter; I think of TS as a better language.

wpollock··on Deno 2.8
> Theres no reason to ship TS to an end user browser.

As things are now, developers write code in TypeScript, then debug and update code in Javascript. It might not be much of a reason, but a single language throughout is surely easier on developers and maintainers.

wpollock··on Deno 2.8
> Because "it doesn't exist". It's just a layer on top of js, ...

C++ was originally a layer on top of C. The first C++ compiler, "cfront" was actually a transpiler to C.

There is nothing preventing TypeScript from becoming "native" in a similar way.

wpollock··on When life gives you lemons, write better error messages
Long ago, I had the insight that not all users are equally technically proficient. Some had the chops to fix some problems if given sufficient information. Other users would be confused with too much detail.

I was writing code for AT&T (in the 1980s), and we were our own customer. So I wrote the error routines to check an environment variable and provide different error messages for different types of users: developers, testers, and a few power users got very detailed error messages, ordinary users got friendly, simplified messages (and weren't told about the environment variable).

wpollock··on What causes lightning? The answer keeps getting more interesting
I found this article interesting but lacking. Lightning also sometimes travels from the ground up to the clouds. Storm clouds produce red sprites (there are some theories about these) and blue jets, that shoot upwards towards space. Then there's ball lightning. None of these phenomena were discussed in the article.

I don't think scientists fully understand lightning at all. (At least, I don't!)

wpollock··on Canvas online again as ShinyHunters threatens to leak schools’ data
> The thing is, I don't need that training to recognize that they are failing to contribute to society.

An old lawyer joke: What do you call 100 lawyers drowning in the ocean? A good start!

(Told to me by my dad, a former attorney till he retired.)

wpollock··on Dirtyfrag: Universal Linux LPE
Or more simply, use

   su -c 'echo 3 > /proc/sys/vm/drop_caches'
wpollock··on How do I inform Windows that I'm writing a binary file?
Interestingly, the IETF has several published RFCs for text protocols, all of which require \r\n line endings.

<https://www.rfc-editor.org/old/EOLstory.txt>

Note this does not apply to file formats (except for RFCs).

wpollock··on Why are there both TMP and TEMP environment variables? (2015)
> In general, I find it unacceptable for programs to use (anywhere in) my file system, besides /tmp, as a dumping ground for their caches and downloads, without cleaning it up.

/tmp must be world-writable and for multi-user or multi-tenant systems it becomes a security hole. Storing temporary files in the current user's home directory (or a subdirectory thereof) makes sense.

What doesn't make sense is this blog post about TMP and TEMP, and ending with "I don't know why" (in different words).

The reason is simple: different programmers thought the other name was bad. They were under no obligation to come to a consensus.

Don't forget about TEMPDIR and TMPDIR! Also Windows has its own environment variables for this. But generally, Linux software ported to Windows still use TMP or TEMP.

wpollock··on The Secret Life of NaN (2018)
I was thinking of DEL, but was obviously mistaken. Thanks for catching that!
wpollock··on Bugs Rust won't catch
Thomas Jefferson famously said that "A coreutils rewrite every now and again is a good thing". Or something like that.

When I was a beta tester for System Vr2 Unix, I collected as many bug reports as possible from Usenet (I used the name "the shell answer man". Looking back I conclude that arrogance is generally inversely proportional to age) and sent a patch for each one I could verify. Something like 100 patches.

So if this rust rewrite cleans up some issues, it's a good thing.

wpollock··on The Secret Life of NaN (2018)
> ... Unicode says that 0xFF is an invalid character.

Not so. You may be thinking of UTF-8 encoding. 0xff is DEL in Unicode.

wpollock··on Columnar Storage Is Normalization
My mental model of columnar storage is as the old notion of parallel arrays, which I used in the 1970s with FORTRAN. Whatever you learned first sticks with you and you end up translating everything to that, or at least I do. I believe this is known as the baby duck syndrome.
wpollock··on The world in which IPv6 was a good design (2017)
The source and destination addresses don't change. If a bomb takes out a router in-between (the military scenario DARPA had in mind), it is NOT IP (L3) or TCP (L4) that handles it. Rather it is a dynamic routing protocol that informs all affected routers of the changed route. Since the early days of the Internet, that's been the job of routing protocols.

For smaller internets, protocols such as RIP (limited to 16 hops) broadcast routing information from each still-working router to other routers. Each router built a picture of the internet (simplifying a bit here, RIP and similar protocols used "distance vector" routing, but other more advanced routing protocols did have each a picture of the internet). So when a packet arrived at its router, that router can forward the pack towards the destination. Such protocols are "interior" routing protocols, used within an ISP's network.

The Internet is too big for such automatic routing and uses an "exterior" routing protocol called BGP. This protocol routes packets from one ISP to the next, using route and connectivity information input by humans. (Again I'm simplifying a bit.)

Wifi uses entirely different protocols to route packets between cells.

Fun fact: wifi is not an acronym for anything, the inventors simply liked how it sounded.

wpollock··on Migrating from DigitalOcean to Hetzner
> I notoriously write bad English...

You mean that you write in English badly. :-)

wpollock··on NASA Shuts Off Instrument on Voyager 1 to Keep Spacecraft Operating
This. Except worse, during busy days you had to stand on line for an hour or more for a turn on the machines. I believe the skill of debugging by mentally stepping through a program's execution came from such long run times, a useful skill many younger programmers lack.
wpollock··on Tactical Success, Strategic Failure? Washington Walks the Path to Defeat in Iran
It's probably not wise to say so on HN, but one possible strategic goal of this war was to distract from the Epstein files.
wpollock··on The economics of software teams: Why most engineering orgs are flying blind
> They don't? It is taught in schools in the early elementary level. I see no indication that most are failing.

Programming in elementary schools typically involves moving a turtle around on the screen. (My mother taught 4th grade in New York for many years, and I believe her when she explained the computer instruction.)

Economically valueable programming is much more complex than is taught in many schools through freshman college. (I taught programming at the college level from 1980 till I retired in 2020.)

wpollock··on WireGuard makes new Windows release following Microsoft signing resolution
> If the company makes it impossible for you to communicate with them, the only recourse is to draw public attention to it in order to shame them.

Legal action works too. You'd be surprised how effective a letter from an attorney can be.

wpollock··on Adobe modifies hosts file to detect whether Creative Cloud is installed
Your post reminded me when Yahoo IM updated their chat protocol to an incompatible version with a gradual rollout! Half their eight servers used v1 and half v2. A v1 only client would connect half the time depending on which server the round-robin DNS sent you to. This took me forever to figure out, but the fix was to put the IP address of the four v1 servers in the hosts file. (Until the client updated its support for v2.)
wpollock··on Big-Endian Testing with QEMU
> And, especially what most people call big-endian, which is a bastardized mixed-endian mess of most significant byte is zero, while least significant bit is likewise zero.

In the 1980s at AT&T Bell Labs, I had to program 3B20 computers to process the phone network's data. 3B20s used the weird byte order 1324 (maybe it was 2413) and I had to tweak the network protocols to start packets with a BOM (byte order mark) (as the various switches that sent data didn't define endianess), then swap bytes accordingly.

Lesson learned was Never Ignore Endian issues.

wpollock··on Delve allegedly forked an open-source tool and sold it as its own
My fantasy: After the salesman says (for the 4th time), "Sorry, the manager won't approve that price, but if you could add X hundred dollars, I'm sure I can convince them!", I wait until they are through high-fiving each other and then tell the salesman "Sorry, my trust manager didn't approve that price. I'm sure I can convince him if you lower the price by X hundred dollars".

My reality: I use my bank's car-buying service and pay the bank's negotiated price.

wpollock··on C++26 is done: ISO C++ standards meeting Trip Report
eiffel.com is a support tooling company. Eiffel the language has the website <https://www.eiffel.org/>. Both sites are worth a look.
wpollock··on DoesItAgeVerify: The age verification status of Open Source Operating Systems
Age verification is simple! A Kelvar strap must be attached to the user before the device will power up. A probe in the strap takes a drop of blood from the user and analyzes the protein markers to determine the user's age. (See the Stanford U. study for details.)

Surprised G. Orwell or A. Huxley didn't think of it first.

wpollock··on C++26 is done: ISO C++ standards meeting Trip Report
> Programming languages used for correct-by-design software (Ada, C++, Rust) ...

A shoutout to Eiffel, the first "modern" (circa 1985) language to incorporate Design by Contract. Well done Bertrand Meyer!

wpollock··on C++26: A User-Friednly assert() macro
You're right, thanks!

This works too (but I wouldn't recommend it):

   assert( someBooleanExpression || ! "It is false" );
← PreviousPage 2 of 8Next →