In C / C ++, you can use __FILE__and __LINE__to access the current file and line number.
__FILE__
__LINE__
Is there something similar?
In fact, it does:
http://golang.org/pkg/runtime/#Caller
runtime.Caller can also be used to get the file name / number of the calling function.
runtime.Caller
Source: https://habr.com/ru/post/1791008/More articles:Convert string / numeric date in Excel to date-formatted object using only formulas - excelC # Daylight Saving Time - c #Can you pack WebFilter into a library - jspIs the operating system an abstraction? - assemblyto embed a non-web application in a jetty - jettyOracle ordering above (colname) does not give correct results for columns without a row - sqlUnzip a 4gb file in C # - c #What is the best way to store session geolocation results from an IP address using rails? - ruby-on-railsForward stdout to a file in a Qt application - c ++Проблема с сохранением JQuery с вращением изображения - jqueryAll Articles