From 4ce2fed5faddcdebd587f652589f00b79f5c73ff Mon Sep 17 00:00:00 2001 From: Volker Date: Thu, 2 Aug 2018 12:12:51 +0200 Subject: [PATCH] add method for patching code position --- .../inetsoftware/jwebassembly/module/WasmInstruction.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/de/inetsoftware/jwebassembly/module/WasmInstruction.java b/src/de/inetsoftware/jwebassembly/module/WasmInstruction.java index be469ab..a69473a 100644 --- a/src/de/inetsoftware/jwebassembly/module/WasmInstruction.java +++ b/src/de/inetsoftware/jwebassembly/module/WasmInstruction.java @@ -57,4 +57,12 @@ abstract class WasmInstruction { int getCodePosition() { return javaCodePos; } + + /** + * Set a new code position after reorganize the order + * @param newPos new position + */ + void setCodePosition( int newPos ) { + this.javaCodePos = newPos; + } }