Closed Bug 1535798 Opened 7 years ago Closed 7 years ago

[Automated review] clang-format bot suggests edits to parts of the file that were not changed and a hunk that doesn't apply

Categories

(Developer Infrastructure :: Source Code Analysis, defect, P1)

Tracking

(Not tracked)

RESOLVED INVALID

People

(Reporter: ehsan.akhgari, Assigned: andi)

Details

Phabricator URL: https://phabricator.services.mozilla.com/D23616

Here is the diff: https://taskcluster-public-blobs.s3.amazonaws.com/AZzXMEz0T7CWPUL1nwPiug/0/public/patch/clang-format-PHID-DIFF-orqfiytxg4wojujaexia.diff

The HttpBaseChannel.cpp changes are parts of the file this patch did not change. And I don't understand the InputStreamLengthHelper.h change... As far as I can tell the existing code in the patch is correctly formatted and in fact that hunk should not even apply!

Andi, as the log are still available: could you please have a look quickly? (it can wait until next Monday) Thanks

Severity: normal → major
Flags: needinfo?(bpostelnicu)
Priority: -- → P1

Ehsan thank you for reporting this issue, for the moment our bot doesn't support a per-hunk filtering when it comes to clang-format that's why we don't even post in-line comments like we do for example with coverity and clang-tidy, right now we only do a per-file format and we post a diff.

When it comes to InputStreamLengthHelper.h, clang-format modified the last line of the patch by deleting one space and adding two spaces for the comment of #endif, do you think this is something wrong? Do you think we should keep only once space?

Assignee: nobody → bpostelnicu
Flags: needinfo?(bpostelnicu) → needinfo?(ehsan)

Hi Andi,

Sorry for my delay here.

About InputStreamLengthHelper.h, I think you are right, and I must have been confused before. I can't even remember what I was thinking at the time I filed the bug but looking at things again indeed clang-format was just doing its job, so perhaps my brain failed me there for a moment. :-) Please ignore that part of my comment.

Flags: needinfo?(ehsan)

Ehsan are you OK closing this bug?

Flags: needinfo?(ehsan)

Sure.

Status: NEW → RESOLVED
Closed: 7 years ago
Flags: needinfo?(ehsan)
Resolution: --- → INVALID
Product: Firefox Build System → Developer Infrastructure
You need to log in before you can comment on or make changes to this bug.