October 17th, 2013, 12:43 PM
Re: template for events
What feature of a constructor does all of your code that you post is missing? It is a feature that you should be using, but you never used it. In some ways, this feature is not a requirement, but it is a requirement if any member variables do not have default constructors.
Originally Posted by Cambalinho
Now given all of that, do you know what this "feature" is that
1) You seem to never use which you should start to use and
2) Is required to initialize members that cannot be default constructed (like the m_foo variable, and the events variable in your class.
That is your homework. Believe me, this is covered in beginner C++ books. The code I posted is beginner code, but from the looks of it, you can't fix it. I know it's humbling, but seriously, this indicates that you need to learn the fundamentals before embarking on this other code you're trying to write.
Last edited by Paul McKenzie; October 17th, 2013 at 12:45 PM.
Click Here to Expand Forum to Full Width