Y
Hacker News
new
|
ask
|
show
|
jobs
by
edflsafoiewq
2528 days ago
There's nothing wrong with unwrap. It's just an assert. Even a[i] is just shorthand for a.get(i).unwrap(). Asserts are definitely appropriate in production code, just not for handling run-time errors.