From 02edb7bde68c1cb2f0659919e065a8ec5f1581a8 Mon Sep 17 00:00:00 2001 From: knu Date: Wed, 21 Feb 2007 13:30:17 +0000 Subject: * numeric.c (fix_equal): A bit more optimization. git-svn-id: http://svn.ruby-lang.org/repos/ruby/trunk@11808 b2dd03c8-39d4-4d8f-98ff-823fe69b080e --- numeric.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'numeric.c') diff --git a/numeric.c b/numeric.c index c94eb63b9..756f510ca 100644 --- a/numeric.c +++ b/numeric.c @@ -2311,9 +2311,8 @@ fix_pow(VALUE x, VALUE y) static VALUE fix_equal(VALUE x, VALUE y) { - if (FIXNUM_P(y)) { - return (x == y)?Qtrue:Qfalse; - } + if (x == y) return Qtrue; + if (FIXNUM_P(y)) return Qfalse; switch (TYPE(y)) { case T_BIGNUM: return rb_big_eq(y, x); -- cgit