Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lint std::panic::catch_unwind #1196

Closed
llogiq opened this issue Aug 27, 2016 · 1 comment
Closed

Lint std::panic::catch_unwind #1196

llogiq opened this issue Aug 27, 2016 · 1 comment
Labels
A-lint Area: New lints good-first-issue These issues are a good way to get started with Clippy T-AST Type: Requires working with the AST

Comments

@llogiq
Copy link
Contributor

llogiq commented Aug 27, 2016

This should only be used when one has no control over code that may panic, e.g. using integer division with unknown operands (although overflower should cover that, too). Otherwise, using a Result type should be the preferred way of dealing with errors.

@llogiq llogiq added good-first-issue These issues are a good way to get started with Clippy T-AST Type: Requires working with the AST A-lint Area: New lints labels Aug 27, 2016
@camsteffen
Copy link
Contributor

This can be done with disallowed_method. A dedicated lint would be restriction so I don't think that's any better.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-lint Area: New lints good-first-issue These issues are a good way to get started with Clippy T-AST Type: Requires working with the AST
Projects
None yet
Development

No branches or pull requests

3 participants