/*
- * Copyright 2016 Facebook, Inc.
+ * Copyright 2017 Facebook, Inc.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* Get the 1-based type index of T in Types.
*/
template <typename T>
- size_t typeIndex() const {
- return dptr_detail::GetTypeIndex<T, Types...>::value;
+ uint16_t typeIndex() const {
+ return uint16_t(dptr_detail::GetTypeIndex<T, Types...>::value);
}
uint16_t index() const { return data_ >> 48; }