Skip to content

GCC Array Typedef/Virtual Methods Bug #44

Description

The following source code pattern causes GCC to write some structures as anonymous in the DWARF:

#define USE_VIRTUAL
#define USE_ARRAY
struct t1
{
    typedef struct
    {
    } t2;
#ifdef USE_VIRTUAL
    virtual void f1();
#endif
};

t1::t2 v1
#ifdef USE_ARRAY
[1]
#endif
;

This is NOT supposed to happen. It's a bug in GCC.

https://lists.dwarfstd.org/pipermail/dwarf-discuss/2024-December/002573.html

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions