Is there a good argument for why e.g. te::MidiEvent or te::MidiEventHolder should not inherit from juce::ReferenceCountedObject?
In my code I keep a reference to some of these pointers. Before I made te::MidiEvent inherit from juce::ReferenceCountedObject, I would get a lot of dangling pointer warnings after the program terminated. Once I made it inherit from juce::ReferenceCountedObject, the warnings went away. I'm not sure if this is the right way of solving this though.
Is there a good argument for why e.g.
te::MidiEvent
orte::MidiEventHolder
should not inherit fromjuce::ReferenceCountedObject
?In my code I keep a reference to some of these pointers. Before I made
te::MidiEvent
inherit fromjuce::ReferenceCountedObject
, I would get a lot ofdangling pointer
warnings after the program terminated. Once I made it inherit fromjuce::ReferenceCountedObject
, the warnings went away. I'm not sure if this is the right way of solving this though.