Skip to content

tracking issue for bugs fixed by the MIR borrow checker or NLL #47366

Closed

Description

@nikomatsakis

Part of: #43234

The MIR-based borrow checker used by NLL fixes a number of bugs in the existing AST-based borrow checker. Our plan for these bugs is to fix them by transitioning to the MIR-based borrow checker. In the meantime, we wish to add tests that show that the bugs are fixed with NLL, and then close the bugs (so they don't clutter up the issue tracker). This issue tracks the set of such bugs and gives instructions for how to proceed.

Bugs fixed by MIR

All these bugs are confirmed as fixed; the checkmark indicates that a PR with a test is enqueued or landed.

Procedure

  • First, if you wish, add yourself to the list of participants for the WG-compiler-nll working group.
    • This will help us to find people who might like to help later!
  • Create a regression test in src/test/ui/nll/
    • The name can be issue-XXX.rs, though giving a more descriptive name is also good
    • The file should include a comment saying // Regression test for #XXX however to ease searching later
  • This test should include the error from the bug along with the following header material:
    • Rust license
    • #![feature(nll)] at the top
    • comments like //~ ERROR for the errors, or whatever is needed for test harness to pass
  • Run ./x.py test --stage 1 src/test/ui --test-args nll, this will test all the nll tests (including yours)
  • Presuming that passes, open a PR! Otherwise, stop in at the WG-compiler-nll gitter channel
    • Put r? @nikomatsakis in the PR summary

Activity

  1. added
    E-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.
    T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.
    on Jan 11, 2018
  2. added this to the milestone on Jan 11, 2018
  3. chrisvittal commented on Jan 11, 2018

    @chrisvittal
    Contributor

    I'll take this. Looks straightforward.

  4. added a commit that references this issue on Jan 11, 2018
    76cf279
  5. nikomatsakis commented on Jan 14, 2018

    @nikomatsakis
    ContributorAuthor

    Added #45045 to the list.

  6. nikomatsakis commented on Jan 16, 2018

    @nikomatsakis
    ContributorAuthor

    This isn't meant to be closed but rather kept open as a record of the issues involved. =)

  7. nikomatsakis commented on Jan 16, 2018

    @nikomatsakis
    ContributorAuthor

    Added #46314 to the list

  8. changed the title [-]add tests for bugs fixed by the MIR borrow checker[/-] [+]tracking issue for bugs fixed by the MIR borrow checker[/+] on Jan 16, 2018
  9. added 2 commits that reference this issue on Jan 17, 2018
  10. nikomatsakis commented on Jan 17, 2018

    @nikomatsakis
    ContributorAuthor

    Added #47053, though I think that it will be handled in #47425

  11. 3 remaining items

  12. sapphire-arches commented on Feb 19, 2018

    @sapphire-arches
    Contributor

    Added #16223

  13. added
    C-bugCategory: This is a bug.
    C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFC
    on Apr 17, 2018
  14. added a commit that references this issue on Aug 17, 2018
  15. acrrd commented on May 4, 2019

    @acrrd
    Contributor

    The test for #48238 has been added in #49295.
    The test for #27868 has been added in #53326.
    The test for #16223 (that appears two times in the list) has been added in #49781.

  16. added 4 commits that reference this issue on Sep 26, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    A-NLLArea: Non-lexical lifetimes (NLL)C-bugCategory: This is a bug.C-tracking-issueCategory: An issue tracking the progress of sth. like the implementation of an RFCE-mentorCall for participation: This issue has a mentor. Use #t-compiler/help on Zulip for discussion.T-compilerRelevant to the compiler team, which will review and decide on the PR/issue.fixed-by-NLLBugs fixed, but only when NLL is enabled.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions