Skip to content

Commit 5b4d938

Browse files
committed
---
yaml --- r: 236545 b: refs/heads/tmp c: b30d896 h: refs/heads/master i: 236543: cbd7f6e v: v3
1 parent 60d5b49 commit 5b4d938

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

[refs]

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ refs/tags/0.11.0: e1247cb1d0d681be034adb4b558b5a0c0d5720f9
2525
refs/tags/0.12.0: f0c419429ef30723ceaf6b42f9b5a2aeb5d2e2d1
2626
refs/heads/beta: d2e13e822a73e0ea46ae9e21afdd3155fc997f6d
2727
refs/tags/1.0.0-alpha: e42bd6d93a1d3433c486200587f8f9e12590a4d7
28-
refs/heads/tmp: 85f48d300a1161338e14b9579007b003c48dc4ba
28+
refs/heads/tmp: b30d8969e86fa2c9dd3b8e2e28ddda2202331f0f
2929
refs/tags/1.0.0-alpha.2: 4c705f6bc559886632d3871b04f58aab093bfa2f
3030
refs/tags/homu-tmp: f859507de8c410b648d934d8f5ec1c52daac971d
3131
refs/tags/1.0.0-beta: 8cbb92b53468ee2b0c2d3eeb8567005953d40828

branches/tmp/src/libcore/array.rs

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,6 +35,15 @@ use slice::{Iter, IterMut, SliceExt};
3535
///
3636
/// This trait can be used to implement other traits on fixed-size arrays
3737
/// without causing much metadata bloat.
38+
///
39+
/// The trait is marked unsafe in order to restrict implementors to fixed-size
40+
/// arrays. User of this trait can assume that implementors have the exact
41+
/// layout in memory of a fixed size array (for example, for unsafe
42+
/// initialization).
43+
///
44+
/// Note that the traits AsRef and AsMut provide similar methods for types that
45+
/// may not be fixed-size arrays. Implementors should prefer those traits
46+
/// instead.
3847
pub unsafe trait FixedSizeArray<T> {
3948
/// Converts the array to immutable slice
4049
fn as_slice(&self) -> &[T];

0 commit comments

Comments
 (0)