Commit Graph

2319 Commits

Author SHA1 Message Date
Adam Kelly
23a4b1e9d8 Additional tests for dictionary iteration. 2019-04-09 10:13:44 +01:00
Adam Kelly
29e9753e51 Even newer style class definitions. 2019-04-08 15:02:04 +01:00
Adam Kelly
2d127b9834 Use macro to generate full set of views and iterators. 2019-04-08 12:11:59 +01:00
Adam Kelly
5c4755ffd7 Separate iterators for items/keys/values. 2019-04-08 11:08:45 +01:00
Adam Kelly
9c32de954b Add iterator for dictionary keys. 2019-04-08 10:35:09 +01:00
Joey
7910c95ff0 Merge pull request #785 from palaviv/set-inner
refactor objset using inner
2019-04-07 18:20:37 -07:00
Aviv Palivoda
abc72e9992 contains return bool 2019-04-07 23:54:42 +03:00
Aviv Palivoda
5ae921dc57 update function support iterable 2019-04-07 23:26:59 +03:00
Aviv Palivoda
848350d334 ior support only set and frozenset 2019-04-07 23:06:42 +03:00
Aviv Palivoda
3ed8727ee5 symmetric_difference support iterable 2019-04-07 23:01:49 +03:00
coolreader18
53aa57dbbe Merge pull request #803 from RustPython/joey/self-by-ref
int, str, range: take self by shared reference
2019-04-07 14:54:08 -05:00
Aviv Palivoda
e011e3f327 intersection and difference support iterable 2019-04-07 22:36:56 +03:00
Aviv Palivoda
fa369ff779 Limit non-operator versions to set and frozenset 2019-04-07 22:09:37 +03:00
Joey Hain
c2e03ed342 fix int.__float__ 2019-04-07 11:56:59 -07:00
Aviv Palivoda
3bc1e3598c Use PyIterable 2019-04-07 21:26:20 +03:00
Joey Hain
ea61599da4 range: take self by ref 2019-04-07 10:07:36 -07:00
Joey Hain
e70f174eb6 str: take self by ref 2019-04-07 10:07:36 -07:00
Joey Hain
aec33634ca int: take self by ref 2019-04-07 10:07:31 -07:00
Aviv Palivoda
a0aa88d2fb clear return implicit None 2019-04-07 20:02:27 +03:00
Windel Bouwman
48cca16dd7 Merge pull request #801 from skinny121/dict_copy_update
Implement copy and update dict methods
2019-04-07 12:24:51 +02:00
Windel Bouwman
f4964dafbf Merge pull request #798 from skinny121/keyword_only_args
Implement keyword only argument defaults
2019-04-07 12:11:15 +02:00
Adam
90ded15339 Merge pull request #799 from RustPython/joey/ref-receiver
Allow first argument to be a shared ref to a python value
2019-04-07 10:02:03 +01:00
Adam
8a5d6ca79e Merge pull request #800 from skinny121/warning_classes
Add builtin warning classes
2019-04-07 09:51:23 +01:00
ben
32051c9d96 Implement copy and update dict methods 2019-04-07 19:19:39 +12:00
ben
02a21cd072 Add builtin warning classes 2019-04-07 17:42:10 +12:00
Joey Hain
c2716040d2 float: take self by shared ref 2019-04-06 19:05:18 -07:00
Joey Hain
be55562457 Allow first argument to be a shared ref to a python value 2019-04-06 18:50:40 -07:00
ben
51732feaed Use get_item_option from ItemProtocol instead of get_item 2019-04-07 07:43:29 +12:00
ben
d5a9d96d62 Expose function.__defaults__ and function.__kwdefaults__(only getters) 2019-04-07 07:38:42 +12:00
ben
5fd3cf2bcd Implemented keyword only defaults 2019-04-07 07:38:42 +12:00
Windel Bouwman
d64554dab2 Merge pull request #797 from palaviv/os-dirs
Add os.{mkdir, mkdirs, rmdir, listdir}
2019-04-06 20:25:00 +02:00
Windel Bouwman
ea95fb2b4e Merge pull request #794 from RustPython/generic_dict
Parameterise dictdatatype::Dict by value type.
2019-04-06 20:18:22 +02:00
Aviv Palivoda
401ca08b65 Use map_err 2019-04-06 21:11:58 +03:00
Aviv Palivoda
a21aa6eac9 Add os.listdir 2019-04-06 19:14:23 +03:00
Aviv Palivoda
bf6b12266a Add os.rmdir 2019-04-06 18:30:40 +03:00
Aviv Palivoda
2ec6afeb11 Add os.mkdirs 2019-04-06 18:24:06 +03:00
Aviv Palivoda
eb9378fe90 Add os.mkdir 2019-04-06 18:20:18 +03:00
Adam Kelly
e67d5f3c62 Parameterise dictdatatype::Dict by value type. 2019-04-06 16:06:42 +01:00
Windel Bouwman
d577bb7ac9 Merge pull request #787 from palaviv/os-fd
Add os.{read,write,remove,unlink}
2019-04-06 17:02:31 +02:00
Windel Bouwman
1faa7fa202 Merge pull request #783 from Ryex/ryex-impl-list.__delitem__
Implement list.__delitem__
2019-04-06 16:56:21 +02:00
Windel Bouwman
0f6a25c38e Merge pull request #791 from RustPython/dict_protocols
Dict protocols
2019-04-06 16:48:30 +02:00
Windel Bouwman
a6858befbc Merge pull request #792 from RustPython/docstring-fix
Fix moment when docstring is set.
2019-04-06 16:39:33 +02:00
Aviv Palivoda
04acfe2665 Remove failing line in windows 2019-04-06 17:29:52 +03:00
Aviv Palivoda
1f0fd39722 Change os new funcs to new arg style 2019-04-06 17:29:40 +03:00
Windel Bouwman
bcf94ed8bf Merge pull request #788 from RustPython/syntax-enhancements
Fix syntax for float literals, statements seperated by semicolons and…
2019-04-06 12:31:53 +02:00
Windel Bouwman
afb28bfccb Fix moment when docstring is set. 2019-04-06 11:53:59 +02:00
Adam Kelly
584b707356 Add dict.__missing__ support. 2019-04-06 10:15:34 +01:00
Adam Kelly
b1dd5836af Simpler implementation of ItemProtocol for PyDictRef. 2019-04-06 10:15:34 +01:00
Adam Kelly
e2a4f22be8 Avoid name similarity between ItemProtocol and inner methods. 2019-04-06 10:15:33 +01:00
Adam Kelly
0fe3f7748c Simplify PyDictRef.__repr__. 2019-04-06 10:15:31 +01:00