design
design copied to clipboard
Never use try()
Because of the weird type-instability. Almost always clearer to use tryCatch().
Except in examples? I.e. use it for the side effect of displaying an error without causing an error.
try() being used in examples, but not really being best practice otherwise should maybe be its own case study.
Another instance of this is the frequent use of require() in examples, which often causes people to use it outside of examples inappropriately.
"When your system for showing realistic usage requires that you show unrealistic usage, it's time to reflect."