Skip to content

Commit 5bca289

Browse files
committed
---
yaml --- r: 73221 b: refs/heads/dist-snap c: db453ec h: refs/heads/master i: 73219: 4d88a2b v: v3
1 parent c798a60 commit 5bca289

File tree

3 files changed

+148
-119
lines changed

3 files changed

+148
-119
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ refs/tags/release-0.1: 1f5c5126e96c79d22cb7862f75304136e204f105
77
refs/heads/ndm: f3868061cd7988080c30d6d5bf352a5a5fe2460b
88
refs/heads/try2: 147ecfdd8221e4a4d4e090486829a06da1e0ca3c
99
refs/heads/incoming: b50030718cf28f2a5a81857a26b57442734fe854
10-
refs/heads/dist-snap: ee4d11f37ea3f1bff8103c0e6b369a972f4b1bf2
10+
refs/heads/dist-snap: db453ec0e507382b4ac1bb9eae4654957b8a7e76
1111
refs/tags/release-0.2: c870d2dffb391e14efb05aa27898f1f6333a9596
1212
refs/tags/release-0.3: b5f0d0f648d9a6153664837026ba1be43d3e2503
1313
refs/heads/try3: 9387340aab40a73e8424c48fd42f0c521a4875c0

branches/dist-snap/src/libcore/prelude.rs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,8 +52,12 @@ pub use from_str::{FromStr};
5252
pub use to_bytes::IterBytes;
5353
pub use to_str::{ToStr, ToStrConsume};
5454
pub use tuple::{CopyableTuple, ImmutableTuple, ExtendedTupleOps};
55-
pub use tuple::{Tuple2, Tuple3, Tuple4, Tuple5, Tuple6, Tuple7, Tuple8, Tuple9};
56-
pub use tuple::{Tuple10, Tuple11, Tuple12};
55+
pub use tuple::{CloneableTuple2, CloneableTuple3, CloneableTuple4, CloneableTuple5};
56+
pub use tuple::{CloneableTuple6, CloneableTuple7, CloneableTuple8, CloneableTuple9};
57+
pub use tuple::{CloneableTuple10, CloneableTuple11, CloneableTuple12};
58+
pub use tuple::{ImmutableTuple2, ImmutableTuple3, ImmutableTuple4, ImmutableTuple5};
59+
pub use tuple::{ImmutableTuple6, ImmutableTuple7, ImmutableTuple8, ImmutableTuple9};
60+
pub use tuple::{ImmutableTuple10, ImmutableTuple11, ImmutableTuple12};
5761
pub use vec::{CopyableVector, ImmutableVector};
5862
pub use vec::{ImmutableEqVector, ImmutableCopyableVector};
5963
pub use vec::{OwnedVector, OwnedCopyableVector, MutableVector};

branches/dist-snap/src/libcore/tuple.rs

Lines changed: 141 additions & 116 deletions
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,6 @@ impl<'self,A:Copy,B:Copy> ExtendedTupleOps<A,B> for (&'self [A], &'self [B]) {
9393
}
9494

9595
impl<A:Copy,B:Copy> ExtendedTupleOps<A,B> for (~[A], ~[B]) {
96-
9796
#[inline(always)]
9897
fn zip(&self) -> ~[(A, B)] {
9998
match *self {
@@ -117,41 +116,54 @@ impl<A:Copy,B:Copy> ExtendedTupleOps<A,B> for (~[A], ~[B]) {
117116

118117
macro_rules! tuple_impls(
119118
($(
120-
$name:ident {
121-
$(fn $get_fn:ident -> $T:ident { $get_pattern:pat => $ret:expr })+
119+
($cloneable_trait:ident, $immutable_trait:ident) {
120+
$(($get_fn:ident, $get_ref_fn:ident) -> $T:ident {
121+
$get_pattern:pat => $ret:expr
122+
})+
122123
}
123124
)+) => (
124125
pub mod inner {
125126
use clone::Clone;
126127
#[cfg(not(test))] use cmp::{Eq, Ord};
127128

128129
$(
129-
pub trait $name<$($T),+> {
130-
$(fn $get_fn<'a>(&'a self) -> &'a $T;)+
130+
pub trait $cloneable_trait<$($T),+> {
131+
$(fn $get_fn(&self) -> $T;)+
132+
}
133+
134+
impl<$($T:Clone),+> $cloneable_trait<$($T),+> for ($($T),+) {
135+
$(
136+
#[inline(always)]
137+
fn $get_fn(&self) -> $T {
138+
self.$get_ref_fn().clone()
139+
}
140+
)+
141+
}
142+
143+
pub trait $immutable_trait<$($T),+> {
144+
$(fn $get_ref_fn<'a>(&'a self) -> &'a $T;)+
131145
}
132146

133-
impl<$($T),+> $name<$($T),+> for ($($T),+) {
147+
impl<$($T),+> $immutable_trait<$($T),+> for ($($T),+) {
134148
$(
135149
#[inline(always)]
136-
fn $get_fn<'a>(&'a self) -> &'a $T {
137-
match *self {
138-
$get_pattern => $ret
139-
}
150+
fn $get_ref_fn<'a>(&'a self) -> &'a $T {
151+
match *self { $get_pattern => $ret }
140152
}
141153
)+
142154
}
143155

144156
impl<$($T:Clone),+> Clone for ($($T),+) {
145157
fn clone(&self) -> ($($T),+) {
146-
($(self.$get_fn().clone()),+)
158+
($(self.$get_ref_fn().clone()),+)
147159
}
148160
}
149161

150162
#[cfg(not(test))]
151163
impl<$($T:Eq),+> Eq for ($($T),+) {
152164
#[inline(always)]
153165
fn eq(&self, other: &($($T),+)) -> bool {
154-
$(*self.$get_fn() == *other.$get_fn())&&+
166+
$(*self.$get_ref_fn() == *other.$get_ref_fn())&&+
155167
}
156168

157169
#[inline(always)]
@@ -164,22 +176,22 @@ macro_rules! tuple_impls(
164176
impl<$($T:Ord),+> Ord for ($($T),+) {
165177
#[inline(always)]
166178
fn lt(&self, other: &($($T),+)) -> bool {
167-
$(*self.$get_fn() < *other.$get_fn())&&+
179+
$(*self.$get_ref_fn() < *other.$get_ref_fn())&&+
168180
}
169181

170182
#[inline(always)]
171183
fn le(&self, other: &($($T),+)) -> bool {
172-
$(*self.$get_fn() <= *other.$get_fn())&&+
184+
$(*self.$get_ref_fn() <= *other.$get_ref_fn())&&+
173185
}
174186

175187
#[inline(always)]
176188
fn ge(&self, other: &($($T),+)) -> bool {
177-
$(*self.$get_fn() >= *other.$get_fn())&&+
189+
$(*self.$get_ref_fn() >= *other.$get_ref_fn())&&+
178190
}
179191

180192
#[inline(always)]
181193
fn gt(&self, other: &($($T),+)) -> bool {
182-
$(*self.$get_fn() > *other.$get_fn())&&+
194+
$(*self.$get_ref_fn() > *other.$get_ref_fn())&&+
183195
}
184196
}
185197
)+
@@ -188,114 +200,114 @@ macro_rules! tuple_impls(
188200
)
189201

190202
tuple_impls!(
191-
Tuple2 {
192-
fn n0 -> A { (ref a,_) => a }
193-
fn n1 -> B { (_,ref b) => b }
203+
(CloneableTuple2, ImmutableTuple2) {
204+
(n0, n0_ref) -> A { (ref a,_) => a }
205+
(n1, n1_ref) -> B { (_,ref b) => b }
194206
}
195207

196-
Tuple3 {
197-
fn n0 -> A { (ref a,_,_) => a }
198-
fn n1 -> B { (_,ref b,_) => b }
199-
fn n2 -> C { (_,_,ref c) => c }
208+
(CloneableTuple3, ImmutableTuple3) {
209+
(n0, n0_ref) -> A { (ref a,_,_) => a }
210+
(n1, n1_ref) -> B { (_,ref b,_) => b }
211+
(n2, n2_ref) -> C { (_,_,ref c) => c }
200212
}
201213

202-
Tuple4 {
203-
fn n0 -> A { (ref a,_,_,_) => a }
204-
fn n1 -> B { (_,ref b,_,_) => b }
205-
fn n2 -> C { (_,_,ref c,_) => c }
206-
fn n3 -> D { (_,_,_,ref d) => d }
214+
(CloneableTuple4, ImmutableTuple4) {
215+
(n0, n0_ref) -> A { (ref a,_,_,_) => a }
216+
(n1, n1_ref) -> B { (_,ref b,_,_) => b }
217+
(n2, n2_ref) -> C { (_,_,ref c,_) => c }
218+
(n3, n3_ref) -> D { (_,_,_,ref d) => d }
207219
}
208220

209-
Tuple5 {
210-
fn n0 -> A { (ref a,_,_,_,_) => a }
211-
fn n1 -> B { (_,ref b,_,_,_) => b }
212-
fn n2 -> C { (_,_,ref c,_,_) => c }
213-
fn n3 -> D { (_,_,_,ref d,_) => d }
214-
fn n4 -> E { (_,_,_,_,ref e) => e }
221+
(CloneableTuple5, ImmutableTuple5) {
222+
(n0, n0_ref) -> A { (ref a,_,_,_,_) => a }
223+
(n1, n1_ref) -> B { (_,ref b,_,_,_) => b }
224+
(n2, n2_ref) -> C { (_,_,ref c,_,_) => c }
225+
(n3, n3_ref) -> D { (_,_,_,ref d,_) => d }
226+
(n4, n4_ref) -> E { (_,_,_,_,ref e) => e }
215227
}
216228

217-
Tuple6 {
218-
fn n0 -> A { (ref a,_,_,_,_,_) => a }
219-
fn n1 -> B { (_,ref b,_,_,_,_) => b }
220-
fn n2 -> C { (_,_,ref c,_,_,_) => c }
221-
fn n3 -> D { (_,_,_,ref d,_,_) => d }
222-
fn n4 -> E { (_,_,_,_,ref e,_) => e }
223-
fn n5 -> F { (_,_,_,_,_,ref f) => f }
229+
(CloneableTuple6, ImmutableTuple6) {
230+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_) => a }
231+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_) => b }
232+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_) => c }
233+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_) => d }
234+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_) => e }
235+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f) => f }
224236
}
225237

226-
Tuple7 {
227-
fn n0 -> A { (ref a,_,_,_,_,_,_) => a }
228-
fn n1 -> B { (_,ref b,_,_,_,_,_) => b }
229-
fn n2 -> C { (_,_,ref c,_,_,_,_) => c }
230-
fn n3 -> D { (_,_,_,ref d,_,_,_) => d }
231-
fn n4 -> E { (_,_,_,_,ref e,_,_) => e }
232-
fn n5 -> F { (_,_,_,_,_,ref f,_) => f }
233-
fn n6 -> G { (_,_,_,_,_,_,ref g) => g }
238+
(CloneableTuple7, ImmutableTuple7) {
239+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_,_) => a }
240+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_,_) => b }
241+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_,_) => c }
242+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_,_) => d }
243+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_,_) => e }
244+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f,_) => f }
245+
(n6, n6_ref) -> G { (_,_,_,_,_,_,ref g) => g }
234246
}
235247

236-
Tuple8 {
237-
fn n0 -> A { (ref a,_,_,_,_,_,_,_) => a }
238-
fn n1 -> B { (_,ref b,_,_,_,_,_,_) => b }
239-
fn n2 -> C { (_,_,ref c,_,_,_,_,_) => c }
240-
fn n3 -> D { (_,_,_,ref d,_,_,_,_) => d }
241-
fn n4 -> E { (_,_,_,_,ref e,_,_,_) => e }
242-
fn n5 -> F { (_,_,_,_,_,ref f,_,_) => f }
243-
fn n6 -> G { (_,_,_,_,_,_,ref g,_) => g }
244-
fn n7 -> H { (_,_,_,_,_,_,_,ref h) => h }
248+
(CloneableTuple8, ImmutableTuple8) {
249+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_,_,_) => a }
250+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_,_,_) => b }
251+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_,_,_) => c }
252+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_,_,_) => d }
253+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_,_,_) => e }
254+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f,_,_) => f }
255+
(n6, n6_ref) -> G { (_,_,_,_,_,_,ref g,_) => g }
256+
(n7, n7_ref) -> H { (_,_,_,_,_,_,_,ref h) => h }
245257
}
246258

247-
Tuple9 {
248-
fn n0 -> A { (ref a,_,_,_,_,_,_,_,_) => a }
249-
fn n1 -> B { (_,ref b,_,_,_,_,_,_,_) => b }
250-
fn n2 -> C { (_,_,ref c,_,_,_,_,_,_) => c }
251-
fn n3 -> D { (_,_,_,ref d,_,_,_,_,_) => d }
252-
fn n4 -> E { (_,_,_,_,ref e,_,_,_,_) => e }
253-
fn n5 -> F { (_,_,_,_,_,ref f,_,_,_) => f }
254-
fn n6 -> G { (_,_,_,_,_,_,ref g,_,_) => g }
255-
fn n7 -> H { (_,_,_,_,_,_,_,ref h,_) => h }
256-
fn n8 -> I { (_,_,_,_,_,_,_,_,ref i) => i }
259+
(CloneableTuple9, ImmutableTuple9) {
260+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_,_,_,_) => a }
261+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_,_,_,_) => b }
262+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_,_,_,_) => c }
263+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_,_,_,_) => d }
264+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_,_,_,_) => e }
265+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f,_,_,_) => f }
266+
(n6, n6_ref) -> G { (_,_,_,_,_,_,ref g,_,_) => g }
267+
(n7, n7_ref) -> H { (_,_,_,_,_,_,_,ref h,_) => h }
268+
(n8, n8_ref) -> I { (_,_,_,_,_,_,_,_,ref i) => i }
257269
}
258270

259-
Tuple10 {
260-
fn n0 -> A { (ref a,_,_,_,_,_,_,_,_,_) => a }
261-
fn n1 -> B { (_,ref b,_,_,_,_,_,_,_,_) => b }
262-
fn n2 -> C { (_,_,ref c,_,_,_,_,_,_,_) => c }
263-
fn n3 -> D { (_,_,_,ref d,_,_,_,_,_,_) => d }
264-
fn n4 -> E { (_,_,_,_,ref e,_,_,_,_,_) => e }
265-
fn n5 -> F { (_,_,_,_,_,ref f,_,_,_,_) => f }
266-
fn n6 -> G { (_,_,_,_,_,_,ref g,_,_,_) => g }
267-
fn n7 -> H { (_,_,_,_,_,_,_,ref h,_,_) => h }
268-
fn n8 -> I { (_,_,_,_,_,_,_,_,ref i,_) => i }
269-
fn n9 -> J { (_,_,_,_,_,_,_,_,_,ref j) => j }
271+
(CloneableTuple10, ImmutableTuple10) {
272+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_,_,_,_,_) => a }
273+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_,_,_,_,_) => b }
274+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_,_,_,_,_) => c }
275+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_,_,_,_,_) => d }
276+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_,_,_,_,_) => e }
277+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f,_,_,_,_) => f }
278+
(n6, n6_ref) -> G { (_,_,_,_,_,_,ref g,_,_,_) => g }
279+
(n7, n7_ref) -> H { (_,_,_,_,_,_,_,ref h,_,_) => h }
280+
(n8, n8_ref) -> I { (_,_,_,_,_,_,_,_,ref i,_) => i }
281+
(n9, n9_ref) -> J { (_,_,_,_,_,_,_,_,_,ref j) => j }
270282
}
271283

272-
Tuple11 {
273-
fn n0 -> A { (ref a,_,_,_,_,_,_,_,_,_,_) => a }
274-
fn n1 -> B { (_,ref b,_,_,_,_,_,_,_,_,_) => b }
275-
fn n2 -> C { (_,_,ref c,_,_,_,_,_,_,_,_) => c }
276-
fn n3 -> D { (_,_,_,ref d,_,_,_,_,_,_,_) => d }
277-
fn n4 -> E { (_,_,_,_,ref e,_,_,_,_,_,_) => e }
278-
fn n5 -> F { (_,_,_,_,_,ref f,_,_,_,_,_) => f }
279-
fn n6 -> G { (_,_,_,_,_,_,ref g,_,_,_,_) => g }
280-
fn n7 -> H { (_,_,_,_,_,_,_,ref h,_,_,_) => h }
281-
fn n8 -> I { (_,_,_,_,_,_,_,_,ref i,_,_) => i }
282-
fn n9 -> J { (_,_,_,_,_,_,_,_,_,ref j,_) => j }
283-
fn n10 -> K { (_,_,_,_,_,_,_,_,_,_,ref k) => k }
284+
(CloneableTuple11, ImmutableTuple11) {
285+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_,_,_,_,_,_) => a }
286+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_,_,_,_,_,_) => b }
287+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_,_,_,_,_,_) => c }
288+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_,_,_,_,_,_) => d }
289+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_,_,_,_,_,_) => e }
290+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f,_,_,_,_,_) => f }
291+
(n6, n6_ref) -> G { (_,_,_,_,_,_,ref g,_,_,_,_) => g }
292+
(n7, n7_ref) -> H { (_,_,_,_,_,_,_,ref h,_,_,_) => h }
293+
(n8, n8_ref) -> I { (_,_,_,_,_,_,_,_,ref i,_,_) => i }
294+
(n9, n9_ref) -> J { (_,_,_,_,_,_,_,_,_,ref j,_) => j }
295+
(n10, n10_ref) -> K { (_,_,_,_,_,_,_,_,_,_,ref k) => k }
284296
}
285297

286-
Tuple12 {
287-
fn n0 -> A { (ref a,_,_,_,_,_,_,_,_,_,_,_) => a }
288-
fn n1 -> B { (_,ref b,_,_,_,_,_,_,_,_,_,_) => b }
289-
fn n2 -> C { (_,_,ref c,_,_,_,_,_,_,_,_,_) => c }
290-
fn n3 -> D { (_,_,_,ref d,_,_,_,_,_,_,_,_) => d }
291-
fn n4 -> E { (_,_,_,_,ref e,_,_,_,_,_,_,_) => e }
292-
fn n5 -> F { (_,_,_,_,_,ref f,_,_,_,_,_,_) => f }
293-
fn n6 -> G { (_,_,_,_,_,_,ref g,_,_,_,_,_) => g }
294-
fn n7 -> H { (_,_,_,_,_,_,_,ref h,_,_,_,_) => h }
295-
fn n8 -> I { (_,_,_,_,_,_,_,_,ref i,_,_,_) => i }
296-
fn n9 -> J { (_,_,_,_,_,_,_,_,_,ref j,_,_) => j }
297-
fn n10 -> K { (_,_,_,_,_,_,_,_,_,_,ref k,_) => k }
298-
fn n11 -> L { (_,_,_,_,_,_,_,_,_,_,_,ref l) => l }
298+
(CloneableTuple12, ImmutableTuple12) {
299+
(n0, n0_ref) -> A { (ref a,_,_,_,_,_,_,_,_,_,_,_) => a }
300+
(n1, n1_ref) -> B { (_,ref b,_,_,_,_,_,_,_,_,_,_) => b }
301+
(n2, n2_ref) -> C { (_,_,ref c,_,_,_,_,_,_,_,_,_) => c }
302+
(n3, n3_ref) -> D { (_,_,_,ref d,_,_,_,_,_,_,_,_) => d }
303+
(n4, n4_ref) -> E { (_,_,_,_,ref e,_,_,_,_,_,_,_) => e }
304+
(n5, n5_ref) -> F { (_,_,_,_,_,ref f,_,_,_,_,_,_) => f }
305+
(n6, n6_ref) -> G { (_,_,_,_,_,_,ref g,_,_,_,_,_) => g }
306+
(n7, n7_ref) -> H { (_,_,_,_,_,_,_,ref h,_,_,_,_) => h }
307+
(n8, n8_ref) -> I { (_,_,_,_,_,_,_,_,ref i,_,_,_) => i }
308+
(n9, n9_ref) -> J { (_,_,_,_,_,_,_,_,_,ref j,_,_) => j }
309+
(n10, n10_ref) -> K { (_,_,_,_,_,_,_,_,_,_,ref k,_) => k }
310+
(n11, n11_ref) -> L { (_,_,_,_,_,_,_,_,_,_,_,ref l) => l }
299311
}
300312
)
301313

@@ -325,16 +337,29 @@ fn test_clone() {
325337
#[test]
326338
fn test_n_tuple() {
327339
let t = (0u8, 1u16, 2u32, 3u64, 4u, 5i8, 6i16, 7i32, 8i64, 9i, 10f32, 11f64);
328-
assert_eq!(*t.n0(), 0u8);
329-
assert_eq!(*t.n1(), 1u16);
330-
assert_eq!(*t.n2(), 2u32);
331-
assert_eq!(*t.n3(), 3u64);
332-
assert_eq!(*t.n4(), 4u);
333-
assert_eq!(*t.n5(), 5i8);
334-
assert_eq!(*t.n6(), 6i16);
335-
assert_eq!(*t.n7(), 7i32);
336-
assert_eq!(*t.n8(), 8i64);
337-
assert_eq!(*t.n9(), 9i);
338-
assert_eq!(*t.n10(), 10f32);
339-
assert_eq!(*t.n11(), 11f64);
340+
assert_eq!(t.n0(), 0u8);
341+
assert_eq!(t.n1(), 1u16);
342+
assert_eq!(t.n2(), 2u32);
343+
assert_eq!(t.n3(), 3u64);
344+
assert_eq!(t.n4(), 4u);
345+
assert_eq!(t.n5(), 5i8);
346+
assert_eq!(t.n6(), 6i16);
347+
assert_eq!(t.n7(), 7i32);
348+
assert_eq!(t.n8(), 8i64);
349+
assert_eq!(t.n9(), 9i);
350+
assert_eq!(t.n10(), 10f32);
351+
assert_eq!(t.n11(), 11f64);
352+
353+
assert_eq!(t.n0_ref(), &0u8);
354+
assert_eq!(t.n1_ref(), &1u16);
355+
assert_eq!(t.n2_ref(), &2u32);
356+
assert_eq!(t.n3_ref(), &3u64);
357+
assert_eq!(t.n4_ref(), &4u);
358+
assert_eq!(t.n5_ref(), &5i8);
359+
assert_eq!(t.n6_ref(), &6i16);
360+
assert_eq!(t.n7_ref(), &7i32);
361+
assert_eq!(t.n8_ref(), &8i64);
362+
assert_eq!(t.n9_ref(), &9i);
363+
assert_eq!(t.n10_ref(), &10f32);
364+
assert_eq!(t.n11_ref(), &11f64);
340365
}

0 commit comments

Comments
 (0)