In similar code, I've done something like the following because I wanted the hash keys to be factored into the hash:

```ruby
keys.map { |key| key.hash ^ send(key).hash }.reduce(self.class.hash, :^)
```

I like your solution though because the work to create the Array has already been done anyway. Might as well call `Array#hash` rather than using `Enumerable#reduce` to xor the hashes.. it's simpler and probably optimized.