in reply to passing array ref without variable

Your syntax would probably work, depending on your expectations. Fortune favors the bold - make a mock-up script and see what happens!

The syntax will pass an anonymous array whose contents are the keys of your hash. By using keys, however, you are breaking the link with the actual element itself (lvalue). This means that the function cannot change the values themselves, i.e. if this function normally removes all 'x's from the elements of the array, the hash keys will remain unchanged.