Skip to content

Commit c0a11ef

Browse files
authored
Merge pull request #2084 from hzeller/20240129-rename-lsp
Rename verilog_ls.cc to the actual name the binary has.
2 parents c548dbb + e716c7d commit c0a11ef

File tree

3 files changed

+15
-4
lines changed

3 files changed

+15
-4
lines changed

verilog/tools/ls/BUILD

+7-1
Original file line numberDiff line numberDiff line change
@@ -124,7 +124,10 @@ cc_library(
124124
":lsp-parse-buffer",
125125
"//common/lsp:lsp-file-utils",
126126
"//common/lsp:lsp-protocol",
127+
"//common/lsp:lsp-text-buffer",
127128
"//common/strings:line-column-map",
129+
"//common/text:text-structure",
130+
"//common/text:token-info",
128131
"//common/util:file-util",
129132
"//common/util:iterator-adaptors",
130133
"//common/util:logging",
@@ -148,6 +151,7 @@ cc_test(
148151
srcs = ["symbol-table-handler_test.cc"],
149152
deps = [
150153
":symbol-table-handler",
154+
"//common/lsp:lsp-file-utils",
151155
"//common/util:file-util",
152156
"//verilog/analysis:verilog-project",
153157
"@com_google_absl//absl/strings",
@@ -194,12 +198,14 @@ cc_test(
194198

195199
cc_binary(
196200
name = "verible-verilog-ls",
197-
srcs = ["verilog_ls.cc"],
201+
srcs = ["verible-verilog-ls.cc"],
198202
features = STATIC_EXECUTABLES_FEATURE,
199203
visibility = ["//visibility:public"],
200204
deps = [
201205
":verilog-language-server",
202206
"//common/util:init-command-line",
207+
"@com_google_absl//absl/status",
208+
"@com_google_absl//absl/strings",
203209
],
204210
)
205211

verilog/tools/ls/symbol-table-handler.cc

+5-1
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@
1515

1616
#include "verilog/tools/ls/symbol-table-handler.h"
1717

18+
#include <algorithm>
1819
#include <filesystem>
1920
#include <map>
2021
#include <memory>
@@ -29,13 +30,17 @@
2930
#include "absl/time/time.h"
3031
#include "common/lsp/lsp-file-utils.h"
3132
#include "common/lsp/lsp-protocol.h"
33+
#include "common/lsp/lsp-text-buffer.h"
3234
#include "common/strings/line_column_map.h"
35+
#include "common/text/text_structure.h"
36+
#include "common/text/token_info.h"
3337
#include "common/util/file_util.h"
3438
#include "common/util/iterator_adaptors.h"
3539
#include "common/util/logging.h"
3640
#include "common/util/range.h"
3741
#include "verilog/analysis/verilog_filelist.h"
3842
#include "verilog/tools/ls/lsp-conversion.h"
43+
#include "verilog/tools/ls/lsp-parse-buffer.h"
3944

4045
ABSL_FLAG(std::string, file_list_path, "verible.filelist",
4146
"Name of the file with Verible FileList for the project");
@@ -473,7 +478,6 @@ SymbolTableHandler::FindRenameLocationsAndCreateEdits(
473478
.changes = {},
474479
};
475480
edit.changes = file_edit_pairs;
476-
std::cerr << "SIZE: " << edit.changes[locations[0].uri].size() << std::endl;
477481
return edit;
478482
}
479483
void SymbolTableHandler::CollectReferencesReferenceComponents(

verilog/tools/ls/verilog_ls.cc verilog/tools/ls/verible-verilog-ls.cc

+3-2
Original file line numberDiff line numberDiff line change
@@ -13,9 +13,10 @@
1313
// limitations under the License.
1414
//
1515

16-
#include <functional>
1716
#include <iostream>
1817

18+
#include "absl/status/status.h"
19+
#include "absl/strings/string_view.h"
1920
#include "common/util/init_command_line.h"
2021
#include "verilog/tools/ls/verilog-language-server.h"
2122

@@ -57,7 +58,7 @@ int main(int argc, char *argv[]) {
5758
return read(kInputFD, buf, size);
5859
});
5960

60-
std::cerr << status.message() << std::endl;
61+
std::cerr << status << '\n';
6162

6263
server.PrintStatistics();
6364
}

0 commit comments

Comments
 (0)