| Commit message (Collapse) | Author | Age | Files | Lines |
| |
|
|
|
|
| |
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
|
| |
|