diff options
| author | manuel <manuel@nc8430.lan> | 2009-05-13 04:09:39 +0200 |
|---|---|---|
| committer | manuel <manuel@nc8430.lan> | 2009-05-13 04:09:39 +0200 |
| commit | 89e202f49b9857dcd3627fbc4e0262125d729bbc (patch) | |
| tree | dbe69dd8498eb0a489bc7b7e24f2b73580c598d2 /ue3/mycpu/cinstruction.cpp | |
| parent | 45581d3d376e8deed84952cb838ae330549e5241 (diff) | |
| download | ooprog-89e202f49b9857dcd3627fbc4e0262125d729bbc.tar.gz ooprog-89e202f49b9857dcd3627fbc4e0262125d729bbc.tar.bz2 ooprog-89e202f49b9857dcd3627fbc4e0262125d729bbc.zip | |
adding all instructions and displays
Diffstat (limited to 'ue3/mycpu/cinstruction.cpp')
| -rw-r--r-- | ue3/mycpu/cinstruction.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ue3/mycpu/cinstruction.cpp b/ue3/mycpu/cinstruction.cpp index 32bdd2f..57acd5f 100644 --- a/ue3/mycpu/cinstruction.cpp +++ b/ue3/mycpu/cinstruction.cpp | |||
| @@ -16,7 +16,7 @@ using namespace std; | |||
| 16 | const unsigned CInstruction::parseRegister(const std::string& str) | 16 | const unsigned CInstruction::parseRegister(const std::string& str) |
| 17 | { | 17 | { |
| 18 | unsigned reg; | 18 | unsigned reg; |
| 19 | if (str.length() < 2 || str[0] != 'R') | 19 | if (str.length() < 2 || str[0] != 'r') |
| 20 | throw runtime_error("Invalid syntax of register"); | 20 | throw runtime_error("Invalid syntax of register"); |
| 21 | 21 | ||
| 22 | try | 22 | try |
| @@ -33,7 +33,7 @@ const unsigned CInstruction::parseRegister(const std::string& str) | |||
| 33 | 33 | ||
| 34 | /*----------------------------------------------------------------------------*/ | 34 | /*----------------------------------------------------------------------------*/ |
| 35 | 35 | ||
| 36 | inline void CInstruction::checkRegister(CCPU *cpu, unsigned regidx) | 36 | inline void CInstruction::checkRegister(CCPU *cpu, const unsigned regidx) |
| 37 | { | 37 | { |
| 38 | if (regidx >= cpu->getRegisterCount()) | 38 | if (regidx >= cpu->getRegisterCount()) |
| 39 | { | 39 | { |
