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

dereference operator needing space #96

Open
curiouskiwi opened this issue May 22, 2020 · 2 comments
Open

dereference operator needing space #96

curiouskiwi opened this issue May 22, 2020 · 2 comments

Comments

@curiouskiwi
Copy link
Collaborator

Here are 2 example lines:

int a = *(c + b + 3) + *(d + e + 3);

float b = (*(c + b + 3) + *(d + e + 3)) / 2.0;

style50 insists on a space between * and (d in the second one, which would be poor style.

style50deref

Might be confused by the parentheses? @crossroads1112

@cmlsharp
Copy link
Contributor

I can experiment, but if astyle doesn't have some flag to fix it, the only thing to do would be to file a bug there.

@Vivraan
Copy link

Vivraan commented Dec 8, 2020

This is also relevant for sizeof *buf kind of statements:

image

although I'd add parens just in case.

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

3 participants