Are ScriptBlock parameters implemented for functions?
PSMDTAG:FAQ: Are ScriptBlock parameters implemented for functions?
Not in V1. Functions do not use the same parameter binding mechanism as Cmdlets.
This is something we intent to address in a future release.