summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGerman M. Bravo <german.mb@deipi.com>2013-10-08 12:58:13 -0700
committerGerman M. Bravo <german.mb@deipi.com>2013-10-08 12:58:13 -0700
commitbbc97c38f36eedac64b55bb7aa130a1d8f2f9598 (patch)
tree00244d42706fe8758a10bb8336e666fd9eb9f46b
parent552d0452d351c3e628d984d0cb02cad646773842 (diff)
downloadpyscss-bbc97c38f36eedac64b55bb7aa130a1d8f2f9598.tar.gz
Added __repr__ to SourceFile
-rw-r--r--scss/__init__.py6
1 files changed, 6 insertions, 0 deletions
diff --git a/scss/__init__.py b/scss/__init__.py
index be98d1f..458bc94 100644
--- a/scss/__init__.py
+++ b/scss/__init__.py
@@ -141,6 +141,12 @@ class SourceFile(object):
self.parent_dir = os.path.realpath(parent_dir)
self.is_string = is_string
+ def __repr__(self):
+ return "<SourceFile '%s' at 0x%x>" % (
+ self.filename,
+ id(self),
+ )
+
@classmethod
def from_filename(cls, fn, filename=None, is_sass=None, line_numbers=True):
if filename is None: