Skip to content

Commit

Permalink
Trial to make documentation py3 compatible
Browse files Browse the repository at this point in the history
  • Loading branch information
Manuel Guenther committed Jun 25, 2015
1 parent 1a20a57 commit 85e8952
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions bob/bio/base/utils/singleton.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,10 @@ class Singleton:

def __init__(self, decorated):
self._decorated = decorated
import functools
for attr in functools.WRAPPER_ASSIGNMENTS:
setattr(self, attr, getattr(decorated, attr))
# see: functools.WRAPPER_ASSIGNMENTS:
self.__doc__ = decorated.__doc__
self.__name__ = decorated.__name__
self.__module__ = decorated.__module__
self.__bases__ = []

self._instance = None
Expand Down

0 comments on commit 85e8952

Please sign in to comment.