aboutsummaryrefslogtreecommitdiffstats
path: root/library/cpp/yt/memory/safe_memory_reader-inl.h
blob: 69d8c1c91848b1efc5c5a1541b5e507510d00d72 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
#ifndef SAFE_MEMORY_READER_INL_H_
#error "Direct inclusion of this file is not allowed, include safe_memory_reader.h"
// For the sake of sane code completion.
#include "safe_memory_reader.h"
#endif

namespace NYT {

////////////////////////////////////////////////////////////////////////////////

template <class T>
bool TSafeMemoryReader::Read(const void* addr, T* value)
{
    return ReadRaw(addr, value, sizeof(*value));
}

////////////////////////////////////////////////////////////////////////////////

} // namespace NYT