diff options
| author | David Wood <david@davidtw.co> | 2018-11-03 16:54:35 +0100 |
|---|---|---|
| committer | David Wood <david@davidtw.co> | 2018-11-03 18:14:21 +0100 |
| commit | a4e094562122d9839a9b247ace2be3c4b3724b47 (patch) | |
| tree | 012801fb234f5dcd79c5ccf2e52d8c062088b599 /src/libstd/thread | |
| parent | 87a3c1ee7016bbfb782f2fd8adc75b46687ef929 (diff) | |
| download | rust-a4e094562122d9839a9b247ace2be3c4b3724b47.tar.gz rust-a4e094562122d9839a9b247ace2be3c4b3724b47.zip | |
Unions reinitialized after assignment into field.
This commit makes two changes: First, it updates the dataflow builder to add an init for the place containing a union if there is an assignment into the field of that union. Second, it stops a "use of uninitialized" error occuring when there is an assignment into the field of an uninitialized union that was previously initialized. Making this assignment would re-initialize the union, as tested in `src/test/ui/borrowck/borrowck-union-move-assign.nll.stderr`. The check for previous initialization ensures that we do not start supporting partial initialization yet (cc #21232, #54499, #54986).
Diffstat (limited to 'src/libstd/thread')
0 files changed, 0 insertions, 0 deletions
