title: swift 4.2 crash on NSAttributedString.Key.writingDirection
body: <p>I have this code in my iOS app:</p>
  
  <pre><code>let subAttr: [NSAttributedString.Key : Any] = [NSAttributedString.Key.font : font,
                                                     NSAttributedString.Key.foregroundColor : color,
                                                     NSAttributedString.Key.writingDirection : NSWritingDirection.leftToRight]
  </code></pre>
  
  <p>This is causing a crash:</p>
  
  <pre><code>2019-01-24 18:12:04.425440+0300 Haraj[5461:1355738] -[_SwiftValue count]: unrecognized selector sent to instance 0x281c752f0
  2019-01-24 18:12:04.425619+0300 Haraj[5461:1355738] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[_SwiftValue count]: unrecognized selector sent to instance 0x281c752f0'
  *** First throw call stack:
  (0x1f5327ef8 0x1f44f5a40 0x1f523f154 0x1f532d810 0x1f532f4bc 0x1f525b954 0x1f90f5e3c 0x1f90f5cf4 0x1f9049030 0x1f9048fb8 0x1f9003050 0x1f9016e28 0x1f9016b6c 0x1f9004070 0x1ff8d7e2c 0x1ff956e38 0x1ff8dc0b0 0x221be3e24 0x221be446c 0x222536c4c 0x22253740c 0x222537068 0x222541210 0x221be38f0 0x22253fd50 0x222540200 0x2225400d4 0x1f5cc551c 0x22254045c 0x2225400d4 0x2225409a4 0x2225405c4 0x2225415e4 0x2225e7e90 0x2225fbfa8 0x1f9909a34 0x1f990e9c4 0x2225e7430 0x2225edfe0 0x22237e130 0x22237e478 0x222349bfc 0x222367ae8 0x2225fbf44 0x1f9909a34 0x1f990e9c4 0x2225e7430 0x221b019bc 0x221afc0b0 0x221afa280 0x2225b7314 0x2225b75d0 0x2225c5490 0x2225c0ecc 0x2225b7058 0x221b027cc 0x221b02da8 0x221b040a8 0x221ae6298 0x2225fbf44 0x1f9909a34 0x1f990e9c4 0x1f986d9d4 0x1f989c2f4 0x222181bf4 0x1f52b5b94 0x1f52b0828 0x1f52b0dc8 0x1f52b05b8 0x1f7524584 0x222158bc8 0x10257be3c 0x1f4d70b94)
  libc++abi.dylib: terminating with uncaught exception of type NSException
  (lldb) po 0x281c752f0
  __C.NSWritingDirection
  
  (lldb) 
  </code></pre>
  
  <p>This was working fine in <code>Swift 3</code> but I recently migrated to <code>Swift 4.2</code>. Any help? </p>