RE: signals versus vfuncs
- From: Gaal Yahas <gaal forum2 org>
- To: Murray Cumming <murrayc usa net>, gtk-devel-list gnome org
- Subject: RE: signals versus vfuncs
- Date: Wed, 21 Jan 2004 19:39:22 +0200
On Wed, Jan 21, 2004 at 12:00:21PM -0500, Murray Cumming wrote:
> Does perl actually have the concept of virtual functions? I mean, if I
> have virtual function on_something() in the base class, and I override
> on_something in a derived class, if I call on_something from
> A::something_else() when the instance is actually an instance of B, will
> it call B::something_else() or A::something_else()? This is what C++
> does when you use the "virtual" keyword on methods, and what Java does
> by default.
Perl will call the subclass's method in the above case.
--
Gaal Yahas <gaal forum2 org>
http://gaal.livejournal.com/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]