RUBY-621: remove unused code and superflous core extensions