Skip to content

Feature Request: Add a setting to allow source files to be discerned from header files #10915

@Colengms

Description

@Colengms

There are various scenarios in which cpptools will try to discern if a file is a source file or a header file. For example:

  • include graph generation - to determine whether a file should be a source node or header node in the graph.
  • TU creation - to determine if a header file is requested, and, if so, determine a source file to create the TU with instead.
  • code analysis - When a save operation is performed on a source file, code analysis for that file is canceled, to ensure clang-tidy doesn't keep it open/locked. When a header file is saved, all code analysis operations are canceled, as any one of them might be keeping the header open/locked.
  • include auto-complete - to determining if a file should be included in the list, or to determine if the includes cache needs to be cleared/updated.
  • Goto-def, to determine if a candidate is a source or header candidate.
  • (various other places)

This issue tracks adding a setting to allow the user to customize what file extensions (or wildcard patterns, to match files.associations) are considered headers vs. sources, rather than hard-coding these associations.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions