Skip to content

Commit 13fc0d8

Browse files
committed
This statement is misleading
1 parent 69408a8 commit 13fc0d8

File tree

2 files changed

+9
-11
lines changed

2 files changed

+9
-11
lines changed

library/core/src/mem/mod.rs

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -898,8 +898,6 @@ pub const fn replace<T>(dest: &mut T, src: T) -> T {
898898

899899
/// Disposes of a value.
900900
///
901-
/// This does so by calling the argument's implementation of [`Drop`][drop].
902-
///
903901
/// This effectively does nothing for types which implement `Copy`, e.g.
904902
/// integers. Such values are copied and _then_ moved into the function, so the
905903
/// value persists after this function call.

tests/ui/thir-print/offset_of.stdout

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,7 @@ body:
6868
)
6969
else_block: None
7070
lint_level: Explicit(HirId(DefId(offset_of::concrete).10))
71-
span: $DIR/offset_of.rs:37:5: 1435:57 (#0)
71+
span: $DIR/offset_of.rs:37:5: 1433:57 (#0)
7272
}
7373
}
7474
Stmt {
@@ -117,7 +117,7 @@ body:
117117
)
118118
else_block: None
119119
lint_level: Explicit(HirId(DefId(offset_of::concrete).20))
120-
span: $DIR/offset_of.rs:38:5: 1435:57 (#0)
120+
span: $DIR/offset_of.rs:38:5: 1433:57 (#0)
121121
}
122122
}
123123
Stmt {
@@ -166,7 +166,7 @@ body:
166166
)
167167
else_block: None
168168
lint_level: Explicit(HirId(DefId(offset_of::concrete).30))
169-
span: $DIR/offset_of.rs:39:5: 1435:57 (#0)
169+
span: $DIR/offset_of.rs:39:5: 1433:57 (#0)
170170
}
171171
}
172172
Stmt {
@@ -215,7 +215,7 @@ body:
215215
)
216216
else_block: None
217217
lint_level: Explicit(HirId(DefId(offset_of::concrete).40))
218-
span: $DIR/offset_of.rs:40:5: 1435:57 (#0)
218+
span: $DIR/offset_of.rs:40:5: 1433:57 (#0)
219219
}
220220
}
221221
Stmt {
@@ -264,7 +264,7 @@ body:
264264
)
265265
else_block: None
266266
lint_level: Explicit(HirId(DefId(offset_of::concrete).50))
267-
span: $DIR/offset_of.rs:41:5: 1435:57 (#0)
267+
span: $DIR/offset_of.rs:41:5: 1433:57 (#0)
268268
}
269269
}
270270
]
@@ -864,7 +864,7 @@ body:
864864
)
865865
else_block: None
866866
lint_level: Explicit(HirId(DefId(offset_of::generic).12))
867-
span: $DIR/offset_of.rs:45:5: 1435:57 (#0)
867+
span: $DIR/offset_of.rs:45:5: 1433:57 (#0)
868868
}
869869
}
870870
Stmt {
@@ -913,7 +913,7 @@ body:
913913
)
914914
else_block: None
915915
lint_level: Explicit(HirId(DefId(offset_of::generic).24))
916-
span: $DIR/offset_of.rs:46:5: 1435:57 (#0)
916+
span: $DIR/offset_of.rs:46:5: 1433:57 (#0)
917917
}
918918
}
919919
Stmt {
@@ -962,7 +962,7 @@ body:
962962
)
963963
else_block: None
964964
lint_level: Explicit(HirId(DefId(offset_of::generic).36))
965-
span: $DIR/offset_of.rs:47:5: 1435:57 (#0)
965+
span: $DIR/offset_of.rs:47:5: 1433:57 (#0)
966966
}
967967
}
968968
Stmt {
@@ -1011,7 +1011,7 @@ body:
10111011
)
10121012
else_block: None
10131013
lint_level: Explicit(HirId(DefId(offset_of::generic).48))
1014-
span: $DIR/offset_of.rs:48:5: 1435:57 (#0)
1014+
span: $DIR/offset_of.rs:48:5: 1433:57 (#0)
10151015
}
10161016
}
10171017
]

0 commit comments

Comments
 (0)