Skip to content

Commit 7865c47

Browse files
authored
Second pass no except (#469)
1 parent 752cf2d commit 7865c47

File tree

6 files changed

+40
-38
lines changed

6 files changed

+40
-38
lines changed

include/sparrow/layout/array_base.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@ namespace sparrow
162162
constexpr array_crtp_base(array_crtp_base&&) noexcept = default;
163163
constexpr array_crtp_base& operator=(array_crtp_base&&) noexcept = default;
164164

165-
[[nodiscard]] constexpr arrow_proxy& get_arrow_proxy();
166-
[[nodiscard]] constexpr const arrow_proxy& get_arrow_proxy() const;
165+
[[nodiscard]] constexpr arrow_proxy& get_arrow_proxy() noexcept;
166+
[[nodiscard]] constexpr const arrow_proxy& get_arrow_proxy() const noexcept;
167167

168168
constexpr bitmap_const_reference has_value(size_type i) const;
169169

@@ -391,13 +391,13 @@ namespace sparrow
391391
}
392392

393393
template <class D>
394-
constexpr auto array_crtp_base<D>::get_arrow_proxy() -> arrow_proxy&
394+
constexpr auto array_crtp_base<D>::get_arrow_proxy() noexcept -> arrow_proxy&
395395
{
396396
return m_proxy;
397397
}
398398

399399
template <class D>
400-
constexpr auto array_crtp_base<D>::get_arrow_proxy() const -> const arrow_proxy&
400+
constexpr auto array_crtp_base<D>::get_arrow_proxy() const noexcept -> const arrow_proxy&
401401
{
402402
return m_proxy;
403403
}

include/sparrow/layout/array_wrapper.hpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ namespace sparrow
4747
template <class ARRAY>
4848
struct get_data_type_from_array
4949
{
50-
[[nodiscard]] static constexpr sparrow::data_type get()
50+
[[nodiscard]] static constexpr sparrow::data_type get() noexcept
5151
{
5252
return arrow_traits<typename ARRAY::inner_value_type>::type_id;
5353
}
@@ -56,7 +56,7 @@ namespace sparrow
5656
template <class ARRAY>
5757
struct is_dictionary_encoded_array
5858
{
59-
[[nodiscard]] static constexpr bool get()
59+
[[nodiscard]] static constexpr bool get() noexcept
6060
{
6161
return false;
6262
}
@@ -80,7 +80,7 @@ namespace sparrow
8080

8181
[[nodiscard]] wrapper_ptr clone() const;
8282

83-
[[nodiscard]] constexpr enum data_type data_type() const;
83+
[[nodiscard]] constexpr enum data_type data_type() const noexcept;
8484
[[nodiscard]] constexpr bool is_dictionary() const;
8585

8686
[[nodiscard]] constexpr arrow_proxy& get_arrow_proxy();
@@ -118,10 +118,10 @@ namespace sparrow
118118

119119
using wrapper_ptr = array_wrapper::wrapper_ptr;
120120

121-
[[nodiscard]] constexpr enum data_type get_data_type() const;
121+
[[nodiscard]] constexpr enum data_type get_data_type() const noexcept;
122122

123123
constexpr array_wrapper_impl(const array_wrapper_impl&);
124-
[[nodiscard]] constexpr bool is_dictionary_impl() const override;
124+
[[nodiscard]] constexpr bool is_dictionary_impl() const noexcept override;
125125
[[nodiscard]] constexpr arrow_proxy& get_arrow_proxy_impl() override;
126126
[[nodiscard]] constexpr const arrow_proxy& get_arrow_proxy_impl() const override;
127127
[[nodiscard]] wrapper_ptr clone_impl() const override;
@@ -146,7 +146,7 @@ namespace sparrow
146146
return clone_impl();
147147
}
148148

149-
constexpr enum data_type array_wrapper::data_type() const
149+
constexpr enum data_type array_wrapper::data_type() const noexcept
150150
{
151151
return m_data_type;
152152
}
@@ -212,7 +212,7 @@ namespace sparrow
212212
}
213213

214214
template <class T>
215-
constexpr enum data_type array_wrapper_impl<T>::get_data_type() const
215+
constexpr enum data_type array_wrapper_impl<T>::get_data_type() const noexcept
216216
{
217217
return detail::get_data_type_from_array<T>::get();
218218
}
@@ -242,7 +242,7 @@ namespace sparrow
242242
}
243243

244244
template <class T>
245-
constexpr bool array_wrapper_impl<T>::is_dictionary_impl() const
245+
constexpr bool array_wrapper_impl<T>::is_dictionary_impl() const noexcept
246246
{
247247
return detail::is_dictionary_encoded_array<T>::get();
248248
}

include/sparrow/layout/decimal_reference.hpp

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -40,11 +40,11 @@ namespace sparrow
4040
using size_type = typename L::size_type;
4141
using difference_type = std::ptrdiff_t;
4242

43-
constexpr decimal_reference(L* layout, size_type index);
43+
constexpr decimal_reference(L* layout, size_type index) noexcept;
4444
constexpr decimal_reference(const decimal_reference&) = default;
4545
constexpr decimal_reference(decimal_reference&&) noexcept = default;
4646

47-
constexpr self_type& operator=(self_type&& rhs);
47+
constexpr self_type& operator=(self_type&& rhs) noexcept;
4848
constexpr self_type& operator=(const self_type& rhs);
4949

5050
constexpr self_type& operator=(value_type&& rhs);
@@ -78,7 +78,7 @@ namespace sparrow
7878
*************************************/
7979

8080
template <typename L>
81-
constexpr decimal_reference<L>::decimal_reference(L* layout, size_type index)
81+
constexpr decimal_reference<L>::decimal_reference(L* layout, size_type index) noexcept
8282
: p_layout(layout)
8383
, m_index(index)
8484
{
@@ -99,7 +99,7 @@ namespace sparrow
9999
}
100100

101101
template <typename L>
102-
constexpr auto decimal_reference<L>::operator=(self_type&& rhs) -> self_type&
102+
constexpr auto decimal_reference<L>::operator=(self_type&& rhs) noexcept -> self_type&
103103
{
104104
this->operator=(rhs.value());
105105
return *this;

include/sparrow/layout/dictionary_encoded_array.hpp

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ namespace sparrow
7373
template <std::integral IT>
7474
struct get_data_type_from_array<sparrow::dictionary_encoded_array<IT>>
7575
{
76-
[[nodiscard]] static constexpr sparrow::data_type get()
76+
[[nodiscard]] static constexpr sparrow::data_type get() noexcept
7777
{
7878
return arrow_traits<typename primitive_array<IT>::inner_value_type>::type_id;
7979
}
@@ -82,7 +82,7 @@ namespace sparrow
8282
template <std::integral IT>
8383
struct is_dictionary_encoded_array<sparrow::dictionary_encoded_array<IT>>
8484
{
85-
[[nodiscard]] static constexpr bool get()
85+
[[nodiscard]] static constexpr bool get() noexcept
8686
{
8787
return true;
8888
}

include/sparrow/layout/variable_size_binary_layout/variable_size_binary_array.hpp

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ namespace sparrow
4444
template <>
4545
struct variable_size_binary_format<std::string, std::int32_t>
4646
{
47-
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format()
47+
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format() noexcept
4848
{
4949
return "u";
5050
}
@@ -53,7 +53,7 @@ namespace sparrow
5353
template <>
5454
struct variable_size_binary_format<std::string, std::int64_t>
5555
{
56-
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format()
56+
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format() noexcept
5757
{
5858
return "U";
5959
}
@@ -62,7 +62,7 @@ namespace sparrow
6262
template <>
6363
struct variable_size_binary_format<std::vector<byte_t>, std::int32_t>
6464
{
65-
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format()
65+
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format() noexcept
6666
{
6767
return "z";
6868
}
@@ -71,7 +71,7 @@ namespace sparrow
7171
template <>
7272
struct variable_size_binary_format<std::vector<byte_t>, std::int64_t>
7373
{
74-
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format()
74+
[[nodiscard]] static SPARROW_CONSTEXPR_GCC_11 std::string format() noexcept
7575
{
7676
return "Z";
7777
}
@@ -138,7 +138,7 @@ namespace sparrow
138138
template <>
139139
struct get_data_type_from_array<sparrow::string_array>
140140
{
141-
[[nodiscard]] static constexpr sparrow::data_type get()
141+
[[nodiscard]] static constexpr sparrow::data_type get() noexcept
142142
{
143143
return sparrow::data_type::STRING;
144144
}
@@ -147,7 +147,7 @@ namespace sparrow
147147
template <>
148148
struct get_data_type_from_array<sparrow::big_string_array>
149149
{
150-
[[nodiscard]] static constexpr sparrow::data_type get()
150+
[[nodiscard]] static constexpr sparrow::data_type get() noexcept
151151
{
152152
return sparrow::data_type::LARGE_STRING;
153153
}
@@ -156,7 +156,7 @@ namespace sparrow
156156
template <>
157157
struct get_data_type_from_array<sparrow::binary_array>
158158
{
159-
[[nodiscard]] static constexpr sparrow::data_type get()
159+
[[nodiscard]] static constexpr sparrow::data_type get() noexcept
160160
{
161161
return sparrow::data_type::BINARY;
162162
}
@@ -165,7 +165,7 @@ namespace sparrow
165165
template <>
166166
struct get_data_type_from_array<sparrow::big_binary_array>
167167
{
168-
[[nodiscard]] static constexpr sparrow::data_type get()
168+
[[nodiscard]] static constexpr sparrow::data_type get() noexcept
169169
{
170170
return sparrow::data_type::LARGE_BINARY;
171171
}

include/sparrow/layout/variable_size_binary_layout/variable_size_binary_iterator.hpp

Lines changed: 14 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -55,12 +55,12 @@ namespace sparrow
5555

5656
[[nodiscard]] constexpr reference dereference() const;
5757

58-
constexpr void increment();
59-
constexpr void decrement();
60-
constexpr void advance(difference_type n);
61-
[[nodiscard]] constexpr difference_type distance_to(const self_type& rhs) const;
62-
[[nodiscard]] constexpr bool equal(const self_type& rhs) const;
63-
[[nodiscard]] constexpr bool less_than(const self_type& rhs) const;
58+
constexpr void increment() noexcept;
59+
constexpr void decrement() noexcept;
60+
constexpr void advance(difference_type n) noexcept;
61+
[[nodiscard]] constexpr difference_type distance_to(const self_type& rhs) const noexcept;
62+
[[nodiscard]] constexpr bool equal(const self_type& rhs) const noexcept;
63+
[[nodiscard]] constexpr bool less_than(const self_type& rhs) const noexcept;
6464

6565
layout_type* p_layout = nullptr;
6666
difference_type m_index;
@@ -96,40 +96,42 @@ namespace sparrow
9696
}
9797

9898
template <class Layout, iterator_types Iterator_types>
99-
constexpr void variable_size_binary_value_iterator<Layout, Iterator_types>::increment()
99+
constexpr void variable_size_binary_value_iterator<Layout, Iterator_types>::increment() noexcept
100100
{
101101
++m_index;
102102
}
103103

104104
template <class Layout, iterator_types Iterator_types>
105-
constexpr void variable_size_binary_value_iterator<Layout, Iterator_types>::decrement()
105+
constexpr void variable_size_binary_value_iterator<Layout, Iterator_types>::decrement() noexcept
106106
{
107107
--m_index;
108108
}
109109

110110
template <class Layout, iterator_types Iterator_types>
111-
constexpr void variable_size_binary_value_iterator<Layout, Iterator_types>::advance(difference_type n)
111+
constexpr void
112+
variable_size_binary_value_iterator<Layout, Iterator_types>::advance(difference_type n) noexcept
112113
{
113114
m_index += n;
114115
}
115116

116117
template <class Layout, iterator_types Iterator_types>
117118
constexpr auto
118-
variable_size_binary_value_iterator<Layout, Iterator_types>::distance_to(const self_type& rhs) const
119+
variable_size_binary_value_iterator<Layout, Iterator_types>::distance_to(const self_type& rhs) const noexcept
119120
-> difference_type
120121
{
121122
return rhs.m_index - m_index;
122123
}
123124

124125
template <class Layout, iterator_types Iterator_types>
125-
constexpr bool variable_size_binary_value_iterator<Layout, Iterator_types>::equal(const self_type& rhs) const
126+
constexpr bool
127+
variable_size_binary_value_iterator<Layout, Iterator_types>::equal(const self_type& rhs) const noexcept
126128
{
127129
return (p_layout == rhs.p_layout) && (m_index == rhs.m_index);
128130
}
129131

130132
template <class Layout, iterator_types Iterator_types>
131133
constexpr bool
132-
variable_size_binary_value_iterator<Layout, Iterator_types>::less_than(const self_type& rhs) const
134+
variable_size_binary_value_iterator<Layout, Iterator_types>::less_than(const self_type& rhs) const noexcept
133135
{
134136
return (p_layout == rhs.p_layout) && (m_index < rhs.m_index);
135137
}

0 commit comments

Comments
 (0)