improve ruby2.0 support