[-] luminasapphira@beehaw.org 1 points 7 months ago

It's still pretty underbaked but you can check out my recent project based around a plugin system (dynamic loading). https://github.com/CerulanLumina/feed-plumber

It relies on the c abi and a whole lot of raw /ffi constructs but contains a helper crate to allow defining plugins in a somewhat rusty manner.

Hopefully it'll be of some use to you!

[-] luminasapphira@beehaw.org 4 points 10 months ago

I'm guessing you're asking because you got a clippy lint. Using Ordering allows you to match the output therefore only calling partial_ord once, compared to using an if-else chain which might call it several times. In many/most cases this would probably be compiler optimized anyway but this makes it explicit.

luminasapphira

joined 1 year ago