http://d.puremagic.com/issues/show_bug.cgi?id=7152



--- Comment #1 from Kenji Hara <k.hara...@gmail.com> 2011-12-22 03:44:43 PST ---
This is a dup of 7019.
I'm not sure the implicit constructor call is allowed in default argument.

Workaround:

struct Foo
{
   this(int n) { }
   //void opAssign(void* a) { }  // not related to this issue.
}

//void test(Foo foo = null) { }  // ng
void test(Foo foo = Foo(null)) { }  // ok

void main()
{
   Foo foo = null;  // ok
}

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to