class const_buffer
{
public:
/// Construct an empty buffer.
const_buffer()
: data_(0),
size_(0)
{
}
/// Construct a buffer to represent a given memory range.
const_buffer(const void* data, std::size_t size)
: data_(data),
size_(size)
{
}
const void* data_;
std::size_t size_;
}
data_ is defined as void* and size_ is of type std::size_t. They are not functions, but why you can do data_(data), size_(size)? Looks like they take on parameters and acting like functions.