This is an archive of the discontinued LLVM Phabricator instance.

[LLDB][NFC] Fix the style issue in TCPSocket
ClosedPublic

Authored by fixathon on Aug 9 2022, 11:19 PM.

Details

Diff Detail

Event Timeline

fixathon created this revision.Aug 9 2022, 11:19 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 9 2022, 11:19 PM
fixathon requested review of this revision.Aug 9 2022, 11:19 PM
Herald added a project: Restricted Project. · View Herald TranscriptAug 9 2022, 11:19 PM

Did you also want to adjust the if (-1 == SetOptionNoDelay()) { line from that patch?

I'd prefer to not reformat the pre-existing 13 instances of (-1 ==)

Ah, I think ChrisB added these -1 == lines in TCPSocket.cpp when he was adding ipv6 support years ago. I was only thinking of the two new ones you added in https://reviews.llvm.org/D131294

"LLDB’s code style differs from LLVM’s coding style. Unfortunately there is no document describing the differences. Please be consistent with the existing code."

Well I don't remember seeing any Yoda conditions elsewhere so LGTM.

clayborg requested changes to this revision.Aug 11 2022, 11:22 AM

if we are going to fix the coding conventions we should do it for all of the locations if possible. All of them should be super simple.

This revision now requires changes to proceed.Aug 11 2022, 11:22 AM
fixathon updated this revision to Diff 451952.Aug 11 2022, 12:37 PM

Fix the style in the entire file.

clayborg accepted this revision.Aug 11 2022, 5:33 PM
This revision is now accepted and ready to land.Aug 11 2022, 5:33 PM
This revision was automatically updated to reflect the committed changes.