This is an archive of the discontinued LLVM Phabricator instance.

[Format] Fix incorrect pointer detection
ClosedPublic

Authored by Nuullll on Jun 2 2021, 10:12 PM.

Details

Summary

https://llvm.org/PR50429

Before:

void f() { f(float(1), a *a); }

After:

void f() { f(float(1), a * a); }

Signed-off-by: Yilong Guo <yilong.guo@intel.com>

Diff Detail

Event Timeline

Nuullll requested review of this revision.Jun 2 2021, 10:12 PM
Nuullll created this revision.
Herald added a project: Restricted Project. · View Herald TranscriptJun 2 2021, 10:12 PM
Herald added a subscriber: cfe-commits. · View Herald Transcript
curdeius requested changes to this revision.Jun 2 2021, 10:29 PM
curdeius added a subscriber: curdeius.

Thanks for looking into this, but please add a test case that demonstrates the bug to FormatTests.cpp
Also, is there, by any chance, an associated bugzilla ticket?

This revision now requires changes to proceed.Jun 2 2021, 10:31 PM
Nuullll updated this revision to Diff 349455.Jun 2 2021, 10:36 PM
Nuullll edited the summary of this revision. (Show Details)

Add test.

Thanks for looking into this, but please add a test case that demonstrates the bug to FormatTests.cpp
Also, is there, by any chance, an associated bugzilla ticket?

Thanks for the comment.
I've added a test and linked to the bugzilla ticket in summary.

Seems reasonable. :)

curdeius edited the summary of this revision. (Show Details)Jun 3 2021, 5:03 AM
curdeius accepted this revision.Jun 3 2021, 5:13 AM

LGTM. Thanks for fixing this!
Do you have commit rights or you need somebody to land it for you?

This revision is now accepted and ready to land.Jun 3 2021, 5:13 AM

LGTM. Thanks for fixing this!
Do you have commit rights or you need somebody to land it for you?

I don't have commit access. I'd appreciate it if you or someone else could land this patch for me :)

This revision was automatically updated to reflect the committed changes.