this post was submitted on 14 Aug 2023
219 points (93.6% liked)

Programmer Humor

32825 readers
147 users here now

Post funny things about programming here! (Or just rant about your favourite programming language.)

Rules:

founded 5 years ago
MODERATORS
 
all 5 comments
sorted by: hot top controversial new old
[–] [email protected] 5 points 1 year ago

That's what I love about Rust: many problems that would turn into runtime errors in other languages aren't possible with its type system and the compiler catches them.

[–] [email protected] 3 points 1 year ago* (last edited 1 year ago)

You get a bit numb to this when working on old code (10+ years), you know there's plenty crash bugs and logic bugs in the code and you know you will introduce a few of them while fixing bugs and adding new features.

The only thing that can give comfort is automated tests and plenty of them! Unit, integration and especially system level for old code.

Good companies priotize this, and can refactor code without breaking too much, other companies learn to live with the bugs breathing down their necks.

[–] [email protected] 2 points 1 year ago

That's my secret, I never run the code. That's the testers' problem.

[–] [email protected] 1 points 1 year ago

No syntax errors here, boss.

// Mr. Incredible happy
x += (new Date()).getSeconds()

// Mr. Incredible despair
x /= (new Date()).getSeconds()