Skip to content

Commit 71027d2

Browse files
committed
Examine scopes only within specific super-scopes, like with items.
1 parent a3c8178 commit 71027d2

File tree

2 files changed

+5
-3
lines changed

2 files changed

+5
-3
lines changed

src/cxxrtl/proto.ts

+1
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ export type ScopeDescriptionMap = {
108108
export type CommandListScopes = {
109109
type: 'command';
110110
command: 'list_scopes';
111+
scope: null | string;
111112
};
112113

113114
export type ResponseListScopes = {

src/debug/session.ts

+4-3
Original file line numberDiff line numberDiff line change
@@ -64,8 +64,8 @@ export class Session {
6464
if (scopeDescriptionMap === undefined) {
6565
const response = await this.connection.listScopes({
6666
type: 'command',
67-
command: 'list_scopes'
68-
// FIXME: should be possible to filter by scope, too
67+
command: 'list_scopes',
68+
scope: scopeIdentifier,
6969
});
7070
const filteredScopes = Object.keys(response.scopes).filter((scopeName) => {
7171
if (scopeIdentifier === '') {
@@ -104,7 +104,8 @@ export class Session {
104104
if (this.rootScopeDesc === undefined) {
105105
const response = await this.connection.listScopes({
106106
type: 'command',
107-
command: 'list_scopes'
107+
command: 'list_scopes',
108+
scope: scopeName,
108109
});
109110
this.rootScopeDesc = response.scopes[scopeName];
110111
}

0 commit comments

Comments
 (0)