Skip to content

Commit f376dec

Browse files
authored
Merge pull request #36 from davidtwco/nll-working-group-template
Update NLL working group to match template.
2 parents ad0d284 + d48c978 commit f376dec

File tree

4 files changed

+109
-36
lines changed

4 files changed

+109
-36
lines changed

working-groups/.template/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ priority order:
8888

8989
Other NLL labels also exist:
9090

91-
- [**NLL-fixed-by-NLL**][NLL_fixed-by-NLL] labels bugs that are problems solely with the
91+
- [**NLL-fixed-by-NLL**][NLL-fixed-by-NLL] labels bugs that are problems solely with the
9292
AST-borrowck -- they are bugs that we intend to close once everyone migrates over to NLL.
9393
- [**NLL-polonius**][NLL-polonius] labels bugs related to the Polonius subproject - see the
9494
Polonius working group for more information on these.

working-groups/nll/FAQ.md

Lines changed: 5 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,7 @@
1-
# Frequently asked questions
2-
3-
## What is NLL?
4-
5-
XXX
6-
7-
## What is "migration mode"?
8-
9-
XXX
1+
# Frequently Asked Questions (FAQ)
2+
If you have a question, feel free to file an issue or ask in the working group's Zulip stream.
103

114
## What is the relationship to Polonius?
12-
13-
Polonius is an experimental, "next generation" NLL implementation,
14-
initially described in [this blog post][polonius]. Enabling the use of
15-
Polonius is **not** in scope for the NLL working group -- there will
16-
be a dedicated working group exploring that topic.
5+
Polonius is an experimental, "next generation" NLL implementation, initially described in
6+
[this blog post][polonius]. Enabling the use of Polonius is **not** in scope for the NLL working
7+
group -- see [the polonius working group][../polonius].

working-groups/nll/NOTES.md

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1-
Feburary 19, 2019
1+
# Non-Lexical Lifetimes (NLL) Meeting Notes
2+
This document contains meeting notes from the NLL working group.
3+
4+
## 2019-02-19:
25
- Agenda:
36
- Meta: What should this meeting be for?
47
- Sync-up regarding Place 2.0 ([#52708][])
58
- Status Updates (TBD)
69

7-
February 13, 2019
10+
## 2019-02-13:
811
- Status updates
912
- matthewjasper
1013
- Opened [#58347][] to fix issues around closures

working-groups/nll/README.md

Lines changed: 98 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,29 +1,108 @@
1-
# Scope and purpose
1+
# Non-Lexical Lifetimes (NLL) Working Group
2+
![working group status: winding down][status]
23

3-
The **nll** working group is working towards transitioning the
4-
compiler use a MIR-based borrow check that implements the initial
5-
non-lexical lifetimes proposal.
4+
This working group aims to implement non-lexical lifetimes (NLL), as described in RFC 2094:
65

7-
XXX add links to RFCs etc
6+
> Extend Rust's borrow system to support non-lexical lifetimes -- these are lifetimes that are
7+
> based on the control-flow graph, rather than lexical scopes. The RFC describes in detail how
8+
> to infer these new, more flexible regions, and also describes how to adjust our error messages.
9+
> The RFC also describes a few other extensions to the borrow checker, the total effect of which is
10+
> to eliminate many common cases where small, function-local code modifications would be required
11+
> to pass the borrow check.
812
9-
# Current status
13+
- **Leads:** [@nikomatsakis][nikomatsakis] and [@pnkfelix][pnkfelix]
14+
- **Meeting Notes:** [All](NOTES.md)
1015

11-
NLL has **landed** in the Rust 2018 edition and is currently in
12-
**migration** mode. The working group is currently working towards
13-
enabling NLL by default, for all editions, and in the full,
14-
non-migration mode. XXX say more here
16+
[status]: https://img.shields.io/badge/status-winding%20down-orange.svg?style=for-the-badge
1517

16-
# How to participate
18+
## Status
19+
NLL has **landed** in the Rust 2018 edition and is currently in **migration** mode. The working
20+
group is currently working towards enabling NLL by default, for all editions, and in the full,
21+
non-migration mode.
1722

18-
## Chat forum
23+
## What is the goal of this working group?
24+
This working group aims to accomplish the following:
1925

20-
On [the rust-lang Zulip][z], in [the `#t-compiler/wg-nll` stream][s].
26+
- Implement a new borrow checker based on the MIR that supports non-lexical lifetimes.
27+
- Handle the migration from the existing AST-based borrow checker.
2128

22-
[z]: https://rust-lang.zulipchat.com/
23-
[s]: https://rust-lang.zulipchat.com/#narrow/stream/122657-t-compiler.2Fwg-nll
29+
# How can I get involved?
30+
If you are interested in getting involved in this working group, you should try to attend a meeting and
31+
introduce yourself or send a message in the Zulip stream. You can be added to the GitHub and Zulip
32+
group for the working group if you are interested in being pinged when there are available tasks.
2433

25-
## Weekly triage meeting
34+
- **Desired experience level:** Any
35+
- **Relevant repositories:** [`rust-lang/rust`][repo] (specifically `src/librustc_mir/borrow_check`)
36+
- **Zulip stream:** [`#t-compiler/wg-nll`][zulip] on Zulip
2637

27-
There is a weekly triage meeting on Wednesdays at 15:30pm Boston time
28-
(UTC-05:00 presently). This meeting takes place on [Zulip][z] in a
29-
dedicated topic of the [the `#t-compiler/wg-nll` stream][s].
38+
[repo]: https://github.com/rust-lang/rust
39+
[zulip]: https://rust-lang.zulipchat.com/#narrow/stream/122657-t-compiler.2Fwg-nll
40+
41+
## What if I don't have much time?
42+
If you don't have time to contribute code, consider using `#![feature(nll)]` to help find bugs
43+
with NLL. If you do, we'd love it if you could file an issue.
44+
45+
## Are there any resources so I can get up to speed?
46+
There are some resources available for those interested in contributing to get some background
47+
and context:
48+
49+
- MIR is an intermediate representation used within the compiler. NLL is implemented as a new
50+
borrow checker implemented on the MIR. You can read about the MIR in
51+
the [relevant rustc-guide chapter](https://rust-lang.github.io/rustc-guide/mir/index.html).
52+
- You can read about the major phases and internals of the MIR borrow checker in
53+
it's [rustc-guide chapter](https://rust-lang.github.io/rustc-guide/borrow_check.html).
54+
- NLL was originally specified
55+
in [RFC 2094](https://github.com/rust-lang/rfcs/blob/master/text/2094-nll.md).
56+
- [@nikomatsakis][nikomatsakis]'s blog posts on NLL are also useful for getting familiar with the
57+
goals of NLL and some initial implementation ideas.
58+
* [Introduction][introduction], [NLL based on liveness][liveness] and
59+
[NLL adding the outlives relation][outlives].
60+
61+
[introduction]: http://smallcultfollowing.com/babysteps/blog/2016/04/27/non-lexical-lifetimes-introduction/
62+
[liveness]: http://smallcultfollowing.com/babysteps/blog/2016/05/04/non-lexical-lifetimes-based-on-liveness/
63+
[outlives]: http://smallcultfollowing.com/babysteps/blog/2016/05/09/non-lexical-lifetimes-adding-the-outlives-relation/
64+
65+
## Do I need to attend any meetings?
66+
The NLL working group meets regularly for triage and discussion of high priority issues - see
67+
the [compiler team meeting calendar](../README.md#meeting-calendar) for the most up to date
68+
time. Attendance is not mandatory but recommended as this can be a good opportunity to ask any
69+
questions and find new issues to work on.
70+
71+
## What do all these NLL labels mean?
72+
The NLL working group monitors the [**A-NLL**][A-NLL] label for issues relating to NLL.
73+
74+
The follow extra labels are used during the working group's prioritization and triage, in roughly
75+
priority order:
76+
77+
- [**NLL-sound**][NLL-sound] labels bugs around examples of code that is meant to be rejected by
78+
NLL. Usually such bugs are either ICE'ing or being erroneously accepted by NLL. *NLL-sound*
79+
things tend to be higher priority than *NLL-complete* things, at least at the moment.
80+
- [**NLL-performant**][NLL-performant] is for cases where NLL is causing *slow, slow, slow*
81+
compile times.
82+
- [**NLL-complete**][NLL-complete] labels bugs around examples of code that is meant to be
83+
accepted by NLL. Usually such bugs are either ICE'ing or being erroneously rejected by NLL.
84+
- [**NLL-reference**][NLL-reference] labels any issues relating to documenting NLL's behaviour
85+
into the language reference.
86+
- [**NLL-diagnostics**][NLL-diagnostics] labels cases where the diagnostics emitted by NLL
87+
specifcally needs improvement. Usually it is/was used for cases where NLL is a regresion
88+
w.r.t diagnostics when compared to AST-borrowck (but at this point its really more of a
89+
catch-all for any diagnostic issue originating from the NLL code base).
90+
91+
Other NLL labels also exist:
92+
93+
- [**NLL-fixed-by-NLL**][NLL-fixed-by-NLL] labels bugs that are problems solely with the
94+
AST-borrowck -- they are bugs that we intend to close once everyone migrates over to NLL.
95+
- [**NLL-polonius**][NLL-polonius] labels bugs related to the Polonius subproject - see the
96+
Polonius working group for more information on these.
97+
98+
[A-NLL]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3AA-NLL
99+
[NLL-sound]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-sound
100+
[NLL-performant]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-performant
101+
[NLL-complete]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-complete
102+
[NLL-reference]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-reference
103+
[NLL-diagnostics]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-diagnostics
104+
[NLL-fixed-by-NLL]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-fixed-by-NLL
105+
[NLL-polonius]: https://github.com/rust-lang/rust/issues?q=is%3Aissue+is%3Aopen+sort%3Aupdated-desc+label%3ANLL-polonius
106+
107+
[nikomatsakis]: https://github.com/nikomatsakis
108+
[pnkfelix]: https://github.com/pnkfelix

0 commit comments

Comments
 (0)