No.
Ok, technically, you could do this (inspired by
https://github.com/JuliaLang/julia/issues/8066#issuecomment-61136584):
julia> function foo()
bt = backtrace()
lookup = ccall(:jl_lookup_code_address, Any, (Ptr{Void}, Int32),
bt[2], 0)
name = lookup[1]
end
foo (generic function with 1 method)
julia> foo()
:foo
But that is a really, really bad idea. Please don't do that.
On Wed, Aug 5, 2015 at 12:04 PM, Dominique Orban <[email protected]>
wrote:
> Sorry if this has been asked before. Is it possible to determine the name
> of a function inside that function? For example,
>
> function blah(x)
> my_name = ... # should evaluate to "blah" or :blah
> end
>
> I didn't see that in the introspection section of the documentation.
>
> Thanks!
>