2011-09-01 02:48:32 +00:00
|
|
|
#ifndef SPROUT_FIXED_CONTAINER_REFERENCE_HPP
|
|
|
|
#define SPROUT_FIXED_CONTAINER_REFERENCE_HPP
|
|
|
|
|
|
|
|
#include <type_traits>
|
|
|
|
#include <sprout/config.hpp>
|
|
|
|
#include <sprout/fixed_container/traits.hpp>
|
|
|
|
|
|
|
|
namespace sprout {
|
|
|
|
//
|
|
|
|
// fixed_reference
|
|
|
|
//
|
|
|
|
template<typename Container>
|
|
|
|
struct fixed_reference {
|
|
|
|
public:
|
2011-12-22 14:28:14 +00:00
|
|
|
typedef typename std::conditional<
|
2011-09-01 02:48:32 +00:00
|
|
|
std::is_const<Container>::value,
|
|
|
|
typename sprout::fixed_container_traits<Container>::const_reference,
|
|
|
|
typename sprout::fixed_container_traits<Container>::reference
|
|
|
|
>::type type;
|
|
|
|
};
|
|
|
|
} // namespace sprout
|
|
|
|
|
|
|
|
#endif // #ifndef SPROUT_FIXED_CONTAINER_REFERENCE_HPP
|