Skip to content

Commit cef66e2

Browse files
committed
the last of them... i think
1 parent 174a33c commit cef66e2

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

src/widgets/QDisassemblyView.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -467,7 +467,7 @@ void QDisassemblyView::setShowAddressSeparator(bool value) {
467467
//------------------------------------------------------------------------------
468468
QString QDisassemblyView::formatAddress(edb::address_t address) const {
469469
if (edb::v1::debuggeeIs32Bit()) {
470-
return format_address<quint32>(address.toUint(), showAddressSeparator_);
470+
return format_address<quint32>(static_cast<quint32>(address.toUint()), showAddressSeparator_);
471471
}
472472
return format_address(address, showAddressSeparator_);
473473
}
@@ -698,7 +698,7 @@ std::optional<unsigned int> QDisassemblyView::getLineOfAddress(edb::address_t ad
698698

699699
if (!showAddresses_.isEmpty()) {
700700
if (addr >= showAddresses_[0] && addr <= showAddresses_[showAddresses_.size() - 1]) {
701-
int pos = std::find(showAddresses_.begin(), showAddresses_.end(), addr) - showAddresses_.begin();
701+
auto pos = static_cast<int>(std::find(showAddresses_.begin(), showAddresses_.end(), addr) - showAddresses_.begin());
702702
if (pos < showAddresses_.size()) { // address was found
703703
return pos;
704704
}
@@ -717,7 +717,7 @@ int QDisassemblyView::updateDisassembly(int lines_to_render) {
717717
instructions_.clear();
718718
showAddresses_.clear();
719719

720-
int bufsize = static_cast<int>(instructionBuffer_.size());
720+
auto bufsize = static_cast<int>(instructionBuffer_.size());
721721
uint8_t *inst_buf = instructionBuffer_.data();
722722
const edb::address_t start_address = addressOffset_ + verticalScrollBar()->value();
723723

@@ -744,7 +744,7 @@ int QDisassemblyView::updateDisassembly(int lines_to_render) {
744744
showAddresses_.push_back(address);
745745

746746
if (instructions_[line].valid()) {
747-
offset += instructions_[line].byteSize();
747+
offset += static_cast<int>(instructions_[line].byteSize());
748748
} else {
749749
++offset;
750750
}
@@ -1765,7 +1765,7 @@ int QDisassemblyView::line4() const {
17651765
// Desc:
17661766
//------------------------------------------------------------------------------
17671767
int QDisassemblyView::addressLength() const {
1768-
const int address_len = static_cast<int>(edb::v1::pointer_size() * CHAR_BIT / 4);
1768+
const auto address_len = static_cast<int>(edb::v1::pointer_size() * CHAR_BIT / 4);
17691769
return address_len + (showAddressSeparator_ ? 1 : 0);
17701770
}
17711771

0 commit comments

Comments
 (0)