RLovelett / langserver-swift

A Swift implementation of the open Language Server Protocol.
Apache License 2.0
177 stars 16 forks source link

FileHandle#waitForDataInBackgroundAndNotify is not implemented on Linux #46

Closed RLovelett closed 6 years ago

RLovelett commented 6 years ago

The original run loop which is watching standard input for incoming text does not work on Linux. The reason is that the function is marked NSUnimplemented(). I did attempt a patch to swift-corelibs-foundation to implement waitForDataInBackgroundAndNotify.

Unfortunately, there are other issues with the run loop as implemented e.g., https://github.com/RLovelett/vscode-swift/issues/36.

I felt the best solution was just switch to using DispatchIO to watch standard input on a well defined run loop.

Fixes issue #41