this post was submitted on 24 Sep 2026
48 points (100.0% liked)

Rust

8304 readers
40 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 3 years ago
MODERATORS
 

See also the discussion for Klabnik's Arguing about arguments

you are viewing a single comment's thread
view the rest of the comments
[โ€“] FizzyOrange@programming.dev 11 points 1 week ago* (last edited 1 week ago) (1 children)

I agree - Structs are kind of a nicer solution here. Especially because it's pretty common to pass a whole set of options through the call stack.

In Python land you end up with functions with 30 arguments and when they want to pass them anywhere they give up and use kwargs which are completely awful and should almost never be used.

[โ€“] TehPers@beehaw.org 5 points 1 week ago

In Python land you end up with functions with 30 arguments and when they want to pass them anywhere they give up and use kwargs which are completely awful and should almost never be used.

Unpack[T] exists, but nobody uses it sadly. Also, it's probably better to just use a dataclass or something instead anyway, but nobody does.