Skip to content

Feat: @compiled is a builtin from the moment the interpreter starts - #62

Merged
b-re-w merged 2 commits into
developfrom
work/builtin-compiled
Oct 3, 2026
Merged

b-re-w merged 2 commits into
developfrom
work/builtin-compiled

Conversation

@b-re-w

@b-re-w b-re-w commented Oct 3, 2026

Copy link
Copy Markdown
Member

Closes #42

Python3.initialize installs builtins.compiled (identity, not overwriting an existing one), once, also on the already-initialised path; reset on finalize. BuiltinCompiledTest (commonTest): resolves without import, identity, existing value preserved.

Coordinator verification: desktopTest 550/0 (2 new), androidNative compile OK, app 70/0, artifact 35/0, compose 109 with one flaky pixel test under load (theHolderSurvivesARecomposition...) that passed twice on rerun.

b-re-w added 2 commits October 3, 2026 09:19
Python3.initialize installs builtins.compiled as an identity decorator once,
unless something already defined it (the TypedPython dev shim on plain
CPython does the same). User code marks compiled functions with no import;
the compiler picks them out at build time, so at run time it is a no-op.
@b-re-w
b-re-w merged commit f2eba65 into develop Oct 3, 2026
@b-re-w
b-re-w deleted the work/builtin-compiled branch October 3, 2026 00:20
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant