Recent submissions

Comment · 3 years ago
Comment · 3 years ago
Comment · 3 years ago
> I've been wondering lately whether a new spatial approach can yet again simplify matters.

I've been closely following the development of Vale since I first saw it here. Though their approach is slightly higher-level than Rust and requires (some) runtime safety checks (though to be fair, so does GC).

https://vale.dev/

https://verdagon.dev/blog/zero-cost-memory-safety-regions-ov...

I think it would be tough to change the spatial model in a language as low-level as Rust, because that spatial model is just reflecting how your CPU actually works under the hood. If you try to hide that away, the programmer is going to end up losing some control.

Comment · 3 years ago
On the other hand though, it brings symmetry to types and values, and makes destructuring feel natural.

  let i: i32 = 1;
  let &i: &i32 = &1;
  let &mut i: &mut i32 = &mut 1;
  let (i, &mut j): (i32, &mut i32) = (1, &mut 2);
I'm not sure how you'd recreate this symmetry without using the same symbol in both places.
Comment · 3 years ago
When I was a kid I had a toy electronics kit and one of the circuits was an AM radio that worked without batteries. A normal radio station signal is strong enough to drive a pair of earbuds without any additional power. Since then I've always wondered if you could harvest that same radio energy to power other things without batteries, maybe even a Game Boy. There's electromagnetic radiation in the air all around us. And I'm sure you could build a Game Boy using today's tech that's much more power efficient than the ones from the 90s.
Comment · 3 years ago
You mean due process? Sounds great, sign me up!
Comment · 3 years ago
If you want compact, use an array of tuples:

  const foos = [("foo", 1, "bar"), ("foo", 1, "bar"), ...];
  for (str1, num, str2) in &foos {
      // ...
  }
For a proper struct you have to name the fields, because otherwise refactoring the fields could cause struct instances to silently get out of sync with the definition.
Comment · 3 years ago
This is megabytes (at most) of text we're talking about, not gigabytes. And ripgrep is absurdly fast. Grepping a 5MB text file should be pretty much instantaneous.
Comment · 3 years ago
> discord has a search feature, but it’s pretty awful

Their search makes me want to pull my hair out.

Why can't I just search the history with grep? That's a feature I would pay for (if anyone at Discord is reading this and wants my $10/month)

Comment · 3 years ago
Comment · 3 years ago
How about a nice game of chess?
Comment · 3 years ago
Comment · 3 years ago
> we are not yet at the point where a voice can be mimicked accurately from a voicemail or a clip on social media

See: https://www.thestar.com/business/technology/2023/01/10/micro...

> Microsoft’s new AI can mimic any voice after just 3 seconds

Play the result over a low-bandwidth PTSN line and it could probably fool people in tech, let alone your grandma. Welcome to the future.

Comment · 3 years ago
The word "fraud" has really lost its punch these last couple years. OpenAI has actual, working products that people think are valuable enough to pay for. The name is misleading, sure, but that doesn't make them a fraudulent company.

Is there a word for the opposite of the euphemism treadmill, where people call ordinary things by worse and worse names trying to get an emotional reaction out of people?

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton