详细讨论看下面链接
https://stackoverflow.com/questions/26292033/stacktrace-class-methods-not-working-in-release-mode
具体来说就是在 Release 配置下做如下图设定。