1. 30 1月, 2015 3 次提交
    • B
      Auto merge of #21692 - pnkfelix:fsk-fix-coerce-match-20055, r=eddyb · 52c74e63
      bors 提交于
      trans: When coercing to `Box<Trait>` or `Box<[T]>`, leave datum in it's original L-/R-value state.
      
      This fixes a subtle issue where temporaries were being allocated (but not necessarily initialized) to the (parent) terminating scope of a match expression; in particular, the code to zero out the temporary emitted by `datum.store_to` is only attached to the particular match-arm for that temporary, but when going down other arms of the match expression, the temporary may falsely appear to have been initialized, depending on what the stack held at that location, and thus may have its destructor erroneously run at the end of the terminating scope.
      
      FIx #20055.
      
      (There may be a latent bug still remaining in `fn into_fat_ptr`, but I am so annoyed by the test/run-pass/coerce_match.rs failures that I want to land this now.)
      52c74e63
    • B
      Auto merge of #21691 - edwardw:double-closure, r=nikomatsakis · 7ea93abf
      bors 提交于
      It was considered to be impossible but actually it can
      happen for nested closures. Also, because there must
      be nested closures when this happens, we can use more
      targeted help message.
      
      Closes #21390
      Closes #21600
      7ea93abf
    • B
      Auto merge of #21677 - japaric:no-range, r=alexcrichton · 265a2332
      bors 提交于
      Note: Do not merge until we get a newer snapshot that includes #21374
      
      There was some type inference fallout (see 4th commit) because type inference with `a..b` is not as good as with `range(a, b)` (see #21672).
      
      r? @alexcrichton 
      265a2332
  2. 29 1月, 2015 28 次提交
  3. 28 1月, 2015 9 次提交