HNHacker News
TopNewBestAskShowJobs

ojnabieoot

1,423 karma · joined August 28, 2019

Functional-first developer. I like F#, Scheme, and Idris.

Currently “on sabbatical” learning more about operating systems and native code.

submissionscomments
ojnabieoot··on PHP 8
Not a PHP dev, but I read a lot of it for work: based on the example provided, I gather the PHP community accepts that the non-strict behavior of ‘switch’ was undesirable, but it would be too difficult to break the non-strict semantics in an existing construct.

Likewise, the fact that ‘match’ is an expression rather than a statement encourages stricter semantics: although it’s technically unrelated to the type coercion issue, ‘match’ expressions should be easy to reason about locally, which isn’t the case for switch statements. This idea is encouraged by the fact that ‘match’ branches can’t continue across multiple lines: although technically ‘match’ could mutate some complicated global state, the intended use case is a constant or a simple function - easy to understand, and relatively gotcha-free. Gotchas should go in a ‘switch’ statement.

Seasoned PHP devs aren’t going to accidentally use the brand-new ‘match’ statement without careful study, and I don’t think the inconsistency is too big of a deal for newer devs: the overall principle is that ‘match’ is safer than ‘switch’ but less powerful.

ojnabieoot··on Progress bars still lie
I mean yes, a universally accurate progress bar would be impossible, but that’s vastly different from a mostly-accurate application-specific progress bar. The point of the article is that most software barely even tries to give you something reasonable.
ojnabieoot··on Wage Theft Is a Much Bigger Problem Than Other Forms of Theft (2014)
a) Being laid off is not nearly as bad as actually being stolen from (especially in countries with unemployment benefits)

b) Speaking from personal experience: having your wages stolen puts you in a horrible position of wondering if maybe you’ll get paid if you keep your head down, or worrying that you’ll be fired if you complain. The extortion is inherent in the nature of the theft, unlike shoplifting and most corporate embezzlement. It’s not just the money, it’s long-term abuse and exploitation of people who can’t easily defend themselves.

c) Obviously there is a scale: the Enron embezzlement (which is analogous to your extreme example) is worse than stealing $100 from a single worker. But $50bn in stolen wages is a much graver crime than $50bn in embezzled goods.

ojnabieoot··on Wage Theft Is a Much Bigger Problem Than Other Forms of Theft (2014)
Keep in mind that’s employee losses, not shoplifting, so it includes corrupt expense reports, embezzling retirement funds, etc.
ojnabieoot··on Wage Theft Is a Much Bigger Problem Than Other Forms of Theft (2014)
That is an extremely good point - I grabbed that article because I was just looking for a source. In retrospect I shouldn’t have trusted CNBC.

I believe the data is based off the Hiscox report [1], which makes the extremely important point that 85% of losses are due to employees at the managerial level or above - who are of course far less likely to be victims of wage theft! So this “eye for an eye” mentality is truly gross, beyond just the ways where it’s self-evidently gross.

[1] https://www.hiscox.com/documents/2018-Hiscox-Embezzlement-St...

ojnabieoot··on Wage Theft Is a Much Bigger Problem Than Other Forms of Theft (2014)
It is not “in fact a much larger amount” - it actually looks to be about the same. The article estimates about $50bn wages are stolen every year, while [1] suggests about $50bn is stolen/embezzled by employees every year.

I will add that even if the net amount is the same, it is much worse morally to rob a worker than a business.

[1] https://www.cnbc.com/2017/09/12/workplace-crime-costs-us-bus...

ojnabieoot··on The Strange Disappearance of Cooperation in America (2013)
I am aware of that, thanks, but the fact that the Democratic president was the one who led passage of the Civil Rights Act, while his 1964 Republican opponent’s campaign focused on opposition to the Civil Rights Act, means that civil rights legislation was in fact “Democrat-led.” It is also relevant that most of the Democrats who voted against the Civil Rights Act had become Republican by the 80s.
ojnabieoot··on The Strange Disappearance of Cooperation in America (2013)
It is extremely problematic to claim that cooperation declined in America after the 1960s without even mentioning civil rights. Americans are certainly cooperating more insofar that it’s no longer literally illegal for gay people to have a relationship, or that black families on vacation no longer need a book indicating which gas stations and hotels will actually serve them.

The fact that white people are meaner to each other - particularly liberal v. conservative - than they used to be is in fact directly (albeit not solely) related to this, as with the polarization in formal political parties. Seeing the decline after the 1960s is really not a mystery if you think about how American society drastically changed due to Democrat-led legislation passed in 1964 and 1965, right when the graphs started nosediving.

ojnabieoot··on The Secret Math Society Known as Nicolas Bourbaki
I’ve always viewed Bourbaki as something like the CRC Handbook for pure mathematics: an exceptional reference and a necessary collation of wide-ranging ideas and information, but dry by design, and a poor way for self-learners to understand any new topics.

I also think it’s going a little far to say “remove the beauty” - but it is true that if you don’t already have an appreciation for the specific subject, that beauty is awfully hard to find.

ojnabieoot··on Zig 0.7.0 tagged
Generally Zig is a bit lower-level and simpler. One big difference is that Nim compiles to C whereas Zig compiles to LLVM IR. Zig is also heavily imperative / procedural, whereas Nim supports more object-programming paradigms, algebraic data types, more sophisticated exception handling, and so on.

They are both low-level compared to Python but fill different niches.

ojnabieoot··on Disney unveiled an animatronic robot with the same gaze as humans
Well there’s an associated journal publication about the technology - Disney Research is hardly keeping this under wraps, and they publish many of their findings and technologies. And in general this is a demo like we might see with Marvel/Lucasfilm demonstrating special effects, etc, and not really a spoiler about a Disney World attraction.

And from a Corporate Disney perspective this is good PR, particularly for the labor market (I am not sure many engineers think of Disney as a major tech employer).

ojnabieoot··on Biden wins White House, vowing new direction for divided U.S.
> But I'd like to believe that most are misled, misinformed, yet good people. I know my neighbor is one in fact.

Something I have found increasingly frustrating is this childish attitude that saying “so-and-so is a bad person” means “so-and-so will always be a bad person and can do nothing to change for the better.” Simplistically separating people by “inherent nature” leads to us not calling a spade a spade when someone is being a bad person, and means bad people can’t ever actually appreciate the scope and impact of their misdeeds.

People who voted for Trump did so for reasons that were, by and large, morally outrageous. We don’t need to treat them like lost sheep who were incapable of understanding what Trump represents. There were a shocking number of horrendously terrible people in Germany and Rwanda, and most didn’t go to jail when the genocide ended. After WW2 it was really hard to find a German who would say they voted for the Nazis, and I am sure many or those millions of people led upstanding lives. That doesn’t make their decision to vote for the racist strongman retrospectively defensible.

(There’s also the related problem of “he can’t be a bad person, he’s nice to me!”)

ojnabieoot··on Biden wins White House, vowing new direction for divided U.S.
That’s a very strange misreading of how elections work (and misstates US demographics, most of us live in suburbs).

But even taken on its own terms, isn’t that better than “a nation ruled by a rotating handful of states with nothing in common other than a somewhat steady 50-50 split in the electorate”? The current system is indefensible madness.

ojnabieoot··on Biden wins White House, vowing new direction for divided U.S.
While it’s true that the US government needs structural reform, the issue wasn’t anything the Constitution can fix by nibbling around the edges. The issue is that the unified Republican elite, along with > 35% of the electorate, is fundamentally lawless and anti-democratic, and will do anything it can to cheat its way into power. All three branches are implicated and have been for a while: Bush v Gore in 2000, the US Attorney firings, Shelby County in 2013, the refusal of the Senate to convict Trump in 2020, the disgusting anti-science politicization of coronavirus, and so on. The scale of Trump’s personal corruption is unique among Republican national figures, particularly in foreign policy. But the racist authoritarianism and fundamental disrespect for elections is a defining creed of the party.

One of the more unpleasant truth about democracy is that it’s quite fragile. In any real sense, the US has only been a democracy since 1965. When large segments of the population are ideologically opposed to democratic governance - universal human rights, respecting fair elections, following the plain text of the law, and so on - mechanisms by which democracy sustains itself begins to fail.

One possibility is to amend the constitution to change first-past-the-post voting in all local-to-federal elections, to let never-Trump types speak out without facing electoral suicide, and to divert right-conservative attention away from a single “leader” figure. And obviously the electoral college needs to go.

But the fact that more than 65 million people voted for Trump at all speaks to a great sickness and nihilism in American culture. Trump himself might be put out to pasture. But Trumpism existed before he got here, and it isn’t going anywhere.

ojnabieoot··on The Early History of Smalltalk (1993)
That seems like a weirdly reductionist view of “taking off.” Smalltalk had always been a primarily academic language whose footprint on programming languages in general vastly exceeds its specific user base. Ruby, Python, Java, C#, etc, all owe a great deal to Smalltalk. In that sense it’s like SML and Scheme: you could fairly say “more studied than used” but that hardly makes it irrelevant.
ojnabieoot··on Silk Road Bitcoins worth $1B transferred after seven years
Look that’s just not what “hard currency” is. “Hard currency” basically means “money which is considered a reliable store of value in major international markets.” Bitcoin simply isn’t that. No functional national government or large corporation is going to sign a large contract in Bitcoin - the very act of signing it could dramatically devalue the currency! You can’t just say Bitcoin is hard currency and devise some random measure of “hardness” out of ideological convenience.

Bitcoin is a fine technology and a fine thing to put part of your wealth into, especially if you support the tech and want to use it to buy things or invest. It’s also brand new, it’s price / USD or euro is obviously unstable, and there’s a global pandemic-depression! It’s just short-sighted (and intellectually dishonest) to say Bitcoin is low-risk and “hard currency” because it’s protected against inflation.

ojnabieoot··on Silk Road Bitcoins worth $1B transferred after seven years
If the commodity in question was anything other than Bitcoin nobody would be saying something like that with a straight face. I think “Beanie Baby” is too strong a term for Bitcoin since they are much more “inherently” valuable ($5 of Bitcoin is much more useful than a $5 stuffed animal). Bitcoin will very likely never be worthless.

But a large chunk of Bitcoin’s 2020 wealth comes from it being a speculative instrument - as your comment indicates! I hope this dies down eventually but obviously Bitcoin is objectively high-risk. We are still in the first year of a serious recession, and significant political turbulence, and a pandemic. It’s not irrational to put that money into dollars / euros / etc.

ojnabieoot··on How to seriously read a scientific paper
I was going to say "write ignorant comments on social media about the paper based solely on the title" but your approach sounds more useful.
ojnabieoot··on Leaving OCaml
“Fewer” is a relative term - F#’s type system is noticeably less fancy (basically generics are “weaker” than in OCaml) but having the entire .NET System library is very useful for practical programming, along with many 3rd party options. The author mentioned a lack of GCP support in OCaml as a major stumbling point, and also mentioned how nice it was that F# had a built-in immutable map. There is more to computer science than type theory - System.Collections.Concurrent is particularly cool, and hard to do in OCaml. If you know C#/Java/C++/etc some of that code is also very well-written and informative.

There are use cases where OCaml’s type system leads to elegant type-safe code that, if expressed in F#, involve inelegant unsafe boilerplate. It’s usually not a whole lot and it’s typically routine but it certainly happens. For some teams and products OCaml is a better choice.

But there’s also a reason why many developers abandoned Lisp for Python: some theoretical fanciness and robustness only infrequently outweighs ease-of-use and quality-of-life.

ojnabieoot··on Dark’s new backend will be in F#
I have been using F# for 5 years and have never once needed to use “null” anywhere in my code - if I were to interact with a C# library I think null-handling is an acceptable price to pay for the interop (similar to weirdness with OCaml/Haskell and C FFI). F# makes that particular separation of concerns very clean and easy to handle. Idiomatic F# is safe against null reference exceptions.

I think you’re needling a small wart in F# due to the .NET requirement, it’s hardly enough to say that F#’s type system is overall bad.

ojnabieoot··on Leaving OCaml
I would say OCaml’s most famous use (or at least its most successful) is in the compiler/runtime for Coq, the proof assistant. Which means that a huge bunch of its user base is in academia and theoretical computer science , and whose jobs it is to worry about fancy type stuff :)

It also does seem that OCaml is more popular in Europe than North America but I don’t have any data on that.

ojnabieoot··on Leaving OCaml
There’s a big gap between “can theoretically build this application” and “can efficiently and reliably build and maintain this application.”
ojnabieoot··on Leaving OCaml
I am an F# person rather than OCaml and am not familiar with the compiler, but this seems to be overstating the difference: I thought the OCaml functors are “real” mathematical functors that implemented a structured type polymorphism over the “input type” - they look pretty similar to C++ templates superficially but they work similarly to Haskell type classes. They are “functions from modules to modules” but those functions take types as values.

Real experts should let me know if I am mistaken: I don’t think OCaml and Haskell have strictly the same type system, but they are both similarly more expressive than F# because of this specific type -> type polymorphism that in particular lets you do type-checked monads, etc.

ojnabieoot··on The Paranoid Style in American Politics (1964)
The truth is that American politics has one divide and basically always has:

- white conservatives and reactionary nonwhites, primarily unified by racialist ideas about rights and citizenship

- white liberals and socialists, and a vast cohort of nonwhites, ranging from Marxist to fire-and-brimstone conservative

It’s really a huge mistake to lump the latter cohort in the “left” and deeply related to why almost all conservative black people (excerpt for the truly radical or careerist) refuse to vote for Republicans.

ojnabieoot··on Homicide victim found in burnt-out SUV ID'd as man behind spam-email empire
It’s a spectrum - Musk isn’t irredeemably terrible, but he’s shockingly callous about the well-being of his workers and, like Edison, despicably shameless about slapping his name on other people’s work. His recklessness on COVID is immoral, even if it stems from narcissism rather than an evil death cult.

Bill Gates isn’t a psychopath like McAfee - and more to the point, unlike McAfee, he is rational. Bill Gates is also one of the worst economic criminals in American history.

ojnabieoot··on Homicide victim found in burnt-out SUV ID'd as man behind spam-email empire
To be clear: you are currently being downvoted for the rude and immature part at the end, and not because you didn’t provide citations.
ojnabieoot··on Homicide victim found in burnt-out SUV ID'd as man behind spam-email empire
Again: bad people with modest tech skills (Hawke, the AirBnB founders) are not the same thing as bad people who are actual technologists (McAfee, Gates, Musk), or even bad people with modest tech skills who lead actual technology companies (Zuckerberg). In particular AirBnB is really not a tech company, it’s a rental company that uses fairly standard commercial/open source tech.

I think the comparison you are making, and asserting that this is a “phenotype” common in tech leaders, is baseless and silly.

ojnabieoot··on Homicide victim found in burnt-out SUV ID'd as man behind spam-email empire
I think calling an email spammer a technologist, and a technological risk-taker, is a bit much - as is the comparison to McAfee. Maybe in temperament but nowhere close in ability or accomplishment. Hawke was just a con artist with some computer skills.
ojnabieoot··on An Earth-sized rogue planet discovered in the Milky Way
Thanks, I see that in the paper now - I didn't get further than the abstract :)
ojnabieoot··on What Bitcoin’s White Paper Got Right, Wrong and What We Still Don’t Know (2018)
> The price has continuously gone up overall at a rate greater than inflation.

This is true but a) there's no reason to think this will be true for another 10 years, and b) if you had invested in November 2013, you wouldn't have seen a profit until 2017. 4 years of being in the red is a hard pill to swallow if you're not diversified.

Things that might look really bad for months, but work out in the end are better investments than savings. I think it's just silly to pretend Bitcoin is anything but

a) an interesting technology that enables a lot of cool internet finance tech and helps people who live in countries with profoundly unstable economies

b) a risky speculative investment on something that's correlated with the price of CPUs, graphics cards, and electricity, and is prone to major supply shocks

← PreviousPage 7 of 12Next →