]> git.lizzy.rs Git - rust.git/commit
auto merge of #18672 : brandonson/rust/functional-update-walk, r=nikomatsakis
authorbors <bors@rust-lang.org>
Fri, 7 Nov 2014 07:16:33 +0000 (07:16 +0000)
committerbors <bors@rust-lang.org>
Fri, 7 Nov 2014 07:16:33 +0000 (07:16 +0000)
commita0a7ab461283322215f0343cd2b5e66fc19a7bd5
treeca291c865de18e4fb591399ad43169360f0640ee
parentb03a2755193cd756583bcf5831cf4545d75ecb8a
parentd80a62d84bc9fbc9ae7c8bd300bf5416249b51f7
auto merge of #18672 : brandonson/rust/functional-update-walk, r=nikomatsakis

Fixes #18567. `Struct{x:foo, .. with_expr}` did not walk `with_expr`, which allowed
using moved variables in some cases.  The CFG for structs also built up with
`with_expr` happening before the fields, which is now reversed. (Fields are now
before the `with_expr` in the CFG)
src/librustc/middle/cfg/construct.rs
src/librustc/middle/expr_use_visitor.rs