Commits
Chris Lattner committed f3ed7e93e14
Completely redesign our AST representation of capturelists. Formerly, a capture list hung off the CaptureExpr it was associated with. This made sense lexically (since a capture list is nested inside of the closure) but not semantically. Semantically, the capture list initializers are evaluated outside the closure, the variables are bound to those values, then the closure captures the newly bound values. To directly represent this, represent captures with a new CaptureListExpr node, which contains the ClosureExpr inside of it. This correctly models the semantic relationship, and makes sure that AST walkers all process the initializers of the capture list as being *outside* of the closure. This fixes rdar://19146761 and probably others. Swift SVN r23756