Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

[master][clang-format] Add: break line entry before ternary operator #20705

Conversation

mozga-intel
Copy link
Contributor

Description

This pull-request solves a problem with ternary operators.
After:

    const char* sevstr = (severity == Severity::kINTERNAL_ERROR ? "    BUG" :
                          severity == Severity::kERROR          ? "  ERROR" :
                          severity == Severity::kWARNING        ? "WARNING" :
                          severity == Severity::kINFO           ? "   INFO" :
                                                                  "UNKNOWN");

Before

    const char* sevstr =
        (severity == Severity::kINTERNAL_ERROR ?
             "    BUG" :
             severity == Severity::kERROR ? "  ERROR" :
                                            severity == Severity::kWARNING ?
                                            "WARNING" :
                                            severity == Severity::kINFO ? "   INFO" : "UNKNOWN");
    (*_ostream) << "[" << buf << " " << sevstr << "] " << msg << std::endl;
  }

Checklist

Essentials

  • PR's title starts with a category (e.g. [BUGFIX], [MODEL], [TUTORIAL], [FEATURE], [DOC], etc)
  • Changes are complete (i.e. I finished coding on this PR)
  • All changes have test coverage
  • Code is well-documented

Changes

  • Feature1, tests, (and when applicable, API doc)
  • Feature2, tests, (and when applicable, API doc)

Comments

  • If this change is a backward incompatible change, why must this change be made.
  • Interesting edge cases to note here

@mxnet-bot
Copy link

Hey @mozga-intel , Thanks for submitting the PR
All tests are already queued to run once. If tests fail, you can trigger one or more tests again with the following commands:

  • To trigger all jobs: @mxnet-bot run ci [all]
  • To trigger specific jobs: @mxnet-bot run ci [job1, job2]

CI supported jobs: [centos-gpu, windows-cpu, edge, sanity, unix-cpu, centos-cpu, windows-gpu, miscellaneous, clang, website, unix-gpu]


Note:
Only following 3 categories can trigger CI :PR Author, MXNet Committer, Jenkins Admin.
All CI tests must pass before the PR can be merged.

@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress and removed pr-awaiting-testing PR is reviewed and waiting CI build and test labels Oct 26, 2021
@mozga-intel mozga-intel force-pushed the mozga-intel/clang_add_entry_break_before_tenary_operators branch from d3d3611 to ac4de97 Compare October 27, 2021 07:32
@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test and removed pr-work-in-progress PR is still work in progress labels Oct 27, 2021
@mseth10 mseth10 added pr-work-in-progress PR is still work in progress and removed pr-awaiting-testing PR is reviewed and waiting CI build and test labels Oct 27, 2021
@mozga-intel
Copy link
Contributor Author

@mxnet-bot run ci [website]

@mxnet-bot
Copy link

Jenkins CI successfully triggered : [website]

@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test pr-work-in-progress PR is still work in progress and removed pr-work-in-progress PR is still work in progress pr-awaiting-testing PR is reviewed and waiting CI build and test labels Oct 27, 2021
@mozga-intel
Copy link
Contributor Author

@mxnet-bot run ci [windows-gpu]

@mxnet-bot
Copy link

Jenkins CI successfully triggered : [windows-gpu]

@mseth10 mseth10 added pr-awaiting-testing PR is reviewed and waiting CI build and test and removed pr-work-in-progress PR is still work in progress labels Oct 27, 2021
@szha
Copy link
Member

szha commented Oct 27, 2021

@barry-jin looks like the link check workflow is running into timeouts. See this run

@mseth10 mseth10 added pr-awaiting-review PR is waiting for code review and removed pr-awaiting-testing PR is reviewed and waiting CI build and test labels Oct 27, 2021
@szha szha merged commit d2107af into apache:master Oct 28, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
pr-awaiting-review PR is waiting for code review
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants