1285 Commits

Author SHA1 Message Date
blueloveTH
dcf51ceff6 add vec2.angle 2023-12-02 17:26:35 +08:00
blueloveTH
9179c31d6a some change about mappingproxy 2023-12-02 16:22:08 +08:00
blueloveTH
728f164d8a add impl 2023-12-02 12:35:53 +08:00
blueloveTH
9e66bab34b fix https://github.com/blueloveTH/pocketpy/issues/179 2023-12-01 10:42:42 +08:00
blueloveTH
74e31b36ed allow complex assignment in class definition 2023-11-30 17:53:11 +08:00
blueloveTH
438857a1f5 some fix 2023-11-29 15:31:28 +08:00
blueloveTH
da12d4b8ff update PrintFunc 2023-11-29 12:20:38 +08:00
blueloveTH
101cf24a36 csv support linebreaks 2023-11-29 11:10:37 +08:00
blueloveTH
f2e6004c1e add csv.DictReader 2023-11-29 00:51:02 +08:00
blueloveTH
657062d25a Update csv.cpp 2023-11-29 00:19:32 +08:00
BLUELOVETH
f1ff2639af
Merge pull request #178 from Chukobyte/c_import_handler
Added import handler to c api.
2023-11-28 23:52:45 +08:00
blueloveTH
e00ddb8692 some refactor
Update vm.cpp
2023-11-28 23:41:50 +08:00
blueloveTH
a62943568f add csv module 2023-11-28 22:40:37 +08:00
Chukobyte
075b9c776c Added the ability to override the import handler in c. 2023-11-28 08:48:50 -05:00
blueloveTH
7b9c7d926d rename easing functions 2023-11-27 16:06:52 +08:00
blueloveTH
d478f9802f ... 2023-11-25 11:15:06 +08:00
blueloveTH
acbfd11366 remove dylib support 2023-11-22 06:32:34 +08:00
blueloveTH
a23e4bfff5 Merge branch 'main' of https://github.com/blueloveTH/pocketpy 2023-11-22 06:16:07 +08:00
blueloveTH
2698040f52 improve f-string 2023-11-22 06:16:05 +08:00
blueloveTH
5be69ffe92 fix a bug 2023-11-21 18:32:47 +08:00
blueloveTH
27f8d6be28 some refactor 2023-11-09 15:46:49 +08:00
blueloveTH
641a1711cf fix https://github.com/blueloveTH/pocketpy/issues/177 2023-11-07 05:05:03 +08:00
blueloveTH
0c46f21c19 Update ceval.cpp 2023-11-07 04:52:37 +08:00
blueloveTH
e124f635c1 support @property.setter 2023-11-07 04:50:06 +08:00
blueloveTH
a7448b7fa0 make json.loads accept bytes 2023-10-31 21:34:30 +08:00
blueloveTH
905defb534 fix a bug of datetime and localtime 2023-10-30 23:55:06 +08:00
blueloveTH
49f70318d9 ... 2023-10-29 22:44:14 +08:00
blueloveTH
f2d5fbbb94 add module operator and add split for single char 2023-10-29 22:16:49 +08:00
blueloveTH
04df1dbe5b fix https://github.com/blueloveTH/pocketpy/issues/172 2023-10-28 15:10:58 +08:00
blueloveTH
a12eb4c8bc ... 2023-10-28 15:00:53 +08:00
S Mahmudul Hasan
c82bfb5455
Implement deque in C++ as required by #139 (#155)
* Initial integration of deque in collections

* some fix

* WIP: Implemented a int-only deque with limited capabilities

* WIP: added some more functionality -> changed int to arbitrary objects

* WIP: Added more functionalities in deque

* WIP: switched to std::deque

* WIP: added more functionalities

* WIP: minor fix

* WIP: added constructor

* WIP: added deque iterator

* WIP: added more functionalities

* Cleaned up and added more functionalities

* minor fix, std::min

* minor fix, rotate, n=0 case

* fix `collections` module

* support pickle

* refactored collections module

* Added some tests, more to follow

* Fixed the tests, more to follow

* Fixed some functionalities and added more tests

* added more tests, called __init__ from pickle, added reverse iterator option

* added the tests

* dropped support for __init__ for now

* moved deque iterator to collections.cpp

* undo unnecessary changes

* Cleaned up and added __str__() support

---------

Co-authored-by: blueloveTH <blueloveTH@foxmail.com>
2023-10-21 07:47:11 +08:00
blueloveTH
901f702f00 rename emit into emit_ to make QT happy 2023-10-16 13:56:07 +08:00
blueloveTH
f3acafe44c rename METHOD() macro 2023-10-16 10:57:06 +08:00
blueloveTH
541ad57d97 ... 2023-10-16 00:15:45 +08:00
blueloveTH
e8b1449979 ... 2023-10-16 00:08:26 +08:00
blueloveTH
ab53927019 ... 2023-10-15 22:14:34 +08:00
blueloveTH
5e3572b32c replace std::stringstream with SStream 2023-10-15 21:58:33 +08:00
blueloveTH
e4b6d566a7 add SStream 2023-10-15 21:36:30 +08:00
blueloveTH
cdcdded9a3 some fix 2023-10-15 16:47:53 +08:00
blueloveTH
227e76e3e4 cjson cleanup 2023-10-15 15:00:25 +08:00
Mahbub Alam
2950d88545
Add cjson module (#151)
* Add cjson module

* Create structure for cjson module

* Implemenet loads function

* Convert cJsonBool to python boolean

* Implement dumps function

* Convert json bool and null to python Bool and None

* necessary changes of project structure

* Update amalgamate.py

* Support non-dictionary json objects (list, tuple, string, number, bool, null)

* Fix tests

* fix CI

* fix CI

* Convert python to cJson and then to string

* Delete cJSON object after use

---------

Co-authored-by: Mahbub Alam <alam.mahbub214@gmail.com>
Co-authored-by: blueloveTH <blueloveth@foxmail.com>
2023-10-15 13:32:20 +08:00
blueloveTH
53e4043e0e fix a bug of _class in Function 2023-10-15 04:44:10 +08:00
blueloveTH
c3f10ae4d1 fix a bug of type.__class__ 2023-10-15 04:31:16 +08:00
blueloveTH
37f47b8cee ... 2023-10-14 15:26:50 +08:00
blueloveTH
0157025097 disable code serialization impl 2023-10-14 15:25:07 +08:00
blueloveTH
eb1f8f0a4f some more optimize 2023-10-14 15:18:45 +08:00
blueloveTH
1afef9dcb9 reduce bytecode size 2023-10-14 14:30:15 +08:00
blueloveTH
ffde186dfa change opcode to uint8_t 2023-10-14 12:43:10 +08:00
BLUELOVETH
1879a47597
Update ceval.cpp 2023-10-14 02:07:58 +08:00
blueloveTH
6c821f35ea ... 2023-10-14 01:07:49 +08:00