[tor-bugs] #27844 [Core Tor/Tor]: rerun rustfmt

Tor Bug Tracker & Wiki blackhole at torproject.org
Tue Oct 16 23:22:01 UTC 2018


#27844: rerun rustfmt
--------------------------+------------------------------------
 Reporter:  cyberpunks    |          Owner:  (none)
     Type:  defect        |         Status:  needs_information
 Priority:  Medium        |      Milestone:  Tor: unspecified
Component:  Core Tor/Tor  |        Version:  Tor: 0.3.5.1-alpha
 Severity:  Normal        |     Resolution:
 Keywords:  rust          |  Actual Points:
Parent ID:                |         Points:
 Reviewer:  catalyst      |        Sponsor:
--------------------------+------------------------------------
Changes (by catalyst):

 * status:  needs_review => needs_information


Comment:

 I get this additional diff when running `make rustfmt` on the pull
 request.  Any ideas why the discrepancy is there?  Is this just version
 skew given a newer rustfmt?

 {{{
 diff --git a/src/rust/protover/protoset.rs b/src/rust/protover/protoset.rs
 index 3bfa781..5b2367b 100644
 --- a/src/rust/protover/protoset.rs
 +++ b/src/rust/protover/protoset.rs
 @@ -273,8 +273,8 @@ impl ProtoSet {
              let excluded_ranges = other
                  .iter()
                  .cloned() // have to be owned tuples, to match
 iter::once(the_end).
 -                .skip_while(move|&(_, hi2)| hi2 < lo) // skip the non-
 overlapping ranges.
 -                .take_while(move|&(lo2, _)| lo2 <= hi) // take all the
 overlapping ones.
 +                .skip_while(move |&(_, hi2)| hi2 < lo) // skip the non-
 overlapping ranges.
 +                .take_while(move |&(lo2, _)| lo2 <= hi) // take all the
 overlapping ones.
                  .chain(iter::once(the_end));

              let mut nextlo = lo;
 }}}

--
Ticket URL: <https://trac.torproject.org/projects/tor/ticket/27844#comment:6>
Tor Bug Tracker & Wiki <https://trac.torproject.org/>
The Tor Project: anonymity online


More information about the tor-bugs mailing list