Repository navigation
v0.6.0 (beta)
Pre-releaseCode Scope 0.6.0 is a beta. It is here for people to try and help shape before it goes to the VS Code Marketplace. If something looks wrong, confusing or missing, open an issue. A screenshot from the panel's Save image button helps a lot.
Install
- Download
code-scope.vsixbelow. - Run
code --install-extension code-scope.vsix, or in VS Code open the Extensions view, click ... and choose Install from VSIX.... - Open one of your programs (or a sample from the repository), set a breakpoint and start debugging. The Code Scope panel opens on the first stop.
You need the debugger for your language: Extension Pack for Java, Node.js 22 or newer for JavaScript, the Python extension, the C# extension, or the C/C++ extension with gdb.
What is new since 0.5.0
- C# and C, validated with the real debuggers: arrays,
List,Stack,Queue,Dictionary, objects and linked lists in C#; arrays, pointers tostructand linked lists in C. - Recursion tree: in
fib(n - 1) + fib(n - 2), every call with what it returned, and how many times the same work was redone. - Guess first: before a line runs, the panel asks what the variable will be, and keeps the score.
- Same object or same contents:
==,equals,===andisexplained, with the classic traps. - Changing in place or creating a new one:
x.sort()versussorted(x), ands.trim();that nobody kept. - How much it costs: the program's comparisons next to log n, n, n log n and n².
- Lists of objects, graphs,
try/catch, inheritance and polymorphism, text as letters, and number traps (integer division,0.1 + 0.2, overflow). - Presentation mode and Save image (PNG of the current step).
Full list in the CHANGELOG.
Known limits
- Not tested yet on macOS and Linux, on VS Code versions older than 1.143, with light or high contrast themes, or with screen readers.
- C++ containers (
std::vector,std::map) are not drawn yet. - JavaScript was only tested on Node, not in the browser.
Want to help?
Start with CONTRIBUTING and the good first issues. Several of them need no code at all.
O Code Scope 0.6.0 é uma beta. Ela existe para as pessoas testarem e ajudarem a melhorar antes de ir para o Marketplace do VS Code. Se algo parecer errado, confuso ou faltando, abra uma issue. Uma imagem do botão Salvar imagem do painel ajuda muito.
Instalar
- Baixe o
code-scope.vsixabaixo. - Rode
code --install-extension code-scope.vsixou, no VS Code, abra a aba Extensões, clique em ... e escolha Install from VSIX.... - Abra um programa seu (ou um exemplo do repositório), coloque um breakpoint e comece a debugar. O painel Code Scope abre na primeira parada.
É preciso o debugger da sua linguagem: Extension Pack for Java, Node.js 22 ou mais novo para JavaScript, a extensão Python, a extensão C#, ou a extensão C/C++ com gdb.
O que há de novo desde a 0.5.0
- C# e C, validados com os debuggers reais: arrays,
List,Stack,Queue,Dictionary, objetos e listas ligadas em C#; arrays, ponteiros parastructe listas ligadas em C. - Árvore de recursão: em
fib(n - 1) + fib(n - 2), todas as chamadas com o que devolveram, e quantas vezes a mesma conta foi refeita. - Adivinhar antes: antes de uma linha rodar, o painel pergunta quanto a variável vai valer e guarda o placar.
- Mesmo objeto ou mesmo conteúdo:
==,equals,===eisexplicados, com as pegadinhas clássicas. - Mudar no lugar ou criar outro:
x.sort()ousorted(x), e os.trim();que ninguém guardou. - Quanto custa: as comparações do programa ao lado de log n, n, n log n e n².
- Lista de objetos, grafos,
try/catch, herança e polimorfismo, texto como letras e pegadinhas de número (divisão de inteiros,0.1 + 0.2, overflow). - Modo apresentação e Salvar imagem (PNG do passo atual).
Lista completa no CHANGELOG.
Limites conhecidos
- Ainda sem teste no macOS e no Linux, em versões do VS Code anteriores à 1.143, com tema claro ou de alto contraste, e com leitores de tela.
- As coleções do C++ (
std::vector,std::map) ainda não são desenhadas. - JavaScript só foi testado no Node, não no navegador.
Quer ajudar?
Comece pelo CONTRIBUTING e pelas tarefas para começar. Várias delas não precisam de código.