Commit Graph

383 Commits

Author SHA1 Message Date
ZapAnton
206ccc55fb Fixed the len_without_is_empty clippy warning 2019-02-12 16:49:34 +03:00
ZapAnton
38930984ec Fixed the redundant_pattern_matching clippy warning 2019-02-12 16:45:44 +03:00
ZapAnton
291dba6bb6 Fixed the toplevel_ref_arg clippy warning 2019-02-12 16:44:47 +03:00
ZapAnton
5fe373555f Fixed the match_bool clippy warning 2019-02-12 16:43:59 +03:00
ZapAnton
45b9ef9719 Fixed the op_ref clippy warnings 2019-02-12 16:42:53 +03:00
ZapAnton
050bf459b0 Fixed the into_iter_on_ref clippy warning 2019-02-12 16:40:08 +03:00
ZapAnton
9144109f7d Fixed the useless_vec clippy warning 2019-02-12 16:39:38 +03:00
ZapAnton
00cfa47f64 Fixed the should_implement_trait clippy warning 2019-02-12 16:35:28 +03:00
ZapAnton
606ddd2216 Fixed the needless_return clippy warnings 2019-02-12 16:30:03 +03:00
ZapAnton
0d1b85a8da Fixed the collapsible_if clippy warning 2019-02-12 16:28:49 +03:00
ben
d14aeef2e5 Handle passing no format_spec into format() 2019-02-12 20:24:57 +13:00
ben
5c12367f59 Merge branch 'master' into object_format 2019-02-12 20:09:27 +13:00
ben
93e5634d39 Fixes #328, add object.__format__ 2019-02-12 20:06:50 +13:00
Windel Bouwman
9177252cf9 Merge pull request #259 from RustPython/list_insert
Implemented list.insert()
2019-02-12 06:10:20 +01:00
Shing Lyu
d188f05ffc Fix errors introduced during rebasing 2019-02-11 22:59:08 +01:00
Shing Lyu
b265601c58 Use isize in list.insert instead of i64 2019-02-11 22:52:55 +01:00
Shing Lyu
3467db51d0 Simplify the number logic for list.insert() 2019-02-11 22:52:55 +01:00
Shing Lyu
c99cb0c366 Rustfmt fixes 2019-02-11 22:52:55 +01:00
Shing Lyu
8ded37d566 Raise OverflowError is the index for list.index() overflows 2019-02-11 22:52:27 +01:00
Shing Lyu
b101a52dd0 Added list.insert() 2019-02-11 22:50:10 +01:00
Adam Kelly
67710d6e28 Don't call __eq__ directly.
Doing so creates a very confusing error when NotImplemented in returned.
2019-02-11 21:11:33 +00:00
Adam
23aa4a71ea Merge pull request #436 from Tom1380/master
Fix #390.
2019-02-11 21:09:32 +00:00
Adam
1033f20e36 Merge pull request #430 from RustPython/dict5
Change to more usage of VirtualMachine in anticipation of proper dicts
2019-02-11 13:04:28 +00:00
Adam
ca51f2d10e Merge pull request #438 from ZapAnton/fix_clippy
Fixed several small clippy warnings
2019-02-11 13:03:07 +00:00
Tommaso Thea Cioni
7e1589d811 Minor fix. 2019-02-11 13:38:53 +01:00
Adam
45f45bf43a Merge pull request #433 from OddCoincidence/not-implemented
Use NotImplemented in binary operations
2019-02-11 12:37:22 +00:00
Tommaso Thea Cioni
c04f4219eb Removed the __code__ attribute from the builtin_function_or_method type. 2019-02-11 13:35:59 +01:00
ZapAnton
e51c75e1df Fixed or_fun_call clippy warnings 2019-02-11 15:29:19 +03:00
ZapAnton
56e2d4c495 Fixed into_iter_on_ref clippy warning 2019-02-11 15:24:51 +03:00
ZapAnton
c8d619c123 Fixed useless_let_if_seq clippy warnings 2019-02-11 15:24:13 +03:00
Tommaso Thea Cioni
cc56f318cb Merge branch 'master' of https://github.com/RustPython/RustPython 2019-02-11 13:21:41 +01:00
Tommaso Thea Cioni
8ac3c46de1 Fix RustPython#390. Now Rust functions have a builtin_function_or_method type, Python functions retain the function type. 2019-02-11 02:50:51 +01:00
Joey Hain
057a22529e Move delegation of __ne__ to __eq__ out of objobject 2019-02-10 15:46:12 -08:00
Joey Hain
a510aed86a Tests and fix objobject ne impl 2019-02-10 10:13:30 -08:00
Joey Hain
dab4f7385f Use NotImplemented in binary operations 2019-02-10 09:19:06 -08:00
Homer McMillan
389fc3acd9 cargo fmt 2019-02-10 12:04:42 -05:00
Homer McMillan
9de733be19 Add range start/stop/step 2019-02-10 12:03:22 -05:00
janczer
aac1ce4e07 Fix the str.{__lt__, __gt__} and add the methods str.{__le__, __ge__} 2019-02-10 16:40:09 +01:00
Windel Bouwman
b1e07f64be Change to more usage of VirtualMachine in anticipation of proper dictionaries. 2019-02-10 15:39:33 +01:00
Windel Bouwman
05cd60bebc Merge pull request #415 from silmeth/fix-int-eq-float
fix int – float equality for big ints, inf and nan
2019-02-10 13:55:50 +01:00
Windel Bouwman
68002f1a9e Fix build error of removed str method. 2019-02-10 13:00:54 +01:00
Windel Bouwman
9497ee89e8 Merge pull request #292 from mcon/sets-using-hashes
Items are now added to sets using proper __hash__ function calls.
2019-02-10 12:57:46 +01:00
Windel Bouwman
1cb59c5731 Merge pull request #394 from ZapAnton/iter_doc
iter type: Added __doc__
2019-02-10 12:28:09 +01:00
Windel Bouwman
2bab31b8e7 Merge pull request #387 from janczer/add_bytes_ge_gt_le_lt
Add bytes.{__ge__, __gt__, __le__, __lt__}
2019-02-10 12:27:01 +01:00
Windel Bouwman
03a2aad82d Merge pull request #410 from OddCoincidence/complex
Add complex.{__abs__, __eq__, __neg__}
2019-02-10 12:23:24 +01:00
Windel Bouwman
c2db23db2b Merge pull request #417 from janczer/fix_lt_le_ge_gt_float
float.{__lt__, __le__, __ge__, __gt__} fix comparing with non float type
2019-02-10 12:10:58 +01:00
Windel Bouwman
fc38d55b59 Merge pull request #381 from nficca/implement-range-count
Implement range.count
2019-02-10 11:46:10 +01:00
Windel Bouwman
94db145ae8 Merge branch 'master' into complex 2019-02-10 11:41:39 +01:00
Windel Bouwman
e69605328b Merge pull request #426 from skinny121/recursive_repr
Fixed #191, fixes recursive repr() for the standard collections
2019-02-10 08:35:02 +01:00
Windel Bouwman
e98d5f11cc Merge pull request #393 from ZapAnton/filter_doc
filter type: Added __doc__
2019-02-10 08:24:50 +01:00