[Issue 4145] cross alias namespace can't be resolve

d-bugmail at puremagic.com d-bugmail at puremagic.com
Sun May 2 04:57:03 PDT 2010


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



--- Comment #2 from galaxylang <galaxylang at gmail.com> 2010-05-02 04:57:02 PDT ---
So a alternative way to solve this problem is re-typedef the it


class A(T) {}
class B(T) {}
alias B!Foo Bar;
typedef A!(int) Foo;
void main() {}

but this will cause a new problem,see below

class A
{
  static A create();
}
typedef A B;
unittest
{
   B b=B.create();//error: A can't convert to B
}

should A create() change to B create when typedef used?

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


More information about the Digitalmars-d-bugs mailing list