Deleted virtual functions

David Vandevoorde daveed at edg.com
Tue May 26 17:57:34 UTC 2009


I think the ABI should specify what should happen with deleted virtual  
functions:

	struct B {
	  virtual void f() = delete;
	};

	struct D: B {
	  virtual void f() = delete;
	};

Our preference would be for such functions to take up a slot in the  
virtual function table, and have that slot point to a new aborting ABI  
function __cxx_deleted_virtual (much like __cxa_pure_virtual).  This  
approach allows  changing a virtual function from deleted to non- 
deleted without breaking the vtable layout.

	Daveed




More information about the cxx-abi-dev mailing list