Re: Empty LST files?

2016-07-31 Thread Thalamus via Digitalmars-d-learn
On Sunday, 31 July 2016 at 17:01:32 UTC, Seb wrote: On Sunday, 31 July 2016 at 16:55:52 UTC, Seb wrote: On Sunday, 31 July 2016 at 16:48:52 UTC, Thalamus wrote: On Sunday, 31 July 2016 at 16:08:49 UTC, Seb wrote: On Sunday, 31 July 2016 at 15:30:46 UTC, Thalamus wrote: [...] How about

Re: Empty LST files?

2016-07-31 Thread Thalamus via Digitalmars-d-learn
On Sunday, 31 July 2016 at 16:08:49 UTC, Seb wrote: On Sunday, 31 July 2016 at 15:30:46 UTC, Thalamus wrote: On Sunday, 31 July 2016 at 14:03:49 UTC, Thalamus wrote: [...] After a couple more hours today, I found a couple of solutions. Neither is satisfactory. [...] How about setting

Re: Empty LST files?

2016-07-31 Thread Thalamus via Digitalmars-d-learn
On Sunday, 31 July 2016 at 14:03:49 UTC, Thalamus wrote: On Sunday, 31 July 2016 at 10:05:04 UTC, Basile B. wrote: On Sunday, 31 July 2016 at 08:29:47 UTC, Basile B. wrote: On Sunday, 31 July 2016 at 01:10:40 UTC, Thalamus wrote: Any idea what I'm doing wrong? Yes, what's going wrong is

Re: Empty LST files?

2016-07-31 Thread Thalamus via Digitalmars-d-learn
On Sunday, 31 July 2016 at 10:05:04 UTC, Basile B. wrote: On Sunday, 31 July 2016 at 08:29:47 UTC, Basile B. wrote: On Sunday, 31 July 2016 at 01:10:40 UTC, Thalamus wrote: Any idea what I'm doing wrong? Yes, what's going wrong is quite actually you said that the LST is well generated but

Empty LST files?

2016-07-30 Thread Thalamus via Digitalmars-d-learn
I'm running into a problem where when I specify -cov in the DMD compiler command, the coverage LST files are generated, but they're all empty. Has anyone else run into this before? My command line is: dmd -m64 -gc -debug -w -wi -cov -X -Xf"obj\Unit.json" -I\ -deps="obj\Unit.dep" -c

Re: Registration-free COM client

2016-06-29 Thread Thalamus via Digitalmars-d-learn
On Wednesday, 29 June 2016 at 19:21:50 UTC, John wrote: On Wednesday, 29 June 2016 at 14:51:10 UTC, Thalamus wrote: [...] A little research reveals that C# COM servers don't export DllGetClassObject, or any of the COM server plumbing. "Registering for COM interop" merely adds the registry

Re: Registration-free COM client

2016-06-29 Thread Thalamus via Digitalmars-d-learn
On Tuesday, 28 June 2016 at 02:30:56 UTC, thedeemon wrote: To load load a COM object from a given file (DLL or AX) without having it registered, just load the file with CoLoadLibrary() and use its DllGetClassObject() function to get IClassFactory which will give you any kind of object in this

Registration-free COM client

2016-06-27 Thread Thalamus via Digitalmars-d-learn
Hi everyone, I've succeeded in using D as a client for regular (registered) COM servers in the past, but in this case, I'm building the server as well. I would like to avoid registering it if possible so XCOPY-like deployment remains an option. Can a registration-free COM client be built in

Re: TypeInfo_Interface from runtime string?

2016-06-22 Thread Thalamus via Digitalmars-d-learn
On Wednesday, 22 June 2016 at 15:46:15 UTC, Thalamus wrote: On Wednesday, 22 June 2016 at 15:43:08 UTC, Basile B. wrote: On Wednesday, 22 June 2016 at 15:15:51 UTC, Thalamus wrote: [...] No need for a constructor. typeid() returns a static instance that's pre-allocated. [...] Thanks

Re: TypeInfo_Interface from runtime string?

2016-06-22 Thread Thalamus via Digitalmars-d-learn
On Wednesday, 22 June 2016 at 15:43:08 UTC, Basile B. wrote: On Wednesday, 22 June 2016 at 15:15:51 UTC, Thalamus wrote: [...] No need for a constructor. typeid() returns a static instance that's pre-allocated. [...] Thanks Basile.

TypeInfo_Interface from runtime string?

2016-06-22 Thread Thalamus via Digitalmars-d-learn
Hi everyone, My project includes lots of .Net interop via C linkage. One of the things I need to do is refer in C# to an interface declared in the D code, and then to actually work with the interface concretely in the D layer. So, I need to get a TypeInfo_Interface object from a string

Re: Convert wchar* to wstring?

2016-04-05 Thread Thalamus via Digitalmars-d-learn
On Tuesday, 5 April 2016 at 19:19:10 UTC, ag0aep6g wrote: On 05.04.2016 20:44, Thalamus wrote: [...] Aside: D has syntax for "// For wchar_t.": `import core.stdc.stddef: wchar_t;`. [...] wchar_t is not wchar. wstring is not (portably) compatible with a wchar_t array. If you actually

Re: Convert wchar* to wstring?

2016-04-05 Thread Thalamus via Digitalmars-d-learn
On Tuesday, 5 April 2016 at 11:26:44 UTC, Thalamus wrote: Thanks everyone! You've all been very helpful. For anyone who has the same question and happens on this thread, I wanted to post what I finally came up with. I combined the information everyone in this thread gave me with what I saw

Re: Convert wchar* to wstring?

2016-04-05 Thread Thalamus via Digitalmars-d-learn
Thanks everyone! You've all been very helpful.

Re: Debugging D DLL from C# app with C linkage for native Unity 5 plugin

2016-03-30 Thread Thalamus via Digitalmars-d-learn
On Wednesday, 30 March 2016 at 07:38:07 UTC, Benjamin Thaut wrote: On Tuesday, 29 March 2016 at 23:41:28 UTC, Thalamus wrote: dmd dllmain.d dll.def -w -wi -g -map -ofLogic.dll -m64 -debug -shared Anyone know what I should try next? Am I missing something simple? :) thanks! Thalamus

Debugging D DLL from C# app with C linkage for native Unity 5 plugin

2016-03-29 Thread Thalamus via Digitalmars-d-learn
Apologies if this has been discussed before, but I wasn't able to find anything similar on the forums or web. I can't seem to figure out how to debug a D DLL from a C# EXE. (My actual purpose here is to use D to build native plugins for Unity 5, but Unity and Mono aren't necessary to repro the

Re: Shared static constructors from C# EXE

2016-02-26 Thread Thalamus via Digitalmars-d-learn
On Friday, 26 February 2016 at 08:37:35 UTC, Benjamin Thaut wrote: On Thursday, 25 February 2016 at 17:46:18 UTC, Thalamus wrote: On Thursday, 25 February 2016 at 16:05:37 UTC, Benjamin Thaut wrote: [...] Thanks Benjamin. When I went to whittle this down to its barest essentials, though,

Re: Shared static constructors from C# EXE

2016-02-25 Thread Thalamus via Digitalmars-d-learn
On Thursday, 25 February 2016 at 16:05:37 UTC, Benjamin Thaut wrote: On Thursday, 25 February 2016 at 14:42:14 UTC, Thalamus wrote: your entry point. Hi Guillaume, Thanks for responding so quickly! I had found that wiki page before and I'd been following the "DLLs with a C Interface"

Re: Shared static constructors from C# EXE

2016-02-25 Thread Thalamus via Digitalmars-d-learn
On Thursday, 25 February 2016 at 14:07:21 UTC, Guillaume Piolat wrote: On Thursday, 25 February 2016 at 14:01:30 UTC, Thalamus wrote: I don't control the EXE itself and the code I write to interface with it must be either C# or JavaScript, but this repros with a test C# driver EXE as well. The

Shared static constructors from C# EXE

2016-02-25 Thread Thalamus via Digitalmars-d-learn
Hi everyone, I looked in the forums and Google in general but I didn't find a similar question, and I'm stumped. I have a scenario where a set of classes must be registered with a class mapper and then instantiated via a factory. The classes themselves are agnostic of one another, and all

Re: Linking a DLL to a DLL with packages

2016-01-13 Thread Thalamus via Digitalmars-d-learn
On Sunday, 10 January 2016 at 15:58:55 UTC, Benjamin Thaut wrote: Am 09.01.2016 um 16:45 schrieb Thalamus: Hi Benjamin, I wouldn't say I need DLLs to work fully _really_ badly. The only non-negligible issue with single very large binaries that's crossed my mind is patching, but we're years

Re: Linking a DLL to a DLL with packages

2016-01-09 Thread Thalamus via Digitalmars-d-learn
On Friday, 8 January 2016 at 12:13:15 UTC, Benjamin Thaut wrote: On Thursday, 7 January 2016 at 19:29:43 UTC, Thalamus wrote: Hi everyone, First off, I've been working with D for a couple of weeks now and I think it's the bee's knees! :) Except for DLLs. thanks! :) Dlls don't currently

Linking a DLL to a DLL with packages

2016-01-07 Thread Thalamus via Digitalmars-d-learn
Hi everyone, First off, I've been working with D for a couple of weeks now and I think it's the bee's knees! :) Except for DLLs. I've been combing through forum posts and Google for this situation. Several threads and articles are close but don't quite cover what I'm doing here. On