Skip to content

Commit 3ed9492

Browse files
authored
take VortexSession by ref (#7270)
## Summary `VortexSession` now has interior mutability ## API Changes Changes several `initialize` functions to take by ref. ## Testing N/A Signed-off-by: Connor Tsui <connor.tsui20@gmail.com>
1 parent f43e12b commit 3ed9492

19 files changed

Lines changed: 27 additions & 27 deletions

File tree

encodings/alp/public-api.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ pub fn vortex_alp::alp_rd_decode<T: vortex_alp::ALPRDFloat>(left_parts: vortex_b
584584

585585
pub fn vortex_alp::decompress_into_array(array: vortex_alp::ALPArray, ctx: &mut vortex_array::executor::ExecutionCtx) -> vortex_error::VortexResult<vortex_array::arrays::primitive::vtable::PrimitiveArray>
586586

587-
pub fn vortex_alp::initialize(session: &mut vortex_session::VortexSession)
587+
pub fn vortex_alp::initialize(session: &vortex_session::VortexSession)
588588

589589
pub type vortex_alp::ALPArray = vortex_array::array::typed::Array<vortex_alp::ALP>
590590

encodings/alp/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ mod alp;
2828
mod alp_rd;
2929

3030
/// Initialize ALP encoding in the given session.
31-
pub fn initialize(session: &mut VortexSession) {
31+
pub fn initialize(session: &VortexSession) {
3232
session.arrays().register(ALP);
3333
session.arrays().register(ALPRD);
3434

encodings/datetime-parts/public-api.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -216,7 +216,7 @@ pub vortex_datetime_parts::TemporalParts::seconds: vortex_array::array::erased::
216216

217217
pub vortex_datetime_parts::TemporalParts::subseconds: vortex_array::array::erased::ArrayRef
218218

219-
pub fn vortex_datetime_parts::initialize(session: &mut vortex_session::VortexSession)
219+
pub fn vortex_datetime_parts::initialize(session: &vortex_session::VortexSession)
220220

221221
pub fn vortex_datetime_parts::split_temporal(array: vortex_array::arrays::datetime::TemporalArray) -> vortex_error::VortexResult<vortex_datetime_parts::TemporalParts>
222222

encodings/datetime-parts/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ use vortex_array::session::ArraySessionExt;
1818
use vortex_session::VortexSession;
1919

2020
/// Initialize datetime-parts encoding in the given session.
21-
pub fn initialize(session: &mut VortexSession) {
21+
pub fn initialize(session: &VortexSession) {
2222
session.arrays().register(DateTimeParts);
2323

2424
session.aggregate_fns().register_aggregate_kernel(

encodings/decimal-byte-parts/public-api.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -162,6 +162,6 @@ pub fn vortex_decimal_byte_parts::DecimalBytesPartsMetadata::clear(&mut self)
162162

163163
pub fn vortex_decimal_byte_parts::DecimalBytesPartsMetadata::encoded_len(&self) -> usize
164164

165-
pub fn vortex_decimal_byte_parts::initialize(session: &mut vortex_session::VortexSession)
165+
pub fn vortex_decimal_byte_parts::initialize(session: &vortex_session::VortexSession)
166166

167167
pub type vortex_decimal_byte_parts::DecimalBytePartsArray = vortex_array::array::typed::Array<vortex_decimal_byte_parts::DecimalByteParts>

encodings/decimal-byte-parts/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ use vortex_array::session::ArraySessionExt;
2020
use vortex_session::VortexSession;
2121

2222
/// Initialize decimal-byte-parts encoding in the given session.
23-
pub fn initialize(session: &mut VortexSession) {
23+
pub fn initialize(session: &VortexSession) {
2424
session.arrays().register(DecimalByteParts);
2525

2626
session.aggregate_fns().register_aggregate_kernel(

encodings/fastlanes/public-api.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -658,7 +658,7 @@ pub fn vortex_fastlanes::RLEData::unsliced_child_and_slice(&self) -> (&vortex_ar
658658

659659
pub fn vortex_fastlanes::delta_compress(array: &vortex_array::arrays::primitive::vtable::PrimitiveArray, ctx: &mut vortex_array::executor::ExecutionCtx) -> vortex_error::VortexResult<(vortex_array::arrays::primitive::vtable::PrimitiveArray, vortex_array::arrays::primitive::vtable::PrimitiveArray)>
660660

661-
pub fn vortex_fastlanes::initialize(session: &mut vortex_session::VortexSession)
661+
pub fn vortex_fastlanes::initialize(session: &vortex_session::VortexSession)
662662

663663
pub type vortex_fastlanes::BitPackedArray = vortex_array::array::typed::Array<vortex_fastlanes::BitPacked>
664664

encodings/fastlanes/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ use vortex_array::session::ArraySessionExt;
3131
use vortex_session::VortexSession;
3232

3333
/// Initialize fastlanes encodings in the given session.
34-
pub fn initialize(session: &mut VortexSession) {
34+
pub fn initialize(session: &VortexSession) {
3535
session.arrays().register(BitPacked);
3636
session.arrays().register(Delta);
3737
session.arrays().register(FoR);

encodings/runend/public-api.lock

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -206,7 +206,7 @@ pub fn vortex_runend::RunEndMetadata::clear(&mut self)
206206

207207
pub fn vortex_runend::RunEndMetadata::encoded_len(&self) -> usize
208208

209-
pub fn vortex_runend::initialize(session: &mut vortex_session::VortexSession)
209+
pub fn vortex_runend::initialize(session: &vortex_session::VortexSession)
210210

211211
pub fn vortex_runend::trimmed_ends_iter<E: vortex_array::dtype::ptype::IntegerPType>(run_ends: &[E], offset: usize, length: usize) -> impl core::iter::traits::iterator::Iterator<Item = usize> + use<'_, E>
212212

encodings/runend/src/lib.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ use vortex_array::session::ArraySessionExt;
3535
use vortex_session::VortexSession;
3636

3737
/// Initialize run-end encoding in the given session.
38-
pub fn initialize(session: &mut VortexSession) {
38+
pub fn initialize(session: &VortexSession) {
3939
session.arrays().register(RunEnd);
4040

4141
// Register the RunEnd-specific aggregate kernels.

0 commit comments

Comments
 (0)