Commit 5127d05
committed
Add SingleOps.__round__ and optimizations in Builtin.round.
Testing
===
```
>>> import System
>>> v = 987.654321
>>> assert round(System.Double(v)) == round(System.Single(v))
>>> print(round(System.Double(v), 3), round(System.Single(v), 3))
987.654 987.654
```
(Attempted to add assertions in tests/suite/test_builtinfunc.py, but attempting to run fails with
```
RUNNING IRONPYTHON TESTS USING THESE FLAGS:
Traceback (most recent call last):
File "run.py", line 330, in <module>
File "run.py", line 295, in runTest
File "run.py", line 241, in runTestSlow
File "run.py", line 226, in run_one_command
AttributeError: 'module' object has no attribute 'popen3'
```
)
```1 parent 3ef134b commit 5127d05
2 files changed
Lines changed: 14 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1313 | 1313 | | |
1314 | 1314 | | |
1315 | 1315 | | |
| 1316 | + | |
| 1317 | + | |
| 1318 | + | |
| 1319 | + | |
1316 | 1320 | | |
1317 | 1321 | | |
1318 | 1322 | | |
| |||
1338 | 1342 | | |
1339 | 1343 | | |
1340 | 1344 | | |
| 1345 | + | |
| 1346 | + | |
| 1347 | + | |
1341 | 1348 | | |
1342 | 1349 | | |
1343 | 1350 | | |
| |||
1350 | 1357 | | |
1351 | 1358 | | |
1352 | 1359 | | |
| 1360 | + | |
| 1361 | + | |
| 1362 | + | |
1353 | 1363 | | |
1354 | 1364 | | |
1355 | 1365 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1187 | 1187 | | |
1188 | 1188 | | |
1189 | 1189 | | |
| 1190 | + | |
| 1191 | + | |
| 1192 | + | |
| 1193 | + | |
1190 | 1194 | | |
1191 | 1195 | | |
0 commit comments