Obviously the correct way would be always to pass Function A a reference to whatever Function B returned, but how can I create the reference to it when I don't know what it's going to be?You don't have to know what it's returning to take a reference to it:funcA(\funcB());will pass a single reference (scalar) to whatever funcB returns.
Update
The note below is correct. Ignore this.
In reply to Re: Auto-detecting returned or passed variable type
by VSarkiss
in thread Auto-detecting returned or passed variable type
by richard5mith
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |