- Notifications
You must be signed in to change notification settings - Fork750
Commit159e0dd
committed
Allow implicit safe conversion to System.Double/Single in method calls
Checking the exact type beforehand is unnecessary and `AsDouble` willcheck whether `__float__` is available and call it.This is not yet supported for integer types, which would use `__int__`or `__index__` (for Python >=3.10), as the respective logic is for somereason only implemented for `AsLongLong` and `AsLong`, not for theunsigned counterparts and also not for the `AsSize_t` variants that weare using.1 parentbd48dc1 commit159e0dd
2 files changed
+27
-10
lines changedLines changed: 2 additions & 10 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
777 | 777 |
| |
778 | 778 |
| |
779 | 779 |
| |
780 |
| - | |
781 |
| - | |
782 |
| - | |
783 |
| - | |
784 | 780 |
| |
785 |
| - | |
| 781 | + | |
786 | 782 |
| |
787 | 783 |
| |
788 | 784 |
| |
| |||
799 | 795 |
| |
800 | 796 |
| |
801 | 797 |
| |
802 |
| - | |
803 |
| - | |
804 |
| - | |
805 |
| - | |
806 | 798 |
| |
807 |
| - | |
| 799 | + | |
808 | 800 |
| |
809 | 801 |
| |
810 | 802 |
| |
|
Lines changed: 25 additions & 0 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
1256 | 1256 |
| |
1257 | 1257 |
| |
1258 | 1258 |
| |
| 1259 | + | |
| 1260 | + | |
| 1261 | + | |
| 1262 | + | |
| 1263 | + | |
| 1264 | + | |
| 1265 | + | |
| 1266 | + | |
| 1267 | + | |
| 1268 | + | |
| 1269 | + | |
| 1270 | + | |
| 1271 | + | |
| 1272 | + | |
| 1273 | + | |
| 1274 | + | |
| 1275 | + | |
| 1276 | + | |
| 1277 | + | |
| 1278 | + | |
| 1279 | + | |
| 1280 | + | |
| 1281 | + | |
| 1282 | + | |
| 1283 | + |
0 commit comments
Comments
(0)