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



--- Comment #3 from timon.g...@gmx.ch 2012-01-26 09:07:23 PST ---
(In reply to comment #2)
> (In reply to comment #1)
> > My understanding is, each inout deduction from a function argument just like
> > pattern matching.
> > 
> > Parameter type:   inout(          int *)*
> >  Argument type: mutable(immutable(int)*)*  // mutable(...) is pseudo 
> > modifier
> > --> 'inout' is deduced to 'mutable'.
> 
> The compiler should either fail to match, since inout wildcard is not applying
> to the immutable, or if it does match, it should treat foo as:
> 
> int** foo(int **x) { return x; }
> 
> This should fail to be able to be called with immutable(int)**.
> 
> The assert should fail because the typeof should resolve to Error.
> 
> I think this bug is invalid.

The typeof resolves to error because inout resolves to immutable.

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

Reply via email to