File tree Expand file tree Collapse file tree 4 files changed +16
-0
lines changed Expand file tree Collapse file tree 4 files changed +16
-0
lines changed Original file line number Diff line number Diff line change 6363 - name : Cargo build
6464 run : cargo build --workspace --features bundled
6565
66+ - name : Cargo clippy
67+ run : cargo clippy --workspace --features bundled -- -D warnings
68+
6669 - name : Cargo test
6770 run : cargo test --workspace --features bundled
6871 env :
Original file line number Diff line number Diff line change @@ -87,6 +87,10 @@ impl<'a> Blob<'a> {
8787 }
8888
8989 /// Construct a `Blob` from a raw pointer. Takes ownership of the blob.
90+ ///
91+ /// # Safety
92+ ///
93+ /// The pointer must be valid and must not be used after this function is called.
9094 pub unsafe fn from_raw ( raw : * mut sys:: hb_blob_t ) -> Self {
9195 Blob {
9296 raw,
Original file line number Diff line number Diff line change @@ -83,6 +83,10 @@ impl Buffer {
8383 }
8484
8585 /// Construct a `Buffer` from a raw pointer. Takes ownership of the buffer.
86+ ///
87+ /// # Safety
88+ ///
89+ /// The pointer must be valid and must not be used after this function is called.
8690 pub unsafe fn from_raw ( raw : * mut sys:: hb_buffer_t ) -> Self {
8791 Buffer { raw }
8892 }
Original file line number Diff line number Diff line change @@ -39,6 +39,11 @@ impl Language {
3939 . unwrap ( )
4040 }
4141
42+ /// Construct a `Language` from a raw pointer.
43+ ///
44+ /// # Safety
45+ ///
46+ /// The pointer must be a valid pointer.
4247 pub unsafe fn from_raw ( raw : sys:: hb_language_t ) -> Self {
4348 Language { raw }
4449 }
You can’t perform that action at this time.
0 commit comments