microsoft / microsoft/vscode-cpptools

go to declaration

Aperta
#9,678 14 commenti 0 reazioni 0 assegnatari Vedi su GitHub

Nessuno ha ancora preso questa issue.

bug Feature: Go to Definition Language Service Verified - Internal Works in VS
Lingua principale
TypeScript
Stelle
6.2k
Fork
1.7k
Merge medio
14h 46m
PR unite (30g)
61

Descrizione

Environment
  • OS and Version: windows 10
  • VS Code Version: 1.69.2
  • C/C++ Extension Version: 1.11.4
  • Other extensions you installed (and if the issue persists after disabling them):
  • If using SSH remote, specify OS of remote machine:
  • A clear and concise description of what the bug is, including information about the workspace (i.e. is the workspace a single project or multiple projects, size of the project, etc).

the display of all parameter declarations disappears

directory used as a project:
https://github.com/llvm/llvm-project

Bug Summary and Steps to Reproduce

directory used as a project:
https://github.com/llvm/llvm-project

the path to the file to open:
G:\llvm-project-main\llvm-project-main\clang\include\clang\Basic\CodeGenOptions.h

at the beginning of the project opening, if you hover the cursor over "setDebugInfo", all definitions of this parameter are shown
image

if you right-click on "CODEGENOPT" and select "go to declaration", then all the places where this parameter is declared will be displayed in the list
image

next comes some kind of file processing and when you hover the cursor over "CODEGENOPT", the display of the remaining parameter declarations disappears
image

also, the "go to declaration" function stops working for the "CODEGENOPT" parameter.
for the "ENUM_CODEGENOPT" parameter, the "go to declaration" function works, but other declarations of this parameter in this file stop being displayed.
image

the display of all ads disappears after the output of this debugging information to the console
image

Expected behavior
  1. it is expected that all parameter declarations will be displayed when the mouse cursor hovers over it

  2. it is expected that when you right-click on the parameter and select the "go to declaration" option, all the places where this parameter is defined will be displayed

  3. the expected behavior when hovering the cursor can be viewed in the wboq documentation generator

https://blog.weghos.com/llvm/llvm/clang/include/clang/Frontend/CodeGenOptions.h.html#34

image

Code sample and Logs
c_cpp_properties.json


{
    "configurations": [
        {
            "name": "Win32",
            "includePath": [
                "${workspaceFolder}/**"
            ],
            "defines": [
                "_DEBUG",
                "UNICODE",
                "_UNICODE"
            ],
            "windowsSdkVersion": "10.0.19041.0",
            "compilerPath": "C:/Program Files/Microsoft Visual Studio/2022/Enterprise/VC/Tools/MSVC/14.32.31326/bin/Hostx64/x64/cl.exe",
            "cStandard": "c17",
            "cppStandard": "c++14",
            "intelliSenseMode": "windows-msvc-x64"
        }
    ],
    "version": 4
}
Screenshots

No response

Additional context

No response

Guida per i contributori

Apri la guida per i contributori

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Direzione di ricerca

Riprodurre con lo spazio di lavoro llvm-project e clang/include/clang/Basic/CodeGenOptions.h, utilizzando la configurazione c_cpp_properties.json mostrata. Iniziare confrontando i risultati di hover e Go to Declaration per CODEGENOPT e ENUM_CODEGENOPT prima e dopo la comparsa dell’output di debug della console. È completato quando le dichiarazioni rimangono disponibili ed entrambi i comportamenti di navigazione continuano a funzionare al termine dell’elaborazione.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Valutazione

Stack tecnologico
cpp, typescript
Ambito
devtools, tooling
Tipo di issue
Bug
Difficoltà
4/5
Tempo stimato
3-5 giorni
Stato di attività
Ferma
Chiarezza
Abbastanza chiara
Idoneità per principianti
35/100

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.