microsoft / microsoft/vscode-cpptools

Switch off nested code analysis from includes

Open
#14,247 2 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug Feature: Code Analysis Language Service
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

Feature Request

Hi,

In a lot of my files I get an "Error while processing" error from the C/C++ tool during the analysis. We are working on a project where we use generated drivers from our microcontroller vendor, and I have disabled analysis of the folders containing those files. When I open one of those files, it does not show the errors. However, the analysis of a file which includes one of those driver files generates a lot of errors under the banner of "Error while processing" which is marked in Line 1 Column 1 of the file. Is it possible to disable analysis of files that are included?

Image

I believe this is also slowing down the analysis quite significantly too, as there is a lot conditional compilation in there too.

Thanks in advance!

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No implementation files or tests are named. Start by tracing how the C/C++ analysis handles included files and how excluded folders are currently applied, then determine where an option to skip included-file analysis belongs. Done means included files from excluded folders are not analyzed while the directly opened file still is, with the reported processing errors avoided.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
devtools, performance
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.