@theia/debug 1.67.0-next.13 → 1.67.0-next.56
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/package.json +15 -15
- package/src/browser/breakpoint/breakpoint-manager.ts +69 -16
- package/src/browser/breakpoint/breakpoint-marker.ts +38 -0
- package/src/browser/breakpoint/debug-data-breakpoint-actions.ts +170 -0
- package/src/browser/console/debug-console-items.tsx +5 -1
- package/src/browser/debug-frontend-application-contribution.ts +19 -0
- package/src/browser/debug-frontend-module.ts +2 -0
- package/src/browser/debug-session-manager.ts +18 -0
- package/src/browser/debug-session.tsx +31 -0
- package/src/browser/model/debug-data-breakpoint.tsx +79 -0
- package/src/browser/style/index.css +4 -0
- package/src/browser/view/debug-breakpoints-source.tsx +4 -10
- package/src/browser/view/debug-stack-frames-widget.ts +6 -2
- package/src/browser/view/debug-variables-widget.ts +99 -2
- package/src/browser/view/debug-view-model.ts +5 -0
- package/lib/browser/breakpoint/breakpoint-manager.d.ts +0 -71
- package/lib/browser/breakpoint/breakpoint-manager.d.ts.map +0 -1
- package/lib/browser/breakpoint/breakpoint-manager.js +0 -321
- package/lib/browser/breakpoint/breakpoint-manager.js.map +0 -1
- package/lib/browser/breakpoint/breakpoint-marker.d.ts +0 -42
- package/lib/browser/breakpoint/breakpoint-marker.d.ts.map +0 -1
- package/lib/browser/breakpoint/breakpoint-marker.js +0 -88
- package/lib/browser/breakpoint/breakpoint-marker.js.map +0 -1
- package/lib/browser/console/debug-console-contribution.d.ts +0 -45
- package/lib/browser/console/debug-console-contribution.d.ts.map +0 -1
- package/lib/browser/console/debug-console-contribution.js +0 -233
- package/lib/browser/console/debug-console-contribution.js.map +0 -1
- package/lib/browser/console/debug-console-items.d.ts +0 -97
- package/lib/browser/console/debug-console-items.d.ts.map +0 -1
- package/lib/browser/console/debug-console-items.js +0 -343
- package/lib/browser/console/debug-console-items.js.map +0 -1
- package/lib/browser/console/debug-console-session.d.ts +0 -32
- package/lib/browser/console/debug-console-session.d.ts.map +0 -1
- package/lib/browser/console/debug-console-session.js +0 -192
- package/lib/browser/console/debug-console-session.js.map +0 -1
- package/lib/browser/debug-call-stack-item-type-key.d.ts +0 -4
- package/lib/browser/debug-call-stack-item-type-key.d.ts.map +0 -1
- package/lib/browser/debug-call-stack-item-type-key.js +0 -20
- package/lib/browser/debug-call-stack-item-type-key.js.map +0 -1
- package/lib/browser/debug-configuration-manager.d.ts +0 -103
- package/lib/browser/debug-configuration-manager.d.ts.map +0 -1
- package/lib/browser/debug-configuration-manager.js +0 -545
- package/lib/browser/debug-configuration-manager.js.map +0 -1
- package/lib/browser/debug-configuration-model.d.ts +0 -30
- package/lib/browser/debug-configuration-model.d.ts.map +0 -1
- package/lib/browser/debug-configuration-model.js +0 -80
- package/lib/browser/debug-configuration-model.js.map +0 -1
- package/lib/browser/debug-contribution.d.ts +0 -23
- package/lib/browser/debug-contribution.d.ts.map +0 -1
- package/lib/browser/debug-contribution.js +0 -20
- package/lib/browser/debug-contribution.js.map +0 -1
- package/lib/browser/debug-frontend-application-contribution.d.ts +0 -249
- package/lib/browser/debug-frontend-application-contribution.d.ts.map +0 -1
- package/lib/browser/debug-frontend-application-contribution.js +0 -1678
- package/lib/browser/debug-frontend-application-contribution.js.map +0 -1
- package/lib/browser/debug-frontend-module.d.ts +0 -5
- package/lib/browser/debug-frontend-module.d.ts.map +0 -1
- package/lib/browser/debug-frontend-module.js +0 -110
- package/lib/browser/debug-frontend-module.js.map +0 -1
- package/lib/browser/debug-package.spec.d.ts +0 -1
- package/lib/browser/debug-package.spec.d.ts.map +0 -1
- package/lib/browser/debug-package.spec.js +0 -19
- package/lib/browser/debug-package.spec.js.map +0 -1
- package/lib/browser/debug-prefix-configuration.d.ts +0 -52
- package/lib/browser/debug-prefix-configuration.d.ts.map +0 -1
- package/lib/browser/debug-prefix-configuration.js +0 -202
- package/lib/browser/debug-prefix-configuration.js.map +0 -1
- package/lib/browser/debug-resource.d.ts +0 -15
- package/lib/browser/debug-resource.d.ts.map +0 -1
- package/lib/browser/debug-resource.js +0 -58
- package/lib/browser/debug-resource.js.map +0 -1
- package/lib/browser/debug-schema-updater.d.ts +0 -14
- package/lib/browser/debug-schema-updater.d.ts.map +0 -1
- package/lib/browser/debug-schema-updater.js +0 -161
- package/lib/browser/debug-schema-updater.js.map +0 -1
- package/lib/browser/debug-session-configuration-label-provider.d.ts +0 -11
- package/lib/browser/debug-session-configuration-label-provider.d.ts.map +0 -1
- package/lib/browser/debug-session-configuration-label-provider.js +0 -48
- package/lib/browser/debug-session-configuration-label-provider.js.map +0 -1
- package/lib/browser/debug-session-configuration-label-provider.spec.d.ts +0 -2
- package/lib/browser/debug-session-configuration-label-provider.spec.d.ts.map +0 -1
- package/lib/browser/debug-session-configuration-label-provider.spec.js +0 -84
- package/lib/browser/debug-session-configuration-label-provider.spec.js.map +0 -1
- package/lib/browser/debug-session-connection.d.ts +0 -111
- package/lib/browser/debug-session-connection.d.ts.map +0 -1
- package/lib/browser/debug-session-connection.js +0 -259
- package/lib/browser/debug-session-connection.js.map +0 -1
- package/lib/browser/debug-session-contribution.d.ts +0 -77
- package/lib/browser/debug-session-contribution.d.ts.map +0 -1
- package/lib/browser/debug-session-contribution.js +0 -143
- package/lib/browser/debug-session-contribution.js.map +0 -1
- package/lib/browser/debug-session-manager.d.ts +0 -138
- package/lib/browser/debug-session-manager.d.ts.map +0 -1
- package/lib/browser/debug-session-manager.js +0 -620
- package/lib/browser/debug-session-manager.js.map +0 -1
- package/lib/browser/debug-session-options.d.ts +0 -56
- package/lib/browser/debug-session-options.d.ts.map +0 -1
- package/lib/browser/debug-session-options.js +0 -92
- package/lib/browser/debug-session-options.js.map +0 -1
- package/lib/browser/debug-session.d.ts +0 -192
- package/lib/browser/debug-session.d.ts.map +0 -1
- package/lib/browser/debug-session.js +0 -913
- package/lib/browser/debug-session.js.map +0 -1
- package/lib/browser/debug-tab-bar-decorator.d.ts +0 -17
- package/lib/browser/debug-tab-bar-decorator.d.ts.map +0 -1
- package/lib/browser/debug-tab-bar-decorator.js +0 -63
- package/lib/browser/debug-tab-bar-decorator.js.map +0 -1
- package/lib/browser/debug-watch-manager.d.ts +0 -22
- package/lib/browser/debug-watch-manager.d.ts.map +0 -1
- package/lib/browser/debug-watch-manager.js +0 -86
- package/lib/browser/debug-watch-manager.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-accessibility-provider.d.ts +0 -7
- package/lib/browser/disassembly-view/disassembly-view-accessibility-provider.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-accessibility-provider.js +0 -39
- package/lib/browser/disassembly-view/disassembly-view-accessibility-provider.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-breakpoint-renderer.d.ts +0 -20
- package/lib/browser/disassembly-view/disassembly-view-breakpoint-renderer.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-breakpoint-renderer.js +0 -111
- package/lib/browser/disassembly-view/disassembly-view-breakpoint-renderer.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-contribution.d.ts +0 -25
- package/lib/browser/disassembly-view/disassembly-view-contribution.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-contribution.js +0 -124
- package/lib/browser/disassembly-view/disassembly-view-contribution.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-instruction-renderer.d.ts +0 -39
- package/lib/browser/disassembly-view/disassembly-view-instruction-renderer.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-instruction-renderer.js +0 -213
- package/lib/browser/disassembly-view/disassembly-view-instruction-renderer.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-table-delegate.d.ts +0 -16
- package/lib/browser/disassembly-view/disassembly-view-table-delegate.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-table-delegate.js +0 -39
- package/lib/browser/disassembly-view/disassembly-view-table-delegate.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-utilities.d.ts +0 -38
- package/lib/browser/disassembly-view/disassembly-view-utilities.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-utilities.js +0 -18
- package/lib/browser/disassembly-view/disassembly-view-utilities.js.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-widget.d.ts +0 -61
- package/lib/browser/disassembly-view/disassembly-view-widget.d.ts.map +0 -1
- package/lib/browser/disassembly-view/disassembly-view-widget.js +0 -446
- package/lib/browser/disassembly-view/disassembly-view-widget.js.map +0 -1
- package/lib/browser/editor/debug-breakpoint-widget.d.ts +0 -58
- package/lib/browser/editor/debug-breakpoint-widget.d.ts.map +0 -1
- package/lib/browser/editor/debug-breakpoint-widget.js +0 -270
- package/lib/browser/editor/debug-breakpoint-widget.js.map +0 -1
- package/lib/browser/editor/debug-editor-model.d.ts +0 -87
- package/lib/browser/editor/debug-editor-model.d.ts.map +0 -1
- package/lib/browser/editor/debug-editor-model.js +0 -499
- package/lib/browser/editor/debug-editor-model.js.map +0 -1
- package/lib/browser/editor/debug-editor-service.d.ts +0 -38
- package/lib/browser/editor/debug-editor-service.d.ts.map +0 -1
- package/lib/browser/editor/debug-editor-service.js +0 -183
- package/lib/browser/editor/debug-editor-service.js.map +0 -1
- package/lib/browser/editor/debug-editor.d.ts +0 -4
- package/lib/browser/editor/debug-editor.d.ts.map +0 -1
- package/lib/browser/editor/debug-editor.js +0 -20
- package/lib/browser/editor/debug-editor.js.map +0 -1
- package/lib/browser/editor/debug-exception-widget.d.ts +0 -30
- package/lib/browser/editor/debug-exception-widget.d.ts.map +0 -1
- package/lib/browser/editor/debug-exception-widget.js +0 -107
- package/lib/browser/editor/debug-exception-widget.js.map +0 -1
- package/lib/browser/editor/debug-expression-provider.d.ts +0 -17
- package/lib/browser/editor/debug-expression-provider.d.ts.map +0 -1
- package/lib/browser/editor/debug-expression-provider.js +0 -107
- package/lib/browser/editor/debug-expression-provider.js.map +0 -1
- package/lib/browser/editor/debug-hover-source.d.ts +0 -19
- package/lib/browser/editor/debug-hover-source.d.ts.map +0 -1
- package/lib/browser/editor/debug-hover-source.js +0 -110
- package/lib/browser/editor/debug-hover-source.js.map +0 -1
- package/lib/browser/editor/debug-hover-widget.d.ts +0 -61
- package/lib/browser/editor/debug-hover-widget.d.ts.map +0 -1
- package/lib/browser/editor/debug-hover-widget.js +0 -271
- package/lib/browser/editor/debug-hover-widget.js.map +0 -1
- package/lib/browser/editor/debug-inline-value-decorator.d.ts +0 -20
- package/lib/browser/editor/debug-inline-value-decorator.d.ts.map +0 -1
- package/lib/browser/editor/debug-inline-value-decorator.js +0 -326
- package/lib/browser/editor/debug-inline-value-decorator.js.map +0 -1
- package/lib/browser/model/debug-breakpoint.d.ts +0 -48
- package/lib/browser/model/debug-breakpoint.d.ts.map +0 -1
- package/lib/browser/model/debug-breakpoint.js +0 -111
- package/lib/browser/model/debug-breakpoint.js.map +0 -1
- package/lib/browser/model/debug-function-breakpoint.d.ts +0 -19
- package/lib/browser/model/debug-function-breakpoint.d.ts.map +0 -1
- package/lib/browser/model/debug-function-breakpoint.js +0 -93
- package/lib/browser/model/debug-function-breakpoint.js.map +0 -1
- package/lib/browser/model/debug-instruction-breakpoint.d.ts +0 -15
- package/lib/browser/model/debug-instruction-breakpoint.d.ts.map +0 -1
- package/lib/browser/model/debug-instruction-breakpoint.js +0 -66
- package/lib/browser/model/debug-instruction-breakpoint.js.map +0 -1
- package/lib/browser/model/debug-source-breakpoint.d.ts +0 -39
- package/lib/browser/model/debug-source-breakpoint.d.ts.map +0 -1
- package/lib/browser/model/debug-source-breakpoint.js +0 -219
- package/lib/browser/model/debug-source-breakpoint.js.map +0 -1
- package/lib/browser/model/debug-source.d.ts +0 -25
- package/lib/browser/model/debug-source.d.ts.map +0 -1
- package/lib/browser/model/debug-source.js +0 -81
- package/lib/browser/model/debug-source.js.map +0 -1
- package/lib/browser/model/debug-stack-frame.d.ts +0 -45
- package/lib/browser/model/debug-stack-frame.d.ts.map +0 -1
- package/lib/browser/model/debug-stack-frame.js +0 -157
- package/lib/browser/model/debug-stack-frame.js.map +0 -1
- package/lib/browser/model/debug-thread.d.ts +0 -68
- package/lib/browser/model/debug-thread.d.ts.map +0 -1
- package/lib/browser/model/debug-thread.js +0 -262
- package/lib/browser/model/debug-thread.js.map +0 -1
- package/lib/browser/view/debug-action.d.ts +0 -18
- package/lib/browser/view/debug-action.d.ts.map +0 -1
- package/lib/browser/view/debug-action.js +0 -44
- package/lib/browser/view/debug-action.js.map +0 -1
- package/lib/browser/view/debug-breakpoints-source.d.ts +0 -10
- package/lib/browser/view/debug-breakpoints-source.d.ts.map +0 -1
- package/lib/browser/view/debug-breakpoints-source.js +0 -63
- package/lib/browser/view/debug-breakpoints-source.js.map +0 -1
- package/lib/browser/view/debug-breakpoints-widget.d.ts +0 -23
- package/lib/browser/view/debug-breakpoints-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-breakpoints-widget.js +0 -81
- package/lib/browser/view/debug-breakpoints-widget.js.map +0 -1
- package/lib/browser/view/debug-configuration-select.d.ts +0 -67
- package/lib/browser/view/debug-configuration-select.d.ts.map +0 -1
- package/lib/browser/view/debug-configuration-select.js +0 -212
- package/lib/browser/view/debug-configuration-select.js.map +0 -1
- package/lib/browser/view/debug-configuration-widget.d.ts +0 -33
- package/lib/browser/view/debug-configuration-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-configuration-widget.js +0 -137
- package/lib/browser/view/debug-configuration-widget.js.map +0 -1
- package/lib/browser/view/debug-exception-breakpoint.d.ts +0 -15
- package/lib/browser/view/debug-exception-breakpoint.d.ts.map +0 -1
- package/lib/browser/view/debug-exception-breakpoint.js +0 -62
- package/lib/browser/view/debug-exception-breakpoint.js.map +0 -1
- package/lib/browser/view/debug-session-widget.d.ts +0 -29
- package/lib/browser/view/debug-session-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-session-widget.js +0 -127
- package/lib/browser/view/debug-session-widget.js.map +0 -1
- package/lib/browser/view/debug-stack-frames-source.d.ts +0 -18
- package/lib/browser/view/debug-stack-frames-source.d.ts.map +0 -1
- package/lib/browser/view/debug-stack-frames-source.js +0 -83
- package/lib/browser/view/debug-stack-frames-source.js.map +0 -1
- package/lib/browser/view/debug-stack-frames-widget.d.ts +0 -25
- package/lib/browser/view/debug-stack-frames-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-stack-frames-widget.js +0 -147
- package/lib/browser/view/debug-stack-frames-widget.js.map +0 -1
- package/lib/browser/view/debug-threads-source.d.ts +0 -9
- package/lib/browser/view/debug-threads-source.d.ts.map +0 -1
- package/lib/browser/view/debug-threads-source.js +0 -56
- package/lib/browser/view/debug-threads-source.js.map +0 -1
- package/lib/browser/view/debug-threads-widget.d.ts +0 -27
- package/lib/browser/view/debug-threads-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-threads-widget.js +0 -139
- package/lib/browser/view/debug-threads-widget.js.map +0 -1
- package/lib/browser/view/debug-toolbar-widget.d.ts +0 -34
- package/lib/browser/view/debug-toolbar-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-toolbar-widget.js +0 -139
- package/lib/browser/view/debug-toolbar-widget.js.map +0 -1
- package/lib/browser/view/debug-variables-source.d.ts +0 -10
- package/lib/browser/view/debug-variables-source.d.ts.map +0 -1
- package/lib/browser/view/debug-variables-source.js +0 -53
- package/lib/browser/view/debug-variables-source.js.map +0 -1
- package/lib/browser/view/debug-variables-widget.d.ts +0 -17
- package/lib/browser/view/debug-variables-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-variables-widget.js +0 -71
- package/lib/browser/view/debug-variables-widget.js.map +0 -1
- package/lib/browser/view/debug-view-model.d.ts +0 -53
- package/lib/browser/view/debug-view-model.d.ts.map +0 -1
- package/lib/browser/view/debug-view-model.js +0 -212
- package/lib/browser/view/debug-view-model.js.map +0 -1
- package/lib/browser/view/debug-watch-expression.d.ts +0 -33
- package/lib/browser/view/debug-watch-expression.d.ts.map +0 -1
- package/lib/browser/view/debug-watch-expression.js +0 -93
- package/lib/browser/view/debug-watch-expression.js.map +0 -1
- package/lib/browser/view/debug-watch-source.d.ts +0 -10
- package/lib/browser/view/debug-watch-source.d.ts.map +0 -1
- package/lib/browser/view/debug-watch-source.js +0 -51
- package/lib/browser/view/debug-watch-source.js.map +0 -1
- package/lib/browser/view/debug-watch-widget.d.ts +0 -17
- package/lib/browser/view/debug-watch-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-watch-widget.js +0 -71
- package/lib/browser/view/debug-watch-widget.js.map +0 -1
- package/lib/browser/view/debug-widget.d.ts +0 -24
- package/lib/browser/view/debug-widget.d.ts.map +0 -1
- package/lib/browser/view/debug-widget.js +0 -101
- package/lib/browser/view/debug-widget.js.map +0 -1
- package/lib/common/debug-adapter-contribution-registry.d.ts +0 -60
- package/lib/common/debug-adapter-contribution-registry.d.ts.map +0 -1
- package/lib/common/debug-adapter-contribution-registry.js +0 -205
- package/lib/common/debug-adapter-contribution-registry.js.map +0 -1
- package/lib/common/debug-adapter-session.d.ts +0 -19
- package/lib/common/debug-adapter-session.d.ts.map +0 -1
- package/lib/common/debug-adapter-session.js +0 -79
- package/lib/common/debug-adapter-session.js.map +0 -1
- package/lib/common/debug-common.d.ts +0 -2
- package/lib/common/debug-common.d.ts.map +0 -1
- package/lib/common/debug-common.js +0 -21
- package/lib/common/debug-common.js.map +0 -1
- package/lib/common/debug-compound.d.ts +0 -15
- package/lib/common/debug-compound.d.ts.map +0 -1
- package/lib/common/debug-compound.js +0 -28
- package/lib/common/debug-compound.js.map +0 -1
- package/lib/common/debug-configuration.d.ts +0 -77
- package/lib/common/debug-configuration.d.ts.map +0 -1
- package/lib/common/debug-configuration.js +0 -32
- package/lib/common/debug-configuration.js.map +0 -1
- package/lib/common/debug-model.d.ts +0 -153
- package/lib/common/debug-model.d.ts.map +0 -1
- package/lib/common/debug-model.js +0 -36
- package/lib/common/debug-model.js.map +0 -1
- package/lib/common/debug-preferences.d.ts +0 -18
- package/lib/common/debug-preferences.d.ts.map +0 -1
- package/lib/common/debug-preferences.js +0 -89
- package/lib/common/debug-preferences.js.map +0 -1
- package/lib/common/debug-service.d.ts +0 -124
- package/lib/common/debug-service.d.ts.map +0 -1
- package/lib/common/debug-service.js +0 -67
- package/lib/common/debug-service.js.map +0 -1
- package/lib/common/debug-uri-utils.d.ts +0 -24
- package/lib/common/debug-uri-utils.d.ts.map +0 -1
- package/lib/common/debug-uri-utils.js +0 -27
- package/lib/common/debug-uri-utils.js.map +0 -1
- package/lib/common/inline-debug-adapter.d.ts +0 -19
- package/lib/common/inline-debug-adapter.d.ts.map +0 -1
- package/lib/common/inline-debug-adapter.js +0 -45
- package/lib/common/inline-debug-adapter.js.map +0 -1
- package/lib/common/launch-preferences.d.ts +0 -6
- package/lib/common/launch-preferences.d.ts.map +0 -1
- package/lib/common/launch-preferences.js +0 -37
- package/lib/common/launch-preferences.js.map +0 -1
- package/lib/node/debug-adapter-factory.d.ts +0 -20
- package/lib/node/debug-adapter-factory.d.ts.map +0 -1
- package/lib/node/debug-adapter-factory.js +0 -89
- package/lib/node/debug-adapter-factory.js.map +0 -1
- package/lib/node/debug-adapter-session-manager.d.ts +0 -38
- package/lib/node/debug-adapter-session-manager.d.ts.map +0 -1
- package/lib/node/debug-adapter-session-manager.js +0 -104
- package/lib/node/debug-adapter-session-manager.js.map +0 -1
- package/lib/node/debug-backend-module.d.ts +0 -4
- package/lib/node/debug-backend-module.d.ts.map +0 -1
- package/lib/node/debug-backend-module.js +0 -45
- package/lib/node/debug-backend-module.js.map +0 -1
- package/lib/node/debug-service-impl.d.ts +0 -31
- package/lib/node/debug-service-impl.d.ts.map +0 -1
- package/lib/node/debug-service-impl.js +0 -117
- package/lib/node/debug-service-impl.js.map +0 -1
- package/lib/node/stream-debug-adapter.d.ts +0 -41
- package/lib/node/stream-debug-adapter.d.ts.map +0 -1
- package/lib/node/stream-debug-adapter.js +0 -113
- package/lib/node/stream-debug-adapter.js.map +0 -1
package/README.md
CHANGED
|
@@ -41,7 +41,7 @@ At the back-end we start a debug adapter using `DebugAdapterFactory` and then a
|
|
|
41
41
|
|
|
42
42
|
## Additional Information
|
|
43
43
|
|
|
44
|
-
* [API documentation for `@theia/debug`](https://eclipse-theia.github.io/theia/docs/next/modules/
|
|
44
|
+
* [API documentation for `@theia/debug`](https://eclipse-theia.github.io/theia/docs/next/modules/_theia_debug.html)
|
|
45
45
|
* [Theia - GitHub](https://github.com/eclipse-theia/theia)
|
|
46
46
|
* [Theia - Website](https://theia-ide.org/)
|
|
47
47
|
* [Debug Adapter Protocol](https://github.com/Microsoft/vscode-debugadapter-node/blob/master/protocol/src/debugProtocol.ts)
|
package/package.json
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@theia/debug",
|
|
3
|
-
"version": "1.67.0-next.
|
|
3
|
+
"version": "1.67.0-next.56+d8f18cc386c",
|
|
4
4
|
"description": "Theia - Debug Extension",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@theia/console": "1.67.0-next.
|
|
7
|
-
"@theia/core": "1.67.0-next.
|
|
8
|
-
"@theia/editor": "1.67.0-next.
|
|
9
|
-
"@theia/filesystem": "1.67.0-next.
|
|
10
|
-
"@theia/markers": "1.67.0-next.
|
|
11
|
-
"@theia/monaco": "1.67.0-next.
|
|
6
|
+
"@theia/console": "1.67.0-next.56+d8f18cc386c",
|
|
7
|
+
"@theia/core": "1.67.0-next.56+d8f18cc386c",
|
|
8
|
+
"@theia/editor": "1.67.0-next.56+d8f18cc386c",
|
|
9
|
+
"@theia/filesystem": "1.67.0-next.56+d8f18cc386c",
|
|
10
|
+
"@theia/markers": "1.67.0-next.56+d8f18cc386c",
|
|
11
|
+
"@theia/monaco": "1.67.0-next.56+d8f18cc386c",
|
|
12
12
|
"@theia/monaco-editor-core": "1.96.302",
|
|
13
|
-
"@theia/output": "1.67.0-next.
|
|
14
|
-
"@theia/process": "1.67.0-next.
|
|
15
|
-
"@theia/task": "1.67.0-next.
|
|
16
|
-
"@theia/terminal": "1.67.0-next.
|
|
17
|
-
"@theia/test": "1.67.0-next.
|
|
18
|
-
"@theia/variable-resolver": "1.67.0-next.
|
|
19
|
-
"@theia/workspace": "1.67.0-next.
|
|
13
|
+
"@theia/output": "1.67.0-next.56+d8f18cc386c",
|
|
14
|
+
"@theia/process": "1.67.0-next.56+d8f18cc386c",
|
|
15
|
+
"@theia/task": "1.67.0-next.56+d8f18cc386c",
|
|
16
|
+
"@theia/terminal": "1.67.0-next.56+d8f18cc386c",
|
|
17
|
+
"@theia/test": "1.67.0-next.56+d8f18cc386c",
|
|
18
|
+
"@theia/variable-resolver": "1.67.0-next.56+d8f18cc386c",
|
|
19
|
+
"@theia/workspace": "1.67.0-next.56+d8f18cc386c",
|
|
20
20
|
"@vscode/debugprotocol": "^1.51.0",
|
|
21
21
|
"fast-deep-equal": "^3.1.3",
|
|
22
22
|
"jsonc-parser": "^2.2.0",
|
|
@@ -64,5 +64,5 @@
|
|
|
64
64
|
"nyc": {
|
|
65
65
|
"extends": "../../configs/nyc.json"
|
|
66
66
|
},
|
|
67
|
-
"gitHead": "
|
|
67
|
+
"gitHead": "d8f18cc386c45a736cd193d42eab02c8f64c6b10"
|
|
68
68
|
}
|
|
@@ -21,7 +21,8 @@ import { StorageService } from '@theia/core/lib/browser';
|
|
|
21
21
|
import { Marker } from '@theia/markers/lib/common/marker';
|
|
22
22
|
import { MarkerManager } from '@theia/markers/lib/browser/marker-manager';
|
|
23
23
|
import URI from '@theia/core/lib/common/uri';
|
|
24
|
-
import { SourceBreakpoint, BREAKPOINT_KIND, ExceptionBreakpoint, FunctionBreakpoint, BaseBreakpoint, InstructionBreakpoint } from './breakpoint-marker';
|
|
24
|
+
import { SourceBreakpoint, BREAKPOINT_KIND, ExceptionBreakpoint, FunctionBreakpoint, BaseBreakpoint, InstructionBreakpoint, DataBreakpoint } from './breakpoint-marker';
|
|
25
|
+
import { DebugProtocol } from '@vscode/debugprotocol';
|
|
25
26
|
|
|
26
27
|
export interface BreakpointsChangeEvent<T extends BaseBreakpoint> {
|
|
27
28
|
uri: URI
|
|
@@ -32,6 +33,7 @@ export interface BreakpointsChangeEvent<T extends BaseBreakpoint> {
|
|
|
32
33
|
export type SourceBreakpointsChangeEvent = BreakpointsChangeEvent<SourceBreakpoint>;
|
|
33
34
|
export type FunctionBreakpointsChangeEvent = BreakpointsChangeEvent<FunctionBreakpoint>;
|
|
34
35
|
export type InstructionBreakpointsChangeEvent = BreakpointsChangeEvent<InstructionBreakpoint>;
|
|
36
|
+
export type DataBreakpointsChangeEvent = BreakpointsChangeEvent<DataBreakpoint>;
|
|
35
37
|
|
|
36
38
|
@injectable()
|
|
37
39
|
export class BreakpointManager extends MarkerManager<SourceBreakpoint> {
|
|
@@ -42,6 +44,8 @@ export class BreakpointManager extends MarkerManager<SourceBreakpoint> {
|
|
|
42
44
|
|
|
43
45
|
static INSTRUCTION_URI = new URI('debug:instruction://');
|
|
44
46
|
|
|
47
|
+
static DATA_URI = new URI('debug:data://');
|
|
48
|
+
|
|
45
49
|
protected readonly owner = 'breakpoint';
|
|
46
50
|
|
|
47
51
|
@inject(StorageService)
|
|
@@ -60,6 +64,9 @@ export class BreakpointManager extends MarkerManager<SourceBreakpoint> {
|
|
|
60
64
|
protected readonly onDidChangeInstructionBreakpointsEmitter = new Emitter<InstructionBreakpointsChangeEvent>();
|
|
61
65
|
readonly onDidChangeInstructionBreakpoints = this.onDidChangeInstructionBreakpointsEmitter.event;
|
|
62
66
|
|
|
67
|
+
protected readonly onDidChangeDataBreakpointsEmitter = new Emitter<DataBreakpointsChangeEvent>();
|
|
68
|
+
readonly onDidChangeDataBreakpoints = this.onDidChangeDataBreakpointsEmitter.event;
|
|
69
|
+
|
|
63
70
|
override setMarkers(uri: URI, owner: string, newMarkers: SourceBreakpoint[]): Marker<SourceBreakpoint>[] {
|
|
64
71
|
const result = this.findMarkers({ uri, owner });
|
|
65
72
|
const added: SourceBreakpoint[] = [];
|
|
@@ -254,21 +261,8 @@ export class BreakpointManager extends MarkerManager<SourceBreakpoint> {
|
|
|
254
261
|
}
|
|
255
262
|
|
|
256
263
|
protected setInstructionBreakpoints(newBreakpoints: InstructionBreakpoint[]): void {
|
|
257
|
-
const
|
|
258
|
-
|
|
259
|
-
const added = [];
|
|
260
|
-
const changed = [];
|
|
261
|
-
for (const [id, breakpoint] of currentBreakpoints.entries()) {
|
|
262
|
-
const old = oldBreakpoints.get(id);
|
|
263
|
-
if (old) {
|
|
264
|
-
changed.push(old);
|
|
265
|
-
} else {
|
|
266
|
-
added.push(breakpoint);
|
|
267
|
-
}
|
|
268
|
-
oldBreakpoints.delete(id);
|
|
269
|
-
}
|
|
270
|
-
const removed = Array.from(oldBreakpoints.values());
|
|
271
|
-
this.instructionBreakpoints = Array.from(currentBreakpoints.values());
|
|
264
|
+
const { added, removed, changed } = diff(this.instructionBreakpoints, newBreakpoints, bp => bp.id);
|
|
265
|
+
this.instructionBreakpoints = newBreakpoints.slice();
|
|
272
266
|
this.fireOnDidChangeMarkers(BreakpointManager.INSTRUCTION_URI);
|
|
273
267
|
this.onDidChangeInstructionBreakpointsEmitter.fire({ uri: BreakpointManager.INSTRUCTION_URI, added, removed, changed });
|
|
274
268
|
}
|
|
@@ -307,10 +301,45 @@ export class BreakpointManager extends MarkerManager<SourceBreakpoint> {
|
|
|
307
301
|
this.setInstructionBreakpoints([]);
|
|
308
302
|
}
|
|
309
303
|
|
|
304
|
+
protected dataBreakpoints: DataBreakpoint[] = [];
|
|
305
|
+
|
|
306
|
+
getDataBreakpoints(): readonly DataBreakpoint[] {
|
|
307
|
+
return Object.freeze(this.dataBreakpoints.slice());
|
|
308
|
+
}
|
|
309
|
+
|
|
310
|
+
setDataBreakpoints(breakpoints: DataBreakpoint[]): void {
|
|
311
|
+
const { added, removed, changed } = diff(this.dataBreakpoints, breakpoints, ({ id }) => id);
|
|
312
|
+
this.dataBreakpoints = breakpoints.slice();
|
|
313
|
+
this.fireOnDidChangeMarkers(BreakpointManager.DATA_URI);
|
|
314
|
+
this.onDidChangeDataBreakpointsEmitter.fire({ uri: BreakpointManager.DATA_URI, added, removed, changed });
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
addDataBreakpoint(breakpoint: DataBreakpoint): void {
|
|
318
|
+
this.setDataBreakpoints(this.dataBreakpoints.concat(breakpoint));
|
|
319
|
+
}
|
|
320
|
+
|
|
321
|
+
updateDataBreakpoint(id: string, options: { enabled?: boolean; raw?: Partial<Omit<DebugProtocol.DataBreakpoint, 'dataId'>> }): void {
|
|
322
|
+
const breakpoint = this.dataBreakpoints.find(bp => bp.id === id);
|
|
323
|
+
if (!breakpoint) { return; }
|
|
324
|
+
Object.assign(breakpoint.raw, options);
|
|
325
|
+
breakpoint.enabled = options.enabled ?? breakpoint.enabled;
|
|
326
|
+
this.fireOnDidChangeMarkers(BreakpointManager.DATA_URI);
|
|
327
|
+
this.onDidChangeDataBreakpointsEmitter.fire({ uri: BreakpointManager.DATA_URI, added: [], removed: [], changed: [breakpoint] });
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
removeDataBreakpoint(id: string): void {
|
|
331
|
+
const index = this.dataBreakpoints.findIndex(bp => bp.id === id);
|
|
332
|
+
if (~index) { return; }
|
|
333
|
+
const removed = this.dataBreakpoints.splice(index);
|
|
334
|
+
this.fireOnDidChangeMarkers(BreakpointManager.DATA_URI);
|
|
335
|
+
this.onDidChangeDataBreakpointsEmitter.fire({ uri: BreakpointManager.DATA_URI, added: [], removed, changed: [] });
|
|
336
|
+
}
|
|
337
|
+
|
|
310
338
|
removeBreakpoints(): void {
|
|
311
339
|
this.cleanAllMarkers();
|
|
312
340
|
this.setFunctionBreakpoints([]);
|
|
313
341
|
this.setInstructionBreakpoints([]);
|
|
342
|
+
this.setDataBreakpoints([]);
|
|
314
343
|
}
|
|
315
344
|
|
|
316
345
|
async load(): Promise<void> {
|
|
@@ -352,6 +381,11 @@ export class BreakpointManager extends MarkerManager<SourceBreakpoint> {
|
|
|
352
381
|
if (this.instructionBreakpoints.length) {
|
|
353
382
|
data.instructionBreakpoints = this.instructionBreakpoints;
|
|
354
383
|
}
|
|
384
|
+
const dataBreakpointsToStore = this.dataBreakpoints.filter(candidate => candidate.info.canPersist);
|
|
385
|
+
if (dataBreakpointsToStore.length) {
|
|
386
|
+
data.dataBreakpoints = dataBreakpointsToStore;
|
|
387
|
+
}
|
|
388
|
+
|
|
355
389
|
this.storage.setData('breakpoints', data);
|
|
356
390
|
}
|
|
357
391
|
|
|
@@ -365,5 +399,24 @@ export namespace BreakpointManager {
|
|
|
365
399
|
exceptionBreakpoints?: ExceptionBreakpoint[];
|
|
366
400
|
functionBreakpoints?: FunctionBreakpoint[];
|
|
367
401
|
instructionBreakpoints?: InstructionBreakpoint[];
|
|
402
|
+
dataBreakpoints?: DataBreakpoint[];
|
|
403
|
+
}
|
|
404
|
+
}
|
|
405
|
+
|
|
406
|
+
export function diff<T>(prevs: T[], nexts: T[], toKey: (member: T) => string): { added: T[], removed: T[], changed: T[] } {
|
|
407
|
+
const old = new Map(prevs.map(item => [toKey(item), item]));
|
|
408
|
+
const current = new Map(nexts.map(item => [toKey(item), item]));
|
|
409
|
+
const added = [];
|
|
410
|
+
const changed = [];
|
|
411
|
+
for (const [id, next] of current.entries()) {
|
|
412
|
+
const prev = old.get(id);
|
|
413
|
+
if (prev) {
|
|
414
|
+
changed.push(prev);
|
|
415
|
+
} else {
|
|
416
|
+
added.push(next);
|
|
417
|
+
}
|
|
418
|
+
old.delete(id);
|
|
368
419
|
}
|
|
420
|
+
const removed = Array.from(old.values());
|
|
421
|
+
return { added, removed, changed };
|
|
369
422
|
}
|
|
@@ -102,3 +102,41 @@ export namespace InstructionBreakpoint {
|
|
|
102
102
|
return isObject<InstructionBreakpoint>(arg) && isString(arg.instructionReference);
|
|
103
103
|
}
|
|
104
104
|
}
|
|
105
|
+
|
|
106
|
+
export type DataBreakpointInfo = DebugProtocol.DataBreakpointInfoResponse['body'];
|
|
107
|
+
|
|
108
|
+
export interface DataBreakpointAddressSource {
|
|
109
|
+
type: DataBreakpointSourceType.Address;
|
|
110
|
+
address: string;
|
|
111
|
+
bytes: number;
|
|
112
|
+
}
|
|
113
|
+
|
|
114
|
+
export interface DataBreakpointVariableSource {
|
|
115
|
+
type: DataBreakpointSourceType.Variable;
|
|
116
|
+
variable: string;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
export const enum DataBreakpointSourceType {
|
|
120
|
+
Variable,
|
|
121
|
+
Address,
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
export type DataBreakpointSource = | DataBreakpointAddressSource | DataBreakpointVariableSource;
|
|
125
|
+
|
|
126
|
+
export interface DataBreakpoint extends BaseBreakpoint {
|
|
127
|
+
raw: DebugProtocol.DataBreakpoint;
|
|
128
|
+
info: DataBreakpointInfo;
|
|
129
|
+
source: DataBreakpointSource;
|
|
130
|
+
}
|
|
131
|
+
|
|
132
|
+
export namespace DataBreakpoint {
|
|
133
|
+
export function create(raw: DebugProtocol.DataBreakpoint, info: DataBreakpointInfo, source: DataBreakpointSource, ref?: DataBreakpoint): DataBreakpoint {
|
|
134
|
+
return {
|
|
135
|
+
raw,
|
|
136
|
+
info,
|
|
137
|
+
id: ref?.id ?? UUID.uuid4(),
|
|
138
|
+
enabled: ref?.enabled ?? true,
|
|
139
|
+
source
|
|
140
|
+
};
|
|
141
|
+
}
|
|
142
|
+
}
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
// *****************************************************************************
|
|
2
|
+
// Copyright (C) 2025 EclipseSource GmbH and others.
|
|
3
|
+
//
|
|
4
|
+
// This program and the accompanying materials are made available under the
|
|
5
|
+
// terms of the Eclipse Public License v. 2.0 which is available at
|
|
6
|
+
// http://www.eclipse.org/legal/epl-2.0.
|
|
7
|
+
//
|
|
8
|
+
// This Source Code may also be made available under the following Secondary
|
|
9
|
+
// Licenses when the conditions for such availability set forth in the Eclipse
|
|
10
|
+
// Public License v. 2.0 are satisfied: GNU General Public License, version 2
|
|
11
|
+
// with the GNU Classpath Exception which is available at
|
|
12
|
+
// https://www.gnu.org/software/classpath/license.html.
|
|
13
|
+
//
|
|
14
|
+
// SPDX-License-Identifier: EPL-2.0 OR GPL-2.0-only WITH Classpath-exception-2.0
|
|
15
|
+
// *****************************************************************************
|
|
16
|
+
|
|
17
|
+
import { nls, CommandHandler, DisposableCollection, MessageService, QuickInputService, Disposable } from '@theia/core';
|
|
18
|
+
import { inject, injectable } from '@theia/core/shared/inversify';
|
|
19
|
+
import { DebugViewModel } from '../view/debug-view-model';
|
|
20
|
+
import { TreeElementNode } from '@theia/core/lib/browser/source-tree';
|
|
21
|
+
import { DebugDataBreakpoint } from '../model/debug-data-breakpoint';
|
|
22
|
+
import { DataBreakpoint, DataBreakpointSource, DataBreakpointSourceType } from './breakpoint-marker';
|
|
23
|
+
import { DebugProtocol } from '@vscode/debugprotocol';
|
|
24
|
+
import { BreakpointManager } from './breakpoint-manager';
|
|
25
|
+
import { TreeNode, Widget } from '@theia/core/lib/browser';
|
|
26
|
+
import { DebugBreakpointsWidget } from '../view/debug-breakpoints-widget';
|
|
27
|
+
|
|
28
|
+
// Adapted from https://github.com/microsoft/vscode/blob/9c883243a89e7ec3b730d3746fbb1e836d5e4f52/src/vs/workbench/contrib/debug/browser/breakpointsView.ts#L1506-L1625
|
|
29
|
+
|
|
30
|
+
@injectable()
|
|
31
|
+
export class AddOrEditDataBreakpointAddress implements CommandHandler {
|
|
32
|
+
@inject(DebugViewModel)
|
|
33
|
+
protected readonly viewModel: DebugViewModel;
|
|
34
|
+
@inject(QuickInputService)
|
|
35
|
+
protected readonly quickInputService: QuickInputService;
|
|
36
|
+
@inject(MessageService)
|
|
37
|
+
protected readonly messageService: MessageService;
|
|
38
|
+
@inject(BreakpointManager)
|
|
39
|
+
protected readonly breakpointManager: BreakpointManager;
|
|
40
|
+
|
|
41
|
+
isEnabled(node?: TreeElementNode): boolean {
|
|
42
|
+
return !!this.viewModel.currentSession?.capabilities.supportsDataBreakpoints
|
|
43
|
+
&& this.viewModel.currentSession?.capabilities.supportsDataBreakpointBytes !== false
|
|
44
|
+
&& this.isAddressBreakpointOrDebugWidget(node);
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
isVisible(node?: TreeElementNode): boolean {
|
|
48
|
+
return this.isEnabled(node);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
protected isAddressBreakpointOrDebugWidget(candidate?: unknown): boolean {
|
|
52
|
+
return !candidate ? true // Probably command palette
|
|
53
|
+
: TreeNode.is(candidate) && TreeElementNode.is(candidate)
|
|
54
|
+
? candidate.element instanceof DebugDataBreakpoint && candidate.element.origin.source.type === DataBreakpointSourceType.Address
|
|
55
|
+
: candidate instanceof Widget
|
|
56
|
+
? candidate instanceof DebugBreakpointsWidget
|
|
57
|
+
: false;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
async execute(node?: TreeElementNode): Promise<void> {
|
|
61
|
+
const existingBreakpoint = TreeElementNode.is(node) && node.element instanceof DebugDataBreakpoint ? node.element : undefined;
|
|
62
|
+
const session = this.viewModel.currentSession;
|
|
63
|
+
if (!session) {
|
|
64
|
+
return;
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
let defaultValue = undefined;
|
|
68
|
+
if (existingBreakpoint?.origin.source.type === DataBreakpointSourceType.Address) {
|
|
69
|
+
defaultValue = `${existingBreakpoint.origin.source.address} + ${existingBreakpoint.origin.source.bytes}`;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
const quickInput = this.quickInputService;
|
|
73
|
+
const range = await this.getRange(defaultValue);
|
|
74
|
+
if (!range) {
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
|
|
78
|
+
const info = await session.sendRequest('dataBreakpointInfo', { asAddress: true, name: range.address, bytes: range.bytes })
|
|
79
|
+
.then(({ body }) => body)
|
|
80
|
+
.catch(e => { this.messageService.error(nls.localizeByDefault('Failed to set data breakpoint at {0}: {1}', range.address, e.message)); });
|
|
81
|
+
if (!info?.dataId) {
|
|
82
|
+
return;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
let accessType: DebugProtocol.DataBreakpointAccessType = 'write';
|
|
86
|
+
if (info.accessTypes && info.accessTypes?.length > 1) {
|
|
87
|
+
const accessTypes = info.accessTypes.map(type => ({ label: type }));
|
|
88
|
+
const selectedAccessType = await quickInput.pick(accessTypes, { placeHolder: nls.localizeByDefault('Select the access type to monitor') });
|
|
89
|
+
if (!selectedAccessType) {
|
|
90
|
+
return;
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
accessType = selectedAccessType.label;
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
const src: DataBreakpointSource = { type: DataBreakpointSourceType.Address, ...range };
|
|
97
|
+
if (existingBreakpoint) {
|
|
98
|
+
this.breakpointManager.removeDataBreakpoint(existingBreakpoint.id);
|
|
99
|
+
}
|
|
100
|
+
|
|
101
|
+
this.breakpointManager.addDataBreakpoint(DataBreakpoint.create({ dataId: info.dataId, accessType }, { ...info, canPersist: true }, src));
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
private getRange(defaultValue?: string): Promise<{ address: string, bytes: number } | undefined> {
|
|
105
|
+
return new Promise(resolve => {
|
|
106
|
+
const disposables = new DisposableCollection();
|
|
107
|
+
const addDisposable = <T extends Disposable>(disposable: T): T => {
|
|
108
|
+
disposables.push(disposable);
|
|
109
|
+
return disposable;
|
|
110
|
+
};
|
|
111
|
+
const input = addDisposable(this.quickInputService.createInputBox());
|
|
112
|
+
input.prompt = nls.localizeByDefault('Enter a memory range in which to break');
|
|
113
|
+
input.placeholder = nls.localizeByDefault('Absolute range (0x1234 - 0x1300) or range of bytes after an address (0x1234 + 0xff)');
|
|
114
|
+
if (defaultValue) {
|
|
115
|
+
input.value = defaultValue;
|
|
116
|
+
input.valueSelection = [0, defaultValue.length];
|
|
117
|
+
}
|
|
118
|
+
addDisposable(input.onDidChangeValue(e => {
|
|
119
|
+
const err = this.parseAddress(e, false);
|
|
120
|
+
input.validationMessage = err?.error;
|
|
121
|
+
}));
|
|
122
|
+
addDisposable(input.onDidAccept(() => {
|
|
123
|
+
const r = this.parseAddress(input.value ?? '', true);
|
|
124
|
+
if ('error' in r) {
|
|
125
|
+
input.validationMessage = r.error;
|
|
126
|
+
} else {
|
|
127
|
+
resolve(r);
|
|
128
|
+
}
|
|
129
|
+
input.dispose();
|
|
130
|
+
}));
|
|
131
|
+
addDisposable(input.onDidHide(() => {
|
|
132
|
+
resolve(undefined);
|
|
133
|
+
disposables.dispose();
|
|
134
|
+
}));
|
|
135
|
+
input.ignoreFocusOut = true;
|
|
136
|
+
input.show();
|
|
137
|
+
});
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
private parseAddress(range: string, isFinal: false): { error: string } | undefined;
|
|
141
|
+
private parseAddress(range: string, isFinal: true): { error: string } | { address: string; bytes: number };
|
|
142
|
+
private parseAddress(range: string, isFinal: boolean): { error: string } | { address: string; bytes: number } | undefined {
|
|
143
|
+
const parts = /^(\S+)\s*(?:([+-])\s*(\S+))?/.exec(range);
|
|
144
|
+
if (!parts) {
|
|
145
|
+
return { error: nls.localizeByDefault('Address should be a range of numbers the form "[Start] - [End]" or "[Start] + [Bytes]"') };
|
|
146
|
+
}
|
|
147
|
+
|
|
148
|
+
const isNum = (e: string) => isFinal ? /^0x[0-9a-f]*|[0-9]*$/i.test(e) : /^0x[0-9a-f]+|[0-9]+$/i.test(e);
|
|
149
|
+
const [, startStr, sign = '+', endStr = '1'] = parts;
|
|
150
|
+
|
|
151
|
+
for (const n of [startStr, endStr]) {
|
|
152
|
+
if (!isNum(n)) {
|
|
153
|
+
return { error: nls.localizeByDefault('Number must be a decimal integer or hex value starting with \"0x\", got {0}', n) };
|
|
154
|
+
}
|
|
155
|
+
}
|
|
156
|
+
|
|
157
|
+
if (!isFinal) {
|
|
158
|
+
return;
|
|
159
|
+
}
|
|
160
|
+
|
|
161
|
+
const start = BigInt(startStr);
|
|
162
|
+
const end = BigInt(endStr);
|
|
163
|
+
const address = `0x${start.toString(16)}`;
|
|
164
|
+
if (sign === '-') {
|
|
165
|
+
return { address, bytes: Number(start - end) };
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
return { address, bytes: Number(end) };
|
|
169
|
+
}
|
|
170
|
+
}
|
|
@@ -51,8 +51,12 @@ export class ExpressionContainer implements CompositeConsoleItem {
|
|
|
51
51
|
return undefined;
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
+
get reference(): number | undefined {
|
|
55
|
+
return this.variablesReference;
|
|
56
|
+
}
|
|
57
|
+
|
|
54
58
|
get hasElements(): boolean {
|
|
55
|
-
return
|
|
59
|
+
return this.variablesReference !== undefined;
|
|
56
60
|
}
|
|
57
61
|
|
|
58
62
|
protected elements: Promise<ExpressionContainer[]> | undefined;
|
|
@@ -63,6 +63,7 @@ import { ConsoleContentWidget } from '@theia/console/lib/browser/console-content
|
|
|
63
63
|
import { ConsoleContextMenu } from '@theia/console/lib/browser/console-contribution';
|
|
64
64
|
import { DebugHoverWidget } from './editor/debug-hover-widget';
|
|
65
65
|
import { DebugExpressionProvider } from './editor/debug-expression-provider';
|
|
66
|
+
import { AddOrEditDataBreakpointAddress } from './breakpoint/debug-data-breakpoint-actions';
|
|
66
67
|
|
|
67
68
|
export namespace DebugMenus {
|
|
68
69
|
export const DEBUG = [...MAIN_MENU_BAR, '6_debug'];
|
|
@@ -198,6 +199,11 @@ export namespace DebugCommands {
|
|
|
198
199
|
category: DEBUG_CATEGORY,
|
|
199
200
|
label: 'Add Function Breakpoint',
|
|
200
201
|
});
|
|
202
|
+
export const ADD_DATA_BREAKPOINT = Command.toDefaultLocalizedCommand({
|
|
203
|
+
id: 'debug.breakpoint.add.data',
|
|
204
|
+
category: DEBUG_CATEGORY,
|
|
205
|
+
label: 'Add Data Breakpoint at Address'
|
|
206
|
+
});
|
|
201
207
|
export const ENABLE_SELECTED_BREAKPOINTS = Command.toLocalizedCommand({
|
|
202
208
|
id: 'debug.breakpoint.enableSelected',
|
|
203
209
|
category: DEBUG_CATEGORY,
|
|
@@ -483,6 +489,9 @@ export class DebugFrontendApplicationContribution extends AbstractViewContributi
|
|
|
483
489
|
@inject(MessageService)
|
|
484
490
|
protected readonly messageService: MessageService;
|
|
485
491
|
|
|
492
|
+
@inject(AddOrEditDataBreakpointAddress)
|
|
493
|
+
protected readonly AddOrEditDataBreakpointAddress: AddOrEditDataBreakpointAddress;
|
|
494
|
+
|
|
486
495
|
constructor() {
|
|
487
496
|
super({
|
|
488
497
|
widgetId: DebugWidget.ID,
|
|
@@ -612,6 +621,7 @@ export class DebugFrontendApplicationContribution extends AbstractViewContributi
|
|
|
612
621
|
DebugCommands.INLINE_BREAKPOINT,
|
|
613
622
|
DebugCommands.ADD_FUNCTION_BREAKPOINT,
|
|
614
623
|
DebugCommands.ADD_LOGPOINT,
|
|
624
|
+
DebugCommands.ADD_DATA_BREAKPOINT
|
|
615
625
|
);
|
|
616
626
|
registerMenuActions(DebugMenus.DEBUG_BREAKPOINTS,
|
|
617
627
|
DebugCommands.ENABLE_ALL_BREAKPOINTS,
|
|
@@ -671,6 +681,7 @@ export class DebugFrontendApplicationContribution extends AbstractViewContributi
|
|
|
671
681
|
|
|
672
682
|
registerMenuActions(DebugBreakpointsWidget.EDIT_MENU,
|
|
673
683
|
DebugCommands.EDIT_BREAKPOINT,
|
|
684
|
+
{ ...DebugCommands.ADD_DATA_BREAKPOINT, label: nls.localizeByDefault('Edit Address...'), originalLabel: 'Edit Address...' },
|
|
674
685
|
DebugCommands.EDIT_LOGPOINT,
|
|
675
686
|
DebugCommands.EDIT_BREAKPOINT_CONDITION
|
|
676
687
|
);
|
|
@@ -863,6 +874,7 @@ export class DebugFrontendApplicationContribution extends AbstractViewContributi
|
|
|
863
874
|
isEnabled: widget => !(widget instanceof Widget) || widget instanceof DebugBreakpointsWidget,
|
|
864
875
|
isVisible: widget => !(widget instanceof Widget) || widget instanceof DebugBreakpointsWidget
|
|
865
876
|
});
|
|
877
|
+
registry.registerCommand(DebugCommands.ADD_DATA_BREAKPOINT, this.AddOrEditDataBreakpointAddress);
|
|
866
878
|
registry.registerCommand(DebugCommands.ENABLE_ALL_BREAKPOINTS, {
|
|
867
879
|
execute: () => this.breakpointManager.enableAllBreakpoints(true),
|
|
868
880
|
isEnabled: () => this.breakpointManager.hasBreakpoints()
|
|
@@ -1314,6 +1326,13 @@ export class DebugFrontendApplicationContribution extends AbstractViewContributi
|
|
|
1314
1326
|
icon: codicon('add'),
|
|
1315
1327
|
tooltip: DebugCommands.ADD_FUNCTION_BREAKPOINT.label
|
|
1316
1328
|
});
|
|
1329
|
+
toolbar.registerItem({
|
|
1330
|
+
id: DebugCommands.ADD_DATA_BREAKPOINT.id,
|
|
1331
|
+
command: DebugCommands.ADD_DATA_BREAKPOINT.id,
|
|
1332
|
+
icon: codicon('variable-group'),
|
|
1333
|
+
tooltip: DebugCommands.ADD_DATA_BREAKPOINT.label,
|
|
1334
|
+
onDidChange: this.manager.onDidStopDebugSession as unknown as Event<void>
|
|
1335
|
+
});
|
|
1317
1336
|
updateToggleBreakpointsEnabled();
|
|
1318
1337
|
this.breakpointManager.onDidChangeBreakpoints(updateToggleBreakpointsEnabled);
|
|
1319
1338
|
toolbar.registerItem(toggleBreakpointsEnabled);
|
|
@@ -64,6 +64,7 @@ import { bindDisassemblyView } from './disassembly-view/disassembly-view-contrib
|
|
|
64
64
|
import { StandaloneServices } from '@theia/monaco-editor-core/esm/vs/editor/standalone/browser/standaloneServices';
|
|
65
65
|
import { ICodeEditorService } from '@theia/monaco-editor-core/esm/vs/editor/browser/services/codeEditorService';
|
|
66
66
|
import { DebugSessionConfigurationLabelProvider } from './debug-session-configuration-label-provider';
|
|
67
|
+
import { AddOrEditDataBreakpointAddress } from './breakpoint/debug-data-breakpoint-actions';
|
|
67
68
|
|
|
68
69
|
export default new ContainerModule((bind: interfaces.Bind) => {
|
|
69
70
|
bindContributionProvider(bind, DebugContribution);
|
|
@@ -135,4 +136,5 @@ export default new ContainerModule((bind: interfaces.Bind) => {
|
|
|
135
136
|
bindDisassemblyView(bind);
|
|
136
137
|
|
|
137
138
|
bind(DebugSessionConfigurationLabelProvider).toSelf().inSingletonScope();
|
|
139
|
+
bind(AddOrEditDataBreakpointAddress).toSelf().inSingletonScope();
|
|
138
140
|
});
|
|
@@ -38,6 +38,7 @@ import { DebugFunctionBreakpoint } from './model/debug-function-breakpoint';
|
|
|
38
38
|
import * as monaco from '@theia/monaco-editor-core';
|
|
39
39
|
import { DebugInstructionBreakpoint } from './model/debug-instruction-breakpoint';
|
|
40
40
|
import { DebugSessionConfigurationLabelProvider } from './debug-session-configuration-label-provider';
|
|
41
|
+
import { DebugDataBreakpoint } from './model/debug-data-breakpoint';
|
|
41
42
|
|
|
42
43
|
export interface WillStartDebugSession extends WaitUntilEvent {
|
|
43
44
|
}
|
|
@@ -449,6 +450,15 @@ export class DebugSessionManager {
|
|
|
449
450
|
}
|
|
450
451
|
|
|
451
452
|
protected cleanup(session: DebugSession): void {
|
|
453
|
+
// Data breakpoints belonging to this session that can't persist and aren't verified by some other session should be removed.
|
|
454
|
+
const currentDataBreakpoints = this.breakpoints.getDataBreakpoints();
|
|
455
|
+
const toRemove = currentDataBreakpoints.filter(candidate => !candidate.info.canPersist && this.sessions.every(otherSession => otherSession !== session
|
|
456
|
+
&& otherSession.getDataBreakpoints().every(otherSessionBp => otherSessionBp.id !== candidate.id || !otherSessionBp.verified)))
|
|
457
|
+
.map(bp => bp.id);
|
|
458
|
+
const toRetain = this.breakpoints.getDataBreakpoints().filter(candidate => !toRemove.includes(candidate.id));
|
|
459
|
+
if (currentDataBreakpoints.length !== toRetain.length) {
|
|
460
|
+
this.breakpoints.setDataBreakpoints(toRetain);
|
|
461
|
+
}
|
|
452
462
|
if (this.remove(session.id)) {
|
|
453
463
|
this.onDidDestroyDebugSessionEmitter.fire(session);
|
|
454
464
|
}
|
|
@@ -604,6 +614,14 @@ export class DebugSessionManager {
|
|
|
604
614
|
return this.breakpoints.getInstructionBreakpoints().map(origin => new DebugInstructionBreakpoint(origin, { labelProvider, breakpoints, editorManager }));
|
|
605
615
|
}
|
|
606
616
|
|
|
617
|
+
getDataBreakpoints(session = this.currentSession): DebugDataBreakpoint[] {
|
|
618
|
+
if (session && session.state > DebugState.Initializing) {
|
|
619
|
+
return session.getDataBreakpoints();
|
|
620
|
+
}
|
|
621
|
+
const { labelProvider, breakpoints, editorManager } = this;
|
|
622
|
+
return this.breakpoints.getDataBreakpoints().map(origin => new DebugDataBreakpoint(origin, { labelProvider, breakpoints, editorManager }));
|
|
623
|
+
}
|
|
624
|
+
|
|
607
625
|
getBreakpoints(session?: DebugSession): DebugSourceBreakpoint[];
|
|
608
626
|
getBreakpoints(uri: URI, session?: DebugSession): DebugSourceBreakpoint[];
|
|
609
627
|
getBreakpoints(arg?: URI | DebugSession, arg2?: DebugSession): DebugSourceBreakpoint[] {
|
|
@@ -46,6 +46,7 @@ import { DebugInstructionBreakpoint } from './model/debug-instruction-breakpoint
|
|
|
46
46
|
import { nls } from '@theia/core';
|
|
47
47
|
import { TestService, TestServices } from '@theia/test/lib/browser/test-service';
|
|
48
48
|
import { DebugSessionManager } from './debug-session-manager';
|
|
49
|
+
import { DebugDataBreakpoint } from './model/debug-data-breakpoint';
|
|
49
50
|
|
|
50
51
|
export enum DebugState {
|
|
51
52
|
Inactive,
|
|
@@ -624,6 +625,14 @@ export class DebugSession implements CompositeTreeElement {
|
|
|
624
625
|
return this.breakpoints.getInstructionBreakpoints().map(origin => new DebugInstructionBreakpoint(origin, this.asDebugBreakpointOptions()));
|
|
625
626
|
}
|
|
626
627
|
|
|
628
|
+
getDataBreakpoints(): DebugDataBreakpoint[] {
|
|
629
|
+
if (this.capabilities.supportsDataBreakpoints) {
|
|
630
|
+
return this.getBreakpoints(BreakpointManager.DATA_URI)
|
|
631
|
+
.filter((breakpoint): breakpoint is DebugDataBreakpoint => breakpoint instanceof DebugDataBreakpoint);
|
|
632
|
+
}
|
|
633
|
+
return this.breakpoints.getDataBreakpoints().map(origin => new DebugDataBreakpoint(origin, this.asDebugBreakpointOptions()));
|
|
634
|
+
}
|
|
635
|
+
|
|
627
636
|
getBreakpoints(uri?: URI): DebugBreakpoint[] {
|
|
628
637
|
if (uri) {
|
|
629
638
|
return this._breakpoints.get(uri.toString()) || [];
|
|
@@ -730,6 +739,8 @@ export class DebugSession implements CompositeTreeElement {
|
|
|
730
739
|
await this.sendFunctionBreakpoints(affectedUri);
|
|
731
740
|
} else if (affectedUri.toString() === BreakpointManager.INSTRUCTION_URI.toString()) {
|
|
732
741
|
await this.sendInstructionBreakpoints();
|
|
742
|
+
} else if (affectedUri.isEqual(BreakpointManager.DATA_URI)) {
|
|
743
|
+
await this.sendDataBreakpoints();
|
|
733
744
|
} else {
|
|
734
745
|
await this.sendSourceBreakpoints(affectedUri, sourceModified);
|
|
735
746
|
}
|
|
@@ -855,6 +866,25 @@ export class DebugSession implements CompositeTreeElement {
|
|
|
855
866
|
this.setBreakpoints(BreakpointManager.INSTRUCTION_URI, all);
|
|
856
867
|
}
|
|
857
868
|
|
|
869
|
+
protected async sendDataBreakpoints(): Promise<void> {
|
|
870
|
+
if (!this.capabilities.supportsDataBreakpoints) { return; }
|
|
871
|
+
const known = this._breakpoints.get(BreakpointManager.DATA_URI.toString());
|
|
872
|
+
const all = this.breakpoints.getDataBreakpoints().map<DebugDataBreakpoint>(bp =>
|
|
873
|
+
known?.find((candidate): candidate is DebugDataBreakpoint => candidate instanceof DebugDataBreakpoint && candidate.id === bp.id)
|
|
874
|
+
?? new DebugDataBreakpoint(bp, this.asDebugBreakpointOptions())
|
|
875
|
+
);
|
|
876
|
+
const enabled = all.filter(bp => bp.enabled);
|
|
877
|
+
try {
|
|
878
|
+
const response = await this.sendRequest('setDataBreakpoints', {
|
|
879
|
+
breakpoints: enabled.map(({ origin }) => origin.raw)
|
|
880
|
+
});
|
|
881
|
+
response.body.breakpoints.forEach((raw, index) => enabled[index].update({ raw }));
|
|
882
|
+
} catch {
|
|
883
|
+
enabled.forEach(breakpoint => breakpoint.update({ raw: { verified: false } }));
|
|
884
|
+
}
|
|
885
|
+
this.setBreakpoints(BreakpointManager.DATA_URI, all);
|
|
886
|
+
}
|
|
887
|
+
|
|
858
888
|
protected setBreakpoints(uri: URI, breakpoints: DebugBreakpoint[]): void {
|
|
859
889
|
this._breakpoints.set(uri.toString(), breakpoints);
|
|
860
890
|
this.fireDidChangeBreakpoints(uri);
|
|
@@ -890,6 +920,7 @@ export class DebugSession implements CompositeTreeElement {
|
|
|
890
920
|
}
|
|
891
921
|
yield BreakpointManager.FUNCTION_URI;
|
|
892
922
|
yield BreakpointManager.EXCEPTION_URI;
|
|
923
|
+
yield BreakpointManager.DATA_URI;
|
|
893
924
|
}
|
|
894
925
|
}
|
|
895
926
|
|