diff options
author | Karel Kočí <cynerd@email.cz> | 2017-09-02 15:34:07 +0200 |
---|---|---|
committer | Karel Kočí <cynerd@email.cz> | 2017-09-02 15:34:07 +0200 |
commit | 375607d9969896c894fa2642ce4a0b8b519a2adb (patch) | |
tree | cb947a843d85f1cd278da15cff432c849986166c /qtmips_machine/instructions/arithmetic.cpp | |
parent | 82884b3ef726889f837542d2b5e98e2cd8246c00 (diff) | |
download | qtmips-375607d9969896c894fa2642ce4a0b8b519a2adb.tar.gz qtmips-375607d9969896c894fa2642ce4a0b8b519a2adb.tar.bz2 qtmips-375607d9969896c894fa2642ce4a0b8b519a2adb.zip |
Use QString and QVector instead of std ones and more
Diffstat (limited to 'qtmips_machine/instructions/arithmetic.cpp')
-rw-r--r-- | qtmips_machine/instructions/arithmetic.cpp | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/qtmips_machine/instructions/arithmetic.cpp b/qtmips_machine/instructions/arithmetic.cpp index 8c8f40e..a620436 100644 --- a/qtmips_machine/instructions/arithmetic.cpp +++ b/qtmips_machine/instructions/arithmetic.cpp @@ -1,13 +1,12 @@ #include "instructions/arithmetic.h" -#include <iostream> InstructionArithmetic::InstructionArithmetic(enum InstructionArithmeticT type, std::uint8_t rs, std::uint8_t rd, std::uint8_t rt) : InstructionR(rs, rd, rt, 0) { this->type = type; } -std::vector<std::string> InstructionArithmetic::to_strs() { - std::vector<std::string> str = this->InstructionR::to_strs(); +QVector<QString> InstructionArithmetic::to_strs() { + QVector<QString> str = this->InstructionR::to_strs(); str.erase(str.begin() + 4); // Drop sa field switch (this->type) { case IAT_ADD: @@ -52,8 +51,8 @@ InstructionArithmeticImmediate::InstructionArithmeticImmediate(enum InstructionA this->type = type; } -std::vector<std::string> InstructionArithmeticImmediate::to_strs() { - std::vector<std::string> str = this->InstructionI::to_strs(); +QVector<QString> InstructionArithmeticImmediate::to_strs() { + QVector<QString> str = this->InstructionI::to_strs(); switch (this->type) { case IAT_ADDI: str[0] = "addi"; |