r/transprogrammer • u/definitelynotagirl99 • Jul 20 '24
Implementing exceptions
Just wanna know if anyone knows a more time-efficient way of implementing exceptions in a language than this or sees any issues with this design :3

handlethrow would exist separately for each try-catch clause
(obv this will only work for x86 but smth similar should work for all major architectures)
15
Upvotes
View all comments
Show parent comment
2
u/definitelynotagirl99 Jul 21 '24
i mean, i could definitely make it so that if a function throws a type that isn't specified by either its signature or a docstring it just emits a warning, but it might not even matter since ppl are just gonna disable that warning.
I feel like ultimately this boils down to a sort of "can't fix stupid" situation, if ppl wanna write shitty code they're gonna write shitty code and there isn't a whole lot that can be done about it.
edit: grammar