Uploaded image for project: 'Mesos'
  1. Mesos
  2. MESOS-4231

Add a new category to cpplint to detect missing white-space in comments

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 0.27.0
    • Component/s: build
    • Labels:

      Description

      Currently we haven't turned on any rule in cpplint.py to detect a missing leading whitespace in comments. Newbies tend to make this mistake even while trying to follow the style guide.

      There is already a category in cpplint.py (whitespace/comments) to detect this, but it has the unfortunate side-affect of also tagging any trailing comments with less than 2 whitespaces between the code and the trailing comment as errors. This side-affect generates a lot of false-positives since trailing comments in mesos codebase usually has only a single white-space. Hence proposing adding a new category called whitespace/mesos-comments that takes care of the more common case of tagging comments with leading whitespace as errors.

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                avinash.mesos Avinash Sridharan
                Reporter:
                avinash.mesos Avinash Sridharan
                Shepherd:
                Michael Park
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: