delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1998/03/17/03:00:48

Date: Tue, 17 Mar 1998 09:53:40 +0200 (EET)
From: Andris Pavenis <pavenis AT latnet DOT lv>
To: Gavin Sinclair <gavins AT cse DOT unsw DOT EDU DOT AU>
cc: djgpp AT delorie DOT com
Subject: Re: Run-time error: pure virtual function called
In-Reply-To: <Pine.GSO.3.95.980316234447.13733A-100000@haydn.orchestra.cse.unsw.EDU.AU>
Message-ID: <Pine.GSO.3.96.980317095141.8120B-100000@sisenis>
MIME-Version: 1.0


On Mon, 16 Mar 1998, Gavin Sinclair wrote:

> Hello,
> 
> I'm having this strange problem whereby my program dies at runtime with
> the message "Pure virtual function called" (using DJGPP of course, gcc
> 2.7.2.1).  Now I know what it means (it's a C++ program), but I found
> where it was stopping and there are certainly no pure virtual function
> calls.  In fact it seems to dislike the line
> 
> 	return kingthreats.numElements;
> 
> where there are obviously no function calls at all.  Has anyone had any
> experience with this?
> 

The most obvious way how to get this message is to call virtual function
from constructor or destructor of base class when this virtual function
is redefined in inheritted class



- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019