fixed build error caused by trunk changes

@tenderlove 

RUBY_TYPED_FREE_IMMEDIATELY is only provided on Ruby 2.2.0.