Skip to content

Commit

Permalink
Minor type cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
jacobdufault authored and MaskRay committed Oct 24, 2019
1 parent b110f0f commit 98090c5
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 11 deletions.
1 change: 0 additions & 1 deletion src/command_line.cc
Original file line number Diff line number Diff line change
Expand Up @@ -306,7 +306,6 @@ void LaunchStdinLoop(Config* config,
MethodType method_type = message->GetMethodType();
(*request_times)[method_type] = Timer();

LOG_S(ERROR) << "!! Got message of type " << method_type;
queue->for_querydb.PushBack(std::move(message));

// If the message was to exit then querydb will take care of the actual
Expand Down
10 changes: 5 additions & 5 deletions src/method.cc
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
#include "method.h"

const char* kMethodType_Unknown = "$unknown";
const char* kMethodType_Exit = "exit";
const char* kMethodType_TextDocumentPublishDiagnostics = "textDocument/publishDiagnostics";
const char* kMethodType_CqueryPublishInactiveRegions = "$cquery/publishInactiveRegions";
const char* kMethodType_CqueryPublishSemanticHighlighting = "$cquery/publishSemanticHighlighting";
MethodType kMethodType_Unknown = "$unknown";
MethodType kMethodType_Exit = "exit";
MethodType kMethodType_TextDocumentPublishDiagnostics = "textDocument/publishDiagnostics";
MethodType kMethodType_CqueryPublishInactiveRegions = "$cquery/publishInactiveRegions";
MethodType kMethodType_CqueryPublishSemanticHighlighting = "$cquery/publishSemanticHighlighting";

InMessage::~InMessage() = default;

Expand Down
10 changes: 5 additions & 5 deletions src/method.h
Original file line number Diff line number Diff line change
Expand Up @@ -6,11 +6,11 @@
#include <string>

using MethodType = std::string;
extern const char* kMethodType_Unknown;
extern const char* kMethodType_Exit;
extern const char* kMethodType_TextDocumentPublishDiagnostics;
extern const char* kMethodType_CqueryPublishInactiveRegions;
extern const char* kMethodType_CqueryPublishSemanticHighlighting;
extern MethodType kMethodType_Unknown;
extern MethodType kMethodType_Exit;
extern MethodType kMethodType_TextDocumentPublishDiagnostics;
extern MethodType kMethodType_CqueryPublishInactiveRegions;
extern MethodType kMethodType_CqueryPublishSemanticHighlighting;

using lsRequestId = std::variant<std::monostate, int64_t, std::string>;

Expand Down

0 comments on commit 98090c5

Please sign in to comment.