dbus2 / zbus-old

Rust D-Bus crate.
https://gitlab.freedesktop.org/dbus/zbus
Other
49 stars 13 forks source link

Draft: zbus::Message to support non-native endian - [opened] #398

Open zeenix opened 2 years ago

zeenix commented 2 years ago

In GitLab by @Raytar on Feb 8, 2022, 17:45

Merges nonnative-endian -> main

This makes it possible to handle both little-endian and big-endian messages regardless of the native endianness.

There is probably a better/cleaner way to implement this, but I just needed a quick fix so that I can move on with my own project. I don't have much more time to work on this, so any help would be appreciated.

Fixes #252

zeenix commented 2 years ago

No deserialization needed here either.

zeenix commented 2 years ago

I never saw the point of local named functions. Especially here, it takes a Message as arg so definitely deserves to be a method of Message taking self arg.

zeenix commented 2 years ago

same here, should be a separate method/function.

zeenix commented 2 years ago

we don't need to deserialize this again here. The primary header is already available at this point.

zeenix commented 2 years ago

same here: let's have a separate method/function outside this method.

zeenix commented 2 years ago

There is probably a better/cleaner way to implement this, but I just needed a quick fix so that I can move on with my own project. I don't have much more time to work on this, so any help would be appreciated.

Thanks so much. Your approach isn't bad at all and probably I'll do the same. Just some cleanup needed (see comments).

zeenix commented 2 years ago

marked this merge request as draft

zeenix commented 2 years ago

@Raytar Hi, any chance you'll be able to address the comments soon? There isn't a lot of work remaining to finis this I think.

zeenix commented 2 years ago

In GitLab by @Raytar on Mar 28, 2022, 13:05

Hi, sorry for taking a long time to reply.

I am really busy these days because I'm working to complete my master's thesis due in May. However, if I find some time this week, I will try to address the commments.

zeenix commented 2 years ago

@Raytar any update? I hope you didn't forget about us. :smile: