Skip to content

Instantly share code, notes, and snippets.

@fhefh2015
Created April 29, 2021 04:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save fhefh2015/f742e8b6a010b8bf240dbeaaed2c5e3a to your computer and use it in GitHub Desktop.
Save fhefh2015/f742e8b6a010b8bf240dbeaaed2c5e3a to your computer and use it in GitHub Desktop.
print
func printLog<T>(message: T,
file: String = #file,
method: String = #function,
line: Int = #line)
{
#if DEBUG
print("\((file as NSString).lastPathComponent)[\(line)], \(method): \(message)")
#endif
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment