|
8 | 8 | ABCSeries,
|
9 | 9 | )
|
10 | 10 |
|
11 |
| -from pandas.core.ops.roperator import ( |
12 |
| - radd, |
13 |
| - rdivmod, |
14 |
| - rfloordiv, |
15 |
| - rmod, |
16 |
| - rmul, |
17 |
| - rpow, |
18 |
| - rsub, |
19 |
| - rtruediv, |
20 |
| -) |
| 11 | +from pandas.core.ops import roperator |
21 | 12 |
|
22 | 13 |
|
23 | 14 | def _get_method_wrappers(cls):
|
@@ -89,27 +80,27 @@ def _create_methods(cls, arith_method, comp_method):
|
89 | 80 | new_methods.update(
|
90 | 81 | {
|
91 | 82 | "add": arith_method(operator.add),
|
92 |
| - "radd": arith_method(radd), |
| 83 | + "radd": arith_method(roperator.radd), |
93 | 84 | "sub": arith_method(operator.sub),
|
94 | 85 | "mul": arith_method(operator.mul),
|
95 | 86 | "truediv": arith_method(operator.truediv),
|
96 | 87 | "floordiv": arith_method(operator.floordiv),
|
97 | 88 | "mod": arith_method(operator.mod),
|
98 | 89 | "pow": arith_method(operator.pow),
|
99 |
| - "rmul": arith_method(rmul), |
100 |
| - "rsub": arith_method(rsub), |
101 |
| - "rtruediv": arith_method(rtruediv), |
102 |
| - "rfloordiv": arith_method(rfloordiv), |
103 |
| - "rpow": arith_method(rpow), |
104 |
| - "rmod": arith_method(rmod), |
| 90 | + "rmul": arith_method(roperator.rmul), |
| 91 | + "rsub": arith_method(roperator.rsub), |
| 92 | + "rtruediv": arith_method(roperator.rtruediv), |
| 93 | + "rfloordiv": arith_method(roperator.rfloordiv), |
| 94 | + "rpow": arith_method(roperator.rpow), |
| 95 | + "rmod": arith_method(roperator.rmod), |
105 | 96 | }
|
106 | 97 | )
|
107 | 98 | new_methods["div"] = new_methods["truediv"]
|
108 | 99 | new_methods["rdiv"] = new_methods["rtruediv"]
|
109 | 100 | if have_divmod:
|
110 | 101 | # divmod doesn't have an op that is supported by numexpr
|
111 | 102 | new_methods["divmod"] = arith_method(divmod)
|
112 |
| - new_methods["rdivmod"] = arith_method(rdivmod) |
| 103 | + new_methods["rdivmod"] = arith_method(roperator.rdivmod) |
113 | 104 |
|
114 | 105 | new_methods.update(
|
115 | 106 | {
|
|
0 commit comments