MCPcopy Create free account
hub / github.com/Marus/cortex-debug / getNamespace

Function getNamespace

src/backend/gdb_expansion.ts:70–96  ·  view source on GitHub ↗
(variable)

Source from the content-addressed store, hash-verified

68 let variable = '';
69
70 const getNamespace = (variable) => {
71 let namespace = '';
72 let prefix = '';
73 stack.push(variable);
74 stack.forEach((name) => {
75 prefix = '';
76 if (name !== '') {
77 if (name.startsWith('[')) {
78 namespace = namespace + name;
79 }
80 else {
81 if (namespace) {
82 while (name.startsWith('*')) {
83 prefix += '*';
84 name = name.substr(1);
85 }
86 namespace = namespace + pointerCombineChar + name;
87 }
88 else {
89 namespace = name;
90 }
91 }
92 }
93 });
94 stack.pop();
95 return prefix + namespace;
96 };
97
98 const parseTupleOrList = () => {
99 value = value.trim();

Callers 1

expandValueFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected