frontend/A32/types: Remove redundant std::string initializer

std::string initializes to empty by default. While we're at it, brace a
lone unbraced if statement.
This commit is contained in:
Lioncash 2019-05-24 02:05:18 -04:00 committed by MerryMage
parent 25b4e463d3
commit b57ed8917a

View file

@ -52,12 +52,13 @@ const char* CoprocRegToString(CoprocReg reg) {
}
std::string RegListToString(RegList reg_list) {
std::string ret = "";
std::string ret;
bool first_reg = true;
for (size_t i = 0; i < 16; i++) {
if (Common::Bit(i, reg_list)) {
if (!first_reg)
if (!first_reg) {
ret += ", ";
}
ret += RegToString(static_cast<Reg>(i));
first_reg = false;
}