Merge pull request #148 from atilaneves/issue138
Fix issue #138: Make sure that RequestKind.addImport carries on analysin...
This commit is contained in:
commit
acbe6e26aa
2
client.d
2
client.d
|
@ -225,6 +225,8 @@ AutocompleteResponse getResponse(TcpSocket socket)
|
|||
auto bytesReceived = socket.receive(buffer);
|
||||
if (bytesReceived == Socket.ERROR)
|
||||
throw new Exception("Incorrect number of bytes received");
|
||||
if (bytesReceived == 0)
|
||||
throw new Exception("Server closed the connection, 0 bytes received");
|
||||
AutocompleteResponse response;
|
||||
msgpack.unpack(buffer[0..bytesReceived], response);
|
||||
return response;
|
||||
|
|
2
server.d
2
server.d
|
@ -157,7 +157,7 @@ int main(string[] args)
|
|||
}
|
||||
if (request.kind & RequestKind.addImport)
|
||||
ModuleCache.addImportPaths(request.importPaths);
|
||||
else if (request.kind & RequestKind.autocomplete)
|
||||
if (request.kind & RequestKind.autocomplete)
|
||||
{
|
||||
Log.info("Getting completions");
|
||||
AutocompleteResponse response = complete(request);
|
||||
|
|
Loading…
Reference in New Issue