digitalmars.D - __init_ vs _init_
- Ben Hinkle (10/10) Nov 22 2004 Does anyone know why D sometimes generates symbol names of the form
- Walter (4/13) Nov 22 2004 code
- Ben Hinkle (14/27) Nov 22 2004 MinTL
Does anyone know why D sometimes generates symbol names of the form __init_10Typeinfo_i vs _init_10Typeinfo_i (note the number of leading underscores). I'm trying to debug various Win32 linking error using MinTL that seem to depend on its use of combinations of mixins and typeid and vararg code. When I get a link error it is looking for the _init_ with one underscore and everything works fine when it looks for __init_ with two underscores. I've reverted to DMD-102 and the link errors go away but even with 106 I still get them. Currently I've started commenting out MinTL code to get something that works. On Linux everything seems ok. -Ben
Nov 22 2004
"Ben Hinkle" <bhinkle mathworks.com> wrote in message news:cntgca$jq7$1 digitaldaemon.com...Does anyone know why D sometimes generates symbol names of the form __init_10Typeinfo_i vs _init_10Typeinfo_i (note the number of leading underscores). I'm trying to debug various Win32 linking error using MinTL that seem to depend on its use of combinations of mixins and typeid and vararg code. When I get a link error it is looking for the _init_ with one underscore and everything works fine when it looks for __init_ with two underscores. I've reverted to DMD-102 and the link errors go away but even with 106 I still get them. Currently I've started commenting out MinTLcodeto get something that works. On Linux everything seems ok.Are you trying to hook up to an import library written in D?
Nov 22 2004
"Walter" <newshound digitalmars.com> wrote in message news:cnthc7$lnt$1 digitaldaemon.com..."Ben Hinkle" <bhinkle mathworks.com> wrote in message news:cntgca$jq7$1 digitaldaemon.com...MinTLDoes anyone know why D sometimes generates symbol names of the form __init_10Typeinfo_i vs _init_10Typeinfo_i (note the number of leading underscores). I'm trying to debug various Win32 linking error usingonethat seem to depend on its use of combinations of mixins and typeid and vararg code. When I get a link error it is looking for the _init_ withevenunderscore and everything works fine when it looks for __init_ with two underscores. I've reverted to DMD-102 and the link errors go away butIt doesn't seem to matter if I use a library or list the relevant files explicitly: The symbol is defined in phobos with two underscores. By some combinations my object file sometimes ends up needing _init and sometimes ends up with __init. I've been trying to get simple reproduction steps but it seems pretty complicated. In MinTL it could involve three modules with a couple mixins and possible vararg functions (comparing against _arguments so it could be that _arguments is the first time the symbol is hit). Scatter throughout are typeid(T) where T is "int" (not that "int" is important - any type will do).with 106 I still get them. Currently I've started commenting out MinTLcodeto get something that works. On Linux everything seems ok.Are you trying to hook up to an import library written in D?
Nov 22 2004