[D-runtime] What is a hidden function?

Steve Schveighoffer schveiguy at yahoo.com
Fri May 11 12:38:20 PDT 2012


class A
{
   void hiddenFunction(int x);

}

class B : A

{
   void hiddenFunction(long x);  // does not override A.hiddenFunction!

}

B b = new B;
A a = b;

b.hiddenFunction(1); // ok, does not call A.hiddenFunction
a.hiddenFunction(1); // error, hiddenFunction exception thrown.

At least, this is what it used to mean.  I think Andrei wanted this to be a compile-time error, but I'm not sure if it is yet.

-Steve




>________________________________
> From: Alex Rønne Petersen <xtzgzorex at gmail.com>
>To: D's runtime library developers list <d-runtime at puremagic.com> 
>Sent: Friday, May 11, 2012 3:13 PM
>Subject: [D-runtime] What is a hidden function?
> 
>Hi,
>
>I just noticed the onHiddenFuncError(Object o) function. However, I
>can't seem to figure out what on earth a hidden function is. Anyone
>know?
>
>Regards,
>Alex
>_______________________________________________
>D-runtime mailing list
>D-runtime at puremagic.com
>http://lists.puremagic.com/mailman/listinfo/d-runtime
>
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.puremagic.com/pipermail/d-runtime/attachments/20120511/aca86394/attachment.html>


More information about the D-runtime mailing list