Skip to content

Code Actions are enabled by default #14341

Closed
Closed

Description

@luc0x61

Environment

  • OS and Version: Windows 11 Pro 25H2
  • VS Code Version: 1.114.0
  • C/C++ Extension Version: 1.31.4
  • If using SSH remote, specify OS of remote machine: n.a.

Bug Summary and Steps to Reproduce

Bug Summary:

Code Actions is enabled by default, without any option to be disabled in settings UI

Steps to reproduce:

  1. Open/create a .c/.h file with an enum definition like the following
Image
  1. Left click on a defined enumerator
  2. The light bulb icon of Code Actions will appear, and will be enabled to be interacted with (menu)

Expected behavior:

  • Processing step 2. there shall not be a resulting icon/menu as in step 3.

Configuration and Logs

From settings.json:

    "C_Cpp.vcFormat.indent.preserveWithinParentheses": true,
    "C_Cpp.vcFormat.indent.withinParentheses": "alignToParenthesis",
    "C_Cpp.vcFormat.space.pointerReferenceAlignment": "center",
    "C_Cpp.doxygen.generateOnType": false,
    "C_Cpp.default.defines": [
        "__TMS320C28XX__"
    ],
    "C_Cpp.copilotHover": "disabled",
    "C_Cpp.default.compilerPath": "C:\\mingw64\\bin\\gcc.exe",
    "C_Cpp.default.enableConfigurationSquiggles": false,
    "C_Cpp.codeAnalysis.clangTidy.codeAction.showDocumentation": false,

Other Extensions

No response

Additional context

No response

Activity

  1. added
    Feature: Doc comments
    on Apr 1, 2026
  2. sean-mcmanus commented on Apr 1, 2026

    @sean-mcmanus
    Contributor

    luc0x61 This looks like it's from the Generate Doxygen comment feature. It looks like a setting to disable that was never implemented.

  3. sean-mcmanus commented on Apr 2, 2026

    @sean-mcmanus
    Contributor

    luc0x61 We have a PR at #14342 that allows disabing the Generate doxygen comment code actions -- is that good enough or were there more code actions you wanted to be able to disable?

  4. Colengms commented on Apr 3, 2026

    @Colengms
    Contributor

    luc0x61 Are you asking for a way to disable all code actions, or doxygen code actions specifically, while others remain enabled?

    It looks like there is a general editor.lightbulb.enabled setting that can disable display of all code action lightbulbs.

    If not specific to cpptools, and you'd really like all code actions disabled by default, I'd suggest opening an issue in the vscode repo.

  5. luc0x61 commented on Apr 8, 2026

    @luc0x61
    Author

    @luc0x61 Are you asking for a way to disable all code actions, or doxygen code actions specifically, while others remain enabled?

    I would have liked to select "no Code Actions at all", somewhere.
    I verified that the Code Actions that I described happen

    • only with cpptools extension enabled
    • not on all enumerators
    • only on some enumeration declaration

    then I assumed it is an issue with the extension.

    It looks like there is a general editor.lightbulb.enabled setting that can disable display of all code action lightbulbs.

    I've done it right now, and it's effective.

    If not specific to cpptools, and you'd really like all code actions disabled by default, I'd suggest opening an issue in the vscode repo.

    As I wrote above, the issue is present when enabling the extension, otherwise I have no such behavior.
    I have no idea on what is the interaction between the extension and vscode about Code Actions. I would find awkward reporting an issue with vscode base, when the behavior can't be replicated without the extension.

  6. added
    fixed
    on Apr 14, 2026
  7. sean-mcmanus commented on Apr 29, 2026

    @sean-mcmanus
    Contributor

    luc0x61 We added a setting to disable the Doxygen code action specifically, but we don't intend to disable that or all code actions by default. With https://github.com/microsoft/vscode-cpptools/releases/tag/v1.32.2

  8. locked and limited conversation to collaborators on Jun 14, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

Feature: Doc commentsLanguage Servicebugfixedquick fix

Type

Projects

  • Status
    Done

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions