#How to do named function arguments in Rust 🐱
9 messages · Page 1 of 1 (latest)
I think it's worth mentioning in the post that, when using the struct, you can use destructuring in the arguments to avoid the params.name, params.age situation
Great post though!
man why are named function args an actual thing in rust 😔
genuinely though, what is the reasoning behind not making them a thing?
their use in swift to both indicate arg purpose as well as sort of describing the function's funcationality is so sick
Yeah, true, I just wanted to keep the post short
It's a complex feature and the implementation is also complicated. This is what I know from this answer on stackoverflow