42School / norminette

Official 42 norminette
MIT License
956 stars 140 forks source link

Variable definition of function pointer that returns a user-defined type is not treated as such #446

Open Miniature opened 12 months ago

Miniature commented 12 months ago

Describe the bug Definitions of variables containing function pointers that return a user-defined type are not treated as variable definitions, but as other code. Function pointers that return builtin types work appropriately.

Erroneous code

typedef int t_example;

void    function2(void)
{
    int (*builtin)(void);

    t_example (*user_defined)(void);
}

Additional infos

Additional context This issue is similar to #443, in that it concerns lack of detection of variable definitions.