Caffe2 - C++ API
A deep learning, cross platform ML framework
Related Pages
Modules
Data Structures
Files
C++ API
Python API
GitHub
File List
Globals
caffe2
core
nomnigraph
include
nomnigraph
Support
Pointer.h
1
//===- nomnigraph/Support/Pointer.h - Smart pointer helpers -----*- C++ -*-===//
2
//
3
// TODO Licensing.
4
//
5
//===----------------------------------------------------------------------===//
6
//
7
// This file defines a C++11 compatible make_unique
8
//
9
//===----------------------------------------------------------------------===//
10
11
#ifndef NOM_SUPPORT_POINTER_H
12
#define NOM_SUPPORT_POINTER_H
13
14
#include <memory>
15
16
namespace
nom
{
17
namespace
util {
18
19
template
<
typename
T,
typename
... Args>
20
std::unique_ptr<T> make_unique(Args &&... args) {
21
return
std::unique_ptr<T>(
new
T(std::forward<Args>(args)...));
22
}
23
24
}
// namespace util
25
}
// namespace nom
26
27
#endif // NOM_SUPPORT_POINTER_H
nom
Definition:
Caffe2.cc:16
Generated on Thu Apr 19 2018 13:03:50 for Caffe2 - C++ API by
1.8.11