449
To type or not to type ? (sh.itjust.works)
you are viewing a single comment's thread
view the rest of the comments
[-] darcy@sh.itjust.works 1 points 1 year ago* (last edited 1 year ago)

i mean, at least with rust, running in debug mode (or release with flags) will hard panic if an overflow occurs, bc it checks everytime a number is changed. it is obviously less performant to do this, so it does not check when running in release/production mode. the problem is if you need to have no overflows occur, it is better to throw an error and exit the program, than cause unexpected behaviour, eg. as an incorrect, but existing array item. this could be hard to find the cause of the bug if it doesnt throw

[-] bioemerl@kbin.social 2 points 1 year ago

I'm a C# dev so I forget that anything that's not this case even exists. Agreed 100 percent.

this post was submitted on 13 Jul 2023
449 points (98.3% liked)

Programmer Humor

32443 readers
860 users here now

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

Rules:

founded 5 years ago
MODERATORS