摘要: 装饰器本质上是一个 Python 函数,它可以让其他函数在不变动代码的前提下增加额外功能,装饰器的返回值也是一个函数对象。 定义函数 >>> def foo(): ... print("hello") ... >>> foo <function foo at 0x00000000035EC268> 阅读全文
posted @ 2019-05-16 10:30 PIPO2 阅读(145) 评论(0) 推荐(0) 编辑