Commit Graph

1000 Commits

Author SHA1 Message Date
K. Lange
4a052191de Support 'else' blocks on for and while loops 2022-05-23 09:41:12 +09:00
K. Lange
ece7da299a Support = to print f-string expression alongside value 2022-05-23 08:42:40 +09:00
K. Lange
78e85ce873 Support an extensive memory debugging process, if you provide some extra files 2022-05-21 21:10:57 +09:00
K. Lange
27278cfa68 Fixup allocation size for bytes literals 2022-05-21 20:39:47 +09:00
K. Lange
953e57fa0d Fix two more instances of bad alloc/dealloc pairings 2022-05-21 20:05:16 +09:00
K. Lange
73c82e0868 Fixup display of gc debug info on 32-bit platforms 2022-05-21 19:18:30 +09:00
K. Lange
a50cfc63a7 Fix tracking of memory from instances of objects with allocSize != sizeof(Instance) 2022-05-21 19:18:13 +09:00
K. Lange
9b1875d8ce Fix incorrect memory usage tracking of taken strings 2022-05-21 19:15:04 +09:00
K. Lange
b6e591601b Fix incorrect memory usage tracking of code object line mappings 2022-05-21 19:14:50 +09:00
K. Lange
81f78b9199 fixup potential leaks when os.exec*() family fails 2022-05-21 19:14:24 +09:00
K. Lange
7c4b129b7c Dict unpacking should only happen on dicts, or we're going to have a bad time 2022-05-19 11:05:55 +09:00
K. Lange
396b8c0ae3 Inline string equality check to save overhead of object.__eq__ call 2022-05-05 16:14:15 +09:00
K. Lange
5df1469ba1 Optimized method invoke 2022-05-05 11:41:05 +09:00
K. Lange
d947e1aba3 Add bound method call test to benchmark suite 2022-05-05 08:23:49 +09:00
K. Lange
f8139f9352 Add versions, local Kuroko to benchmark 2022-05-05 08:23:40 +09:00
K. Lange
246316ad59 v1.2.5 2022-05-03 16:49:58 +09:00
K. Lange
6613db6cd4 Implement slice objects, slice stepping
This is an initial implementation of slice stepping and slice objects.
The __getslice__, __setslice__, and __delslice__ methods have been removed.
Slice expressions are now turned into slice objects with the OP_SLICE instruction.
Slice objects have a start, end, and step, all of which default to None.
Slice objects are passed to __getitem__, et al., as a normal parameter.

Support for slices in list.__getitem__, str.__getitem__, and bytes.__getitem__ has
been implemented.
2022-05-03 16:49:58 +09:00
K. Lange
c750f76a57 Assign non-None REPL results to __builtins__._ 2022-04-13 22:34:45 -04:00
K. Lange
c5b95645a7 Support KUROKOPATH similar to PYTHONPATH 2022-03-31 18:01:12 +09:00
K. Lange
dbd1071bc1 Internalize random's rng, seed it with more bits 2022-03-29 10:17:36 +09:00
K. Lange
e815497555 Fixup bad recursive locks in list functions? 2022-03-29 09:42:56 +09:00
K. Lange
73bfd17364 Improve some common string manipulation functions 2022-03-27 20:50:16 +09:00
K. Lange
b651f96094 Add random.seed 2022-03-27 16:32:12 +09:00
K. Lange
4c96839d1b Add os.get_terminal_size 2022-03-27 16:25:30 +09:00
K. Lange
799952c298 Fix str.replace when replacement string contains nil bytes 2022-03-24 10:23:52 +09:00
K. Lange
e24ea3d32c Fix incorrect handling of blank and comment lines before 'else', 'except', etc. 2022-02-17 09:49:24 +09:00
K. Lange
c1f2c7d9f3 Improve GC debug output and switch to a more aggressive strategy beyond 128MiB 2021-12-31 21:58:08 +09:00
K. Lange
38f3b6fa22 Allow 'del' on locals, upvalues as a shorthand for 'None' assignment 2021-12-31 21:57:25 +09:00
K. Lange
7c879c9675 Raise an exception on invalid sequence element lengths 2021-12-22 08:28:23 +09:00
K. Lange
7a7bb5662c Support sequence unpack for dict.__init__, fixes #23 2021-12-22 08:23:07 +09:00
K. Lange
e01ce6d93d Support {{ / }} in f-strings properly 2021-12-22 08:22:49 +09:00
K. Lange
c70cfb0533 Remove erroneously committed binaries? 2021-12-21 22:24:28 +09:00
K. Lange
836612fb75 Windows fixes 2021-12-20 16:49:44 +09:00
K. Lange
3f84dcbd86 Why am I even doing this 2021-12-20 16:44:02 +09:00
K. Lange
0cac488fae 1.2.4 2021-12-20 16:19:41 +09:00
K. Lange
773206680e add dict.values, dictvalues iterator 2021-12-20 16:16:11 +09:00
K. Lange
c4fced350e dict should be iterable; make __iter__() an alias to keys() 2021-12-20 16:09:28 +09:00
K. Lange
a81aa80420 os.exit 2021-12-20 16:06:15 +09:00
K. Lange
87dbc4fb80 int64_t is long long on at least aarch64 macos? 2021-12-17 13:39:08 +09:00
K. Lange
2c158f9491 Fixup bad cast when comparing int to float 2021-12-15 17:31:15 +09:00
K. Lange
abd49b93a7 Fix 'del' on table entries not updating count 2021-12-15 17:22:52 +09:00
K. Lange
6a431e9aa3 Add a test for that 2021-12-15 15:11:27 +09:00
K. Lange
89d3572a72 Mask argument name when compiling default expression (Fixes #24) 2021-12-15 15:09:54 +09:00
K. Lange
8fb1689e1d Return assigned values in list.__setitem__/dict.__setitem__ 2021-12-14 17:46:31 +09:00
K. Lange
c8b1df7056 gamma/lgamma are missing in emscripten 2021-12-12 15:41:56 +09:00
K. Lange
afef6e1042 Add builtin abs() 2021-12-08 22:56:04 +09:00
K. Lange
982240a986 Support keyword argument initialization for dicts 2021-12-07 07:30:01 +09:00
K. Lange
293ca155c5 Drop os.sync for now 2021-12-06 18:46:38 +09:00
K. Lange
180ecc6068 Stop trying to pick up math functions with ifdef as not everyone has them as macros 2021-12-06 18:06:16 +09:00
K. Lange
993bf78933 Maybe better to just use 'setenv' everywhere except Windows where it doesn't exist 2021-12-06 18:02:46 +09:00