Python:PyCharm坏了吗?或者我可能会被打破?或两者?

gar*_*000 5 python pycharm

PyCharm社区版3.4.1运行Python 2.7.8.简单代码:

def test(x):
    print x

d={'test': test}
d['test'](5)
Run Code Online (Sandbox Code Playgroud)

d['test'](5)
Run Code Online (Sandbox Code Playgroud)

'空无法调用'

在shell中,此代码执行无错误.

Tom*_*ski 1

内置检查似乎过于敏感(如果你愿意的话,也可以说是有缺陷)。

如果你尝试(d['test'])(5),它就不会抱怨。