diff options
author | chibash <chiba@javassist.org> | 2014-07-23 19:15:11 +0900 |
---|---|---|
committer | chibash <chiba@javassist.org> | 2014-07-23 19:15:11 +0900 |
commit | 7497ae88e9644826568aa3b927f314804e4fc021 (patch) | |
tree | 200e45cf47db63cc07ffbe4e704e506376eaeca3 | |
parent | 3daf2b308683ea53ab52950438efe33c41b83f7f (diff) | |
download | javassist-7497ae88e9644826568aa3b927f314804e4fc021.tar.gz javassist-7497ae88e9644826568aa3b927f314804e4fc021.zip |
fixed JIRA-227
-rw-r--r-- | Readme.html | 2 | ||||
-rw-r--r-- | src/main/javassist/bytecode/CodeIterator.java | 5 | ||||
-rw-r--r-- | src/main/javassist/bytecode/InstructionPrinter.java | 2 | ||||
-rw-r--r-- | src/main/javassist/tools/framedump.java | 2 |
4 files changed, 8 insertions, 3 deletions
diff --git a/Readme.html b/Readme.html index 378bb0f5..7b1b5046 100644 --- a/Readme.html +++ b/Readme.html @@ -283,7 +283,7 @@ see javassist.Dump. <p>-version 3.19 <ul> -<li>JIRA JASSIST-158, 205, 206, 207, 211, 212, 216, 223, 224. +<li>JIRA JASSIST-158, 205, 206, 207, 211, 212, 216, 220, 223, 224, 227. </ul> </p> diff --git a/src/main/javassist/bytecode/CodeIterator.java b/src/main/javassist/bytecode/CodeIterator.java index a1d882e0..e1edcbb7 100644 --- a/src/main/javassist/bytecode/CodeIterator.java +++ b/src/main/javassist/bytecode/CodeIterator.java @@ -127,6 +127,11 @@ public class CodeIterator implements Opcode { public int byteAt(int index) { return bytecode[index] & 0xff; } /** + * Returns the signed 8bit value at the given index. + */ + public int signedByteAt(int index) { return bytecode[index]; } + + /** * Writes an 8bit value at the given index. */ public void writeByte(int value, int index) { diff --git a/src/main/javassist/bytecode/InstructionPrinter.java b/src/main/javassist/bytecode/InstructionPrinter.java index 12f74d5b..93182baa 100644 --- a/src/main/javassist/bytecode/InstructionPrinter.java +++ b/src/main/javassist/bytecode/InstructionPrinter.java @@ -116,7 +116,7 @@ public class InstructionPrinter implements Opcode { case IF_ICMPNE: return opstring + " " + (iter.s16bitAt(pos + 1) + pos); case IINC: - return opstring + " " + iter.byteAt(pos + 1); + return opstring + " " + iter.byteAt(pos + 1) + ", " + iter.signedByteAt(pos + 2); case GOTO: case JSR: return opstring + " " + (iter.s16bitAt(pos + 1) + pos); diff --git a/src/main/javassist/tools/framedump.java b/src/main/javassist/tools/framedump.java index 95329111..43a2beb6 100644 --- a/src/main/javassist/tools/framedump.java +++ b/src/main/javassist/tools/framedump.java @@ -36,7 +36,7 @@ public class framedump { */ public static void main(String[] args) throws Exception { if (args.length != 1) { - System.err.println("Usage: java javassist.tools.framedump <class file name>"); + System.err.println("Usage: java javassist.tools.framedump <fully-qualified class name>"); return; } |