| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
|
|
|
|
|
|
| |
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.
|
| |
|
|
|
|
|
|
|
|
|
| |
When the circ-padding feature is enabled, we use maybenot, which does
not yet support rand 0.10. In the meantime, enabling this feature pulls
in rand 0.9. This is not ideal, but should be okay as a temporary
situation.
This also replaces the use of ReseedingRng (which was removed in 0.10)
with the reseeding_rng crate. This is somewhat less performant, but it
should be okay.
|
| | |
|
| | |
|
| |
|
|
| |
Run maint/add_warning
|
| |
|
|
| |
Made with https://crates.io/crates/typos-cli
|
| | |
|
| |
|
|
| |
- The Rng::gen() functions have been renamed to Rng::random().
|
| |
|
|
|
| |
This took a little refactoring, since derive_more::Foo
no longer re-exports std::ops::Foo.
|
| |\
| |
| |
| |
| | |
memquota: Fix account lifetime bugs, and arrange to test mq in shadow
See merge request tpo/core/arti!2560
|
| | | |
|
| |/ |
|
| |
|
|
|
|
| |
The `derive_more` crate broke backward compatibility with this version,
so this change involved quite a few manual fixups.
With luck, they'll keep compatibility for some while in the future.
|
| |
|
|
|
|
| |
This detect possibly-panicking operations.
Empirically this lint seems rather better now.
|
| | |
|
| |
|
|
|
|
| |
It is not locally obvious that n_particips can't be zero, here.
Certainly if it *is* that would be state corruption, but I don't think
I can quite rule it out in the presence of a bug somewhere else.
|
| | |
|
| |
|
|
| |
I realised a way this could happen without there being a bug.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Allow a `Config` to represent "this is supposed to be disabled".
This involves wrapping the actual built configuration in an IfEnabled.
We treat max = usize::MAX, or max being unspecified, as "disable".
We can now reporting an error during config building if max is set but
we're compiling the feature out. Conversely, we can now make
`MemoryQuotaTracker::new()` unconditional, since enabled
confiogurations are uninhabited when the feature is compiled out.
We change how we derive the setters, deriving them from the Builder.
I chose to abolish the use of derive_builder. See the new comment on
ConfigBuilder.
|
| | |
|
| |
|
|
| |
Code motion of byte_qty.rs, and minimal necessary supporting changes.
|
| |
|
|
|
|
|
| |
This will hopefully allow much caller code to be compiled out.
The users (IsParticipant impls) don't generally need to bother with
it - they can just ignore it.
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
Wrap up most of the structures in IfEnabled.
Sadly this diff is very noisy. I experimented with macros for the
little enabled check at the start of each function but they didn't
really help.
We don't test this yet. We'll do a smoke test of this later.
|
| |
|
|
| |
This will make some later diffs easier to read.
|
| |
|
|
|
| |
As per
https://gitlab.torproject.org/tpo/core/arti/-/merge_requests/2292#note_3059520
|
| | |
|
| |\
| |
| |
| |
| | |
tor-memquota: HasMemoryCost trait, and type-safe methods
See merge request tpo/core/arti!2282
|
| | | |
|
| | | |
|
| | |
| |
| |
| |
| | |
Now the constructor is able to return other data to the caller,
passing it through the mtracker machinery.
|
| | |
| |
| |
| | |
The stream wrapper is going to want this.
|
| |/
|
|
|
| |
There is no `p_used` here; what we meant was the very same
`ClaimedQty.`
|
| |
|
|
|
|
|
|
|
|
|
| |
* Change `pub` to `export`
* Change the `=` in define to `:`
* Change `pub_template_semver_check` to `template_export_semver_check`
Right now, 0.12.1 supports both syntaxes. I have verified this branch
also compiles with
https://gitlab.torproject.org/Diziet/rust-derive-deftly/-/merge_requests/402
ee171ffaf56d7dcb7d75584054921153fe19b222
|
| |
|