]> git.lizzy.rs Git - rust.git/commit
Conservatively assume dropping a generator touches its upvars, via locals' dtors.
authorFelix S. Klock II <pnkfelix@pnkfx.org>
Fri, 13 Apr 2018 15:11:53 +0000 (17:11 +0200)
committerFelix S. Klock II <pnkfelix@pnkfx.org>
Tue, 1 May 2018 20:28:54 +0000 (22:28 +0200)
commitedb8d1c0d4b2e32088f3c6a77437b091b10ddf7e
tree004215cfb42495e6a8e8fea5ff93889140f90d50
parent4d7bbdd82682b0c4891538b241f7fe584f148710
Conservatively assume dropping a generator touches its upvars, via locals' dtors.

This is meant to address rust-lang/rust#49918.

Review feedback: put back comment justifying skipping interior traversal.

Review feedback: dropck generators like trait objects: all their upvars must
outlive the generator itself, so just create a DtorckConstraint saying so.
src/librustc_traits/dropck_outlives.rs