@@ -53,6 +53,7 @@ void Init_symengine() {
5353 c_integer = rb_define_class_under (m_symengine , "Integer" , c_basic );
5454 rb_define_alloc_func (c_integer , cbasic_alloc );
5555 rb_define_method (c_integer , "initialize" , cinteger_init , 1 );
56+ rb_define_method (c_integer , "%" , cntheory_mod , 1 );
5657
5758 //Rational class
5859 c_rational = rb_define_class_under (m_symengine , "Rational" , c_basic );
@@ -150,7 +151,6 @@ void Init_symengine() {
150151 rb_define_module_function (m_symengine , "gcd" , cntheory_gcd , 2 );
151152 rb_define_module_function (m_symengine , "lcm" , cntheory_lcm , 2 );
152153 rb_define_module_function (m_symengine , "nextprime" , cntheory_nextprime , 1 );
153- rb_define_module_function (m_symengine , "%" , cntheory_mod , 2 );
154154 rb_define_module_function (m_symengine , "quotient" , cntheory_quotient , 2 );
155155 rb_define_module_function (m_symengine , "fibonacci" , cntheory_fibonacci , 1 );
156156 rb_define_module_function (m_symengine , "lucas" , cntheory_lucas , 1 );
0 commit comments