Path: utzoo!attcan!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!usc!apple!voder!tolerant!procase!roger From: roger@procase.UUCP (Roger H. Scott) Newsgroups: comp.lang.c++ Subject: Re: pointers to member functions Message-ID: <4747383d.12160@espol> Date: 7 Dec 89 07:08:00 GMT References: <950@sl10c.concurrent.co.uk> Reply-To: roger@procase.UUCP (Roger H. Scott) Organization: proCASE Corporation, Santa Clara, CA Lines: 11 In article <950@sl10c.concurrent.co.uk> asc@concurrent.co.uk (Andy Chittenden) writes: >... >// However, how is one meant to achieve the >// above effect under v2 (pass an arbitrary function of a derived class >// with matching parameters)? 1. Declare any/all such functions to be virtual functions in the base class. This is the "right" way. 2. Cast. Have you ever seen a cast involving a pointer-to-member-function *without* a typedef? This is the "wrong" way.