Created
May 10, 2014 08:35
-
-
Save moskytw/09ed2509e5e6bd86686f to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
def deco(f): | |
def f_warpper(*args, **kagrs): | |
print 'Hi, I am f_warpper.' | |
return f(*args, **kagrs) | |
return f_warpper | |
@deco | |
def f(): | |
print 'Hi, I am f.' | |
return 1 | |
if __name__ == '__main__': | |
print f() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment