(root)/
gcc-13.2.0/
gcc/
testsuite/
g++.dg/
torture/
pr81462.C
// { dg-do compile }
// { dg-options "-O1 -fno-ipa-pure-const" }
struct B {
        B* self;
        B() : self( this ) { self->f(); }
        virtual void f() = 0;
    };

    struct D : B
    {
        void f() {}
    };

    int main()
    {
        D d;
    }