third_party/blink/tools/blinkpy/style/checkers/cpp.py
def check_for_new_line_at_eof(lines, error):
    """Logs an error if there is no newline char at the end of the file.

    Args:
      lines: An array of strings, each representing a line of the file.
      error: The function to call with any errors found.
    """

    # The array lines() was created by adding two newlines to the
    # original file (go figure), then splitting on \n.
    # To verify that the file ends in \n, we just have to make sure the
    # last-but-two element of lines() exists and is empty.
    if len(lines) < 3 or lines[-2]:
        error(
            len(lines) - 2, 'whitespace/ending_newline', 5,
            'Could not find a newline character at the end of the file.')
Logs an error if there is no newline char at the end of the file.

    Args:
      lines: An array of strings, each representing a line of the file.
      error: The function to call with any errors found.
    
Logs an error if there is no newline char at the end of the file.
Logs an error if there is no newline char at the end of the file .
def check_for_new_line_at_eof(lines, error):
    if len(lines) < 3 or lines[-2]:
        error(
            len(lines) - 2, 'whitespace/ending_newline', 5,
            'Could not find a newline character at the end of the file.')
def check_for_new_line_at_eof ( lines , error ) : if len ( lines ) < 3 or lines [ - 2 ] : error ( len ( lines ) - 2 , 'whitespace/ending_newline' , 5 , 'Could not find a newline character at the end of the file.' )
Logs an error if there is no newline char at the end of the file.
Logs an error if there is no newline char at the end of the file .
"""Logs an error if there is no newline char at the end of the file.

    Args:
      lines: An array of strings, each representing a line of the file.
      error: The function to call with any errors found.
    """ # The array lines() was created by adding two newlines to the # original file (go figure), then splitting on \n. # To verify that the file ends in \n, we just have to make sure the # last-but-two element of lines() exists and is empty.
lines
An array of strings, each representing a line of the file.
An array of strings each representing a line of the file .
error
The function to call with any errors found.
The function to call with any errors found .