[Issue 22891] BetterC classes vtable

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Mar 18 01:09:14 UTC 2022


https://issues.dlang.org/show_bug.cgi?id=22891

Richard Cattermole <alphaglosined at gmail.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |alphaglosined at gmail.com

--- Comment #1 from Richard Cattermole <alphaglosined at gmail.com> ---
Current status:

import core.lifetime;

extern(C) void main()
{
    void[1000] buffer = void;
    Foo foo = emplace!Foo(buffer[], 12);
}

class Foo {
    this(int) {}
}

Output:

onlineapp.o:onlineapp.d:_D9onlineapp3Foo7__ClassZ: error: undefined reference
to '_D14TypeInfo_Class6__vtblZ'
onlineapp.o:onlineapp.d:_D9onlineapp3Foo7__ClassZ: error: undefined reference
to '_D6Object7__ClassZ'
onlineapp.o:onlineapp.d:_D9onlineapp3Foo6__vtblZ: error: undefined reference to
'_D6object6Object8toStringMFZAya'
onlineapp.o:onlineapp.d:_D9onlineapp3Foo6__vtblZ: error: undefined reference to
'_D6object6Object6toHashMFNbNeZm'
onlineapp.o:onlineapp.d:_D9onlineapp3Foo6__vtblZ: error: undefined reference to
'_D6object6Object5opCmpMFCQqZi'
onlineapp.o:onlineapp.d:_D9onlineapp3Foo6__vtblZ: error: undefined reference to
'_D6object6Object8opEqualsMFCQtZb'
collect2: error: ld returned 1 exit status
Error: linker exited with status 1

--


More information about the Digitalmars-d-bugs mailing list