Skip to content

Instantly share code, notes, and snippets.

@blue-bird1
Created October 30, 2018 14:59
Show Gist options
  • Select an option

  • Save blue-bird1/0e156331e77cdfa62cbcca90408884fd to your computer and use it in GitHub Desktop.

Select an option

Save blue-bird1/0e156331e77cdfa62cbcca90408884fd to your computer and use it in GitHub Desktop.
func print self __doc__
from inspect import *
def my_selfexplaining_function():
"""This is my function document string"""
print getdoc(globals()[getframeinfo(currentframe()).function])
my_selfexplaining_function()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment