]> git.phdru.name Git - m_lib.git/blobdiff - m_lib/md5wrapper.py
Use print function for Py3 compatibility
[m_lib.git] / m_lib / md5wrapper.py
index 0c1a5f1e2c03ed8e991dfd642d8edf8fac302a8e..d428d55586841491926fdace564260768fdb86ef 100755 (executable)
@@ -1,18 +1,15 @@
 #! /usr/bin/env python
 """User wrapper for md5 builtin object"""
 
-__author__ = "Oleg Broytman <phd@phdru.name>"
-__copyright__ = "Copyright (C) 1997-2012 PhiloSoft Design"
-__license__ = "GNU GPL"
-
-__all__ = ['md5wrapper']
-
+from __future__ import print_function
 import sys
 if sys.version < '2.5':
     from md5 import md5
 else:
     from hashlib import md5
 
+__all__ = ['md5wrapper']
+
 class md5wrapper:
    def __init__(self, init=None):
       if init:
@@ -48,6 +45,6 @@ class md5wrapper:
             infile.close()
 
 if __name__ == "__main__":
-   print "This must print exactly the string"
-   print "Test: 900150983cd24fb0d6963f7d28e17f72"
-   print "Test:", md5wrapper("abc")
+   print("This must print exactly the string")
+   print("Test: 900150983cd24fb0d6963f7d28e17f72")
+   print("Test:", md5wrapper("abc"))