Hi Rockit8.
I know you've worked around your issue (I'd still like to know exactly what it was you needed to do), but I think I have worked out kinda what you were asking, and to quench my curiousity, I want to follow this up some more to clarify some things (for me, and possibly for you).
I suspect what you're asking is demonstrated by this pseudocode:
<cffunction name="myFunction">
<cfargument name="theArgumentFromThePerspectiveOfTheFunction">
<!---I have arguments.theArgumentFromThePerspectiveOfTheFunction, but I want to know that it got its value from variables.theVariableWhoseNameIWantToKnow --->
<cfreturn somehow("variables.theVariableWhoseNameIWantToKnow")>
</cffunction>
<cfset variables.theVariableWhoseNameIWantToKnow = "some value">
<cfset variables.theNameOfTheVariable = myFunction(variables.theVariableWhoseNameIWantToKnow)>
Is that the sort of thing you're wanting to do? This is not possible.
When calling a function like this, the function never knows anything about variables.theVariableWhoseNameIWantToKnow, it never gets passed variables.theVariableWhoseNameIWantToKnow, it just gets passed its value. And CF puts the value into arguments.theArgumentFromThePerspectiveOfTheFunction. The only variable myFunction() knows about is arguments.theArgumentFromThePerspectiveOfTheFunction. It is irrelevant to myFunction() that the calling code used a variable to hold "some value", it could just as likely have been:
<cfset variables.theNameOfTheVariable = myFunction("some value")>
This demonstrates why I say your question - as asked - is meaningless.
However not all data is passed by value. Consider this code:
<cfset variables.firstOneToReferenceTheStruct = {foo="bar"}>
<cfset variables.anotherOneThatReferencesTheStruct = variables.firstOneToReferenceTheStruct>
In CF, a struct is copied by reference (kinda), not value, so both variables.firstOneToReferenceTheStruct and variables.anotherOneThatReferencesTheStruct will be separate references to the same piece of memory (and the memory holds the struct {foo="bar"}.
So if one has this code:
<cfset variables.theNameOfTheVariable = myFunction(variables.anotherOneThatReferencesTheStruct)>
Then arguments.theArgumentFromThePerspectiveOfTheFunction will simply be yet another reference to exactly the same memory as variables.firstOneToReferenceTheStruct and variables.anotherOneThatReferencesTheStruct. So one might initially think "aha, so there's a way to know that arguments.theArgumentFromThePerspectiveOfTheFunction was 'originally' called 'variables.firstOneToReferenceTheStruct'". No, there isn't. Because whilst those references all point to the same memory, they're all still completely separate references (a reference is a memory address, so each of those three actually just hold the memory address that the struct is at, but it's three separate copies of the address. Not three separate copies of the content of the memory address, but three separate copies of the address), and do not have any corelation at all.
Now... Java obviously keeps track of which references point to which bits of memory (so it knows when memory can be cleared by the garbage collector), so it is possible to find out a list of references that reference that particular piece of memory, but I don't know that this is exposed even via the Java API, and it's definitely not exposed to ColdFusion. I'm not a Java developer, but I can google, but I did not come up with any Java functionality that exposes this (disclosure: I only spent about 2min trying). I suspect it's too low level, and not really of any particular use. Why really would one want to know this sort of thing anyhow? It's not useful information to an application, after all.
Does this explain why I said your question is a bit meaningless?
--
Adam