Skip to content

IntelliSense partially incomplete for sigaction #13646

@francescounitn

Description

@francescounitn

Environment

  • OS and Version: Windows 11
  • VS Code Version: Version: 1.100.2
  • C/C++ Extension Version: Version 1.25.3: April 28, 2025
  • If using SSH remote, specify OS of remote machine:

Hello, I've found a weird behaviour of the intellisense and I'm wondering if it's normal.
I'm learning about signals and while trying using sigaction the intellisense doesn't show the complete list of parameters.

Here's the code:

void handler(int signo, siginfo_t *info, void *empty)
{
printf("received SIGUSR2 %d", info->si_value.sival_int);
}

If I try to interact with 'info->' si_value is missing and also susequent variables.
The program compiles just fine.

Is this reproducible for you?
Also note that I've tried fixing this with no avail at the moment, any help is appreciated.

I hope this is the right place. if this is an issue not related to VS Code I apologize, do not hesitate to tell me.

Bug Summary and Steps to Reproduce

Bug Summary: About <signal.h>, siginfo_t, Intellisense doesn't show all fields of struct

Steps to reproduce:

  1. include <signal.h>
  2. create a custom handler void handler_giocatori(int signo, siginfo_t *info, void *empty){}
  3. try to access siginfo_t varibale (in this case info->)

Expected behavior:
Intellisense should show all expected fields

Configuration and Logs

Here's my c_cpp_properties,json file:

{
    "configurations": [
        {
            "name": "Linux",
            "includePath": [
                "${workspaceFolder}/**",
                "/usr/include",
                "/usr/include/x86_64-linux-gnu"
            ],
            "defines": [
                "_GNU_SOURCE",
                "_POSIX_C_SOURCE=200809L"
            ],
            "compilerPath": "/usr/bin/gcc",
            "intelliSenseMode": "linux-gcc-x64",
            "cStandard": "gnu23",
            "cppStandard": "gnu++23"
        }
    ],
    "version": 4
}



Here's the output of 'C/C++: log diagnostics':

-------- Diagnostics - 5/28/2025, 3:04:59 PM
Version: 1.25.3
Current Configuration:
{
    "name": "Linux",
    "includePath": [
        "/home/francesco/University/Sistemi Operativi/Sistemi Operativi 2024-2025/**",
        "/usr/include",
        "/usr/include/x86_64-linux-gnu"
    ],
    "defines": [
        "_GNU_SOURCE",
        "_POSIX_C_SOURCE=200809L"
    ],
    "compilerPath": "/usr/bin/gcc",
    "intelliSenseMode": "linux-gcc-x64",
    "cStandard": "gnu23",
    "cppStandard": "gnu++23",
    "compilerPathIsExplicit": true,
    "cStandardIsExplicit": true,
    "cppStandardIsExplicit": true,
    "intelliSenseModeIsExplicit": true,
    "recursiveIncludesReduceIsExplicit": false,
    "recursiveIncludesPriorityIsExplicit": false,
    "recursiveIncludesOrderIsExplicit": false,
    "compilerPathInCppPropertiesJson": "/usr/bin/gcc",
    "mergeConfigurations": false,
    "recursiveIncludes": {},
    "browse": {
        "limitSymbolsToIncludedHeaders": true
    }
}
Modified Settings:
{
    "C_Cpp.default.cStandard": "gnu23",
    "C_Cpp.default.cppStandard": "gnu++23"
}
Additional Tracked Settings:
{
    "editorTabSize": 2,
    "editorInsertSpaces": true,
    "editorAutoClosingBrackets": "languageDefined",
    "filesEncoding": "utf8",
    "filesAssociations": {
        "stdio.h": "c",
        "string.h": "c",
        "stdlib.h": "c",
        "signal.h": "c",
        "types.h": "c"
    },
    "filesExclude": {
        "**/.git": true,
        "**/.svn": true,
        "**/.hg": true,
        "**/.DS_Store": true,
        "**/Thumbs.db": true
    },
    "filesAutoSaveAfterDelay": false,
    "editorInlayHintsEnabled": true,
    "editorParameterHintsEnabled": true,
    "searchExclude": {
        "**/node_modules": true,
        "**/bower_components": true,
        "**/*.code-search": true
    },
    "workbenchSettingsEditor": "ui"
}
cpptools version (native): 1.25.3.0
Current database path: /home/francesco/.cache/vscode-cpptools/57f27239870de5782ca0427dd3ae631f/.browse.VC.db
Translation Unit Mappings:
[ /home/francesco/University/Sistemi Operativi/Sistemi Operativi 2024-2025/Esami/simulazione_LabSO_26052025/simulazione_LabSO_26052025.c - source TU]:
    /usr/include/asm-generic/errno-base.h
    /usr/include/errno.h
    /usr/include/math.h
    /usr/include/signal.h
    /usr/include/stdio.h
    /usr/include/stdlib.h
    /usr/include/string.h
    /usr/include/strings.h
    /usr/include/time.h
    /usr/include/unistd.h
    /usr/include/x86_64-linux-gnu/bits/confname.h
    /usr/include/x86_64-linux-gnu/bits/fcntl-linux.h
    /usr/include/x86_64-linux-gnu/bits/mathcalls-narrow.h
    /usr/include/x86_64-linux-gnu/bits/sigaction.h
    /usr/include/x86_64-linux-gnu/bits/signum-generic.h
    /usr/include/x86_64-linux-gnu/bits/stat.h
    /usr/include/x86_64-linux-gnu/bits/timex.h
    /usr/include/x86_64-linux-gnu/bits/types/FILE.h
    /usr/include/x86_64-linux-gnu/bits/types/error_t.h
    /usr/include/x86_64-linux-gnu/bits/types/sig_atomic_t.h
    /usr/include/x86_64-linux-gnu/bits/types/siginfo_t.h
    /usr/include/x86_64-linux-gnu/sys/stat.h
    /usr/include/x86_64-linux-gnu/sys/types.h
    /usr/include/x86_64-linux-gnu/sys/wait.h
    /usr/lib/gcc/x86_64-linux-gnu/9/include/stddef.h
Translation Unit Configurations:
[ /home/francesco/University/Sistemi Operativi/Sistemi Operativi 2024-2025/Esami/simulazione_LabSO_26052025/simulazione_LabSO_26052025.c ]
    Process ID: 25929
    Memory Usage: 29 MB
    Compiler Path: /usr/bin/gcc
    Include paths:
        include: /usr/include
        include: /usr/include/x86_64-linux-gnu
        system include: /usr/lib/gcc/x86_64-linux-gnu/9/include
        system include: /usr/local/include
        system include: /usr/include/x86_64-linux-gnu
        system include: /usr/include
    Defines:
        _GNU_SOURCE
        _POSIX_C_SOURCE=200809L
    Standard Version: c23
    IntelliSense Mode: linux-gcc-x64
    Other Flags:
        --gcc
        --gnu_version=90400
Total Memory Usage: 29 MB

------- Workspace parsing diagnostics -------
Number of files discovered (not excluded): 2710

Other Extensions

No response

Additional context

No response

Metadata

Metadata

Assignees

No one assigned

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions