VS Code Extension
First-class VS Code support for Pseudo โ syntax highlighting, pmap-driven snippets, inline diagnostics, and complexity analysis, all in one extension.
sanayvarghese ยท Extension ID: sanayvarghese.pseudo-syntaxFeatures
Full token-level highlighting for .pseudo, .psu, .pmap, and pseudo.config files โ driven dynamically by your active pmap.
Every pattern in your pmap becomes a live snippet with tab stops. Custom patterns from pseudo.config appear first.
Hover any line to see which pmap pattern it matched, what it captures, and complexity metrics for functions.
Errors and warnings appear inline as you type. No need to run the file to catch mistakes.
Time and space complexity overlays appear above every function definition. Click to see detailed reasoning.
Run the current file or run with complexity analysis directly from the editor title bar.
Installation
From VS Code
- 1
Open the Extensions panel
Press
Ctrl+Shift+X(Windows/Linux) orCmd+Shift+X(macOS). - 2
Search for Pseudo
Type
pseudo language supportin the search box and select the extension published by sanayvarghese. - 3
Click Install
The extension activates immediately โ no reload required.
From the Command Line
code --install-extension sanayvarghese.pseudo-syntaxManual Install (.vsix)
Download the .vsix file from the GitHub Releases page and install via:
code --install-extension pseudo-syntax-1.1.0.vsixSupported File Types
| File / Extension | Language ID | Support |
|---|---|---|
.pseudo, .psu | pseudo | Highlighting ยท Snippets ยท Hover ยท Diagnostics ยท CodeLens ยท Run buttons |
.pmap | pmap | Highlighting (sections, placeholders, directives, strings) |
pseudo.config, .pseudorc | pseudo-config | Highlighting (keys, paths, JSON structure) |
Dynamic Highlighting
Unlike most language extensions, highlighting in Pseudo is not hardcoded. The extension reads your active .pmap file and extracts every keyword from every pattern โ these become the highlighted tokens in your .pseudo file. If you add a new keyword to your custom pmap, it lights up instantly.
.pmap file, pseudo.config, or .pseudorc automatically re-indexes highlighting and snippets without restarting VS Code.pmap-Driven Snippets
Every pattern line in your active pmap is converted into a VS Code snippet. Placeholders like {var:name} become tab stops you can jump between with Tab.
[FOR_LOOP]
for {var:name} from {start:expr} to {end:expr} step {step:expr}
for {var:name} from {start:expr} to {end:expr}When you type for in a .pseudo file, both patterns appear as snippet completions โ with the cursor pre-placed on var, then start, then end as you press Tab.
pseudo.config pointing to a custom pmap, those patterns are listed before the defaults in the completion list.pseudo.config Integration
The extension reads pseudo.config (or .pseudorc) from your workspace root to discover which custom .pmapyou're using โ the same file the runtime reads.
{
"pmap": "custom.pmap"
}With this in place, the extension merges custom.pmap and default.pmap โ custom keywords and snippets take priority.
Hover & CodeLens
Function hover
Hovering a user-defined function name shows its signature and โ if you've run the file โ time and space complexity:
function bubbleSort(arr)
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Complexity Analysis:
Time Complexity : O(nยฒ)
Space Complexity : O(1)Pattern hover
Hovering any other line shows which pmap pattern it matched and what values were captured:
Pseudo Mapping Explanation
โโโโโโโโโโโโโโโโโโโโโโโโโโโโโโ
Matched: for {var:name} from {start:expr} to {end:expr}
Captures:
{var} = "i"
{start} = "0"
{end} = "n"Complexity CodeLens
A one-line complexity summary appears above every function definition after running the file. Click it to see the full reasoning in an output panel.
Run Buttons
Two buttons appear in the editor title bar when a .pseudo file is open:
| Button | Command | What it runs |
|---|---|---|
| โถ (play) | Pseudo: Run File | pseudo run <file> |
| ๐ (graph) | Pseudo: Run with Complexity Analysis | pseudo run <file> --analyze --explain |
Requirements
pseudo under the hood. The extension automatically detects the Python interpreter from the ms-python.python extension if installed, otherwise falls back to python on your PATH.Syntax highlighting and snippet completions work without Python โ only the runtime features require it.