Here is my code:
var structure = {
A: function() {
this.B();
},
B: function() {
console.log(arguments.callee.caller.toString());
}
};
Then I run:
structure.A();
As you understand, I'm trying to get caller function name, but result is empty string. Are any ideas how to do that?