On 8/13/2010 12:20 AM, Yao G. wrote:
On Thu, 12 Aug 2010 23:04:54 -0500, dickl <[email protected]> wrote:
On 8/12/2010 11:46 PM, Yao G. wrote:
You are mixing windows specific functions (WinMain) and console
functions (writeln). This will either cause an exception or just fail to
run. Try to replace calls to writeln with calls to MessageBox if you
want to check if the static constructor/destructor is working correctly.
The point is the static if isn't getting called at all...
and writeln does work in this example...
Try using:
shared static this()
I had a similar problem with a Win32 wrapper that I did.
using shared works
tnx