#ifndef SEARCH_H #define SEARCH_H #include "global.h" namespace JGadget { //! @todo: mangled name isn't correct, fix this //! Current: toValueFromIndex__7JGadgetFiPCPFdd_dUlRCPFdd_d //! Target: toValueFromIndex__7JGadgetFiPCPFdd_dUlRCPFdd_d_RCPFdd_d template inline const T& toValueFromIndex(int idx, const T* pValue, u32 count, const T& fallback) { ASSERT(pValue != NULL); return (idx < count) ? pValue[idx] : fallback; } } // namespace JGadget #endif /* SEARCH_H */