diff --git a/teavm-core/src/main/java/org/teavm/debugging/DebugInformation.java b/teavm-core/src/main/java/org/teavm/debugging/DebugInformation.java index 821ff1c05..58cf889e9 100644 --- a/teavm-core/src/main/java/org/teavm/debugging/DebugInformation.java +++ b/teavm-core/src/main/java/org/teavm/debugging/DebugInformation.java @@ -232,6 +232,8 @@ public class DebugInformation { static class FileDescriptionBuilder { FileDescriptionProto[] files; + int lastFileIndex = -1; + int lastSourceLine = -1; public FileDescriptionBuilder(int size) { files = new FileDescriptionProto[size]; @@ -244,6 +246,11 @@ public class DebugInformation { if (sourceLine == -1 || fileIndex == -1) { return; } + if (lastFileIndex == fileIndex && lastSourceLine == sourceLine) { + return; + } + lastFileIndex = fileIndex; + lastSourceLine = sourceLine; FileDescriptionProto proto = files[fileIndex]; proto.addLocation(sourceLine, line, column); } diff --git a/teavm-core/src/main/java/org/teavm/debugging/JavaScriptLocation.java b/teavm-core/src/main/java/org/teavm/debugging/JavaScriptLocation.java index 2cee84c2d..64d6372fc 100644 --- a/teavm-core/src/main/java/org/teavm/debugging/JavaScriptLocation.java +++ b/teavm-core/src/main/java/org/teavm/debugging/JavaScriptLocation.java @@ -41,4 +41,9 @@ public class JavaScriptLocation { public int getColumn() { return column; } + + @Override + public String toString() { + return script + ":(" + line + ";" + column + ")"; + } } diff --git a/teavm-eclipse-plugin/src/main/java/org/teavm/eclipse/debugger/ui/TeaVMTab.java b/teavm-eclipse-plugin/src/main/java/org/teavm/eclipse/debugger/ui/TeaVMTab.java index d232b5552..201fae30d 100644 --- a/teavm-eclipse-plugin/src/main/java/org/teavm/eclipse/debugger/ui/TeaVMTab.java +++ b/teavm-eclipse-plugin/src/main/java/org/teavm/eclipse/debugger/ui/TeaVMTab.java @@ -26,6 +26,7 @@ public class TeaVMTab extends AbstractLaunchConfigurationTab { GridLayout layout = new GridLayout(); layout.verticalSpacing = 6; layout.numColumns = 2; + layout.horizontalSpacing = 6; root.setLayout(layout); Label portLabel = new Label(root, SWT.NONE); diff --git a/teavm-eclipse-updatesite/site.xml b/teavm-eclipse-updatesite/site.xml index c68822863..8f988551a 100644 --- a/teavm-eclipse-updatesite/site.xml +++ b/teavm-eclipse-updatesite/site.xml @@ -3,7 +3,7 @@ TeaVM update site - +