Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make RangeInclusive just a two-field struct #42134

Merged
merged 2 commits into from
May 25, 2017

Commits on May 21, 2017

  1. Make RangeInclusive just a two-field struct

    Not being an enum improves ergonomics, especially since NonEmpty could be Empty.  It can still be iterable without an extra "done" bit by making the range have !(start <= end), which is even possible without changing the Step trait.
    
    Implements RFC 1980
    scottmcm committed May 21, 2017
    Configuration menu
    Copy the full SHA
    f166bd9 View commit details
    Browse the repository at this point in the history
  2. Return a correct size_hint for degenerate inclusive ranges

    Fixes rust-lang#42135
    
    Found while fixing run-pass/range_inclusive test failure.
    scottmcm committed May 21, 2017
    Configuration menu
    Copy the full SHA
    7eaca60 View commit details
    Browse the repository at this point in the history