HNHacker News
TopNewBestAskShowJobs

throwaway2037

8,543 karma · joined January 1, 2021

submissionscomments
throwaway2037··on Show HN: NES Contra (1987) port (ASM –> C and then C –> WebAssembly)
100% agree. That makes this commented code so incredibly impressive to me!
throwaway2037··on Surviving "The Graduate"
Thank you to share!

Also on Spotify: https://open.spotify.com/episode/2hQgVUyHUjox67XgkmVbRX

throwaway2037··on Show HN: NES Contra (1987) port (ASM –> C and then C –> WebAssembly)
How would that work for hit detection algorithms in the code?
throwaway2037··on Show HN: NES Contra (1987) port (ASM –> C and then C –> WebAssembly)
Wow, the source 6502 assembly with comments is incredible: https://github.com/vermiceli/nes-contra-us/blob/main/src/ban...

The whole thing (all banks) is more than 10,000 lines of assembly code. When I wrote assembly code for a university computer science course, it was hard to manage even 200 lines. I cannot imagine writing and managing 10,000 lines!

throwaway2037··on StackOverflow now gets fewer than 1000 questions a month
I can reliably say that Wiki has had the digital fiefdom issue for more than 10 years. It is not recent.
throwaway2037··on StackOverflow now gets fewer than 1000 questions a month
I was also a heavy user of SO for many years. At the end, I noticed things started to get really weird. I would ask a carefully researched question, get multiple answers, and get zero upvotes on the question. The Win32 community got so weird that people would only post comments under your question, but zero answers would be posted.

Maybe we will look back at mid-life SO (its golden period) as something like bulletin boards in the 1990s. Once the Internet arrived, BBSes were wiped out.

throwaway2037··on Anthropic blocks users for anything touching training larger models
The author's homepage: https://jiahao-shao1.github.io/

... says:

    > My research aims to build a general-purpose agent that can understand, reason, and act in the physical world — at the intersection of multimodal learning, generative modeling, and embodied AI.
His tweet says:

    > got tagged for "training a competitor,"
I don't get it. To me, it sounds like he is training a competitor. Do I misunderstand? Is there a Chinese equivalent LLM that he can use instead?

Also, give the national security sensitivity around AI/LLMs, I can understand why Anthropic wants to be especially cautious with mainland Chinese researchers, including those from blocked regions (Hongkong, in this case).

throwaway2037··on Much Ado About None: Sentinel Values in Python
Here is the sample code from the article:

    > MISSING = sentinel("MISSING")

    > def update_email(user_id: int, email: str | None | MISSING = MISSING) -> None:
    >     if email is MISSING:
    >         return  # nothing to update
    >     elif email is None:
    >         db.delete_email(user_id)
    >     else:
    >         db.set_email(user_id, email.lower())  # narrowed to str
I see this style frequently from long time Python programmers. The language is so dynamic that people begin to think this is a good way to program. Hot take: It is not. Why not two different functions called delete_email() and set_email()? That would be more clear.
throwaway2037··on The $6.3B Binance hack was pulled off in just 20 minutes
Jesus, what do they spend 12B USD per year on expenses?
throwaway2037··on I Returned My iPhone Duo
More likely Apple factors this used return rate into the pricing. They must have lots of data when new products are released, including with radical changes.
throwaway2037··on I Returned My iPhone Duo
I think Samsung is on their eighth generation of foldable phone. That would quite a corporate vanity project if unprofitable!
throwaway2037··on I Returned My iPhone Duo

    > to using the larger screen instead of Mac
I wonder if the Apple product development team considered this canabalisation risk.
throwaway2037··on I Returned My iPhone Duo

    > Screen ratios make reels-like addictive content less appealing which is great for me
This is interesting feedback! Can share more? Is it not possible to rotate the double screen vertically?
throwaway2037··on I Returned My iPhone Duo
I think this interpretation is needlessly judgemental/negative. The author probably intended it is a post-purchase review. This is very common for non-professional tech reviews.
throwaway2037··on I Returned My iPhone Duo
I agree. I have never once done it my life. This behavior is wasteful.
throwaway2037··on I Returned My iPhone Duo
What a weird post. No Face ID would be a pre-purchase "no go" for many people.

What happens to these returned phones?

throwaway2037··on Apple's git still trusts the compromised eMudhra certificates
Thanks for the helpful reply!

    > lots of tools ship their own CA bundle.
Can you give an example for Homebrew? And did the package maintainer explain why?

With the exception of Java, on a modern enterprise Linux box, all packages use the same CA cert pack.

throwaway2037··on Iterating Backwards in C
His final solution is so tricky. I needed to re-read it a few times to understand the trick of using post decrement in the for loop condition. Personally, I would never write code like that. I would always find a way to use ssize_t.

This part was an interesting requirement:

    > ssize_t is a POSIX thing so you'd have to define it yourself on windows.
That seems like a lot of mental gymnastics to avoid this very simple macro:

    > #if defined(_WIN32) && !defined(ssize_t)
    > #define ssize_t SSIZE_T
    > #endif
Read about the Win32 macro SSIZE_T here: https://learn.microsoft.com/en-us/windows/win32/winprog/wind...

To me, this solution is more readable and maintainable:

    > for (ssize_t i = count - 1; i >= 0; i--)
    > {
    >     if (haystack[i] == needle)
    >     {
    >         *where = i;
    >         return 1;
    >     }
    > }
    > return 0;
Alternatively, you can use a while loop where the condition appears at the end of the loop:

    > size_t i = count - 1;
    > while (1)  // true
    > {
    >     if (haystack[i] == needle)
    >     {
    >         *where = i;
    >         return 1;
    >     }
    >     if (0 == i)
    >     {
    >         return 0;
    >     }
    >     --i;
    > }
throwaway2037··on CNC Stone Carving
Nerd Catnip Alert! Can you share the X.com account that "specializes in CNC sculpting of Renaissance quality marble statues"?
throwaway2037··on CNC Stone Carving
I would to love to learn more about the metals used in their drill bits. I think about oil/gas drilling and tunnel boring machines. They are facing some of the harshest conditions possible. (Imagine a tunnel boring machine trying to carve through granite rock in Manhattan or Swiss Alps. It is tough!) These CNC machines are doing similar on a "micro-scale". How often do they need to sharpen or replace these drill bits? And what is the cost?
throwaway2037··on Apple's git still trusts the compromised eMudhra certificates

    > Homebrew ships its own CA bundle
No trolling by this question: Can you explain your decision? I can see some pros and cons of this decision. Was it simply removing dependency upon Apple if there was a disagreement on which CA certs to trust? (You can act without permission from Apple to add/remove CA certs?) Also: How does Homebrew decide which CA certs to include/exclude? Do you get a CA cert pack from Oracle/Mozilla/Google/Microsoft/Amazon/Apple?

Outside of an enterprise environment, I never thought about having multiple "golden sources" of CA certs on a single host. (I have no experience working outside of classic enterprise environments, so please do not read my surprise as immediate dismissal of this idea!) For those unaware, in enterprise environments, it is very common to use a common CA cert pack from Oracle/Mozilla/Google/Microsoft/Amazon/Apple, but add 2-5 CA certs from your own company that act as trust roots.

I did some Googling on this matter. It looks like the "Big Four" of CA cert packs are: Mozilla, Microsoft, Apple, and Google. (I guess there is one or two in China also, be leave that alone for the moment.) What happens if they are in disagreement? This is a complex problem! If anyone is involved in this process, I would like to learn more.

throwaway2037··on Apple's git still trusts the compromised eMudhra certificates
Correct. I Googled to ask about location of certs on disk: /etc/ssl/cert.pem

Is it possible for users to remove the eMudhra certificates themselves? I have no experience with MacOS, so I don't know if certain actions are prohibited. To be clear: I am not suggesting that normies do this! Rather, I am asking if it is possible for highly skilled users.

throwaway2037··on Git for the US Code
Hat tip. I didn't understand what you meant by "with proper time stamps", until I opened the page and saw "57 years ago"(!).
throwaway2037··on Ghostty 1.4
Yeah, I thought the pharma bit was potentially performative, but I want to give OP the benefit of the doubt, as is customary here on HN.
throwaway2037··on Microsoft and others tell crypto platform not to tokenize their stocks

    > Germany has the highest number of billionaires in Europe.
It is better to use number of billionaires per capita. That would be: Monaco, Liechtenstein, Guernsey, Cyprus, Switzerland, Sweden.

    > Those contributing the worst to wealth inequality are paying minuscule taxes through family offices
I did some Googling. It looks like they are using Familienstiftungen (family foundations). They pay much lower taxes than regular income tax. Yeah, I am with you on this one: It is bullshit that they can pay lower taxes.

One thing that I wish more countries did to handle large inheritances: Make people pay a relatively high inhertiance tax (say 25-50%), but grant them a state-backed low interest loan to repay the inheritance tax over 15-30 years. My hottest take: Make there almost no exemptions (farms, family homes, etc.) and no minimum. Any well-run, but private business, should easily be able to pay this back within the timeframe. Also, it would protect family-owned businesses, which I know is an important cultural consideration in Germany, thanks to Mittelstand.

throwaway2037··on Police are using AI to pull over drivers for 'suspicious' behavior
Are there any well-documented (mass media) examples of an arrest and conviction for having a smartphone that does not run iOS or Android? I doubt it.
throwaway2037··on Ghostty 1.4
Real question: Is the Linux kernel terminal the fastest of all? If yes, why not compile there?
throwaway2037··on Ghostty 1.4

    > By default, Konsole disables OSC8 link support.
Is this for security reasons? I am sure the Konsole has a reason for it.
throwaway2037··on Ghostty 1.4
I am pretty sure that Mitchell has addressed the matter in previous blog posts.
throwaway2037··on Ghostty 1.4
Here, "proven" can be read as a synonym for "demonstrated".
← PreviousPage 4 of 34Next →