Is it possible to have a function automatically contain the line number and the file that the function was CALLED in,
as if i call __LINE__
or __FILE__
in the function it will use the line and file the function definition is in.
but i dont want to have to pass __LINE__
and __FILE__
into the function every time.
so if i set them as the default params, do they come from the function definition, or where it is being called from?
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…