Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Readability when dropping arguments #4

Open
cortner opened this issue Jun 3, 2024 · 0 comments
Open

Readability when dropping arguments #4

cortner opened this issue Jun 3, 2024 · 0 comments

Comments

@cortner
Copy link
Member

cortner commented Jun 3, 2024

WithAlloc leads to code that looks like this:

A, B = @withalloc myfunction!(x1, x2, x3)

which stands for

A = @alloc( ... )
B = @alloc( ... )
myfunction!(A, B, x1, x2, x3)

To make it clear that the two allocated hidden arguments are in there hidden, one could do something like

A, B = @withalloc myfunction!(_, _, x1, x2, x3)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant