Another alternative: The local of Data::Alias does it right (it ignores ties and such), so this works:
alias(local $_) = @_ ? $_ : $_;
And it avoids localizing the entire *_
The parens here are needed because alias local $_ = ... would be parsed as alias(local $_ = ...) which means the assignment would make an alias, which isn't what you want here.