[Issue 24085] Separate Compilation Bugs

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Oct 18 16:38:06 UTC 2024


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

ilya.yanok at gmail.com changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ilya.yanok at gmail.com

--- Comment #2 from ilya.yanok at gmail.com ---
I think I'm also affected by the same bug (also reproducible with LDC), but I
think my minimal example uses even less features. There is also a cyclic
dependency and an overloaded operator though.

That's what dustmite produced (doesn't make sense, because of infinite
recursion, but still symbols should be there, I think):

// option.d
import util;
struct Option(T) {
        int opCmp()(const(Option) rhs) const {
            return this.opCmp(rhs);
        }
}
Option!string f;

// util.d
import option;
Option!string x;

// dmd -c option.d
// dmd -c util.d
// nm option.o util.o | ddemangle | grep 'opCmp!'
// Neither of .o files have an implementation for this symbol


It is possible to make the actual implementation more reasonable, while still
having this issue.

--


More information about the Digitalmars-d-bugs mailing list