Skip to content
| Marketplace
Sign in
Visual Studio Code>Linters>C++ Code DoctorNew to Visual Studio Code? Get it now.
C++ Code Doctor

C++ Code Doctor

RSCD

|
2 installs
| (0) | Free
Real-time C++ code analysis in VS Code to detect issues and improve maintainability.
Installation
Launch VS Code Quick Open (Ctrl+P), paste the following command, and press enter.
Copied to clipboard
More Info

C++ Code Doctor

C++ Code Doctor is a VS Code extension designed to help you write cleaner, more maintainable, and more efficient C++ code directly inside the editor.

It is available in a Free and a Pro version.

The Free version provides lightweight, file-level analysis based on pattern matching. The Pro version adds AST-based, project-aware analysis with higher accuracy and deeper insights.

Upgrade to Pro to unlock full C++ semantic analysis and advanced code quality checks.


What It Solves

C++ Code Doctor helps you maintain clean, efficient, and maintainable C++ code by identifying patterns that can:

  • Increase cognitive load
  • Make refactoring harder
  • Hide potential issues
  • Inflate translation units and compilation times
  • Accumulate as technical debt

It provides immediate, in-editor feedback so you can address these problems as you code, without relying on external tools or build steps.


Visual Demo

Unused Variable Detection (Pro Version)

Demo

Highlights variables that are declared but never used (Pro version).


Unused Include Detection (Pro Version)

Demo

Highlights include directives that are not required in the current file (Pro version).


Upgrade to Pro

The Pro version extends these capabilities with AST-based analysis, providing:

  • Scope-aware unused variable detection
  • Accurate include analysis across files
  • Reduced false positives
  • Support for complex C++ constructs such as templates, macros, and namespaces
  • Dedicated panel listing all detected issues
  • Ability to mark findings as false positives and suppress them persistently

If you work with larger codebases or advanced C++ features, the Pro version provides significantly improved accuracy and reliability.

Upgrade to Pro


Pricing

C++ Code Doctor Pro is available with the following pricing:

  • Early Adopter: 24.99 USD per year
  • Regular Price: 49.99 USD per year

Free vs Pro

Feature Free Pro
Analysis method Regex-based detection Real AST-based analysis
Unused variable detection ✔️ ✔️
Unused include detection ✔️ ✔️
Unevaluated return value detection ❌ ✔️*
Dead code detection ❌ ✔️*
Project-wide analysis ❌ ✔️
Reports Limited Custom analysis panel
QuickFixes ✔️ ✔️

* planned in upcoming release


Free Version (RegEx-Based Analysis)

The Free version uses a lightweight RegEx-based approach.

Included

  • Detect unused variables (file-level analysis)
  • Detect unused includes (file-level analysis)
  • Fast execution inside VS Code
  • No external dependencies

This approach is intentionally simple and fast. However, since it is text-based, it does not fully understand C++ semantics.

Limitations

  • Possible false positives in complex syntax
  • Possible false negatives in edge cases
  • Limited handling of macros, templates, and advanced constructs
  • Header files with multiple dots in their filename (e.g., my.header.hpp) may be incorrectly marked as unused
  • System headers are excluded from checks

The Free version is suitable for small to medium files and straightforward code.


Pro Version (AST-Based Analysis)

The Pro version uses AST (Abstract Syntax Tree) analysis instead of pattern matching.

This enables:

  • Structural understanding of C++ code
  • Accurate scope resolution
  • Reliable handling of complex syntax
  • Fewer inaccuracies

The Pro version uses Tree-sitter for AST-based parsing.

Included

  • AST-based unused variable detection (scope-aware)
  • AST-based unused include detection (scope-aware)
  • Dedicated panel listing all detected issues
  • Mark findings as false positives to suppress them persistently across sessions
  • Improved handling of larger and more complex codebases

Upgrade to Pro


Requirements

No external dependencies are required.

Install the extension and open a C++ project.


Activating Pro

The extension provides a setting to configure a Pro license key:

  • cppCodeDoctor.proLicenseKey

Providing a valid license key enables Pro features.


Known Limitations

Free Version (RegEx-Based)

  • Possible false positives or false negatives
  • Limited handling of macros and complex syntax
  • Header files with multiple dots in their filename (e.g., my.header.hpp) may be incorrectly marked as unused
  • System headers are excluded from checks

Pro Version (AST-Based)

  • Certain alias definitions (using / typedef) may not always be resolved correctly when determining unused includes
  • Complex transitive include dependencies may lead to edge cases
  • Highly template-heavy or macro-generated code can still produce rare inaccuracies

AST-based analysis continues to be refined to handle these edge cases more reliably.

If you encounter issues in either version, please report them in the issue tracker:

https://gitlab.com/rscd-dev/cpp-code-doctor/cpp-code-doctor-free/-/issues


Get Started

Install the Free version to start using C++ Code Doctor immediately.

When you are ready for deeper analysis and advanced features, upgrade to Pro:

Upgrade to Pro


Third-Party Components

This extension uses third-party software components.

All third-party dependencies and their licenses are listed in the NOTICE file.

These include, among others:

  • Tree-sitter (MIT)
  • Tree-sitter C grammar (MIT)
  • Tree-sitter C++ grammar (MIT)
  • node-gyp-build (MIT)
  • vscode-languageclient (MIT)
  • TypeScript (Apache 2.0)
  • JavaScript Obfuscator (BSD-2-Clause)
  • ESLint and TypeScript ESLint plugins (MIT)

All third-party components retain their respective licenses.


License

This project is proprietary software. See the LICENSE file for details.

Third-party dependencies are subject to their respective licenses as described in the NOTICE file.


Changelog

For a full history of changes, including differences between Free and Pro versions, see CHANGELOG.md.

  • Contact us
  • Jobs
  • Privacy
  • Manage cookies
  • Terms of use
  • Trademarks
© 2026 Microsoft