You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@NobodyXu
I am checking out the codebase and have some basic understanding. The suggestion seems like a interesting addition of API. If were to implement the function signature you suggested, based on my understanding that would be an addition of something like
Could you give a concrete example of what would be an instance of function/closure as the argument of the type: f: impl FnOnce(&mut Self) to call the new API with?
I just started playing with the codebase and don't see what such instance would be like (presumably a block of code involving use of some of the existing APIs to do some business, but I just don't visualise how that might be the case)
This features exists in bossy::Command here: https://docs.rs/bossy/latest/bossy/struct.Command.html#method.with_args
It is quite useful, allowing you to write this:
... instead of this:
This saves using the
mut
keyword and a new line, and can even be implemented trivially using an extension traitThe text was updated successfully, but these errors were encountered: