another indicator (as documented) that GC destructor won't work
// extern(C++) classes don't have a classinfo pointer in their
vtable so the GC can't finalize them
https://github.com/dlang/druntime/blob/3d8d4a45c01832fb657c16a656b6e1566d77fb21/src/rt/lifetime.d#L90
annoying :(
Markus
On Wednesday, 22 November 2017 at 08:43:54 UTC, drug wrote:
22.11.2017 02:12, Markus пишет:
What about dtor - you allocate class using D GC but try to
destroy it manually - namely this I guess gives you an error in
rt_finalize2 because it tries to destroy object that has been
destroyed.
hi, im trying to interface a cpp class. I'd like to interface a
bigger library and I'm trying to figure out the minimum effort.
--- c++ part:
#include
class some_class {
public:
static some_class* __ctor();
some_class();
~some_class();
void some_method();
};
some_class*
On Tuesday, 21 November 2017 at 04:39:52 UTC, A Guy With a
Question wrote:
I'm trying to learn D using Visual D in Visual Studio Community
2015. Both dmd and ldc give me this error when building from
Visual Studio. Any ideas? I'm able to build C++ projects...
I had to update "Visual Studio
On Friday, 17 August 2018 at 08:09:52 UTC, Markus wrote:
I wonder what's the reason for that?
I wonder why it's not at least @trusted. Literally, can't I trust
that method/function?
Hi.
I'm a big fan of @safe code. But within my first 20 program lines
I already run into problems:
Error: @safe function D main cannot call @system function
std.getopt.defaultGetoptPrinter
https://dlang.org/phobos/std_getopt.html#.defaultGetoptPrinter
I wonder what's the reason for that?
Hi, I'm using core.sys.windows.windows to make a Windows GUI, and
the WindowProc must be nothrow. My code does not provide me a
stack backtrace when some exception is thrown in there. I would
like to have at least the number of the line that caused a throw,
has anyone an idea how to do this?
On Monday, 3 June 2019 at 12:09:18 UTC, Adam D. Ruppe wrote:
Don't use just e.msg, that's just the string the constructor
sent, use e.toString and see if it works for you.
toString works, thanks! :)
On Tuesday, 11 June 2019 at 05:15:17 UTC, Markus wrote:
I have cleaned it up, kind of. Just in case you want to compile
it. The Zip contains some DLL from
https://github.com/spatialaudio/portaudio-binaries where you
can find the original if you want.
https://gofile.io/?c=NpUxrJ
I'm in
Hi, when you use core.windows and LoadLibrary to load a DLL, and
that DLL will create a new thread and inside that it will call
back into your D app, is there something to special to be aware
of?
I've done it like with the CreateWindow and WndProc, but this
time I'm loading a compiled
I have cleaned it up, kind of. Just in case you want to compile
it. The Zip contains some DLL from
https://github.com/spatialaudio/portaudio-binaries where you can
find the original if you want.
https://gofile.io/?c=NpUxrJ
I'm in general thinking of buying a Mac. I know it has not much
to
Hi, sorry for the broad and vague question. I have read in some
reddit post about benchmarks, that some code didn't use the final
keyword on methods in a sense that final would make it faster, I
believe.
I thought, without any D knowledge, it could be that with shorter
code I might create
12 matches
Mail list logo