microsoft / microsoft/vscode-cpptools

Go to Definition jumps to .h declaration instead of .c definition in 1.33.2 (regression from 1.32.2)

Open
#14,686 8 comments 1 reaction 1 assignee View on GitHub

@sean-mcmanus is already working on this.

Since Aug 17, 2026.

Feature: Go to Definition Language Service more info needed regression
Dominant language
TypeScript
Stars
6.2k
Forks
1.7k
Avg merge
14h 46m
Merged PRs (30d)
61

Description

Environment

  • OS: Windows 10 Pro for Workstations
  • VS Code version: (your version)
  • C/C++ extension version: 1.33.2 (broken), 1.32.2 (works)
  • Project type: Embedded C firmware (esirisc architecture)
  • Workspace on: mapped virtual drive (M:)

Problem

After upgrading to 1.33.2, pressing F12 (Go to Definition) on a function
always jumps to the declaration in the .h header file instead of the
implementation in the .c source file. Downgrading to 1.32.2 restores
correct behavior immediately.

Steps to Reproduce

  1. Open a C project on a mapped virtual drive
  2. Open a source file (e.g. FlowWork.c)
  3. Press F12 on a function call (e.g. AppFrontFilter())
  4. Expected: jumps to AppFrontFilter.c:929 (definition)
  5. Actual: jumps to AppFrontFilter.h:77 (declaration)

Additional Info

  • The issue occurs even when the target .c file is open in the editor
  • compile_commands.json is configured and loaded correctly (verified via Log Diagnostics)
  • The browse database is fully built (verified via C/C++ Output channel)
  • Downgrading to 1.32.2 fixes the issue without any other changes

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.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.