title: Why is the weak self reference in the UIView animation closure causing a compilation error in Swift
body: <p>I'm getting a compile error when trying to use a weak reference in the UIView animation closure. Based upon other tutorials and Apple's documentation this should be valid.</p>
  
  <p><strong>Snippet</strong></p>
  
  <pre><code>UIView.animateKeyframesWithDuration(0.35, delay: 0.5, options: UIViewKeyframeAnimationOptions.CalculationModeCubicPaced, animations:{ [weak self] in
  
      UIView.addKeyframeWithRelativeStartTime(0, relativeDuration: 0, animations:{
  
          if let actualSelf = self {
              actualSelf.noPlayListsView.transform = CGAffineTransformScale(CGAffineTransformIdentity, 1.5, 1.5)
          }
      })
  
      UIView.addKeyframeWithRelativeStartTime(0, relativeDuration: 0, animations:{
  
          if let actualSelf = self {
              actualSelf.noPlayListsView.transform = CGAffineTransformScale(CGAffineTransformIdentity, 0.9, 0.9)
          }
      })
  
      UIView.addKeyframeWithRelativeStartTime(0, relativeDuration: 0, animations:{
  
          if let actualSelf = self {
              actualSelf.noPlayListsView.transform = CGAffineTransformIdentity
          }
      })
  }, completion:nil)
  </code></pre>