title: Unichar variable in Swift
body: <p>How to define a <code>unichar</code> type variable in Swift likes <code>'\0'</code> <code>'\n'</code> in Objective-C ?</p>
  
  <p>In Swift,</p>
  
  <pre><code>func previousCharacter() -&gt; unichar {
      return "\n"     //Error
  }
  </code></pre>
  
  <p>Compiler gave me an error:</p>
  
  <blockquote>
    <p>Cannot convert return expression of type 'String' to expected return type 'unichar'</p>
  </blockquote>
  
  <p>But in Objective-C, it will more easy to do this directly.</p>