For example:
function Foo { [string]$functionName = commandRetrievesFoo Write-Host "This function is called $functionName" }
Output:
PS > Foo This function is called foo
You can use $MyInvocation which contains some useful information about what is currently executed.
$MyInvocation
function foo { 'This function is called {0}.' -f $MyInvocation.MyCommand }