Skip to content

Commit 3944cea

Browse files
committed
Update GitHub actions (#352)
* Update GitHub actions * Downgrade rust-toolchain to the latest stable version (1.74.0) from 1.80.0 * Fix issues with latest clippy * Fix rustdoc check issue * Update Rust toolchain in Dockerfile
1 parent 0570fc0 commit 3944cea

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

rosidl_runtime_rs/src/string.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -250,7 +250,7 @@ macro_rules! string_impl {
250250

251251
impl PartialOrd for $string {
252252
fn partial_cmp(&self, other: &Self) -> Option<Ordering> {
253-
self.deref().partial_cmp(other.deref())
253+
Some(self.cmp(other))
254254
}
255255
}
256256

rosidl_runtime_rs/src/string/serde.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ impl Serialize for WString {
125125
{
126126
// Not particularly efficient
127127
// SAFETY: See the Display implementation.
128-
let u16_slice = unsafe { std::slice::from_raw_parts(self.data as *mut u16, self.size) };
128+
let u16_slice = unsafe { std::slice::from_raw_parts(self.data, self.size) };
129129
let s = std::string::String::from_utf16_lossy(u16_slice);
130130
serializer.serialize_str(&s)
131131
}

0 commit comments

Comments
 (0)