Commit Graph

909 Commits

Author SHA1 Message Date
K. Lange
dc91091de4 Build static archive; build static interpreter where possible 2021-04-09 21:50:44 +09:00
K. Lange
40dcc7e4ea Ignore .lo files 2021-04-09 21:45:27 +09:00
K. Lange
20eb921c55 Add an extra flag so we can force stuff external stuff to build without direct TLS references 2021-04-09 21:45:13 +09:00
K. Lange
744946f14b Get clang to stop complaining about fallthrough attribute 2021-04-09 21:44:47 +09:00
HarJIT
0ef38bb6ee
Corrected documentation for iso-2022-jp-ext (implementation unchanged) (#8) 2021-04-09 17:59:39 +09:00
K. Lange
562b3b4122 Update license flag when building deb package 2021-04-09 17:47:32 +09:00
K. Lange
8d6561831b Accede fully to MIT for license terms
Previously Kuroko as ISC with an additional copy of the MIT
terms attributing components based on _Crafting Interpreters_.
The MIT license remains more well known, and in Berne signatory
states (anywhere I'd be okay taking a vacation), is legally
equivalent to the ISC license and other licenses I use in
other places. Before anyone else contributes to core, I am
relicensing fully under just the MIT for cleanliness.
2021-04-09 17:42:25 +09:00
K. Lange
b5f3ad3309 Compact the opcode list since we ditched the operand encoding 2021-04-09 16:43:38 +09:00
K. Lange
a932147ceb Inline better operand collectors 2021-04-09 14:41:23 +09:00
K. Lange
76264c5e35 Simplify stack push/pop for potentially better inlining? 2021-04-08 21:04:03 +09:00
K. Lange
8a289a25d8 Mark krk_runtimeError as a format string function 2021-04-08 21:02:16 +09:00
K. Lange
42fdb59321 Minor cleanup 2021-04-08 20:23:22 +09:00
K. Lange
33e0b295f1 Remove unused OP_INC 2021-04-08 08:43:03 +09:00
K. Lange
817140dac1 Reset the parser when starting a new source compilation 2021-04-07 12:15:29 +09:00
K. Lange
fa3020143b Sporadic cleanup 2021-04-06 20:41:31 +09:00
K. Lange
1f76e7a846 Minimal support for raw string literals 2021-04-06 20:41:16 +09:00
K. Lange
b75ea1161e These microoptimizations will be the end of me 2021-04-06 18:36:43 +09:00
K. Lange
fdab54aa83 Add OP_CALL_ITER to perform iterator calls and compare values in place 2021-04-06 18:07:09 +09:00
K. Lange
59deaf18cb Add 'OP_UNSET' to emit KWARGS(0) values 2021-04-06 18:06:36 +09:00
K. Lange
6f6d16077e Remove redundant SET_LOCAL from iteration loops 2021-04-06 10:13:03 +09:00
K. Lange
45704dfdad Avoid growing lists by one element repeatedly when extending by an iterator 2021-04-05 20:34:36 +09:00
K. Lange
1e40e9b6ad Fix typo 2021-04-05 08:30:59 +09:00
K. Lange
438acaf8a9 Rename DEBUG to KRK_ENABLE_DEBUG to avoid conflicts with third-party libraries 2021-04-05 08:27:15 +09:00
K. Lange
6eec130313 Add a few more build flags to disable functionality 2021-04-03 06:24:42 +09:00
K. Lange
80f1c598f3 Consistently use parseStrInt macro to parse ints 2021-04-03 06:24:19 +09:00
K. Lange
10ea9030bb Quick flag to force-disable threads 2021-04-02 20:10:08 +09:00
K. Lange
03ff93beb7 Don't reference dl* when building with STATIC_ONLY 2021-04-02 19:59:32 +09:00
K. Lange
9a5f738b93 v1.1.0-rc0 2021-04-02 17:24:16 +09:00
HarJIT
614193b8a1
Codecs package docs, as well as some assorted tweaks or minor additions (#5)
* Add some docs, and remove second Code page 874 codec (they handled the
non-overridden C1 area differently, but we only need one).

* More docs work.

* Doc stuff.

* Adjusted.

* More tweaks (table padding is not the docstring's problem).

* CSS and docstring tweaks.

* Link from modules to parent packages and vice versa.

* More documentation.

* Docstrings for all `codecs` submodules.

* Move encode_jis7_reduced into dbextra_data_7bit (thus completing the lazy
startup which was apparently not complete already) and docstrings added to
implementations of base class methods referring up to the base class.

* Remove FUSE junk that somehow made it into the repo.

* Some more docstrings.

* Fix some broken references to `string` (rather than `data`) which would have
caused a problem if any existing error handler had returned a negative
offset (which no current handler does, but it's worth fixing anyway).

* Add a cp042 codec to accompany the x-user-defined codec, and to pave the
way for maybe adding Adobe Symbol, Zapf Dingbats or Wingdings codecs
in future.

* Better Japanese Autodetect behaviour for ISO-2022-JP (add yet another
condition in which it will be detected, making it able to conclusively
detect it prior to end of stream without being fed an entire escape
sequence in one call). Also some docs tweaks.

* idstr() → _idstr() since it's internal.

* Docs for codecs.pifonts.

* Docstrings for dbextra.

* Document the sbextra classes.

* Docstrings for the web encodings.

* Possibly a fairer assessment of likely reality.

* Docstrings for codecs.binascii

* The *encoding* isn't removed (the BOM is).

* Make it clearer when competing OEM code pages use different letter layouts.

* Fix copied in error.

* Stop generating linking to non-existent "← tools" from tools.gendoc.

* Move .fuse_hidden* exclusion to my user-level config.

* Constrain the table style changes to class .markdownTable, to avoid any
effect on other interface tables generated by Doxygen.

* Refer to `__ispackage__` when generating help.
2021-04-02 16:34:10 +09:00
K. Lange
0fd2849fd8 undef unrequested bool macro to _Bool... 2021-04-02 16:23:11 +09:00
K. Lange
40836cba21 Implement Python 3 division semantics 2021-04-02 16:02:05 +09:00
K. Lange
a90ca22f4c Track library handles in modules so we can dlclose what we dlopen 2021-04-02 13:30:34 +09:00
K. Lange
06bb0fdefb str.__mul__ should takeString, not copyString 2021-04-02 13:07:54 +09:00
K. Lange
dc361af48b Fix incorrect binding of classmethod when called on instance of subclass 2021-04-02 12:25:07 +09:00
K Lange
ea443f11df Update README section on async/await 2021-04-01 20:53:47 +09:00
K. Lange
dae6ce8925 Fixups for things ubsan is complaining about 2021-04-01 12:16:42 +09:00
K. Lange
7142abf955 Add codeobject.co_flags with Python-compatible values 2021-03-31 20:16:15 +09:00
K. Lange
002412ecf8 Initial support for async/await 2021-03-31 19:27:13 +09:00
K. Lange
f4ea799d42 Fix generator not being popped from stack on 'yield from' 2021-03-31 19:09:06 +09:00
K. Lange
d307de84c0 Fixup repl tab completion to use krk_valueGetAttribute_default 2021-03-31 16:09:45 +09:00
K. Lange
96cb0a1da5 Fix up some doxygen things 2021-03-30 20:26:36 +09:00
K. Lange
9a8a5d2cad Highlight NotImplemented as a built-in 2021-03-30 19:22:32 +09:00
K. Lange
4f1e6a10e0 Simplify krk_valuesEqual 2021-03-30 17:27:32 +09:00
K. Lange
729220568e Try swapping args to __eq__ on NotImplemented 2021-03-30 17:00:23 +09:00
K. Lange
70d5f1b2b7 Implement NotImplemented, fallback operators
Adds 'NOTIMPL' as a new primitive value, available from
__builtins__.NotImplemented. Adds support for inverse /
reflected overrides for binary operators. Adds opcodes
for LESS_EQUAL and GREATER_EQUAL.
2021-03-30 16:42:29 +09:00
K. Lange
873daa1f67 Improve some syntax errors 2021-03-30 14:18:39 +09:00
K. Lange
006119cc1e Support arguments to super(), support outside of classes 2021-03-30 14:18:39 +09:00
K. Lange
1c5c2577e9 Make 'self' not a keyword
It's still implicitly the first argument to a method and can not be
used in a method signature outside of the first argument, which is
ignored in the compiler. Actually, we allowed 'self' to be quietly
stuck in other slots but now we should correctly error on it.
2021-03-30 12:28:16 +09:00
K. Lange
84817c45cf Add more docstrings to builtins 2021-03-29 10:39:40 +09:00
K. Lange
db1275d57f Fix typo in docstring for builtins module 2021-03-29 09:27:18 +09:00