generalized on Squash.rb