Fix debug output.

This commit is contained in:
chriseth 2017-01-10 16:35:10 +01:00
parent da5e171f3b
commit 7127f2fdfd

View File

@ -283,13 +283,19 @@ string Pattern::toString() const
s << instructionInfo(m_instruction).name; s << instructionInfo(m_instruction).name;
break; break;
case Push: case Push:
s << "PUSH " << hex << data(); if (m_data)
s << "PUSH " << hex << data();
else
s << "PUSH ";
break; break;
case UndefinedItem: case UndefinedItem:
s << "ANY"; s << "ANY";
break; break;
default: default:
s << "t=" << dec << m_type << " d=" << hex << data(); if (m_data)
s << "t=" << dec << m_type << " d=" << hex << data();
else
s << "t=" << dec << m_type << " d: nullptr";
break; break;
} }
if (!m_requireDataMatch) if (!m_requireDataMatch)