代码来自王巍的Swifter Tips
func printLog<T>(_ message: T,
file: String = #file,
method: String = #function,
line: Int = #line)
{
#if DEBUG
print("\((file as NSString).lastPathComponent) \(method) \(line) : \(message) ")
#endif
}