| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
| |
This is both recognized and unrecognized protocol kinds.
|
| | |
|
| | |
|
| |
|
|
| |
We don't need to open-code this any more.
|
| |
|
|
| |
This makes the interning more natural.
|
| | |
|
| |
|
|
| |
Removed unnecessary lint
|
| |
|
|
| |
We'll want this for the flow-control line in hsdescs.
|
| |
|
|
| |
The patch looks complicated, but this is just code movement.
|
| |
|
|
|
|
|
|
|
|
| |
Instead of doing an O(n) check every time we add an unrecognized
protocol, we just scan the list of unrecognized protocols
after we sort them.
Closes #2601.
Resolves TROVE-2026-027.
|
| |
|
|
|
| |
See torspec!519. This is actually not legal and already rejected, the
docs are just wrong.
|
| |
|
|
| |
Let's leave this untouched for now as it is not urgent right now.
|
| |
|
|
|
| |
This commit modifies the codebase to actually return Intern<T> in
InternCache<T> and adds calls to .into() accordingly.
|
| | |
|
| |
|
|
|
|
|
|
| |
This commit adds #[allow(clippy::string_slice)] to all functions in the
code where string slices are used, alongside a TODO comment.
We do this add the function header to have it consistent, as things like
expression based allow's are still experimental.
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This commit executes maint/add_warning with the just added change to
deny string slices except in tests.
I recommend auditing this by checking out the previous commit followed
by running the script yourself and then verifying that the diff is
identical to this commit.
This commit makes cargo clippy fail. We will add exceptions in the next
commit.
|
| |
|
|
|
|
|
|
|
| |
`clippy::collapsible_if` started triggering after bumping the MSRV to
1.88.
Since this triggers from a lot of places, and since there even are a
couple of instances where we explicitly allow `clippy::collapsible_ifs`,
I've opened #2342 for deciding what to do about it.
|
| |
|
|
| |
This adds the lint to all our crates.
|
| | |
|
| |
|
|
|
| |
This will help us with all the places we want to copy around
Protocols objects.
|
| |
|
|
| |
This will help us make it self-interning.
|
| | |
|
| |
|
|
| |
Run maint/add_warning
|
| |
|
|
| |
This feature has been removed from nightly, in favor of doc_cfg.
|
| |
|
|
|
| |
This breaks the syntax highlighting in vim for some reason and makes the
file unreadable for me.
|
| |
|
|
| |
See #2060.
|
| |
|
|
|
| |
This type differs from `NamedSubver` in that the represented
subprotocol capability isn't necessarily recognized or valid.
|
| |
|
|
|
| |
It is not remotely close to exhausting a u8,
and several of our protocols expect it to be expressible as one.
|
| | |
|
| |
|
|
| |
This rule makes PartialEq more sensible.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Part of #1849.
Note that these functions are distributed across crates,
so that if (in the future) we stop doing API breaks
with every release, we will get the right outputs.
Note also that these functions build the list of protocols
out of specific symbolic features, rather than numbers:
this makes it easier to avoid errors about "which feature was
Relay=4 again", and easier to avoid accidentally referring to a
protocol that doesn't exist, like "Consensus" (should be "Cons")
or "HsDir" (case is wrong).
|
| |
|
|
| |
Closes #1923
|
| | |
|
| |
|
|
|
|
|
|
| |
We have places where, if we were to create certain ProtoKinds
or NamedProtos with invalid values, we could cause a panic.
This isn't remotely triggerable, or even triggerable from outside
the protover crate, but it's best to avoid the possibility
of future mistakes.
|
| |
|
|
|
| |
This will be helpful in building a list of protocols
from several crates.
|
| |
|
|
|
| |
This will be helpful in building a list of protocols
from several crates.
|
| |
|
|
|
| |
This will be helpful in checking whether a list of protocols
has any unsupported members.
|
| |
|
|
|
|
|
|
| |
It's error-prone to have to remember e.g. that "Desc=5"
means "family ID support", so in torspec!251 we added mnemonic names
like DESC_FAMILY_IDS.
Here we use those names in tor-protover.
|
| | |
|
| |
|
|
|
|
| |
Denies 'mod.rs' files for consistency.
https://rust-lang.github.io/rust-clippy/master/index.html#mod_module_files
|
| |
|
|
|
|
|
|
| |
In 1.83, this warning triggers on many of our crates.
We're thinking of fixing them all, but for now,
we're going to disable the warning.
This is part of #1765.
|
| |
|
|
| |
This commit is automatically generated.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
Closes #950.
|