From 6061a2c4cccd1f25e6a974fe3a505daea5d27487 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Adrien=20Verg=C3=A9?= Date: Mon, 27 Jun 2016 21:37:31 +0200 Subject: [PATCH] Rules: common: Remove dead code --- yamllint/rules/common.py | 21 --------------------- 1 file changed, 21 deletions(-) diff --git a/yamllint/rules/common.py b/yamllint/rules/common.py index 07baced..9893459 100644 --- a/yamllint/rules/common.py +++ b/yamllint/rules/common.py @@ -48,27 +48,6 @@ def spaces_before(token, prev, next, min=-1, max=-1, token.start_mark.column + 1, min_desc) -class Comment(object): - def __init__(self, line, column, buffer, pointer): - self.line = line - self.column = column - self.buffer = buffer - self.pointer = pointer - - def __repr__(self): - end = self.buffer.find('\n', self.pointer) - if end == -1: - end = self.buffer.find('\0', self.pointer) - if end != -1: - return self.buffer[self.pointer:end] - return self.buffer[self.pointer:] - - def __eq__(self, other): - return (self.line == other.line and - self.column == other.column and - str(self) == str(other)) - - def get_line_indent(token): """Finds the indent of the line the token starts in.""" start = token.start_mark.buffer.rfind('\n', 0,