From df40cead45c11f4fac64bbcc773ea553136fae9b Mon Sep 17 00:00:00 2001 From: Cader Date: Wed, 9 Oct 2019 16:09:17 -0700 Subject: [PATCH] Overload methods are not grouped together --- .../assembly/DefaultInstructionSet.java | 21 +++++++++---------- 1 file changed, 10 insertions(+), 11 deletions(-) diff --git a/Server/src/main/java/net/simon987/server/assembly/DefaultInstructionSet.java b/Server/src/main/java/net/simon987/server/assembly/DefaultInstructionSet.java index cd9aa3f..68ad271 100755 --- a/Server/src/main/java/net/simon987/server/assembly/DefaultInstructionSet.java +++ b/Server/src/main/java/net/simon987/server/assembly/DefaultInstructionSet.java @@ -104,18 +104,9 @@ public class DefaultInstructionSet implements InstructionSet { return defaultInstruction; } } - /** - * Add a new instruction to the instructionSet - * - * @param opcode opcode of the instruction - * @param instruction Instruction to add + * Get an instruction frim its mnemonic */ - public void addInstruction(int opcode, Instruction instruction) { - instructionMap.put(opcode, instruction); - } - - @Override public Instruction get(String mnemonic) { for (Instruction ins : instructionMap.values()) { @@ -131,7 +122,15 @@ public class DefaultInstructionSet implements InstructionSet { return null; } - + /** + * Add a new instruction to the instructionSet + * + * @param opcode opcode of the instruction + * @param instruction Instruction to add + */ + public void addInstruction(int opcode, Instruction instruction) { + instructionMap.put(opcode, instruction); + } @Override public void add(Instruction instruction) {