title: Why am I getting the error "Cannot assign to the result of this expression" when checking for the class of a sender?
body: <p>I am trying to make a function that will check the class of the sender and act accordingly but for some reason I get the error "Cannot assign to the result of this expression" with the first condition. Can anyone enlighten me on what I'm doing wrong? The error appears on the <code>clipToBounds</code> line.
   Here's the code:</p>
  
  <pre><code>func setupContactIcons(sender: AnyObject?) {
          if (sender!.isKindOfClass(UIVisualEffectView)) {
          sender!.layer.cornerRadius = sender!.frame.size.width/2
          sender!.clipsToBounds = true
          }
      }
  </code></pre>
  
  <p>Bonus: Is there a better way of doing this?</p>