Ephera

joined 5 years ago
[–] Ephera@lemmy.ml 7 points 2 days ago

It's mainly horrid, because it means you have to code extremely defensively (or I guess, use a different API).
You can't rely on new Date("not a date") aborting execution of your function by throwing an error. Instead, you have to know that it can produce an Invalid Date object and check for that. Otherwise a random NaN shows up during execution, which is gonna be extremely fun to try to find the source of.

I understand that it's implemented like that partially for historical reasons, partially because it's often better to display "NaN" rather than nothing, but it's still the sort of behavior that puts me in a cold sweat, because I should be memorizing all kinds of Best Practices™ before trying to code JavaScript.

[–] Ephera@lemmy.ml 0 points 2 days ago

(saying something more realistic like “2015” or whatever your inexperience or AI told you to)

User input is probably the big one where this API is gonna get stress-tested...

[–] Ephera@lemmy.ml 7 points 2 days ago

Hmm, I can believe that it was based on java.util.Date, but I don't remember that being as unpredictable. I guess, a different API to begin with, would have avoided a lot of problems, though...

[–] Ephera@lemmy.ml 1 points 2 days ago
[–] Ephera@lemmy.ml 0 points 2 days ago

I'll let the hivemind know that we're supposed to have only one opinion.

[–] Ephera@lemmy.ml 25 points 2 days ago (8 children)

On a definitely related note, I've recently been thinking it's wild how we build foot paths out of rocks and then put on rubber socks for actually walking on them.

In other words, asphalt is a scam by Big Foot to sell more shoes.

[–] Ephera@lemmy.ml 8 points 2 days ago (3 children)

I imagine, they can still get inflamed gums or similar, if something gets stuck in there...

[–] Ephera@lemmy.ml 14 points 2 days ago (2 children)

I believe, you have to take turns pushing down individual teeth. By random chance, it will close the mouth when you do that. So, you lose when you get bitten.

[–] Ephera@lemmy.ml 8 points 2 days ago

I'm always amazed how badly companies understand the concept of human interaction. Showing appreciation requires putting in some amount of effort. If you just type some words into a box and an image comes out, that's not anything. Might as well use the first clipart that comes up in image search...

[–] Ephera@lemmy.ml 2 points 2 days ago (1 children)

I believe, you can basically turn it off in Firefox, by telling it to open new windows instead of tabs.

Might need to hide the tab bar via userChrome.css, though...

 

The rendered output looks like this:

It even sounds half-decent.

I would also like to congratulate German for having the most fucked up notation system, according to the LilyPond documentation. 🙃

Source code

 
 

If I'm interpreting this correctly, many MP4 patents are going to expire next year. 🎉

 
 
 
 

So, this uses a macro, but if you're thinking anything is possible with a macro, it's actually not in Rust. The input does still need to parse as valid Rust tokens.

Which means the authors asked themselves at some point: Is the Rust syntax a superset of the Python syntax?
And well, it's not. In particular, some Python keywords will just be tokenized as an identifier (like a variable name).

But it is close enough that the authors decided against requiring a massive string to be passed in, which does amuse me. 🙃

 

Vom Wikipedia-Artikel zur sprichwörtlichen Eintagsfliege: https://de.wikipedia.org/wiki/Eintagsfliege

 
 

We often talk about the climate impact based on greenhouse gases, but extracting fuel from the ground and using it in exothermal processes of course also releases energy as heat.

This is mostly¹ in contrast with renewables, which make use of energy that's not long-term contained to begin with, so would end up as heat in our atmosphere anyways.

So, my question is: Does the amount of energy released by non-renewables have any notable impact on our global temperature? Or would it easily radiate into space, if we solved the greenhouse gas problem?


¹) In the case of solar, putting up black surfaces does mean that less sunlight gets reflected, so more heat ultimately gets trapped in our atmosphere. There's probably other such cases, too.

 
view more: ‹ prev next ›