Skip to content

Disallow "partial" borrows of @mut  #4716

@nikomatsakis

Description

@nikomatsakis

Right now if you have an @mut data structure and you borrow a sub-field, you wind up freezing the whole box and its confusing. We should only permit you to borrow the whole @mut, which makes this particular error a bit harder to do.

Metadata

Metadata

Assignees

Labels

A-lifetimesArea: Lifetimes / regions

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions