Skip to content

Commit 5cfbaa0

Browse files
authored
Merge pull request #2521 from AlexandreSinger/feature-remove-warnings
Removed Warnings in libvtrutil and vqm2blif
2 parents 63675f9 + 1d109bc commit 5cfbaa0

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

libs/libvtrutil/test/test_array_view.cpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ struct test_tag;
88
using TestStrongId = vtr::StrongId<test_tag>;
99

1010
TEST_CASE("Array view", "[array_view/array_view]") {
11-
std::array<uint16_t, 10> arr;
11+
std::array<uint16_t, 10> arr = {0};
1212
vtr::array_view<uint16_t> arr_view(arr.data(), arr.size());
1313

1414
const vtr::array_view<uint16_t>& carr_view = arr_view;
@@ -56,7 +56,7 @@ TEST_CASE("Array view", "[array_view/array_view]") {
5656
}
5757

5858
TEST_CASE("Array view id", "[array_view/array_view_id]") {
59-
std::array<uint16_t, 10> arr;
59+
std::array<uint16_t, 10> arr = {0};
6060
vtr::array_view_id<TestStrongId, uint16_t> arr_view(arr.data(), arr.size());
6161

6262
const vtr::array_view_id<TestStrongId, uint16_t>& carr_view = arr_view;

utils/vqm2blif/src/base/cleanup.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,7 @@ void remove_one_lut_nodes ( busvec* buses, std::unordered_map<std::string, int>
297297
t_node_port_association* source_port;
298298
t_node_port_association* prev_port;
299299
netvec* prev_bus;
300-
t_net* prev_net;
300+
t_net* prev_net = nullptr;
301301

302302
netvec* vcc_bus = get_bus_from_hash (hash_table, const_cast<char*>("vcc"), buses);
303303
VTR_ASSERT(vcc_bus != NULL);
@@ -658,7 +658,7 @@ void verify_netlist ( t_node** nodes, int num_nodes, busvec* buses, std::unorder
658658
auto hash_entry = hash_table.find(ref_pin->name);
659659

660660
VTR_ASSERT(hash_entry != hash_table.end());
661-
VTR_ASSERT((unsigned int)hash_entry->second == i);
661+
VTR_ASSERT((unsigned int)hash_entry->second == (unsigned int)i);
662662

663663
for (int j = 0; (unsigned int)j < temp_bus->size(); j++){
664664
temp_net = &(temp_bus->at(j));
@@ -903,4 +903,4 @@ void reorganize_module_node_list(t_module* module)
903903
}
904904

905905
//============================================================================================
906-
//============================================================================================
906+
//============================================================================================

0 commit comments

Comments
 (0)