Skip to content

Commit b1cf08b

Browse files
committed
use actual type names in vortex-vector
Signed-off-by: Connor Tsui <[email protected]>
1 parent dd22351 commit b1cf08b

File tree

16 files changed

+162
-19
lines changed

16 files changed

+162
-19
lines changed

vortex-vector/src/bool/vector.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@ impl VectorOps for BoolVector {
8383
&self.validity
8484
}
8585

86-
fn try_into_mut(self) -> Result<Self::Mutable, Self>
86+
fn try_into_mut(self) -> Result<BoolVectorMut, Self>
8787
where
8888
Self: Sized,
8989
{

vortex-vector/src/bool/vector_mut.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -152,7 +152,7 @@ impl VectorMutOps for BoolVectorMut {
152152
self.validity.append_n(false, n);
153153
}
154154

155-
fn freeze(self) -> Self::Immutable {
155+
fn freeze(self) -> BoolVector {
156156
BoolVector {
157157
bits: self.bits.freeze(),
158158
validity: self.validity.freeze(),

vortex-vector/src/decimal/generic.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ impl<D: NativeDecimalType> VectorOps for DVector<D> {
9797
&self.validity
9898
}
9999

100-
fn try_into_mut(self) -> Result<Self::Mutable, Self>
100+
fn try_into_mut(self) -> Result<DVectorMut<D>, Self>
101101
where
102102
Self: Sized,
103103
{

vortex-vector/src/decimal/generic_mut.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ impl<D: NativeDecimalType> VectorMutOps for DVectorMut<D> {
3131
self.validity.reserve(additional);
3232
}
3333

34-
fn extend_from_vector(&mut self, other: &Self::Immutable) {
34+
fn extend_from_vector(&mut self, other: &DVector<D>) {
3535
self.elements.extend_from_slice(&other.elements);
3636
self.validity.append_mask(other.validity());
3737
}
@@ -41,7 +41,7 @@ impl<D: NativeDecimalType> VectorMutOps for DVectorMut<D> {
4141
self.validity.append_n(false, n);
4242
}
4343

44-
fn freeze(self) -> Self::Immutable {
44+
fn freeze(self) -> DVector<D> {
4545
DVector {
4646
ps: self.ps,
4747
elements: self.elements.freeze(),

vortex-vector/src/decimal/vector.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ impl VectorOps for DecimalVector {
3636
match_each_dvector!(self, |v| { v.validity() })
3737
}
3838

39-
fn try_into_mut(self) -> Result<Self::Mutable, Self>
39+
fn try_into_mut(self) -> Result<DecimalVectorMut, Self>
4040
where
4141
Self: Sized,
4242
{

vortex-vector/src/decimal/vector_mut.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ impl VectorMutOps for DecimalVectorMut {
3939
match_each_dvector_mut!(self, |d| { d.reserve(additional) })
4040
}
4141

42-
fn extend_from_vector(&mut self, other: &Self::Immutable) {
42+
fn extend_from_vector(&mut self, other: &DecimalVector) {
4343
match (self, other) {
4444
(DecimalVectorMut::D8(s), DecimalVector::D8(o)) => s.extend_from_vector(o),
4545
(DecimalVectorMut::D16(s), DecimalVector::D16(o)) => s.extend_from_vector(o),
@@ -55,7 +55,7 @@ impl VectorMutOps for DecimalVectorMut {
5555
match_each_dvector_mut!(self, |d| { d.append_nulls(n) })
5656
}
5757

58-
fn freeze(self) -> Self::Immutable {
58+
fn freeze(self) -> DecimalVector {
5959
match_each_dvector_mut!(self, |d| { d.freeze().into() })
6060
}
6161

vortex-vector/src/null/vector.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ impl VectorOps for NullVector {
4343
&self.validity
4444
}
4545

46-
fn try_into_mut(self) -> Result<Self::Mutable, Self>
46+
fn try_into_mut(self) -> Result<NullVectorMut, Self>
4747
where
4848
Self: Sized,
4949
{

vortex-vector/src/null/vector_mut.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -39,15 +39,15 @@ impl VectorMutOps for NullVectorMut {
3939
// We do not allocate memory for `NullVector`, so this is a no-op.
4040
}
4141

42-
fn extend_from_vector(&mut self, other: &Self::Immutable) {
42+
fn extend_from_vector(&mut self, other: &NullVector) {
4343
self.len += other.len;
4444
}
4545

4646
fn append_nulls(&mut self, n: usize) {
4747
self.len += n;
4848
}
4949

50-
fn freeze(self) -> Self::Immutable {
50+
fn freeze(self) -> NullVector {
5151
NullVector::new(self.len)
5252
}
5353

vortex-vector/src/primitive/vector.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@ impl VectorOps for PrimitiveVector {
7373
match_each_pvector!(self, |v| { v.validity() })
7474
}
7575

76-
fn try_into_mut(self) -> Result<Self::Mutable, Self>
76+
fn try_into_mut(self) -> Result<PrimitiveVectorMut, Self>
7777
where
7878
Self: Sized,
7979
{

vortex-vector/src/primitive/vector_mut.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@ impl VectorMutOps for PrimitiveVectorMut {
9696
match_each_pvector_mut!(self, |v| { v.reserve(additional) })
9797
}
9898

99-
fn extend_from_vector(&mut self, other: &Self::Immutable) {
99+
fn extend_from_vector(&mut self, other: &PrimitiveVector) {
100100
match (self, other) {
101101
(PrimitiveVectorMut::U8(a), PrimitiveVector::U8(b)) => a.extend_from_vector(b),
102102
(PrimitiveVectorMut::U16(a), PrimitiveVector::U16(b)) => a.extend_from_vector(b),
@@ -117,7 +117,7 @@ impl VectorMutOps for PrimitiveVectorMut {
117117
match_each_pvector_mut!(self, |v| { v.append_nulls(n) })
118118
}
119119

120-
fn freeze(self) -> Self::Immutable {
120+
fn freeze(self) -> PrimitiveVector {
121121
match_each_pvector_mut!(self, |v| { v.freeze().into() })
122122
}
123123

0 commit comments

Comments
 (0)