lint(ast) {
    var errors = [];

    ast.traverseByType('block', (block) => {
      block.eachFor((currentNode) => {
        var nodeWithoutSemicolon;
        // Skip nodes that already have `;` at the end:
        if (currentNode.is('declarationDelimiter')) return null;

        // Add semicolon only after declarations and includes.
        // If current node is include, insert semicolon right into it.
        // If it's declaration, look for value node:
        if (currentNode.is('include') ||
            currentNode.is('extend')) {
          nodeWithoutSemicolon = currentNode;
        } else if (currentNode.is('declaration')) {
          nodeWithoutSemicolon = currentNode.last('value');
        } else {
          return;
        }

        errors.push({
          message: 'Missing semicolon',
          line: nodeWithoutSemicolon.end.line,
          column: nodeWithoutSemicolon.end.column + 1
        });

        // Stop looping through block's children:
        return null;
      });
    });

    return errors;
  }
Checks ast for code style errors.

@param {Node} ast
@return {Array?} List of found errors.