mirror of
https://github.com/autc04/Retro68.git
synced 2024-11-30 19:53:46 +00:00
16 lines
197 B
C++
16 lines
197 B
C++
// { dg-do run }
|
|
|
|
#include "event-private.h"
|
|
|
|
template<typename T> void derefIfNotNull(T* ptr)
|
|
{
|
|
if (ptr != 0)
|
|
ptr->deref();
|
|
}
|
|
|
|
int main()
|
|
{
|
|
Event * ev = new Event;
|
|
derefIfNotNull(ev);
|
|
}
|