I didn't think of it at the time, but you could use $regsub to delete any string that doesn't match our criteria. Something like:
alias blah {
var %a
tokenize 32 $(,,$regsub($1-,/.*?((?<= |^)\$\S+ ?)|.*,\1,%a)) %a
echo -a $*
}Note to anyone testing this, obviously you must not use the double // slash when using it from the command line, or it will evaluate the identifiers that you pass it to. Similarly, if you issue it from within a script, the identifiers must be escaped, or again they will evalute.
/blah this $is a $test $to see if $this works
or
//blah this $!is a $!test $!to see if $!this works
Note that it does not catch the $rc in something like "mi$rc" since the original requester asked for "words starting with $", although I'm wondering what exactly he meant with those dots. Are those supposed to be real dots, or do they mean other words in between?