We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 694846f commit 951ac65Copy full SHA for 951ac65
tests/run-pass/vec.rs
@@ -148,6 +148,16 @@ fn swap_remove() {
148
vec.swap_remove(1);
149
}
150
151
+fn reverse() {
152
+ #[repr(align(2))]
153
+ #[derive(Debug)]
154
+ struct Foo(u8);
155
+
156
+ let mut v: Vec<_> = (0..50).map(Foo).collect();
157
+ v.reverse();
158
+ assert!(v[0].0 == 49);
159
+}
160
161
fn main() {
162
assert_eq!(vec_reallocate().len(), 5);
163
@@ -176,4 +186,5 @@ fn main() {
176
186
sort();
177
187
swap();
178
188
swap_remove();
189
+ reverse();
179
190
0 commit comments