Jump to content

  • Log In with Google      Sign In   
  • Create Account


abrakadabra

Member Since 12 May 2013
Offline Last Active Apr 27 2014 01:21 PM
-----

Posts I've Made

In Topic: Paul Nettle's memory tracker mmgr and C++11

13 April 2014 - 10:58 AM

I can't think of any clean way to do it, but you can use a macro that evaluates to `delete':

#define cpp11_delete delete

// ...

class TestClass
{
public:
       TestClass() = cpp11_delete;
// ...
You could also use a less hackish tool, like Valgrind or Purify.

 

 

I tried it but cpp11_delete still evaluates to (m_setOwner (__FILE__,__LINE__,__FUNCTION__),false) ? m_setOwner("",0,"") : delete. sad.png


In Topic: polymorphism and inheriting from a base template class

12 May 2013 - 05:34 AM

I'm wondering what you want to achieve with this hierarchy. Isn't the goal of component based design to get away from inheritance as much as possible?

The goal is for every component system contain the components without having to define the std::map<int, component> and accessory methods in every system. That is 100's of lines of cut and paste for every component system (create_component(), component_exists(), etc).

 

Thank you Hodgman for your help, I will rethink my approach.


PARTNERS