top | item 45973944 (no title) sayrer | 3 months ago Yes, can't have .unwrap() in production code (it's ok in tests) discuss order hn newest orphea|3 months ago Like goto, unwrap is just a tool that has its use cases. No need to make a boogeyman out of it. gishh|3 months ago To be fair, if you’re not “this tall” you really shouldn’t consider using goto in a c program. Most people aren’t that tall. load replies (1) metaltyphoon|3 months ago Yes it's meant to be used in test code. If you're sure it can't fail do then use .expect() that way it shows you made a choice and it wasn't just a dev oversight. fwjafwasd|3 months ago panicans should be using .expect() in production keyle|3 months ago unwrap itself isn't the problem...
orphea|3 months ago Like goto, unwrap is just a tool that has its use cases. No need to make a boogeyman out of it. gishh|3 months ago To be fair, if you’re not “this tall” you really shouldn’t consider using goto in a c program. Most people aren’t that tall. load replies (1) metaltyphoon|3 months ago Yes it's meant to be used in test code. If you're sure it can't fail do then use .expect() that way it shows you made a choice and it wasn't just a dev oversight. fwjafwasd|3 months ago panicans should be using .expect() in production
gishh|3 months ago To be fair, if you’re not “this tall” you really shouldn’t consider using goto in a c program. Most people aren’t that tall. load replies (1)
metaltyphoon|3 months ago Yes it's meant to be used in test code. If you're sure it can't fail do then use .expect() that way it shows you made a choice and it wasn't just a dev oversight.
orphea|3 months ago
gishh|3 months ago
metaltyphoon|3 months ago
fwjafwasd|3 months ago
keyle|3 months ago