jfh
7bc10da154
Relocate vm.get_attribute to obj.get_attr.
2021-10-17 10:30:21 +03:00
Jim Fasarakis-Hilliard
7af58dd822
Merge pull request #3328 from youknowone/del-error-cold
...
__del__ failure is a cold function
2021-10-17 07:48:46 +03:00
Jeong YunWon
e1bd36d8f6
Merge pull request #3323 from DimitrisJim/supply_dict_on_absent_prepare
...
Ignore AttributeError for missing `__prepare__`.
2021-10-17 06:26:38 +09:00
Jeong YunWon
ecf83ecc3a
__del__ failure is a cold function
2021-10-17 06:25:04 +09:00
Jim Fasarakis-Hilliard
61c325371b
Update vm/src/stdlib/builtins.rs
...
Co-authored-by: Jeong YunWon <69878+youknowone@users.noreply.github.com >
2021-10-16 21:10:57 +03:00
Jeong YunWon
273193f361
Merge pull request #3306 from youknowone/object-protocol
...
Object protocol
2021-10-17 03:09:45 +09:00
jfh
2f3f3f8505
Ignore AttributeError for missing __prepare__.
2021-10-16 20:16:33 +03:00
Jim Fasarakis-Hilliard
69f436378d
Merge pull request #3322 from deantvv/io-error-builder-doc
...
update doc for IOErrorBuilder
2021-10-16 19:08:23 +03:00
Jim Fasarakis-Hilliard
dd747a6920
Merge pull request #3320 from DimitrisJim/allow_objects_meta
...
Allow non-types as metaclass argument.
2021-10-16 19:07:32 +03:00
Dean Li
98007094f6
update doc for IOErrorBuilder
2021-10-16 22:59:25 +08:00
Dean Li
69771724c6
posix: add os.SCHED_* for macos
2021-10-16 22:30:44 +08:00
jfh
d2f0f94dee
Allow non-types as metaclass argument.
2021-10-16 15:02:11 +03:00
Jim Fasarakis-Hilliard
f0280dabb8
Merge pull request #3290 from tony-jinwoo-ahn/_range
...
Modify range in pytype.rs
2021-10-16 13:30:26 +03:00
Tony Jinwoo Ahn
fcf07fcf9f
Modify range in pytype.rs
...
For readability, replace exclusive range with inclusive range.
2021-10-16 18:56:40 +09:00
Jim Fasarakis-Hilliard
45290b1553
Merge pull request #3314 from DimitrisJim/mapping_locals
...
Allow any mapping for locals.
2021-10-16 12:34:58 +03:00
jfh
94b9163297
Use PyMapping, fix handling of __prepare__.
2021-10-16 09:57:02 +03:00
Steve Shi
723357962a
Refactor list avoid duplicate the vec ( #3241 )
...
* list count bench
* Refactor list count avoid duplicate the vec
* optimize list count with HEAPTYPE flag
* introduce generic safe iter functions for list
* Refactor list functions (contains, index, remove)
* Refactor list iter functions with const generics
* optimize list with richcompare
* optimize list iter_equal
2021-10-16 13:16:45 +09:00
Jim Fasarakis-Hilliard
3ab48baf10
Merge pull request #3317 from RustPython/fix-doc-links
...
Fix intra doc links
2021-10-16 06:47:32 +03:00
Noa
a6e2b10296
Fix intra doc links
2021-10-15 14:25:38 -05:00
jfh
dce45825ae
Allow any mapping for locals.
2021-10-15 17:34:52 +03:00
Jeong YunWon
8df1c573e5
Merge pull request #3313 from DimitrisJim/mapping_check
...
Check if subscript is present for PyMapping::check.
2021-10-15 19:43:01 +09:00
Jeong YunWon
79e951b630
Object protocol
2021-10-15 17:54:30 +09:00
Jeong YunWon
42912a36a1
No downcast for unhashable
2021-10-15 16:32:05 +09:00
Jeong YunWon
97623b4e72
Fix __hash__ not to perform unnecessary downcast
2021-10-15 16:32:00 +09:00
jfh
9b63c50446
Check if subscript is present for PyMapping::check.
2021-10-15 09:46:18 +03:00
Jim Fasarakis-Hilliard
4ede6b1510
Merge pull request #3311 from pheki/recursion-limit
...
Guarantee recursion_depth is never higher than recursion_limit
2021-10-15 09:16:57 +03:00
Aphek
773305022f
Guarantee recursion_depth is never higher than recursion_limit
2021-10-15 02:31:07 -03:00
Jeong YunWon
77e33c5338
slot_as_mapping never fails
2021-10-15 05:59:05 +09:00
Jeong YunWon
22b3679529
as_mapping never fails
2021-10-15 05:45:54 +09:00
Jeong Yunwon
0d2e20363a
Fix windows build error
2021-10-15 04:47:10 +09:00
Jeong YunWon
8c42d0469c
msvcrt uses #[pymodule]
2021-10-15 04:04:16 +09:00
Jeong YunWon
6c318f2de8
Merge pull request #3305 from youknowone/less-pymodule
...
replace py_module! from errno and sysconfigdata
2021-10-15 04:03:36 +09:00
Jeong YunWon
25e715e300
winreg uses #[pymodule]
2021-10-15 02:38:13 +09:00
Jeong YunWon
806c81b628
winreg constants to #[pymodule]
2021-10-15 02:38:13 +09:00
Jeong YunWon
de3df09e0e
Merge pull request #3222 from youknowone/slots
...
clean up Callable and mark inline for slot methods
2021-10-15 02:16:03 +09:00
Jeong YunWon
b9ffa93eb1
replace py_module! from errno and sysconfigdata
2021-10-15 02:11:35 +09:00
Jeong YunWon
3cfd350628
fix fmt
2021-10-15 02:01:41 +09:00
Jeong YunWon
67a2110073
_winapi uses #[pymodule]
2021-10-15 01:28:23 +09:00
Jeong YunWon
b581d8303e
_winapi constants to #[pymodule]
2021-10-15 01:26:49 +09:00
jfh
0e193f8ec3
Implement unconstructible for dict_views.
2021-10-14 17:10:16 +03:00
jfh
37ba1b8a87
Mark internal types as not constructible.
2021-10-14 12:09:31 +03:00
Jeong YunWon
e3bb8404c8
use tuple rather than vec for FuncArgs
2021-10-14 17:31:31 +09:00
Jeong YunWon
2acacec967
Callable::call -> PyType::call for readability
2021-10-14 17:29:54 +09:00
Jeong YunWon
c086e17bc6
mark inilne for slots
2021-10-14 17:28:58 +09:00
Jeong YunWon
67d0cdf8fe
inline slot hash
2021-10-14 17:26:05 +09:00
Jeong YunWon
521a50b6a1
clean up Callable
2021-10-14 17:26:04 +09:00
Jeong YunWon
19dc69cef8
Merge pull request #3295 from DimitrisJim/cmp_recursions
...
Handle recursions when comparing objects.
2021-10-14 16:54:58 +09:00
Jeong YunWon
f44c61efe5
Merge pull request #3293 from DimitrisJim/recursive_inst_subcls
...
Fix recursions in isinstance and issubclass.
2021-10-14 16:16:13 +09:00
jfh
54a5db29ae
Handle recursions when comparing objects.
2021-10-14 10:13:25 +03:00
Jeong YunWon
8cdde9150e
Rename slot traits to drop Slot prefix
2021-10-14 13:44:22 +09:00