diff options
author | Lars Wirzenius <liw@liw.fi> | 2021-09-29 10:03:15 +0300 |
---|---|---|
committer | Lars Wirzenius <liw@sequoia-pgp.org> | 2021-09-30 08:31:17 +0300 |
commit | c52c0b44f28c7a235002c77e8c27c32e8251e1e3 (patch) | |
tree | 1eebb82c6599eb5e3bcfd69a18ee941b04ba5c9c /clippy.toml | |
parent | b4b7e5197cff09f59fe92a4449b5d7c84d212457 (diff) |
Allow complex types without names
A complex type without a name tends to be harder to understand. We
have a few of them. Using "type" to give them a name would hopefully
help, but I don't understand the code well enough to come up with
meaningful names, and meaningless names won't help. Also, arguably, a
struct or enum would often be the better approach, but would change
the API. Thus, I'm only configuring clippy to allow complex types. We
should later revisit this and improve the code, when we're making
other API changes anyway.
Found by clippy lint type_complexity:
https://rust-lang.github.io/rust-clippy/master/index.html#type_complexity
Diffstat (limited to 'clippy.toml')
-rw-r--r-- | clippy.toml | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/clippy.toml b/clippy.toml index 0cd7b888..073c6d1f 100644 --- a/clippy.toml +++ b/clippy.toml @@ -3,4 +3,5 @@ #msrv = "1.48.0" enum-variant-size-threshold = 512 -too-many-arguments-threshold = 10
\ No newline at end of file +too-many-arguments-threshold = 10 +type-complexity-threshold = 500 |