Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- using System;
- using System.Runtime.CompilerServices;
- public class Program
- {
- public static void Main()
- {
- }
- public static void Log(string text, [CallerMemberName] string memberName ="", [CallerFilePath] string sourceFilePath = "", [CallerLineNumber] int sourceLineNumber = 0)
- {
- Console.WriteLine("{text} - {sourceFilePath}/{memberName} (line {sourceLineNumber})");
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment