Skip to content

Commit

Permalink
fixed rebasing issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Klaim committed Apr 5, 2024
1 parent 4b7d2db commit e6d52b9
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 18 deletions.
16 changes: 16 additions & 0 deletions include/sparrow/data_type.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,22 @@ namespace sparrow
};


namespace impl
{
template <class C, bool is_const>
struct get_inner_reference
: std::conditional<is_const, typename C::inner_const_reference, typename C::inner_reference>
{
};

template <class C, bool is_const>
using get_inner_reference_t = typename get_inner_reference<C, is_const>::type;
} // namespace impl

template <class T>
concept layout_offset = std::same_as<T, std::int32_t> || std::same_as<T, std::int64_t>;



}

13 changes: 0 additions & 13 deletions include/sparrow/mp_utils.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -265,18 +265,5 @@ namespace sparrow::mpl
}


namespace impl
{
template <class C, bool is_const>
struct get_inner_reference
: std::conditional<is_const, typename C::inner_const_reference, typename C::inner_reference>
{
};

template <class C, bool is_const>
using get_inner_reference_t = typename get_inner_reference<C, is_const>::type;
} // namespace impl

template <class T>
concept layout_offset = std::same_as<T, std::int32_t> || std::same_as<T, std::int64_t>;
}
10 changes: 5 additions & 5 deletions include/sparrow/variable_size_binary_layout.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ namespace sparrow
>;
using reference = typename base_type::reference;
using difference_type = typename base_type::difference_type;

using offset_iterator = std::conditional_t<
is_const, typename L::const_offset_iterator, typename L::offset_iterator
>;
Expand Down Expand Up @@ -99,7 +99,7 @@ namespace sparrow
* The internal buffers will be:
* - offset: [0, 6, 11, 13, 15, 24, 30]
* - data: ['p','l','e','a','s','e','a','l','l','o','w','m','e','t','o','i','n','t','r','o','d','u','c','e','m','y','s','e','l','f']
*
*
* @tparam T the type of the data stored in the data buffer, not its byte representation.
* @tparam R the reference type to the data. This type is different from the reference type of the layout,
* which behaves like std::optional<R>.
Expand Down Expand Up @@ -133,7 +133,7 @@ namespace sparrow
using const_offset_iterator = const OT*;
using data_iterator = data_type*;
using const_data_iterator = const data_type*;

using const_value_iterator = vs_binary_value_iterator<self_type, true>;
using const_bitmap_iterator = array_data::bitmap_type::const_iterator;
using const_iterator = layout_iterator<self_type, true>;
Expand Down Expand Up @@ -264,7 +264,7 @@ namespace sparrow
assert(i < size());
return const_reference(value(i), has_value(i));
}

template <class T, class R, class CR, layout_offset OT>
auto variable_size_binary_layout<T, R, CR, OT>::cbegin() const -> const_iterator
{
Expand All @@ -276,7 +276,7 @@ namespace sparrow
{
return const_iterator(value_cend(), bitmap_cend());
}

template <class T, class R, class CR, layout_offset OT>
auto variable_size_binary_layout<T, R, CR, OT>::bitmap() const -> const_bitmap_range
{
Expand Down

0 comments on commit e6d52b9

Please sign in to comment.