This is the mail archive of the gdb-prs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/22242] recursive display of variable information


https://sourceware.org/bugzilla/show_bug.cgi?id=22242

--- Comment #4 from Jeremi <jeremip11 at gmail dot com> ---
Comment on attachment 10502
  --> https://sourceware.org/bugzilla/attachment.cgi?id=10502
Code for demonstrating the "infinite print"

>/* compile with g++ -O0 -g3 recursivegdb.cpp */
>
>class CInner {
>public:
>  constexpr CInner(unsigned range = 0) : m_Range(range){};
>
>  static const CInner sm_NullGeometry;
>
>private:
>  unsigned m_Range;
>};
>const CInner CInner::sm_NullGeometry{};
>
>struct CKiller {
>  CInner m_PrimaryErase;
>  static const CKiller sm_NullConfig;
>};
>
>const CKiller CKiller::sm_NullConfig = {};
>
>int main(int argc, char **argv) { 
>    CKiller v;
>}

-- 
You are receiving this mail because:
You are on the CC list for the bug.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]