this post was submitted on 28 Jan 2025
10 points (100.0% liked)

Rust

6383 readers
136 users here now

Welcome to the Rust community! This is a place to discuss about the Rust programming language.

Wormhole

!performance@programming.dev

Credits

  • The icon is a modified version of the official rust logo (changing the colors to a gradient and black background)

founded 2 years ago
MODERATORS
 

Inspired by Contex-Generic Programming, I made this macro, that allows you to write those generic implementations easily. This is kinda CGP, but simple and with better errors.

Ever repeat yourself implementing traits? Or wanted to easily swap out parts of your code, with (almost) no need to refactor? That is what this is for.

top 1 comments
sorted by: hot top controversial new old
[–] Aras@feddit.org 2 points 3 weeks ago

For a deeper showcase (the complete cgp example adapted): https://github.com/Aras14HD/abstract_impl_showcase