title: How to use Strings as Printables in Swift
body: <p>I'm trying to write a function that takes a parameter of type Printable:</p>
  
  <pre><code>func logMessage(message: Printable) {
      // ...
  }
  </code></pre>
  
  <p>Strangely, this doesn't work as expected when passing in Strings.</p>
  
  <p>This doesn't compile:</p>
  
  <pre><code>logMessage("some string \(someVariable)")
  
  // Neither does this:
  let aString = "aString"
  logMessage(aString)
  </code></pre>
  
  <p>This however compiles:</p>
  
  <pre><code>logMessage("A string")
  // This works too:
  let aString: Printable = "a string"
  logMessage(aString)
  </code></pre>
  
  <p>This is quite confusing. It seems that in some cases String implements Printable and in others not.</p>
  
  <p>In addition, it seems that string interpolation always produces a String that does not implement Printable. This crashes at runtime with a cast error:</p>
  
  <pre><code>let aString = "a string"
  let interpolatedString = "contains \(aString)"
  </code></pre>
  
  <p>Any idea what's going on here?</p>