aboutsummaryrefslogtreecommitdiff
path: root/backend/util.hpp
blob: 2d9e76ab72fb2432221e40db40571ccc85e642f9 (plain)
1
2
3
4
5
6
7
8
9
10
11
#pragma once

#include "util.h"

template <typename T>
void safe_free(List<T *> & ptr_list) {
	for (T * obj : ptr_list)
		delete obj;
	ptr_list.clear();
}