pytron-kit 0.3.12__py3-none-macosx_11_0_universal2.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- pytron/__init__.py +112 -0
- pytron/application.py +562 -0
- pytron/apputils/__init__.py +0 -0
- pytron/apputils/chrome_ipc.py +203 -0
- pytron/apputils/codegen.py +261 -0
- pytron/apputils/config.py +303 -0
- pytron/apputils/deadmansswitch.py +47 -0
- pytron/apputils/extras.py +76 -0
- pytron/apputils/native.py +148 -0
- pytron/apputils/shell.py +73 -0
- pytron/apputils/windows.py +286 -0
- pytron/cli.py +384 -0
- pytron/commands/__init__.py +0 -0
- pytron/commands/android.py +28 -0
- pytron/commands/build.py +26 -0
- pytron/commands/doctor.py +221 -0
- pytron/commands/engine.py +23 -0
- pytron/commands/frontend.py +60 -0
- pytron/commands/harvest.py +112 -0
- pytron/commands/helpers.py +239 -0
- pytron/commands/info.py +50 -0
- pytron/commands/init.py +521 -0
- pytron/commands/install.py +294 -0
- pytron/commands/login.py +130 -0
- pytron/commands/package.py +228 -0
- pytron/commands/plugin.py +442 -0
- pytron/commands/run.py +312 -0
- pytron/commands/scan.py +210 -0
- pytron/commands/show.py +23 -0
- pytron/commands/uninstall.py +150 -0
- pytron/commands/utils.py +42 -0
- pytron/commands/workflow.py +95 -0
- pytron/console.py +133 -0
- pytron/core.py +18 -0
- pytron/dependencies/WebView2Loader.dll +0 -0
- pytron/dependencies/__init__.py +1 -0
- pytron/dependencies/pytron_native.so +0 -0
- pytron/engines/chrome/adapter.py +445 -0
- pytron/engines/chrome/engine.py +576 -0
- pytron/engines/chrome/forge.py +147 -0
- pytron/engines/chrome/shell/package.json +8 -0
- pytron/engines/chrome/shell/preload.js +12 -0
- pytron/engines/chrome/shell/shell.js +534 -0
- pytron/exceptions.py +36 -0
- pytron/inspector.py +201 -0
- pytron/inspector_ui.py +512 -0
- pytron/installer/Installation.nsi +236 -0
- pytron/installer/header.bmp +0 -0
- pytron/installer/pytron.ico +0 -0
- pytron/installer/sidebar.bmp +0 -0
- pytron/llms.md +98 -0
- pytron/manifests/README.md +29 -0
- pytron/manifests/windows-utf8.manifest +44 -0
- pytron/menu.py +128 -0
- pytron/nsis-setup.exe +0 -0
- pytron/pack/__init__.py +0 -0
- pytron/pack/assets.py +131 -0
- pytron/pack/compilers.py +289 -0
- pytron/pack/crystal.py +297 -0
- pytron/pack/graph.py +377 -0
- pytron/pack/inference.py +157 -0
- pytron/pack/installers.py +402 -0
- pytron/pack/introspect.py +357 -0
- pytron/pack/metadata.py +213 -0
- pytron/pack/modules.py +618 -0
- pytron/pack/nuitka.py +108 -0
- pytron/pack/pipeline.py +107 -0
- pytron/pack/pyinstaller.py +176 -0
- pytron/pack/rust_engine.py +273 -0
- pytron/pack/secure.py +309 -0
- pytron/pack/secure_loader/bin/pytron_rust_bootloader +0 -0
- pytron/pack/secure_loader/icon.ico +0 -0
- pytron/pack/utils.py +110 -0
- pytron/pack/virtual_root.py +124 -0
- pytron/platforms/__init__.py +0 -0
- pytron/platforms/android/__init__.py +3 -0
- pytron/platforms/android/android.py +103 -0
- pytron/platforms/android/builder.py +736 -0
- pytron/platforms/android/ops/build.py +79 -0
- pytron/platforms/android/ops/init.py +63 -0
- pytron/platforms/android/ops/run.py +79 -0
- pytron/platforms/android/ops/sync.py +770 -0
- pytron/platforms/android/ops/utils.py +8 -0
- pytron/platforms/android/shell/README.md +30 -0
- pytron/platforms/android/shell/app/build.gradle +64 -0
- pytron/platforms/android/shell/app/src/main/AndroidManifest.xml +29 -0
- pytron/platforms/android/shell/app/src/main/assets/python/main.py +86 -0
- pytron/platforms/android/shell/app/src/main/assets/python/python314.zip +0 -0
- pytron/platforms/android/shell/app/src/main/cpp/CMakeLists.txt +25 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/Python.h +155 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/abstract.h +915 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/audit.h +30 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/bltinmodule.h +14 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/boolobject.h +54 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/bytearrayobject.h +44 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/bytesobject.h +66 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/ceval.h +145 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/codecs.h +176 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/compile.h +22 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/complexobject.h +30 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/abstract.h +104 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/audit.h +8 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/bytearrayobject.h +38 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/bytesobject.h +42 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/cellobject.h +50 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/ceval.h +43 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/classobject.h +71 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/code.h +340 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/compile.h +50 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/complexobject.h +33 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/context.h +107 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/critical_section.h +154 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/descrobject.h +62 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/dictobject.h +105 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/fileobject.h +16 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/fileutils.h +16 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/floatobject.h +27 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/frameobject.h +35 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/funcobject.h +185 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/genobject.h +56 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/import.h +30 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/initconfig.h +334 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/listobject.h +53 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/lock.h +74 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/longintrepr.h +184 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/longobject.h +89 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/memoryobject.h +50 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/methodobject.h +66 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/modsupport.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/monitoring.h +269 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/object.h +493 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/objimpl.h +104 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/odictobject.h +43 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/picklebufobject.h +31 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pthread_stubs.h +105 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyatomic.h +614 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyatomic_gcc.h +615 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyatomic_msc.h +1197 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyatomic_std.h +1112 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyctype.h +39 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pydebug.h +38 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyerrors.h +132 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyfpe.h +15 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyframe.h +45 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pyhash.h +54 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pylifecycle.h +89 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pymem.h +84 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pystate.h +275 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pystats.h +194 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pythonrun.h +96 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pythread.h +43 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/pytime.h +27 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/setobject.h +71 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/traceback.h +13 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/tracemalloc.h +32 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/tupleobject.h +40 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/unicodeobject.h +773 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/warnings.h +20 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/cpython/weakrefobject.h +66 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/critical_section.h +16 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/datetime.h +267 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/descrobject.h +100 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/dictobject.h +108 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/dynamic_annotations.h +499 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/enumobject.h +17 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/errcode.h +45 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/exports.h +105 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/fileobject.h +41 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/fileutils.h +62 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/floatobject.h +54 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/frameobject.h +20 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/genericaliasobject.h +14 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/import.h +103 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/mimalloc/mimalloc/atomic.h +392 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/mimalloc/mimalloc/internal.h +969 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/mimalloc/mimalloc/prim.h +329 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/mimalloc/mimalloc/track.h +147 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/mimalloc/mimalloc/types.h +721 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/mimalloc/mimalloc.h +565 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_abstract.h +61 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_asdl.h +112 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_ast.h +945 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_ast_state.h +271 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_atexit.h +31 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_audit.h +35 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_backoff.h +133 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_bitutils.h +186 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_blocks_output_buffer.h +321 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_brc.h +73 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_bytes_methods.h +82 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_bytesobject.h +149 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_c_array.h +39 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_call.h +206 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_capsule.h +17 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_cell.h +75 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_ceval.h +390 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_ceval_state.h +48 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_code.h +671 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_codecs.h +76 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_compile.h +230 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_complexobject.h +34 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_condvar.h +93 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_context.h +59 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_critical_section.h +237 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_crossinterp.h +406 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_crossinterp_data_registry.h +41 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_debug_offsets.h +379 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_descrobject.h +28 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_dict.h +410 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_dict_state.h +28 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_dtoa.h +40 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_emscripten_signal.h +30 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_emscripten_trampoline.h +70 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_exceptions.h +40 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_faulthandler.h +100 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_fileutils.h +320 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_fileutils_windows.h +98 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_floatobject.h +49 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_flowgraph.h +47 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_format.h +27 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_frame.h +61 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_freelist.h +111 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_freelist_state.h +70 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_function.h +53 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_gc.h +378 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_genobject.h +43 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_getopt.h +22 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_gil.h +66 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_global_objects.h +34 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_global_objects_fini_generated.h +1592 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_global_strings.h +854 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_hamt.h +113 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_hashtable.h +150 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_import.h +141 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_importdl.h +139 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_index_pool.h +36 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_initconfig.h +197 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_instruction_sequence.h +83 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_instruments.h +127 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_interp.h +109 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_interp_structs.h +977 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_interpframe.h +401 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_interpframe_structs.h +95 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_interpolation.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_intrinsics.h +51 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_jit.h +29 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_list.h +81 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_llist.h +106 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_lock.h +236 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_long.h +319 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_magic_number.h +305 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_memoryobject.h +20 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_mimalloc.h +69 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_modsupport.h +99 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_moduleobject.h +62 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_namespace.h +21 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_object.h +1029 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_object_alloc.h +71 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_object_deferred.h +32 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_object_stack.h +95 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_object_state.h +49 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_obmalloc.h +702 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_obmalloc_init.h +66 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_opcode_metadata.h +2117 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_opcode_utils.h +90 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_optimizer.h +318 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_parking_lot.h +97 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_parser.h +78 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pathconfig.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pyarena.h +68 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pyatomic_ft_wrappers.h +174 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pybuffer.h +21 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pyerrors.h +213 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pyhash.h +91 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pylifecycle.h +136 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pymath.h +205 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pymem.h +145 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pymem_init.h +103 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pystate.h +339 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pystats.h +21 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pythonrun.h +68 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_pythread.h +172 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_qsbr.h +172 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_range.h +21 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_runtime.h +63 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_runtime_init.h +239 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_runtime_init_generated.h +1589 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_runtime_structs.h +310 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_semaphore.h +67 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_setobject.h +41 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_signal.h +108 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_sliceobject.h +20 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_stackref.h +791 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_stats.h +97 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_strhex.h +39 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_structs.h +88 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_structseq.h +40 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_symtable.h +201 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_sysmodule.h +32 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_template.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_time.h +334 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_token.h +110 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_traceback.h +111 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_tracemalloc.h +164 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_tstate.h +88 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_tuple.h +75 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_typedefs.h +18 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_typeobject.h +155 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_typevarobject.h +28 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_ucnhash.h +36 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_unicodeobject.h +308 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_unicodeobject_generated.h +3132 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_unionobject.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_uniqueid.h +57 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_uop_ids.h +335 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_uop_metadata.h +1204 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_warnings.h +21 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/internal/pycore_weakref.h +133 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/intrcheck.h +23 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/iterobject.h +24 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/listobject.h +55 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/lock.h +16 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/longobject.h +178 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/marshal.h +31 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/memoryobject.h +34 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/methodobject.h +146 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/modsupport.h +146 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/moduleobject.h +122 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/monitoring.h +18 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/object.h +828 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/objimpl.h +211 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/opcode.h +43 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/opcode_ids.h +259 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/osdefs.h +57 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/osmodule.h +17 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/patchlevel.h +49 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/py_curses.h +117 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyatomic.h +16 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pybuffer.h +145 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pycapsule.h +58 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyconfig.h +2088 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pydtrace.h +59 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyerrors.h +335 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyexpat.h +62 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyframe.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyhash.h +59 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pylifecycle.h +80 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pymacconfig.h +91 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pymacro.h +243 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pymath.h +65 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pymem.h +110 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pyport.h +710 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pystate.h +132 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pystats.h +28 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pystrcmp.h +23 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pystrtod.h +37 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pythonrun.h +42 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pythread.h +131 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/pytypedefs.h +30 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/rangeobject.h +27 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/refcount.h +555 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/setobject.h +49 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/sliceobject.h +69 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/structmember.h +56 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/structseq.h +46 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/sysmodule.h +27 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/traceback.h +26 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/tupleobject.h +46 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/typeslots.h +96 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/unicodeobject.h +1029 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/warnings.h +45 -0
- pytron/platforms/android/shell/app/src/main/cpp/include/weakrefobject.h +46 -0
- pytron/platforms/android/shell/app/src/main/cpp/pytron_bridge.cpp +224 -0
- pytron/platforms/android/shell/app/src/main/java/com/pytron/shell/MainActivity.kt +208 -0
- pytron/platforms/android/shell/app/src/main/res/mipmap-xxhdpi/ic_launcher.png +0 -0
- pytron/platforms/android/shell/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png +0 -0
- pytron/platforms/android/shell/build.gradle +11 -0
- pytron/platforms/android/shell/gradle/wrapper/gradle-wrapper.jar +0 -0
- pytron/platforms/android/shell/gradle/wrapper/gradle-wrapper.properties +5 -0
- pytron/platforms/android/shell/gradle.properties +2 -0
- pytron/platforms/android/shell/gradlew.bat +85 -0
- pytron/platforms/android/shell/settings.gradle +16 -0
- pytron/platforms/darwin.py +82 -0
- pytron/platforms/darwin_ops/libs.py +31 -0
- pytron/platforms/darwin_ops/system.py +182 -0
- pytron/platforms/darwin_ops/utils.py +85 -0
- pytron/platforms/darwin_ops/webview.py +5 -0
- pytron/platforms/darwin_ops/window.py +102 -0
- pytron/platforms/interface.py +152 -0
- pytron/platforms/linux.py +82 -0
- pytron/platforms/linux_ops/libs.py +49 -0
- pytron/platforms/linux_ops/system.py +316 -0
- pytron/platforms/linux_ops/utils.py +19 -0
- pytron/platforms/linux_ops/webview.py +5 -0
- pytron/platforms/linux_ops/window.py +115 -0
- pytron/platforms/windows.py +136 -0
- pytron/platforms/windows_ops/__init__.py +0 -0
- pytron/platforms/windows_ops/constants.py +126 -0
- pytron/platforms/windows_ops/system.py +518 -0
- pytron/platforms/windows_ops/utils.py +3 -0
- pytron/platforms/windows_ops/webview.py +5 -0
- pytron/platforms/windows_ops/window.py +361 -0
- pytron/plugin.py +467 -0
- pytron/rcedit-x64.exe +0 -0
- pytron/router.py +146 -0
- pytron/serializer.py +240 -0
- pytron/shortcuts.py +279 -0
- pytron/state.py +76 -0
- pytron/tray.py +399 -0
- pytron/updater.py +181 -0
- pytron/utf8_hook.py +112 -0
- pytron/utils.py +44 -0
- pytron/webview.py +722 -0
- pytron_kit-0.3.12.dist-info/METADATA +131 -0
- pytron_kit-0.3.12.dist-info/RECORD +419 -0
- pytron_kit-0.3.12.dist-info/WHEEL +5 -0
- pytron_kit-0.3.12.dist-info/entry_points.txt +2 -0
- pytron_kit-0.3.12.dist-info/licenses/LICENSE +201 -0
- pytron_kit-0.3.12.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
/* Static DTrace probes interface */
|
|
2
|
+
|
|
3
|
+
#ifndef Py_DTRACE_H
|
|
4
|
+
#define Py_DTRACE_H
|
|
5
|
+
#ifdef __cplusplus
|
|
6
|
+
extern "C" {
|
|
7
|
+
#endif
|
|
8
|
+
|
|
9
|
+
#ifdef WITH_DTRACE
|
|
10
|
+
|
|
11
|
+
#include "pydtrace_probes.h"
|
|
12
|
+
|
|
13
|
+
/* pydtrace_probes.h, on systems with DTrace, is auto-generated to include
|
|
14
|
+
`PyDTrace_{PROBE}` and `PyDTrace_{PROBE}_ENABLED()` macros for every probe
|
|
15
|
+
defined in pydtrace.d.
|
|
16
|
+
|
|
17
|
+
Calling these functions must be guarded by a `PyDTrace_{PROBE}_ENABLED()`
|
|
18
|
+
check to minimize performance impact when probing is off. For example:
|
|
19
|
+
|
|
20
|
+
if (PyDTrace_FUNCTION_ENTRY_ENABLED())
|
|
21
|
+
PyDTrace_FUNCTION_ENTRY(f);
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
#else
|
|
25
|
+
|
|
26
|
+
/* Without DTrace, compile to nothing. */
|
|
27
|
+
|
|
28
|
+
static inline void PyDTrace_LINE(const char *arg0, const char *arg1, int arg2) {}
|
|
29
|
+
static inline void PyDTrace_FUNCTION_ENTRY(const char *arg0, const char *arg1, int arg2) {}
|
|
30
|
+
static inline void PyDTrace_FUNCTION_RETURN(const char *arg0, const char *arg1, int arg2) {}
|
|
31
|
+
static inline void PyDTrace_GC_START(int arg0) {}
|
|
32
|
+
static inline void PyDTrace_GC_DONE(Py_ssize_t arg0) {}
|
|
33
|
+
static inline void PyDTrace_INSTANCE_NEW_START(int arg0) {}
|
|
34
|
+
static inline void PyDTrace_INSTANCE_NEW_DONE(int arg0) {}
|
|
35
|
+
static inline void PyDTrace_INSTANCE_DELETE_START(int arg0) {}
|
|
36
|
+
static inline void PyDTrace_INSTANCE_DELETE_DONE(int arg0) {}
|
|
37
|
+
static inline void PyDTrace_IMPORT_FIND_LOAD_START(const char *arg0) {}
|
|
38
|
+
static inline void PyDTrace_IMPORT_FIND_LOAD_DONE(const char *arg0, int arg1) {}
|
|
39
|
+
static inline void PyDTrace_AUDIT(const char *arg0, void *arg1) {}
|
|
40
|
+
|
|
41
|
+
static inline int PyDTrace_LINE_ENABLED(void) { return 0; }
|
|
42
|
+
static inline int PyDTrace_FUNCTION_ENTRY_ENABLED(void) { return 0; }
|
|
43
|
+
static inline int PyDTrace_FUNCTION_RETURN_ENABLED(void) { return 0; }
|
|
44
|
+
static inline int PyDTrace_GC_START_ENABLED(void) { return 0; }
|
|
45
|
+
static inline int PyDTrace_GC_DONE_ENABLED(void) { return 0; }
|
|
46
|
+
static inline int PyDTrace_INSTANCE_NEW_START_ENABLED(void) { return 0; }
|
|
47
|
+
static inline int PyDTrace_INSTANCE_NEW_DONE_ENABLED(void) { return 0; }
|
|
48
|
+
static inline int PyDTrace_INSTANCE_DELETE_START_ENABLED(void) { return 0; }
|
|
49
|
+
static inline int PyDTrace_INSTANCE_DELETE_DONE_ENABLED(void) { return 0; }
|
|
50
|
+
static inline int PyDTrace_IMPORT_FIND_LOAD_START_ENABLED(void) { return 0; }
|
|
51
|
+
static inline int PyDTrace_IMPORT_FIND_LOAD_DONE_ENABLED(void) { return 0; }
|
|
52
|
+
static inline int PyDTrace_AUDIT_ENABLED(void) { return 0; }
|
|
53
|
+
|
|
54
|
+
#endif /* !WITH_DTRACE */
|
|
55
|
+
|
|
56
|
+
#ifdef __cplusplus
|
|
57
|
+
}
|
|
58
|
+
#endif
|
|
59
|
+
#endif /* !Py_DTRACE_H */
|
|
@@ -0,0 +1,335 @@
|
|
|
1
|
+
// Error handling definitions
|
|
2
|
+
|
|
3
|
+
#ifndef Py_ERRORS_H
|
|
4
|
+
#define Py_ERRORS_H
|
|
5
|
+
#ifdef __cplusplus
|
|
6
|
+
extern "C" {
|
|
7
|
+
#endif
|
|
8
|
+
|
|
9
|
+
PyAPI_FUNC(void) PyErr_SetNone(PyObject *);
|
|
10
|
+
PyAPI_FUNC(void) PyErr_SetObject(PyObject *, PyObject *);
|
|
11
|
+
PyAPI_FUNC(void) PyErr_SetString(
|
|
12
|
+
PyObject *exception,
|
|
13
|
+
const char *string /* decoded from utf-8 */
|
|
14
|
+
);
|
|
15
|
+
PyAPI_FUNC(PyObject *) PyErr_Occurred(void);
|
|
16
|
+
PyAPI_FUNC(void) PyErr_Clear(void);
|
|
17
|
+
PyAPI_FUNC(void) PyErr_Fetch(PyObject **, PyObject **, PyObject **);
|
|
18
|
+
PyAPI_FUNC(void) PyErr_Restore(PyObject *, PyObject *, PyObject *);
|
|
19
|
+
PyAPI_FUNC(PyObject *) PyErr_GetRaisedException(void);
|
|
20
|
+
PyAPI_FUNC(void) PyErr_SetRaisedException(PyObject *);
|
|
21
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030b0000
|
|
22
|
+
PyAPI_FUNC(PyObject*) PyErr_GetHandledException(void);
|
|
23
|
+
PyAPI_FUNC(void) PyErr_SetHandledException(PyObject *);
|
|
24
|
+
#endif
|
|
25
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03030000
|
|
26
|
+
PyAPI_FUNC(void) PyErr_GetExcInfo(PyObject **, PyObject **, PyObject **);
|
|
27
|
+
PyAPI_FUNC(void) PyErr_SetExcInfo(PyObject *, PyObject *, PyObject *);
|
|
28
|
+
#endif
|
|
29
|
+
|
|
30
|
+
/* Defined in Python/pylifecycle.c
|
|
31
|
+
|
|
32
|
+
The Py_FatalError() function is replaced with a macro which logs
|
|
33
|
+
automatically the name of the current function, unless the Py_LIMITED_API
|
|
34
|
+
macro is defined. */
|
|
35
|
+
PyAPI_FUNC(void) _Py_NO_RETURN Py_FatalError(const char *message);
|
|
36
|
+
|
|
37
|
+
/* Error testing and normalization */
|
|
38
|
+
PyAPI_FUNC(int) PyErr_GivenExceptionMatches(PyObject *, PyObject *);
|
|
39
|
+
PyAPI_FUNC(int) PyErr_ExceptionMatches(PyObject *);
|
|
40
|
+
PyAPI_FUNC(void) PyErr_NormalizeException(PyObject**, PyObject**, PyObject**);
|
|
41
|
+
|
|
42
|
+
/* Traceback manipulation (PEP 3134) */
|
|
43
|
+
PyAPI_FUNC(int) PyException_SetTraceback(PyObject *, PyObject *);
|
|
44
|
+
PyAPI_FUNC(PyObject *) PyException_GetTraceback(PyObject *);
|
|
45
|
+
|
|
46
|
+
/* Cause manipulation (PEP 3134) */
|
|
47
|
+
PyAPI_FUNC(PyObject *) PyException_GetCause(PyObject *);
|
|
48
|
+
PyAPI_FUNC(void) PyException_SetCause(PyObject *, PyObject *);
|
|
49
|
+
|
|
50
|
+
/* Context manipulation (PEP 3134) */
|
|
51
|
+
PyAPI_FUNC(PyObject *) PyException_GetContext(PyObject *);
|
|
52
|
+
PyAPI_FUNC(void) PyException_SetContext(PyObject *, PyObject *);
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
PyAPI_FUNC(PyObject *) PyException_GetArgs(PyObject *);
|
|
56
|
+
PyAPI_FUNC(void) PyException_SetArgs(PyObject *, PyObject *);
|
|
57
|
+
|
|
58
|
+
/* */
|
|
59
|
+
|
|
60
|
+
#define PyExceptionClass_Check(x) \
|
|
61
|
+
(PyType_Check((x)) && \
|
|
62
|
+
PyType_FastSubclass((PyTypeObject*)(x), Py_TPFLAGS_BASE_EXC_SUBCLASS))
|
|
63
|
+
|
|
64
|
+
#define PyExceptionInstance_Check(x) \
|
|
65
|
+
PyType_FastSubclass(Py_TYPE(x), Py_TPFLAGS_BASE_EXC_SUBCLASS)
|
|
66
|
+
|
|
67
|
+
PyAPI_FUNC(const char *) PyExceptionClass_Name(PyObject *);
|
|
68
|
+
|
|
69
|
+
#define PyExceptionInstance_Class(x) _PyObject_CAST(Py_TYPE(x))
|
|
70
|
+
|
|
71
|
+
#define _PyBaseExceptionGroup_Check(x) \
|
|
72
|
+
PyObject_TypeCheck((x), (PyTypeObject *)PyExc_BaseExceptionGroup)
|
|
73
|
+
|
|
74
|
+
/* Predefined exceptions */
|
|
75
|
+
|
|
76
|
+
PyAPI_DATA(PyObject *) PyExc_BaseException;
|
|
77
|
+
PyAPI_DATA(PyObject *) PyExc_Exception;
|
|
78
|
+
PyAPI_DATA(PyObject *) PyExc_BaseExceptionGroup;
|
|
79
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000
|
|
80
|
+
PyAPI_DATA(PyObject *) PyExc_StopAsyncIteration;
|
|
81
|
+
#endif
|
|
82
|
+
PyAPI_DATA(PyObject *) PyExc_StopIteration;
|
|
83
|
+
PyAPI_DATA(PyObject *) PyExc_GeneratorExit;
|
|
84
|
+
PyAPI_DATA(PyObject *) PyExc_ArithmeticError;
|
|
85
|
+
PyAPI_DATA(PyObject *) PyExc_LookupError;
|
|
86
|
+
|
|
87
|
+
PyAPI_DATA(PyObject *) PyExc_AssertionError;
|
|
88
|
+
PyAPI_DATA(PyObject *) PyExc_AttributeError;
|
|
89
|
+
PyAPI_DATA(PyObject *) PyExc_BufferError;
|
|
90
|
+
PyAPI_DATA(PyObject *) PyExc_EOFError;
|
|
91
|
+
PyAPI_DATA(PyObject *) PyExc_FloatingPointError;
|
|
92
|
+
PyAPI_DATA(PyObject *) PyExc_OSError;
|
|
93
|
+
PyAPI_DATA(PyObject *) PyExc_ImportError;
|
|
94
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03060000
|
|
95
|
+
PyAPI_DATA(PyObject *) PyExc_ModuleNotFoundError;
|
|
96
|
+
#endif
|
|
97
|
+
PyAPI_DATA(PyObject *) PyExc_IndexError;
|
|
98
|
+
PyAPI_DATA(PyObject *) PyExc_KeyError;
|
|
99
|
+
PyAPI_DATA(PyObject *) PyExc_KeyboardInterrupt;
|
|
100
|
+
PyAPI_DATA(PyObject *) PyExc_MemoryError;
|
|
101
|
+
PyAPI_DATA(PyObject *) PyExc_NameError;
|
|
102
|
+
PyAPI_DATA(PyObject *) PyExc_OverflowError;
|
|
103
|
+
PyAPI_DATA(PyObject *) PyExc_RuntimeError;
|
|
104
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000
|
|
105
|
+
PyAPI_DATA(PyObject *) PyExc_RecursionError;
|
|
106
|
+
#endif
|
|
107
|
+
PyAPI_DATA(PyObject *) PyExc_NotImplementedError;
|
|
108
|
+
PyAPI_DATA(PyObject *) PyExc_SyntaxError;
|
|
109
|
+
PyAPI_DATA(PyObject *) PyExc_IndentationError;
|
|
110
|
+
PyAPI_DATA(PyObject *) PyExc_TabError;
|
|
111
|
+
PyAPI_DATA(PyObject *) PyExc_ReferenceError;
|
|
112
|
+
PyAPI_DATA(PyObject *) PyExc_SystemError;
|
|
113
|
+
PyAPI_DATA(PyObject *) PyExc_SystemExit;
|
|
114
|
+
PyAPI_DATA(PyObject *) PyExc_TypeError;
|
|
115
|
+
PyAPI_DATA(PyObject *) PyExc_UnboundLocalError;
|
|
116
|
+
PyAPI_DATA(PyObject *) PyExc_UnicodeError;
|
|
117
|
+
PyAPI_DATA(PyObject *) PyExc_UnicodeEncodeError;
|
|
118
|
+
PyAPI_DATA(PyObject *) PyExc_UnicodeDecodeError;
|
|
119
|
+
PyAPI_DATA(PyObject *) PyExc_UnicodeTranslateError;
|
|
120
|
+
PyAPI_DATA(PyObject *) PyExc_ValueError;
|
|
121
|
+
PyAPI_DATA(PyObject *) PyExc_ZeroDivisionError;
|
|
122
|
+
|
|
123
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03030000
|
|
124
|
+
PyAPI_DATA(PyObject *) PyExc_BlockingIOError;
|
|
125
|
+
PyAPI_DATA(PyObject *) PyExc_BrokenPipeError;
|
|
126
|
+
PyAPI_DATA(PyObject *) PyExc_ChildProcessError;
|
|
127
|
+
PyAPI_DATA(PyObject *) PyExc_ConnectionError;
|
|
128
|
+
PyAPI_DATA(PyObject *) PyExc_ConnectionAbortedError;
|
|
129
|
+
PyAPI_DATA(PyObject *) PyExc_ConnectionRefusedError;
|
|
130
|
+
PyAPI_DATA(PyObject *) PyExc_ConnectionResetError;
|
|
131
|
+
PyAPI_DATA(PyObject *) PyExc_FileExistsError;
|
|
132
|
+
PyAPI_DATA(PyObject *) PyExc_FileNotFoundError;
|
|
133
|
+
PyAPI_DATA(PyObject *) PyExc_InterruptedError;
|
|
134
|
+
PyAPI_DATA(PyObject *) PyExc_IsADirectoryError;
|
|
135
|
+
PyAPI_DATA(PyObject *) PyExc_NotADirectoryError;
|
|
136
|
+
PyAPI_DATA(PyObject *) PyExc_PermissionError;
|
|
137
|
+
PyAPI_DATA(PyObject *) PyExc_ProcessLookupError;
|
|
138
|
+
PyAPI_DATA(PyObject *) PyExc_TimeoutError;
|
|
139
|
+
#endif
|
|
140
|
+
|
|
141
|
+
|
|
142
|
+
/* Compatibility aliases */
|
|
143
|
+
PyAPI_DATA(PyObject *) PyExc_EnvironmentError;
|
|
144
|
+
PyAPI_DATA(PyObject *) PyExc_IOError;
|
|
145
|
+
#ifdef MS_WINDOWS
|
|
146
|
+
PyAPI_DATA(PyObject *) PyExc_WindowsError;
|
|
147
|
+
#endif
|
|
148
|
+
|
|
149
|
+
/* Predefined warning categories */
|
|
150
|
+
PyAPI_DATA(PyObject *) PyExc_Warning;
|
|
151
|
+
PyAPI_DATA(PyObject *) PyExc_UserWarning;
|
|
152
|
+
PyAPI_DATA(PyObject *) PyExc_DeprecationWarning;
|
|
153
|
+
PyAPI_DATA(PyObject *) PyExc_PendingDeprecationWarning;
|
|
154
|
+
PyAPI_DATA(PyObject *) PyExc_SyntaxWarning;
|
|
155
|
+
PyAPI_DATA(PyObject *) PyExc_RuntimeWarning;
|
|
156
|
+
PyAPI_DATA(PyObject *) PyExc_FutureWarning;
|
|
157
|
+
PyAPI_DATA(PyObject *) PyExc_ImportWarning;
|
|
158
|
+
PyAPI_DATA(PyObject *) PyExc_UnicodeWarning;
|
|
159
|
+
PyAPI_DATA(PyObject *) PyExc_BytesWarning;
|
|
160
|
+
PyAPI_DATA(PyObject *) PyExc_EncodingWarning;
|
|
161
|
+
PyAPI_DATA(PyObject *) PyExc_ResourceWarning;
|
|
162
|
+
|
|
163
|
+
|
|
164
|
+
/* Convenience functions */
|
|
165
|
+
|
|
166
|
+
PyAPI_FUNC(int) PyErr_BadArgument(void);
|
|
167
|
+
PyAPI_FUNC(PyObject *) PyErr_NoMemory(void);
|
|
168
|
+
PyAPI_FUNC(PyObject *) PyErr_SetFromErrno(PyObject *);
|
|
169
|
+
PyAPI_FUNC(PyObject *) PyErr_SetFromErrnoWithFilenameObject(
|
|
170
|
+
PyObject *, PyObject *);
|
|
171
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03040000
|
|
172
|
+
PyAPI_FUNC(PyObject *) PyErr_SetFromErrnoWithFilenameObjects(
|
|
173
|
+
PyObject *, PyObject *, PyObject *);
|
|
174
|
+
#endif
|
|
175
|
+
PyAPI_FUNC(PyObject *) PyErr_SetFromErrnoWithFilename(
|
|
176
|
+
PyObject *exc,
|
|
177
|
+
const char *filename /* decoded from the filesystem encoding */
|
|
178
|
+
);
|
|
179
|
+
|
|
180
|
+
PyAPI_FUNC(PyObject *) PyErr_Format(
|
|
181
|
+
PyObject *exception,
|
|
182
|
+
const char *format, /* ASCII-encoded string */
|
|
183
|
+
...
|
|
184
|
+
);
|
|
185
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03050000
|
|
186
|
+
PyAPI_FUNC(PyObject *) PyErr_FormatV(
|
|
187
|
+
PyObject *exception,
|
|
188
|
+
const char *format,
|
|
189
|
+
va_list vargs);
|
|
190
|
+
#endif
|
|
191
|
+
|
|
192
|
+
#ifdef MS_WINDOWS
|
|
193
|
+
PyAPI_FUNC(PyObject *) PyErr_SetFromWindowsErrWithFilename(
|
|
194
|
+
int ierr,
|
|
195
|
+
const char *filename /* decoded from the filesystem encoding */
|
|
196
|
+
);
|
|
197
|
+
PyAPI_FUNC(PyObject *) PyErr_SetFromWindowsErr(int);
|
|
198
|
+
PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErrWithFilenameObject(
|
|
199
|
+
PyObject *,int, PyObject *);
|
|
200
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03040000
|
|
201
|
+
PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErrWithFilenameObjects(
|
|
202
|
+
PyObject *,int, PyObject *, PyObject *);
|
|
203
|
+
#endif
|
|
204
|
+
PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErrWithFilename(
|
|
205
|
+
PyObject *exc,
|
|
206
|
+
int ierr,
|
|
207
|
+
const char *filename /* decoded from the filesystem encoding */
|
|
208
|
+
);
|
|
209
|
+
PyAPI_FUNC(PyObject *) PyErr_SetExcFromWindowsErr(PyObject *, int);
|
|
210
|
+
#endif /* MS_WINDOWS */
|
|
211
|
+
|
|
212
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03060000
|
|
213
|
+
PyAPI_FUNC(PyObject *) PyErr_SetImportErrorSubclass(PyObject *, PyObject *,
|
|
214
|
+
PyObject *, PyObject *);
|
|
215
|
+
#endif
|
|
216
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03030000
|
|
217
|
+
PyAPI_FUNC(PyObject *) PyErr_SetImportError(PyObject *, PyObject *,
|
|
218
|
+
PyObject *);
|
|
219
|
+
#endif
|
|
220
|
+
|
|
221
|
+
/* Export the old function so that the existing API remains available: */
|
|
222
|
+
PyAPI_FUNC(void) PyErr_BadInternalCall(void);
|
|
223
|
+
PyAPI_FUNC(void) _PyErr_BadInternalCall(const char *filename, int lineno);
|
|
224
|
+
/* Mask the old API with a call to the new API for code compiled under
|
|
225
|
+
Python 2.0: */
|
|
226
|
+
#define PyErr_BadInternalCall() _PyErr_BadInternalCall(__FILE__, __LINE__)
|
|
227
|
+
|
|
228
|
+
/* Function to create a new exception */
|
|
229
|
+
PyAPI_FUNC(PyObject *) PyErr_NewException(
|
|
230
|
+
const char *name, PyObject *base, PyObject *dict);
|
|
231
|
+
PyAPI_FUNC(PyObject *) PyErr_NewExceptionWithDoc(
|
|
232
|
+
const char *name, const char *doc, PyObject *base, PyObject *dict);
|
|
233
|
+
PyAPI_FUNC(void) PyErr_WriteUnraisable(PyObject *);
|
|
234
|
+
|
|
235
|
+
|
|
236
|
+
/* In signalmodule.c */
|
|
237
|
+
PyAPI_FUNC(int) PyErr_CheckSignals(void);
|
|
238
|
+
PyAPI_FUNC(void) PyErr_SetInterrupt(void);
|
|
239
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030A0000
|
|
240
|
+
PyAPI_FUNC(int) PyErr_SetInterruptEx(int signum);
|
|
241
|
+
#endif
|
|
242
|
+
|
|
243
|
+
/* Support for adding program text to SyntaxErrors */
|
|
244
|
+
PyAPI_FUNC(void) PyErr_SyntaxLocation(
|
|
245
|
+
const char *filename, /* decoded from the filesystem encoding */
|
|
246
|
+
int lineno);
|
|
247
|
+
PyAPI_FUNC(void) PyErr_SyntaxLocationEx(
|
|
248
|
+
const char *filename, /* decoded from the filesystem encoding */
|
|
249
|
+
int lineno,
|
|
250
|
+
int col_offset);
|
|
251
|
+
PyAPI_FUNC(PyObject *) PyErr_ProgramText(
|
|
252
|
+
const char *filename, /* decoded from the filesystem encoding */
|
|
253
|
+
int lineno);
|
|
254
|
+
|
|
255
|
+
/* The following functions are used to create and modify unicode
|
|
256
|
+
exceptions from C */
|
|
257
|
+
|
|
258
|
+
/* create a UnicodeDecodeError object */
|
|
259
|
+
PyAPI_FUNC(PyObject *) PyUnicodeDecodeError_Create(
|
|
260
|
+
const char *encoding, /* UTF-8 encoded string */
|
|
261
|
+
const char *object,
|
|
262
|
+
Py_ssize_t length,
|
|
263
|
+
Py_ssize_t start,
|
|
264
|
+
Py_ssize_t end,
|
|
265
|
+
const char *reason /* UTF-8 encoded string */
|
|
266
|
+
);
|
|
267
|
+
|
|
268
|
+
/* get the encoding attribute */
|
|
269
|
+
PyAPI_FUNC(PyObject *) PyUnicodeEncodeError_GetEncoding(PyObject *);
|
|
270
|
+
PyAPI_FUNC(PyObject *) PyUnicodeDecodeError_GetEncoding(PyObject *);
|
|
271
|
+
|
|
272
|
+
/* get the object attribute */
|
|
273
|
+
PyAPI_FUNC(PyObject *) PyUnicodeEncodeError_GetObject(PyObject *);
|
|
274
|
+
PyAPI_FUNC(PyObject *) PyUnicodeDecodeError_GetObject(PyObject *);
|
|
275
|
+
PyAPI_FUNC(PyObject *) PyUnicodeTranslateError_GetObject(PyObject *);
|
|
276
|
+
|
|
277
|
+
/* get the value of the start attribute (the int * may not be NULL)
|
|
278
|
+
return 0 on success, -1 on failure */
|
|
279
|
+
PyAPI_FUNC(int) PyUnicodeEncodeError_GetStart(PyObject *, Py_ssize_t *);
|
|
280
|
+
PyAPI_FUNC(int) PyUnicodeDecodeError_GetStart(PyObject *, Py_ssize_t *);
|
|
281
|
+
PyAPI_FUNC(int) PyUnicodeTranslateError_GetStart(PyObject *, Py_ssize_t *);
|
|
282
|
+
|
|
283
|
+
/* assign a new value to the start attribute
|
|
284
|
+
return 0 on success, -1 on failure */
|
|
285
|
+
PyAPI_FUNC(int) PyUnicodeEncodeError_SetStart(PyObject *, Py_ssize_t);
|
|
286
|
+
PyAPI_FUNC(int) PyUnicodeDecodeError_SetStart(PyObject *, Py_ssize_t);
|
|
287
|
+
PyAPI_FUNC(int) PyUnicodeTranslateError_SetStart(PyObject *, Py_ssize_t);
|
|
288
|
+
|
|
289
|
+
/* get the value of the end attribute (the int *may not be NULL)
|
|
290
|
+
return 0 on success, -1 on failure */
|
|
291
|
+
PyAPI_FUNC(int) PyUnicodeEncodeError_GetEnd(PyObject *, Py_ssize_t *);
|
|
292
|
+
PyAPI_FUNC(int) PyUnicodeDecodeError_GetEnd(PyObject *, Py_ssize_t *);
|
|
293
|
+
PyAPI_FUNC(int) PyUnicodeTranslateError_GetEnd(PyObject *, Py_ssize_t *);
|
|
294
|
+
|
|
295
|
+
/* assign a new value to the end attribute
|
|
296
|
+
return 0 on success, -1 on failure */
|
|
297
|
+
PyAPI_FUNC(int) PyUnicodeEncodeError_SetEnd(PyObject *, Py_ssize_t);
|
|
298
|
+
PyAPI_FUNC(int) PyUnicodeDecodeError_SetEnd(PyObject *, Py_ssize_t);
|
|
299
|
+
PyAPI_FUNC(int) PyUnicodeTranslateError_SetEnd(PyObject *, Py_ssize_t);
|
|
300
|
+
|
|
301
|
+
/* get the value of the reason attribute */
|
|
302
|
+
PyAPI_FUNC(PyObject *) PyUnicodeEncodeError_GetReason(PyObject *);
|
|
303
|
+
PyAPI_FUNC(PyObject *) PyUnicodeDecodeError_GetReason(PyObject *);
|
|
304
|
+
PyAPI_FUNC(PyObject *) PyUnicodeTranslateError_GetReason(PyObject *);
|
|
305
|
+
|
|
306
|
+
/* assign a new value to the reason attribute
|
|
307
|
+
return 0 on success, -1 on failure */
|
|
308
|
+
PyAPI_FUNC(int) PyUnicodeEncodeError_SetReason(
|
|
309
|
+
PyObject *exc,
|
|
310
|
+
const char *reason /* UTF-8 encoded string */
|
|
311
|
+
);
|
|
312
|
+
PyAPI_FUNC(int) PyUnicodeDecodeError_SetReason(
|
|
313
|
+
PyObject *exc,
|
|
314
|
+
const char *reason /* UTF-8 encoded string */
|
|
315
|
+
);
|
|
316
|
+
PyAPI_FUNC(int) PyUnicodeTranslateError_SetReason(
|
|
317
|
+
PyObject *exc,
|
|
318
|
+
const char *reason /* UTF-8 encoded string */
|
|
319
|
+
);
|
|
320
|
+
|
|
321
|
+
PyAPI_FUNC(int) PyOS_snprintf(char *str, size_t size, const char *format, ...)
|
|
322
|
+
Py_GCC_ATTRIBUTE((format(printf, 3, 4)));
|
|
323
|
+
PyAPI_FUNC(int) PyOS_vsnprintf(char *str, size_t size, const char *format, va_list va)
|
|
324
|
+
Py_GCC_ATTRIBUTE((format(printf, 3, 0)));
|
|
325
|
+
|
|
326
|
+
#ifndef Py_LIMITED_API
|
|
327
|
+
# define Py_CPYTHON_ERRORS_H
|
|
328
|
+
# include "cpython/pyerrors.h"
|
|
329
|
+
# undef Py_CPYTHON_ERRORS_H
|
|
330
|
+
#endif
|
|
331
|
+
|
|
332
|
+
#ifdef __cplusplus
|
|
333
|
+
}
|
|
334
|
+
#endif
|
|
335
|
+
#endif /* !Py_ERRORS_H */
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
/* Stuff to export relevant 'expat' entry points from pyexpat to other
|
|
2
|
+
* parser modules, such as cElementTree. */
|
|
3
|
+
|
|
4
|
+
/* note: you must import expat.h before importing this module! */
|
|
5
|
+
|
|
6
|
+
#define PyExpat_CAPI_MAGIC "pyexpat.expat_CAPI 1.1"
|
|
7
|
+
#define PyExpat_CAPSULE_NAME "pyexpat.expat_CAPI"
|
|
8
|
+
|
|
9
|
+
struct PyExpat_CAPI
|
|
10
|
+
{
|
|
11
|
+
char* magic; /* set to PyExpat_CAPI_MAGIC */
|
|
12
|
+
int size; /* set to sizeof(struct PyExpat_CAPI) */
|
|
13
|
+
int MAJOR_VERSION;
|
|
14
|
+
int MINOR_VERSION;
|
|
15
|
+
int MICRO_VERSION;
|
|
16
|
+
/* pointers to selected expat functions. add new functions at
|
|
17
|
+
the end, if needed */
|
|
18
|
+
const XML_LChar * (*ErrorString)(enum XML_Error code);
|
|
19
|
+
enum XML_Error (*GetErrorCode)(XML_Parser parser);
|
|
20
|
+
XML_Size (*GetErrorColumnNumber)(XML_Parser parser);
|
|
21
|
+
XML_Size (*GetErrorLineNumber)(XML_Parser parser);
|
|
22
|
+
enum XML_Status (*Parse)(
|
|
23
|
+
XML_Parser parser, const char *s, int len, int isFinal);
|
|
24
|
+
XML_Parser (*ParserCreate_MM)(
|
|
25
|
+
const XML_Char *encoding, const XML_Memory_Handling_Suite *memsuite,
|
|
26
|
+
const XML_Char *namespaceSeparator);
|
|
27
|
+
void (*ParserFree)(XML_Parser parser);
|
|
28
|
+
void (*SetCharacterDataHandler)(
|
|
29
|
+
XML_Parser parser, XML_CharacterDataHandler handler);
|
|
30
|
+
void (*SetCommentHandler)(
|
|
31
|
+
XML_Parser parser, XML_CommentHandler handler);
|
|
32
|
+
void (*SetDefaultHandlerExpand)(
|
|
33
|
+
XML_Parser parser, XML_DefaultHandler handler);
|
|
34
|
+
void (*SetElementHandler)(
|
|
35
|
+
XML_Parser parser, XML_StartElementHandler start,
|
|
36
|
+
XML_EndElementHandler end);
|
|
37
|
+
void (*SetNamespaceDeclHandler)(
|
|
38
|
+
XML_Parser parser, XML_StartNamespaceDeclHandler start,
|
|
39
|
+
XML_EndNamespaceDeclHandler end);
|
|
40
|
+
void (*SetProcessingInstructionHandler)(
|
|
41
|
+
XML_Parser parser, XML_ProcessingInstructionHandler handler);
|
|
42
|
+
void (*SetUnknownEncodingHandler)(
|
|
43
|
+
XML_Parser parser, XML_UnknownEncodingHandler handler,
|
|
44
|
+
void *encodingHandlerData);
|
|
45
|
+
void (*SetUserData)(XML_Parser parser, void *userData);
|
|
46
|
+
void (*SetStartDoctypeDeclHandler)(XML_Parser parser,
|
|
47
|
+
XML_StartDoctypeDeclHandler start);
|
|
48
|
+
enum XML_Status (*SetEncoding)(XML_Parser parser, const XML_Char *encoding);
|
|
49
|
+
int (*DefaultUnknownEncodingHandler)(
|
|
50
|
+
void *encodingHandlerData, const XML_Char *name, XML_Encoding *info);
|
|
51
|
+
/* might be NULL for expat < 2.1.0 */
|
|
52
|
+
int (*SetHashSalt)(XML_Parser parser, unsigned long hash_salt);
|
|
53
|
+
/* might be NULL for expat < 2.6.0 */
|
|
54
|
+
XML_Bool (*SetReparseDeferralEnabled)(XML_Parser parser, XML_Bool enabled);
|
|
55
|
+
/* might be NULL for expat < 2.7.2 */
|
|
56
|
+
XML_Bool (*SetAllocTrackerActivationThreshold)(
|
|
57
|
+
XML_Parser parser, unsigned long long activationThresholdBytes);
|
|
58
|
+
XML_Bool (*SetAllocTrackerMaximumAmplification)(
|
|
59
|
+
XML_Parser parser, float maxAmplificationFactor);
|
|
60
|
+
/* always add new stuff to the end! */
|
|
61
|
+
};
|
|
62
|
+
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/* Limited C API of PyFrame API
|
|
2
|
+
*
|
|
3
|
+
* Include "frameobject.h" to get the PyFrameObject structure.
|
|
4
|
+
*/
|
|
5
|
+
|
|
6
|
+
#ifndef Py_PYFRAME_H
|
|
7
|
+
#define Py_PYFRAME_H
|
|
8
|
+
#ifdef __cplusplus
|
|
9
|
+
extern "C" {
|
|
10
|
+
#endif
|
|
11
|
+
|
|
12
|
+
/* Return the line of code the frame is currently executing. */
|
|
13
|
+
PyAPI_FUNC(int) PyFrame_GetLineNumber(PyFrameObject *);
|
|
14
|
+
|
|
15
|
+
PyAPI_FUNC(PyCodeObject *) PyFrame_GetCode(PyFrameObject *frame);
|
|
16
|
+
|
|
17
|
+
#ifndef Py_LIMITED_API
|
|
18
|
+
# define Py_CPYTHON_PYFRAME_H
|
|
19
|
+
# include "cpython/pyframe.h"
|
|
20
|
+
# undef Py_CPYTHON_PYFRAME_H
|
|
21
|
+
#endif
|
|
22
|
+
|
|
23
|
+
#ifdef __cplusplus
|
|
24
|
+
}
|
|
25
|
+
#endif
|
|
26
|
+
#endif /* !Py_PYFRAME_H */
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
#ifndef Py_HASH_H
|
|
2
|
+
#define Py_HASH_H
|
|
3
|
+
#ifdef __cplusplus
|
|
4
|
+
extern "C" {
|
|
5
|
+
#endif
|
|
6
|
+
|
|
7
|
+
/* Cutoff for small string DJBX33A optimization in range [1, cutoff).
|
|
8
|
+
*
|
|
9
|
+
* About 50% of the strings in a typical Python application are smaller than
|
|
10
|
+
* 6 to 7 chars. However DJBX33A is vulnerable to hash collision attacks.
|
|
11
|
+
* NEVER use DJBX33A for long strings!
|
|
12
|
+
*
|
|
13
|
+
* A Py_HASH_CUTOFF of 0 disables small string optimization. 32 bit platforms
|
|
14
|
+
* should use a smaller cutoff because it is easier to create colliding
|
|
15
|
+
* strings. A cutoff of 7 on 64bit platforms and 5 on 32bit platforms should
|
|
16
|
+
* provide a decent safety margin.
|
|
17
|
+
*/
|
|
18
|
+
#ifndef Py_HASH_CUTOFF
|
|
19
|
+
# define Py_HASH_CUTOFF 0
|
|
20
|
+
#elif (Py_HASH_CUTOFF > 7 || Py_HASH_CUTOFF < 0)
|
|
21
|
+
# error Py_HASH_CUTOFF must in range 0...7.
|
|
22
|
+
#endif /* Py_HASH_CUTOFF */
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
/* Hash algorithm selection
|
|
26
|
+
*
|
|
27
|
+
* The values for Py_HASH_* are hard-coded in the
|
|
28
|
+
* configure script.
|
|
29
|
+
*
|
|
30
|
+
* - FNV and SIPHASH* are available on all platforms and architectures.
|
|
31
|
+
* - With EXTERNAL embedders can provide an alternative implementation with::
|
|
32
|
+
*
|
|
33
|
+
* PyHash_FuncDef PyHash_Func = {...};
|
|
34
|
+
*
|
|
35
|
+
* XXX: Figure out __declspec() for extern PyHash_FuncDef.
|
|
36
|
+
*/
|
|
37
|
+
#define Py_HASH_EXTERNAL 0
|
|
38
|
+
#define Py_HASH_SIPHASH24 1
|
|
39
|
+
#define Py_HASH_FNV 2
|
|
40
|
+
#define Py_HASH_SIPHASH13 3
|
|
41
|
+
|
|
42
|
+
#ifndef Py_HASH_ALGORITHM
|
|
43
|
+
# ifndef HAVE_ALIGNED_REQUIRED
|
|
44
|
+
# define Py_HASH_ALGORITHM Py_HASH_SIPHASH13
|
|
45
|
+
# else
|
|
46
|
+
# define Py_HASH_ALGORITHM Py_HASH_FNV
|
|
47
|
+
# endif /* uint64_t && uint32_t && aligned */
|
|
48
|
+
#endif /* Py_HASH_ALGORITHM */
|
|
49
|
+
|
|
50
|
+
#ifndef Py_LIMITED_API
|
|
51
|
+
# define Py_CPYTHON_HASH_H
|
|
52
|
+
# include "cpython/pyhash.h"
|
|
53
|
+
# undef Py_CPYTHON_HASH_H
|
|
54
|
+
#endif
|
|
55
|
+
|
|
56
|
+
#ifdef __cplusplus
|
|
57
|
+
}
|
|
58
|
+
#endif
|
|
59
|
+
#endif // !Py_HASH_H
|
|
@@ -0,0 +1,80 @@
|
|
|
1
|
+
|
|
2
|
+
/* Interfaces to configure, query, create & destroy the Python runtime */
|
|
3
|
+
|
|
4
|
+
#ifndef Py_PYLIFECYCLE_H
|
|
5
|
+
#define Py_PYLIFECYCLE_H
|
|
6
|
+
#ifdef __cplusplus
|
|
7
|
+
extern "C" {
|
|
8
|
+
#endif
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
/* Initialization and finalization */
|
|
12
|
+
PyAPI_FUNC(void) Py_Initialize(void);
|
|
13
|
+
PyAPI_FUNC(void) Py_InitializeEx(int);
|
|
14
|
+
PyAPI_FUNC(void) Py_Finalize(void);
|
|
15
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x03060000
|
|
16
|
+
PyAPI_FUNC(int) Py_FinalizeEx(void);
|
|
17
|
+
#endif
|
|
18
|
+
PyAPI_FUNC(int) Py_IsInitialized(void);
|
|
19
|
+
|
|
20
|
+
/* Subinterpreter support */
|
|
21
|
+
PyAPI_FUNC(PyThreadState *) Py_NewInterpreter(void);
|
|
22
|
+
PyAPI_FUNC(void) Py_EndInterpreter(PyThreadState *);
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
/* Py_PyAtExit is for the atexit module, Py_AtExit is for low-level
|
|
26
|
+
* exit functions.
|
|
27
|
+
*/
|
|
28
|
+
PyAPI_FUNC(int) Py_AtExit(void (*func)(void));
|
|
29
|
+
|
|
30
|
+
PyAPI_FUNC(void) _Py_NO_RETURN Py_Exit(int);
|
|
31
|
+
|
|
32
|
+
/* Bootstrap __main__ (defined in Modules/main.c) */
|
|
33
|
+
PyAPI_FUNC(int) Py_Main(int argc, wchar_t **argv);
|
|
34
|
+
PyAPI_FUNC(int) Py_BytesMain(int argc, char **argv);
|
|
35
|
+
|
|
36
|
+
/* In pathconfig.c */
|
|
37
|
+
Py_DEPRECATED(3.11) PyAPI_FUNC(void) Py_SetProgramName(const wchar_t *);
|
|
38
|
+
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetProgramName(void);
|
|
39
|
+
|
|
40
|
+
Py_DEPRECATED(3.11) PyAPI_FUNC(void) Py_SetPythonHome(const wchar_t *);
|
|
41
|
+
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetPythonHome(void);
|
|
42
|
+
|
|
43
|
+
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetProgramFullPath(void);
|
|
44
|
+
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetPrefix(void);
|
|
45
|
+
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetExecPrefix(void);
|
|
46
|
+
Py_DEPRECATED(3.13) PyAPI_FUNC(wchar_t *) Py_GetPath(void);
|
|
47
|
+
#ifdef MS_WINDOWS
|
|
48
|
+
int _Py_CheckPython3(void);
|
|
49
|
+
#endif
|
|
50
|
+
|
|
51
|
+
/* In their own files */
|
|
52
|
+
PyAPI_FUNC(const char *) Py_GetVersion(void);
|
|
53
|
+
PyAPI_FUNC(const char *) Py_GetPlatform(void);
|
|
54
|
+
PyAPI_FUNC(const char *) Py_GetCopyright(void);
|
|
55
|
+
PyAPI_FUNC(const char *) Py_GetCompiler(void);
|
|
56
|
+
PyAPI_FUNC(const char *) Py_GetBuildInfo(void);
|
|
57
|
+
|
|
58
|
+
/* Signals */
|
|
59
|
+
typedef void (*PyOS_sighandler_t)(int);
|
|
60
|
+
PyAPI_FUNC(PyOS_sighandler_t) PyOS_getsig(int);
|
|
61
|
+
PyAPI_FUNC(PyOS_sighandler_t) PyOS_setsig(int, PyOS_sighandler_t);
|
|
62
|
+
|
|
63
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030B0000
|
|
64
|
+
PyAPI_DATA(const unsigned long) Py_Version;
|
|
65
|
+
#endif
|
|
66
|
+
|
|
67
|
+
#if !defined(Py_LIMITED_API) || Py_LIMITED_API+0 >= 0x030D0000
|
|
68
|
+
PyAPI_FUNC(int) Py_IsFinalizing(void);
|
|
69
|
+
#endif
|
|
70
|
+
|
|
71
|
+
#ifndef Py_LIMITED_API
|
|
72
|
+
# define Py_CPYTHON_PYLIFECYCLE_H
|
|
73
|
+
# include "cpython/pylifecycle.h"
|
|
74
|
+
# undef Py_CPYTHON_PYLIFECYCLE_H
|
|
75
|
+
#endif
|
|
76
|
+
|
|
77
|
+
#ifdef __cplusplus
|
|
78
|
+
}
|
|
79
|
+
#endif
|
|
80
|
+
#endif /* !Py_PYLIFECYCLE_H */
|