Skip to content

Commit 0c8cf2b

Browse files
anutosh491vgvassilev
authored andcommitted
Removed unused variables to address warnings
1 parent eb4d98a commit 0c8cf2b

File tree

3 files changed

+3
-8
lines changed

3 files changed

+3
-8
lines changed

src/xinspect.hpp

-2
Original file line numberDiff line numberDiff line change
@@ -160,7 +160,6 @@ namespace xcpp
160160
tagfile = it->at("tagfile");
161161
std::string filename = tagfiles_dir + "/" + tagfile;
162162
pugi::xml_document doc;
163-
pugi::xml_parse_result result = doc.load_file(filename.c_str());
164163
class_member_predicate predicate{typename_, "function", method[2]};
165164
auto node = doc.find_node(predicate);
166165
if (!node.empty())
@@ -194,7 +193,6 @@ namespace xcpp
194193
tagfile = it->at("tagfile");
195194
std::string filename = tagfiles_dir + "/" + tagfile;
196195
pugi::xml_document doc;
197-
pugi::xml_parse_result result = doc.load_file(filename.c_str());
198196
for (auto c : check)
199197
{
200198
node_predicate predicate{c, find_string};

src/xinterpreter.cpp

+3-3
Original file line numberDiff line numberDiff line change
@@ -282,7 +282,7 @@ namespace xcpp
282282
}
283283

284284
nl::json interpreter::execute_request_impl(
285-
int execution_counter,
285+
int /*execution_counter*/,
286286
const std::string& code,
287287
bool silent,
288288
bool /*store_history*/,
@@ -414,7 +414,7 @@ namespace xcpp
414414
return kernel_res;
415415
}
416416

417-
nl::json interpreter::complete_request_impl(const std::string& code, int cursor_pos)
417+
nl::json interpreter::complete_request_impl(const std::string& /*code*/, int cursor_pos)
418418
{
419419
return xeus::create_complete_reply(
420420
nl::json::array(), /*matches*/
@@ -436,7 +436,7 @@ namespace xcpp
436436
return kernel_res;
437437
}
438438

439-
nl::json interpreter::is_complete_request_impl(const std::string& code)
439+
nl::json interpreter::is_complete_request_impl(const std::string& /*code*/)
440440
{
441441
return xeus::create_is_complete_reply("complete", " ");
442442
}

src/xsystem.hpp

-3
Original file line numberDiff line numberDiff line change
@@ -32,8 +32,6 @@ namespace xcpp
3232
std::smatch to_execute;
3333
std::regex_search(code, to_execute, re);
3434

35-
int ret = 1;
36-
3735
// Redirection of stderr to stdout
3836
std::string command = to_execute.str(1) + " 2>&1";
3937

@@ -45,7 +43,6 @@ namespace xcpp
4543
if (shell_result)
4644
{
4745
char buff[512];
48-
ret = 0;
4946
while (fgets(buff, sizeof(buff), shell_result))
5047
{
5148
std::cout << buff;

0 commit comments

Comments
 (0)