Date: Thu, 28 Apr 2022 00:13:37 +0200 From: Joerg Sonnenberger <joerg@bec.de> To: freebsd-hackers@freebsd.org Subject: Re: llvm & RTTI over shared libraries Message-ID: <YmnAEXat8iaMXf%2Bh@bec.de> In-Reply-To: <A7BF3192-44EF-485C-8CB7-E7F4FFCA1E5A@yahoo.com> References: <A7BF3192-44EF-485C-8CB7-E7F4FFCA1E5A.ref@yahoo.com> <A7BF3192-44EF-485C-8CB7-E7F4FFCA1E5A@yahoo.com>
next in thread | previous in thread | raw e-mail | index | archive | help
Am Tue, Apr 26, 2022 at 05:48:00PM -0700 schrieb Mark Millard: > • Joerg Sonnenberger <joerg_at_bec.de> wrote on > • Date: Tue, 26 Apr 2022 23:47:23 UTC : > > > Am Mon, Apr 25, 2022 at 03:39:48PM -0700 schrieb Mark Millard: > > > Basically I avoid inline definitions of: > > > > > > virtual ~type_base(); > > > virtual ~type_int(); > > > virtual ~type_string(); > > > > You only need to ensure that the class has one non-pure non-inline > > function. > > I'm confused at what you are claiming that I did wrong or > described incorrectly for the example at hand. I'm giving the exact rule to make sure the OP knows what exactly to follow. Otherwise they can test a chance, discover that in their use case an inlined dtor actually works because something else is the key function etc. I don't disagree with your example, I just want to make sure that it is understood what the critical point is. > > If there is no such function, both will be defined as weak > > mergable symbol and that will not result in a unique address when using > > RTLD_LOCAL. > > I was certainly less detailed about how multiple definitions > are handled. Was that your point? I added that note because it also tells you what symptoms to look for to diagnose the issue. E.g. it is normally a bad sign in C++ to see weak vtable and type symbols and something that should be checked. Joerg
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?YmnAEXat8iaMXf%2Bh>