Skip to content

C language 'Go to Definition' recognition function error #3609

@JasonLeeCn

Description

@JasonLeeCn

Issue Type: Bug

If the function without parameter, but the function declaration with 'void' in header file. In other file (not the function entity file) call the function. Using F12 (Go to Definition), the editor will just jump to the header file, not the function entify '*.c' file.

Eg.:
file1: testA.c
void test_a()
{
/* function entity*/
}

file2: testA.h
extern void test_a(void);

file3: testB.c
#include "testA.h"

void test_b(void)
{
test_a();
}

When 'Go to Definition' to test_a(); the editor will jump to testA.h file not testA.c file. But if testA.c is
void test_a(void)
{
/* function entity */
}
It can jump to the testA.c file.

Extension version: 0.23.0
VS Code version: Code 1.33.1 (51b0b28134d51361cf996d2f0a1c698247aeabd8, 2019-04-11T08:27:14.102Z)
OS version: Windows_NT x64 10.0.16299

System Info
Item Value
CPUs Intel(R) Core(TM) i5-6300U CPU @ 2.40GHz (4 x 2496)
GPU Status 2d_canvas: enabled
checker_imaging: disabled_off
flash_3d: enabled
flash_stage3d: enabled
flash_stage3d_baseline: enabled
gpu_compositing: enabled
multiple_raster_threads: enabled_on
native_gpu_memory_buffers: disabled_software
rasterization: enabled
surface_synchronization: enabled_on
video_decode: enabled
webgl: enabled
webgl2: enabled
Memory (System) 7.66GB (3.48GB free)
Process Argv D:\Workspace\Projects\EB_QL_02\03_Software_Design\Trunk\EB_PMSM
Screen Reader no
VM 0%

Metadata

Metadata

Assignees

No one assigned

    Labels

    Feature: Go to DefinitionAn issue related to Go to Definition/Declaration.Language ServicebugfixedCheck the Milestone for the release in which the fix is or will be available.quick fix

    Type

    No type

    Projects

    No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions