• 0 Posts
  • 251 Comments
Joined 1 year ago
cake
Cake day: July 9th, 2023

help-circle
  • It makes total sense that new C++ will contain a higher percentage of bugs than old C++, but after being an almost full time Rust dev for the last two years, you will not convince me that new Rust code has more bugs than old C++ code.

    So far I have yet to come across a bug in any of my Rust code that made it into production. All issue reports from users are still related to the C++ code base that we haven’t managed to fully divorce from.

    The only advantage to C++ interop is that managers want to see new code get deployed immediately and continuously. They don’t want to wait until the corporation’s billions (literally) of lines of code are all rewritten in a new language before they start to see the benefits of that transition.


  • The “reform is impossible” is a self-fulfilling prophesy because it leads leftists to never try to get involved in the party, which means they’ll never get a seat at the table, which means they’ll never be able to steer the party.

    I certainly can’t prove that the influence of big money can ever be overcome within the party by grassroots organization, but you also can’t prove that it’s impossible (you can only prove that it’s difficult, which is something I certainly won’t dispute).

    You certainly can’t prove that a true socialist movement will ever gain traction in America. It seems like the general public is so brainwashed they would rather be indentured servants of large corporations than lift a single finger to seize the means of production.

    So we’re left with two unprovable paths to consider, and here’s the thing: the two paths are not mutually exclusive. Leftists can try both at the same time with neither being disruptive to the other. So this is the pragmatism: consider all possibilities and put the eggs into more than one basket.


  • Or he’s a pragmatist who is concerned with both harm reduction and the likely reality that the only takeaway that Democrats will ever have from losing an election to someone right wing is that Democrats need to go even further to the right to win.

    If leftists give the impression that nothing will ever be good enough for them then

    1. Democrats have no incentive to court the left
    2. Democrats have no estimate for how many votes they would even be able to pick up from the left relative to how far left they might try to reach

    I personally believe that if the Democrats had taken on a progressive populist anti-genocide platform they would have won the election handsomely, but I am left with no way to empirically prove that to anyone because so many leftists opt out of voting entirely.









  • How exactly is an individual supposed to determine which cops will be good and which will abuse their power?

    Just as we can’t make a general statement that all cops are definitely bad, you can’t make a general statement that all cops in any particular country or town will be good.

    From a basic risk management viewpoint, it doesn’t make sense for anyone to accept the risk that any given cop won’t abuse their position, even if we were willing to accept that very few would actually do so.

    Cops have an extremely privileged status in society and the amount of damage that a bad one can do to an individual - on purpose or even by accident - is incalculable, including setting up an innocent person for capital punishment as we’re seeing unfold in Missouri right now.





  • Best practice when using .unwrap() in production code is to put a line of documentation immediately above the use of .unwrap() that describes the safety invariants which allow the unwrap to be safe.

    Since code churn could eventually cause those safety invariants to be violated, I think it’s not a bad thing for a blunt audit of .unwrap() to bring your attention to those cases and prompt to reevaluate if the invariants are still satisfied.




  • It’s a massive win, and I would question the credibility of any systems programmer that doesn’t recognize that as soon as they understand the wrapper arrangement. I would have to assume that such people are going around making egregious errors in how they’re using mutexes in their C-like code, and are the reason Rust is such an important language to roll out everywhere.

    The only time I’ve ever needed a Mutex<()> so far with Rust is when I had to interop with a C library which itself was not thread safe (unprotected use of global variables), so I needed to lock the placeholder mutex each time I called one of the C functions.