diff --git a/.appveyor.yml b/.appveyor.yml index d0ac05a3..5f50f81f 100644 --- a/.appveyor.yml +++ b/.appveyor.yml @@ -10,26 +10,26 @@ environment: matrix: - job_name: Build Python for iOS - job_group: build_python + job_group: build_python_darwin APPVEYOR_BUILD_WORKER_IMAGE: macos-monterey - job_name: Build Python for Android - job_group: build_python + job_group: build_python_android APPVEYOR_BUILD_WORKER_IMAGE: Ubuntu2004 - job_name: Test on macOS job_group: test_serious_python - job_depends_on: build_python + job_depends_on: build_python_darwin APPVEYOR_BUILD_WORKER_IMAGE: macos-monterey - job_name: Test on iOS job_group: test_serious_python - job_depends_on: build_python + job_depends_on: build_python_darwin APPVEYOR_BUILD_WORKER_IMAGE: macos-monterey - job_name: Test on Android job_group: test_serious_python - job_depends_on: build_python + job_depends_on: build_python_android APPVEYOR_BUILD_WORKER_IMAGE: ubuntu-gce-c - job_name: Test on Windows @@ -74,7 +74,7 @@ for: # install Kivy toolchain - pip3 list - - pip3 install kivy-ios + - pip3 install git+https://github.com/flet-dev/python-for-ios.git - HOMEBREW_NO_AUTO_UPDATE=1 brew install autoconf automake libtool pkg-config - brew link libtool @@ -125,7 +125,7 @@ for: - echo "y" | sdkmanager --install "platforms;$SDK_VERSION" > /dev/null # install Kivy for Android - - pip3 install python-for-android + - pip3 install git+https://github.com/flet-dev/python-for-android.git@3.11.6 - pip3 install --upgrade cython - p4a --help - p4a create --requirements python3 --arch arm64-v8a --arch armeabi-v7a --arch x86_64 --sdk-dir $ANDROID_SDK_ROOT --ndk-dir $ANDROID_SDK_ROOT/ndk/$NDK_VERSION --dist-name serious_python @@ -221,7 +221,7 @@ for: UDID=$(xcrun xctrace list devices | grep "^e2e test Simulator (16.1)" | awk '{gsub(/[()]/,""); print $NF}') echo $UDID xcrun simctl boot "${UDID:?No Simulator with this name found}" - - flutter doctor -v + #- flutter doctor -v # download dist for non-releases - | diff --git a/README.md b/README.md index 9f548c5a..4548ed24 100644 --- a/README.md +++ b/README.md @@ -16,11 +16,11 @@ Serious Python is part of [Flet](https://flet.dev) project - the fastest way to ### Python versions -* iOS: Python 3.10.10 - based on [Kivy toolchain](https://github.com/kivy/kivy-ios). -* Android: Python 3.10.10 - based on [Kivy python-for-android](https://github.com/kivy/python-for-android). -* macOS: Python 3.10.13 - based on [Beeware's Python Apple Support](https://github.com/beeware/Python-Apple-support). -* Linux: Python 3.10.13 - based on [indygreg/python-build-standalone](https://github.com/indygreg/python-build-standalone). -* Windows: Python 3.10.11 - based on [CPython](https://www.python.org/downloads/release/python-31011/). +* iOS: Python 3.11.6 - based on [Kivy toolchain](https://github.com/kivy/kivy-ios). +* Android: Python 3.11.6 - based on [Kivy python-for-android](https://github.com/kivy/python-for-android). +* macOS: Python 3.11.6 - based on [Beeware's Python Apple Support](https://github.com/beeware/Python-Apple-support). +* Linux: Python 3.11.6 - based on [indygreg/python-build-standalone](https://github.com/indygreg/python-build-standalone). +* Windows: Python 3.11.6 - based on [CPython](https://www.python.org/downloads/release/python-3116/). ## Usage diff --git a/src/serious_python/CHANGELOG.md b/src/serious_python/CHANGELOG.md index cbb50ef5..1a144ab1 100644 --- a/src/serious_python/CHANGELOG.md +++ b/src/serious_python/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.5.0 + +* Python 3.11.6 for all platforms. + ## 0.4.1 * Bumping version after fixing pubspec.yaml. diff --git a/src/serious_python/README.md b/src/serious_python/README.md index 71df37d4..17c54401 100644 --- a/src/serious_python/README.md +++ b/src/serious_python/README.md @@ -16,11 +16,11 @@ Serious Python is part of [Flet](https://flet.dev) project - the fastest way to ### Python versions -* iOS: Python 3.10.10 - based on [Kivy toolchain](https://github.com/kivy/kivy-ios). -* Android: Python 3.10.10 - based on [Kivy python-for-android](https://github.com/kivy/python-for-android). -* macOS: Python 3.10.13 - based on [Beeware's Python Apple Support](https://github.com/beeware/Python-Apple-support). -* Linux: Python 3.10.13 - based on [indygreg/python-build-standalone](https://github.com/indygreg/python-build-standalone). -* Windows: Python 3.10.11 - based on [CPython](https://www.python.org/downloads/release/python-31011/). +* iOS: Python 3.11.6 - based on [Kivy toolchain](https://github.com/kivy/kivy-ios). +* Android: Python 3.11.6 - based on [Kivy python-for-android](https://github.com/kivy/python-for-android). +* macOS: Python 3.11.6 - based on [Beeware's Python Apple Support](https://github.com/beeware/Python-Apple-support). +* Linux: Python 3.11.6 - based on [indygreg/python-build-standalone](https://github.com/indygreg/python-build-standalone). +* Windows: Python 3.11.6 - based on [CPython](https://www.python.org/downloads/release/python-3116/). ## Usage diff --git a/src/serious_python/bin/package_command.dart b/src/serious_python/bin/package_command.dart index 03fba170..1b43f741 100644 --- a/src/serious_python/bin/package_command.dart +++ b/src/serious_python/bin/package_command.dart @@ -221,7 +221,7 @@ class PackageCommand extends Command { Future runPython(List args, {Map? environment}) async { var pythonDir = - Directory(path.join(Directory.systemTemp.path, "hostpython3.10")); + Directory(path.join(Directory.systemTemp.path, "hostpython3.11")); var pythonExePath = Platform.isWindows ? path.join(pythonDir.path, 'python', 'python.exe') @@ -252,7 +252,7 @@ class PackageCommand extends Command { } final url = - "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.10.13+20231002-$arch-install_only.tar.gz"; + "https://github.com/indygreg/python-build-standalone/releases/download/20231002/cpython-3.11.6+20231002-$arch-install_only.tar.gz"; // Download the release asset var response = await http.get(Uri.parse(url)); diff --git a/src/serious_python/example/flask_example/ios/Podfile.lock b/src/serious_python/example/flask_example/ios/Podfile.lock index 9c9a3d76..d7060841 100644 --- a/src/serious_python/example/flask_example/ios/Podfile.lock +++ b/src/serious_python/example/flask_example/ios/Podfile.lock @@ -1,19 +1,25 @@ PODS: - Flutter (1.0.0) + - package_info_plus (0.4.5): + - Flutter - path_provider_foundation (0.0.1): - Flutter - FlutterMacOS - - serious_python_darwin (0.3.1): + - serious_python_darwin (0.5.0): - Flutter + - FlutterMacOS DEPENDENCIES: - Flutter (from `Flutter`) + - package_info_plus (from `.symlinks/plugins/package_info_plus/ios`) - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`) - serious_python_darwin (from `.symlinks/plugins/serious_python_darwin/darwin`) EXTERNAL SOURCES: Flutter: :path: Flutter + package_info_plus: + :path: ".symlinks/plugins/package_info_plus/ios" path_provider_foundation: :path: ".symlinks/plugins/path_provider_foundation/darwin" serious_python_darwin: @@ -21,8 +27,9 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 + package_info_plus: 115f4ad11e0698c8c1c5d8a689390df880f47e85 path_provider_foundation: eaf5b3e458fc0e5fbb9940fb09980e853fe058b8 - serious_python_darwin: 354fff846b363860d6a0e7b2bee8c907862d510a + serious_python_darwin: be59ff398a983746c5bb1c425d9e5caf706198e4 PODFILE CHECKSUM: 7be2f5f74864d463a8ad433546ed1de7e0f29aef diff --git a/src/serious_python/example/flask_example/pubspec.lock b/src/serious_python/example/flask_example/pubspec.lock index 4c86866f..342f819a 100644 --- a/src/serious_python/example/flask_example/pubspec.lock +++ b/src/serious_python/example/flask_example/pubspec.lock @@ -53,10 +53,10 @@ packages: dependency: transitive description: name: collection - sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a url: "https://pub.dev" source: hosted - version: "1.17.2" + version: "1.18.0" convert: dependency: transitive description: @@ -180,10 +180,10 @@ packages: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + sha256: a6e590c838b18133bb482a2745ad77c5bb7715fb0451209e1a7567d416678b8e url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.0" package_info_plus: dependency: transitive description: @@ -302,42 +302,42 @@ packages: path: "../.." relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_android: dependency: transitive description: path: "../../../serious_python_android" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_darwin: dependency: transitive description: path: "../../../serious_python_darwin" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_linux: dependency: transitive description: path: "../../../serious_python_linux" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_platform_interface: dependency: transitive description: path: "../../../serious_python_platform_interface" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_windows: dependency: transitive description: path: "../../../serious_python_windows" relative: true source: path - version: "0.4.1" + version: "0.5.0" sky_engine: dependency: transitive description: flutter @@ -355,18 +355,18 @@ packages: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 + sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b" url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.11.1" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" string_scanner: dependency: transitive description: @@ -387,10 +387,10 @@ packages: dependency: transitive description: name: test_api - sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" + sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" url: "https://pub.dev" source: hosted - version: "0.6.0" + version: "0.6.1" toml: dependency: transitive description: @@ -419,10 +419,10 @@ packages: dependency: transitive description: name: web - sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 + sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152 url: "https://pub.dev" source: hosted - version: "0.1.4-beta" + version: "0.3.0" win32: dependency: transitive description: @@ -440,5 +440,5 @@ packages: source: hosted version: "1.0.0" sdks: - dart: ">=3.1.3 <4.0.0" + dart: ">=3.2.0-194.0.dev <4.0.0" flutter: ">=3.7.0" diff --git a/src/serious_python/example/flet_example/ios/Podfile.lock b/src/serious_python/example/flet_example/ios/Podfile.lock index 55787bc6..ea23104f 100644 --- a/src/serious_python/example/flet_example/ios/Podfile.lock +++ b/src/serious_python/example/flet_example/ios/Podfile.lock @@ -43,12 +43,12 @@ PODS: - path_provider_foundation (0.0.1): - Flutter - FlutterMacOS - - SDWebImage (5.15.8): - - SDWebImage/Core (= 5.15.8) - - SDWebImage/Core (5.15.8) + - SDWebImage (5.18.5): + - SDWebImage/Core (= 5.18.5) + - SDWebImage/Core (5.18.5) - sensors_plus (0.0.1): - Flutter - - serious_python_darwin (0.3.1): + - serious_python_darwin (0.5.0): - Flutter - FlutterMacOS - shared_preferences_foundation (0.0.1): @@ -108,9 +108,9 @@ SPEC CHECKSUMS: integration_test: 13825b8a9334a850581300559b8839134b124670 package_info_plus: 115f4ad11e0698c8c1c5d8a689390df880f47e85 path_provider_foundation: eaf5b3e458fc0e5fbb9940fb09980e853fe058b8 - SDWebImage: cb032eba469c54e0000e78bcb0a13cdde0a52798 + SDWebImage: 7ac2b7ddc5e8484c79aa90fc4e30b149d6a2c88f sensors_plus: 5717760720f7e6acd96fdbd75b7428f5ad755ec2 - serious_python_darwin: a56e5abbd03a9dae9eb69cb6631d183d32a04b7c + serious_python_darwin: be59ff398a983746c5bb1c425d9e5caf706198e4 shared_preferences_foundation: e2dae3258e06f44cc55f49d42024fd8dd03c590c SwiftyGif: 93a1cc87bf3a51916001cf8f3d63835fb64c819f url_launcher_ios: 08a3dfac5fb39e8759aeb0abbd5d9480f30fc8b4 diff --git a/src/serious_python/example/flet_example/macos/Podfile.lock b/src/serious_python/example/flet_example/macos/Podfile.lock index cfa07ad4..d6a99ecf 100644 --- a/src/serious_python/example/flet_example/macos/Podfile.lock +++ b/src/serious_python/example/flet_example/macos/Podfile.lock @@ -9,7 +9,7 @@ PODS: - FlutterMacOS - screen_retriever (0.0.1): - FlutterMacOS - - serious_python_darwin (0.3.1): + - serious_python_darwin (0.4.1): - Flutter - FlutterMacOS - shared_preferences_foundation (0.0.1): @@ -62,7 +62,7 @@ SPEC CHECKSUMS: package_info_plus: 02d7a575e80f194102bef286361c6c326e4c29ce path_provider_foundation: eaf5b3e458fc0e5fbb9940fb09980e853fe058b8 screen_retriever: 59634572a57080243dd1bf715e55b6c54f241a38 - serious_python_darwin: a56e5abbd03a9dae9eb69cb6631d183d32a04b7c + serious_python_darwin: 9f70530340090c8704d985333396f53d8f79df1a shared_preferences_foundation: e2dae3258e06f44cc55f49d42024fd8dd03c590c url_launcher_macos: 5335912b679c073563f29d89d33d10d459f95451 window_manager: 3a1844359a6295ab1e47659b1a777e36773cd6e8 diff --git a/src/serious_python/example/flet_example/pubspec.lock b/src/serious_python/example/flet_example/pubspec.lock index 88f31cc6..ab96d0ac 100644 --- a/src/serious_python/example/flet_example/pubspec.lock +++ b/src/serious_python/example/flet_example/pubspec.lock @@ -109,10 +109,10 @@ packages: dependency: transitive description: name: collection - sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a url: "https://pub.dev" source: hosted - version: "1.17.2" + version: "1.18.0" convert: dependency: transitive description: @@ -339,10 +339,10 @@ packages: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + sha256: a6e590c838b18133bb482a2745ad77c5bb7715fb0451209e1a7567d416678b8e url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.0" package_info_plus: dependency: transitive description: @@ -435,10 +435,10 @@ packages: dependency: transitive description: name: platform - sha256: "4a451831508d7d6ca779f7ac6e212b4023dd5a7d08a27a63da33756410e32b76" + sha256: ae68c7bfcd7383af3629daafb32fb4e8681c7154428da4febcff06200585f102 url: "https://pub.dev" source: hosted - version: "3.1.0" + version: "3.1.2" plugin_platform_interface: dependency: transitive description: @@ -509,42 +509,42 @@ packages: path: "../.." relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_android: dependency: transitive description: path: "../../../serious_python_android" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_darwin: dependency: transitive description: path: "../../../serious_python_darwin" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_linux: dependency: transitive description: path: "../../../serious_python_linux" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_platform_interface: dependency: transitive description: path: "../../../serious_python_platform_interface" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_windows: dependency: transitive description: path: "../../../serious_python_windows" relative: true source: path - version: "0.4.1" + version: "0.5.0" shake: dependency: transitive description: @@ -626,18 +626,18 @@ packages: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 + sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b" url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.11.1" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" string_scanner: dependency: transitive description: @@ -674,10 +674,10 @@ packages: dependency: transitive description: name: test_api - sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" + sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" url: "https://pub.dev" source: hosted - version: "0.6.0" + version: "0.6.1" toml: dependency: transitive description: @@ -802,18 +802,18 @@ packages: dependency: transitive description: name: vm_service - sha256: c620a6f783fa22436da68e42db7ebbf18b8c44b9a46ab911f666ff09ffd9153f + sha256: c538be99af830f478718b51630ec1b6bee5e74e52c8a802d328d9e71d35d2583 url: "https://pub.dev" source: hosted - version: "11.7.1" + version: "11.10.0" web: dependency: transitive description: name: web - sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 + sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152 url: "https://pub.dev" source: hosted - version: "0.1.4-beta" + version: "0.3.0" web_socket_channel: dependency: transitive description: @@ -871,5 +871,5 @@ packages: source: hosted version: "6.3.0" sdks: - dart: ">=3.1.3 <4.0.0" + dart: ">=3.2.0-194.0.dev <4.0.0" flutter: ">=3.10.0" diff --git a/src/serious_python/example/run_example/ios/Podfile.lock b/src/serious_python/example/run_example/ios/Podfile.lock index 90b5993d..e7b04a33 100644 --- a/src/serious_python/example/run_example/ios/Podfile.lock +++ b/src/serious_python/example/run_example/ios/Podfile.lock @@ -2,16 +2,19 @@ PODS: - Flutter (1.0.0) - integration_test (0.0.1): - Flutter + - package_info_plus (0.4.5): + - Flutter - path_provider_foundation (0.0.1): - Flutter - FlutterMacOS - - serious_python_darwin (0.3.1): + - serious_python_darwin (0.5.0): - Flutter - FlutterMacOS DEPENDENCIES: - Flutter (from `Flutter`) - integration_test (from `.symlinks/plugins/integration_test/ios`) + - package_info_plus (from `.symlinks/plugins/package_info_plus/ios`) - path_provider_foundation (from `.symlinks/plugins/path_provider_foundation/darwin`) - serious_python_darwin (from `.symlinks/plugins/serious_python_darwin/darwin`) @@ -20,6 +23,8 @@ EXTERNAL SOURCES: :path: Flutter integration_test: :path: ".symlinks/plugins/integration_test/ios" + package_info_plus: + :path: ".symlinks/plugins/package_info_plus/ios" path_provider_foundation: :path: ".symlinks/plugins/path_provider_foundation/darwin" serious_python_darwin: @@ -28,8 +33,9 @@ EXTERNAL SOURCES: SPEC CHECKSUMS: Flutter: f04841e97a9d0b0a8025694d0796dd46242b2854 integration_test: 13825b8a9334a850581300559b8839134b124670 + package_info_plus: 115f4ad11e0698c8c1c5d8a689390df880f47e85 path_provider_foundation: 29f094ae23ebbca9d3d0cec13889cd9060c0e943 - serious_python_darwin: 3b3e9802e671014eb062d16976ef5394dea763ce + serious_python_darwin: be59ff398a983746c5bb1c425d9e5caf706198e4 PODFILE CHECKSUM: 7be2f5f74864d463a8ad433546ed1de7e0f29aef diff --git a/src/serious_python/example/run_example/pubspec.lock b/src/serious_python/example/run_example/pubspec.lock index 094d9e13..c40cc747 100644 --- a/src/serious_python/example/run_example/pubspec.lock +++ b/src/serious_python/example/run_example/pubspec.lock @@ -53,10 +53,10 @@ packages: dependency: transitive description: name: collection - sha256: f092b211a4319e98e5ff58223576de6c2803db36221657b46c82574721240687 + sha256: ee67cb0715911d28db6bf4af1026078bd6f0128b07a5f66fb2ed94ec6783c09a url: "https://pub.dev" source: hosted - version: "1.17.2" + version: "1.18.0" convert: dependency: transitive description: @@ -195,10 +195,10 @@ packages: dependency: transitive description: name: meta - sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3" + sha256: a6e590c838b18133bb482a2745ad77c5bb7715fb0451209e1a7567d416678b8e url: "https://pub.dev" source: hosted - version: "1.9.1" + version: "1.10.0" package_info_plus: dependency: transitive description: @@ -283,10 +283,10 @@ packages: dependency: transitive description: name: platform - sha256: "4a451831508d7d6ca779f7ac6e212b4023dd5a7d08a27a63da33756410e32b76" + sha256: ae68c7bfcd7383af3629daafb32fb4e8681c7154428da4febcff06200585f102 url: "https://pub.dev" source: hosted - version: "3.1.0" + version: "3.1.2" plugin_platform_interface: dependency: transitive description: @@ -317,42 +317,42 @@ packages: path: "../.." relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_android: dependency: transitive description: path: "../../../serious_python_android" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_darwin: dependency: transitive description: path: "../../../serious_python_darwin" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_linux: dependency: transitive description: path: "../../../serious_python_linux" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_platform_interface: dependency: transitive description: path: "../../../serious_python_platform_interface" relative: true source: path - version: "0.4.1" + version: "0.5.0" serious_python_windows: dependency: transitive description: path: "../../../serious_python_windows" relative: true source: path - version: "0.4.1" + version: "0.5.0" sky_engine: dependency: transitive description: flutter @@ -370,18 +370,18 @@ packages: dependency: transitive description: name: stack_trace - sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5 + sha256: "73713990125a6d93122541237550ee3352a2d84baad52d375a4cad2eb9b7ce0b" url: "https://pub.dev" source: hosted - version: "1.11.0" + version: "1.11.1" stream_channel: dependency: transitive description: name: stream_channel - sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8" + sha256: ba2aa5d8cc609d96bbb2899c28934f9e1af5cddbd60a827822ea467161eb54e7 url: "https://pub.dev" source: hosted - version: "2.1.1" + version: "2.1.2" string_scanner: dependency: transitive description: @@ -410,10 +410,10 @@ packages: dependency: transitive description: name: test_api - sha256: "75760ffd7786fffdfb9597c35c5b27eaeec82be8edfb6d71d32651128ed7aab8" + sha256: "5c2f730018264d276c20e4f1503fd1308dfbbae39ec8ee63c5236311ac06954b" url: "https://pub.dev" source: hosted - version: "0.6.0" + version: "0.6.1" toml: dependency: transitive description: @@ -442,18 +442,18 @@ packages: dependency: transitive description: name: vm_service - sha256: c620a6f783fa22436da68e42db7ebbf18b8c44b9a46ab911f666ff09ffd9153f + sha256: c538be99af830f478718b51630ec1b6bee5e74e52c8a802d328d9e71d35d2583 url: "https://pub.dev" source: hosted - version: "11.7.1" + version: "11.10.0" web: dependency: transitive description: name: web - sha256: dc8ccd225a2005c1be616fe02951e2e342092edf968cf0844220383757ef8f10 + sha256: afe077240a270dcfd2aafe77602b4113645af95d0ad31128cc02bce5ac5d5152 url: "https://pub.dev" source: hosted - version: "0.1.4-beta" + version: "0.3.0" webdriver: dependency: transitive description: @@ -479,5 +479,5 @@ packages: source: hosted version: "1.0.3" sdks: - dart: ">=3.1.3 <4.0.0" + dart: ">=3.2.0-194.0.dev <4.0.0" flutter: ">=3.7.0" diff --git a/src/serious_python/pubspec.yaml b/src/serious_python/pubspec.yaml index 522c729b..7401f8c7 100644 --- a/src/serious_python/pubspec.yaml +++ b/src/serious_python/pubspec.yaml @@ -2,7 +2,7 @@ name: serious_python description: A cross-platform plugin for adding embedded Python runtime to your Flutter apps. homepage: https://flet.dev repository: https://github.com/flet-dev/serious-python -version: 0.4.1 +version: 0.5.0 platforms: ios: diff --git a/src/serious_python_android/CHANGELOG.md b/src/serious_python_android/CHANGELOG.md index 9762c583..52ad02cc 100644 --- a/src/serious_python_android/CHANGELOG.md +++ b/src/serious_python_android/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.5.0 + +* Python 3.11.6. + ## 0.4.1 * Bumping version after fixing pubspec.yaml. diff --git a/src/serious_python_android/android/build.gradle b/src/serious_python_android/android/build.gradle index 88ae8277..4d79e5cf 100644 --- a/src/serious_python_android/android/build.gradle +++ b/src/serious_python_android/android/build.gradle @@ -1,5 +1,5 @@ group 'com.flet.serious_python_android' -version '0.4.1' +version '0.5.0' buildscript { repositories { diff --git a/src/serious_python_android/lib/serious_python_android.dart b/src/serious_python_android/lib/serious_python_android.dart index b1307523..5da65603 100644 --- a/src/serious_python_android/lib/serious_python_android.dart +++ b/src/serious_python_android/lib/serious_python_android.dart @@ -54,7 +54,7 @@ class SeriousPythonAndroid extends SeriousPythonPlatform { debugPrint("pythonLibPath: $pythonLibPath"); runPythonProgramFFI( - sync ?? false, "libpython3.10.so", pythonLibPath, appPath, [ + sync ?? false, "libpython3.11.so", pythonLibPath, appPath, [ ...?modulePaths, "$pythonLibPath/modules", "$pythonLibPath/site-packages", diff --git a/src/serious_python_android/pubspec.yaml b/src/serious_python_android/pubspec.yaml index b644a99b..96fa0d6c 100644 --- a/src/serious_python_android/pubspec.yaml +++ b/src/serious_python_android/pubspec.yaml @@ -2,7 +2,7 @@ name: serious_python_android description: Android implementation of the serious_python plugin homepage: https://flet.dev repository: https://github.com/flet-dev/serious-python -version: 0.4.1 +version: 0.5.0 environment: sdk: ">=3.0.0 <4.0.0" diff --git a/src/serious_python_darwin/CHANGELOG.md b/src/serious_python_darwin/CHANGELOG.md index 612e9132..1f9ca683 100644 --- a/src/serious_python_darwin/CHANGELOG.md +++ b/src/serious_python_darwin/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.5.0 + +* Python 3.11.6. + ## 0.4.1 * Bumping version after fixing pubspec.yaml. diff --git a/src/serious_python_darwin/darwin/Classes/SeriousPythonPlugin.swift b/src/serious_python_darwin/darwin/Classes/SeriousPythonPlugin.swift index 4943321b..9082e9e0 100644 --- a/src/serious_python_darwin/darwin/Classes/SeriousPythonPlugin.swift +++ b/src/serious_python_darwin/darwin/Classes/SeriousPythonPlugin.swift @@ -48,7 +48,7 @@ public class SeriousPythonPlugin: NSObject, FlutterPlugin { "\(appDir)/__pypackages__", resourcePath, "\(resourcePath)/lib/site-packages.zip", - "\(resourcePath)/lib/python3.10", + "\(resourcePath)/lib/python3.11", "\(resourcePath)/python-stdlib", "\(resourcePath)/python-stdlib/lib-dynload" ] diff --git a/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/Info.plist b/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/Info.plist deleted file mode 100644 index 0c4b0ea1..00000000 --- a/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/Info.plist +++ /dev/null @@ -1,59 +0,0 @@ - - - - - AvailableLibraries - - - HeadersPath - Headers - LibraryIdentifier - ios-arm64 - LibraryPath - libpython3.a - SupportedArchitectures - - arm64 - - SupportedPlatform - ios - - - HeadersPath - Headers - LibraryIdentifier - ios-arm64_x86_64-simulator - LibraryPath - libpython3.a - SupportedArchitectures - - arm64 - x86_64 - - SupportedPlatform - ios - SupportedPlatformVariant - simulator - - - HeadersPath - Headers - LibraryIdentifier - macos-arm64_x86_64 - LibraryPath - libpython3.a - SupportedArchitectures - - arm64 - x86_64 - - SupportedPlatform - macos - - - CFBundlePackageType - XFWK - XCFrameworkFormatVersion - 1.0 - - diff --git a/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/macos-arm64_x86_64/Headers/module.modulemap b/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/macos-arm64_x86_64/Headers/module.modulemap deleted file mode 100644 index 1e5a7a62..00000000 --- a/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/macos-arm64_x86_64/Headers/module.modulemap +++ /dev/null @@ -1,89 +0,0 @@ -module Python { - umbrella header "Python.h" - export * - exclude header "token.h" - exclude header "marshal.h" - exclude header "py_curses.h" - exclude header "errcode.h" - exclude header "structmember.h" - exclude header "frameobject.h" - exclude header "internal/pycore_pyerrors.h" - exclude header "internal/pycore_warnings.h" - exclude header "internal/pycore_global_strings.h" - exclude header "internal/pycore_asdl.h" - exclude header "internal/pycore_getopt.h" - exclude header "internal/pycore_hamt.h" - exclude header "internal/pycore_pymath.h" - exclude header "internal/pycore_parser.h" - exclude header "internal/pycore_accu.h" - exclude header "internal/pycore_runtime_init.h" - exclude header "internal/pycore_pylifecycle.h" - exclude header "internal/pycore_runtime.h" - exclude header "internal/pycore_emscripten_signal.h" - exclude header "internal/pycore_namespace.h" - exclude header "internal/pycore_genobject.h" - exclude header "internal/pycore_gil.h" - exclude header "internal/pycore_exceptions.h" - exclude header "internal/pycore_compile.h" - exclude header "internal/pycore_signal.h" - exclude header "internal/pycore_atomic_funcs.h" - exclude header "internal/pycore_sliceobject.h" - exclude header "internal/pycore_code.h" - exclude header "internal/pycore_unionobject.h" - exclude header "internal/pycore_pyhash.h" - exclude header "internal/pycore_tuple.h" - exclude header "internal/pycore_long.h" - exclude header "internal/pycore_ucnhash.h" - exclude header "internal/pycore_fileutils.h" - exclude header "internal/pycore_floatobject.h" - exclude header "internal/pycore_call.h" - exclude header "internal/pycore_hashtable.h" - exclude header "internal/pycore_abstract.h" - exclude header "internal/pycore_list.h" - exclude header "internal/pycore_pymem.h" - exclude header "internal/pycore_structseq.h" - exclude header "internal/pycore_bitutils.h" - exclude header "internal/pycore_interpreteridobject.h" - exclude header "internal/pycore_pystate.h" - exclude header "internal/pycore_gc.h" - exclude header "internal/pycore_traceback.h" - exclude header "internal/pycore_dict.h" - exclude header "internal/pycore_strhex.h" - exclude header "internal/pycore_atomic.h" - exclude header "internal/pycore_import.h" - exclude header "internal/pycore_symtable.h" - exclude header "internal/pycore_sysmodule.h" - exclude header "internal/pycore_ast_state.h" - exclude header "internal/pycore_pyarena.h" - exclude header "internal/pycore_initconfig.h" - exclude header "internal/pycore_bytesobject.h" - exclude header "internal/pycore_frame.h" - exclude header "internal/pycore_opcode.h" - exclude header "internal/pycore_interp.h" - exclude header "internal/pycore_dtoa.h" - exclude header "internal/pycore_format.h" - exclude header "internal/pycore_function.h" - exclude header "internal/pycore_condvar.h" - exclude header "internal/pycore_typeobject.h" - exclude header "internal/pycore_bytes_methods.h" - exclude header "internal/pycore_object.h" - exclude header "internal/pycore_ceval.h" - exclude header "internal/pycore_pathconfig.h" - exclude header "internal/pycore_moduleobject.h" - exclude header "internal/pycore_global_objects.h" - exclude header "internal/pycore_unicodeobject.h" - exclude header "internal/pycore_blocks_output_buffer.h" - exclude header "internal/pycore_context.h" - exclude header "internal/pycore_ast.h" - exclude header "datetime.h" - exclude header "pyexpat.h" - exclude header "cpython/pthread_stubs.h" - exclude header "cpython/frameobject.h" - exclude header "osdefs.h" - exclude header "opcode.h" - exclude header "pydtrace.h" - exclude header "pyconfig-arm64.h" - exclude header "pyconfig-x86_64.h" - exclude header "dynamic_annotations.h" - link "Python" -} \ No newline at end of file diff --git a/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/ios-arm64/Headers/module.modulemap b/src/serious_python_darwin/darwin/pod_templates/libpython3.11.xcframework/ios-arm64/Headers/module.modulemap similarity index 100% rename from src/serious_python_darwin/darwin/pod_templates/Python.xcframework/ios-arm64/Headers/module.modulemap rename to src/serious_python_darwin/darwin/pod_templates/libpython3.11.xcframework/ios-arm64/Headers/module.modulemap diff --git a/src/serious_python_darwin/darwin/pod_templates/Python.xcframework/ios-arm64_x86_64-simulator/Headers/module.modulemap b/src/serious_python_darwin/darwin/pod_templates/libpython3.11.xcframework/ios-x86_64-simulator/Headers/module.modulemap similarity index 100% rename from src/serious_python_darwin/darwin/pod_templates/Python.xcframework/ios-arm64_x86_64-simulator/Headers/module.modulemap rename to src/serious_python_darwin/darwin/pod_templates/libpython3.11.xcframework/ios-x86_64-simulator/Headers/module.modulemap diff --git a/src/serious_python_darwin/darwin/pod_templates/site-packages/_posixsubprocess.py b/src/serious_python_darwin/darwin/pod_templates/site-packages/_posixsubprocess.py index dd461a98..e19588bb 100644 --- a/src/serious_python_darwin/darwin/pod_templates/site-packages/_posixsubprocess.py +++ b/src/serious_python_darwin/darwin/pod_templates/site-packages/_posixsubprocess.py @@ -1 +1,3 @@ # this stub makes `import subprocess` work. +def fork_exec(): + pass diff --git a/src/serious_python_darwin/darwin/serious_python_darwin.podspec b/src/serious_python_darwin/darwin/serious_python_darwin.podspec index 09051c1a..28282be7 100644 --- a/src/serious_python_darwin/darwin/serious_python_darwin.podspec +++ b/src/serious_python_darwin/darwin/serious_python_darwin.podspec @@ -4,7 +4,7 @@ # Pod::Spec.new do |s| s.name = 'serious_python_darwin' - s.version = '0.4.1' + s.version = '0.5.0' s.summary = 'A cross-platform plugin for adding embedded Python runtime to your Flutter apps.' s.description = <<-DESC A cross-platform plugin for adding embedded Python runtime to your Flutter apps. @@ -28,10 +28,10 @@ Pod::Spec.new do |s| } s.swift_version = '5.0' - python_framework = 'dist/frameworks/Python.xcframework' + python_framework = 'dist/xcframework/libpython3.11.xcframework' python_macos_framework = 'dist_macos/Python.xcframework' - s.prepare_command = <<-CMD + prepare_command = <<-CMD if [ -d "dist" ]; then rm -rf dist fi @@ -49,22 +49,17 @@ Pod::Spec.new do |s| rm $PYTHON_IOS_DIST_FILE fi - PYTHON_MACOS_DIST_FILE=Python-3.10-macOS-support.b7.tar.gz - curl -LO https://github.com/beeware/Python-Apple-support/releases/download/3.10-b7/$PYTHON_MACOS_DIST_FILE + PYTHON_MACOS_DIST_FILE=Python-3.11-macOS-support.b3.tar.gz + curl -LO https://github.com/beeware/Python-Apple-support/releases/download/3.11-b3/$PYTHON_MACOS_DIST_FILE mkdir -p dist_macos tar -xzf $PYTHON_MACOS_DIST_FILE -C dist_macos rm $PYTHON_MACOS_DIST_FILE ROOT=`pwd` - rm -rf #{python_framework} - mkdir -p #{python_framework} - cp -R pod_templates/Python.xcframework/* #{python_framework} - cp dist/lib/libpython3.a #{python_framework}/ios-arm64 - cp dist/lib/libpython3.a #{python_framework}/ios-arm64_x86_64-simulator - cp #{python_macos_framework}/macos-arm64_x86_64/libPython3.10.a #{python_framework}/macos-arm64_x86_64/libpython3.a - cp -R dist/root/python3/include/python3.10/* #{python_framework}/ios-arm64/Headers - cp -R dist/root/python3/include/python3.10/* #{python_framework}/ios-arm64_x86_64-simulator/Headers - cp -R dist/root/python3/include/python3.10/* #{python_framework}/macos-arm64_x86_64/Headers + cp -R pod_templates/libpython3.11.xcframework dist/xcframework + cp -R dist/root/python3/include/python3.11/* #{python_framework}/ios-arm64/Headers + cp -R dist/root/python3/include/python3.11/* #{python_framework}/ios-x86_64-simulator/Headers + cp #{python_framework}/ios-arm64/Headers/module.modulemap #{python_macos_framework}/macos-arm64_x86_64/Headers # compile dist_macos/python-stdlib pushd dist_macos/python-stdlib @@ -74,34 +69,48 @@ Pod::Spec.new do |s| rm -rf **/__pycache__ popd - # compile python310.zip - PYTHON310_ZIP=$ROOT/dist/root/python3/lib/python310.zip - unzip $PYTHON310_ZIP -d python310_temp - rm $PYTHON310_ZIP - pushd python310_temp + # compile python311.zip + PYTHON311_ZIP=$ROOT/dist/root/python3/lib/python311.zip + unzip $PYTHON311_ZIP -d python311_temp + rm $PYTHON311_ZIP + pushd python311_temp $ROOT/dist/hostpython3/bin/python -m compileall -b . find . \\( -name '*.so' -or -name '*.py' -or -name '*.typed' \\) -type f -delete - zip -r $PYTHON310_ZIP . + zip -r $PYTHON311_ZIP . popd - rm -rf python310_temp + rm -rf python311_temp # fix import subprocess, asyncio - cp -R pod_templates/site-packages/* dist/root/python3/lib/python3.10/site-packages + cp -R pod_templates/site-packages/* dist/root/python3/lib/python3.11/site-packages # zip site-packages - pushd dist/root/python3/lib/python3.10/site-packages + pushd dist/root/python3/lib/python3.11/site-packages $ROOT/dist/hostpython3/bin/python -m compileall -b . find . \\( -name '*.so' -or -name '*.py' -or -name '*.typed' \\) -type f -delete zip -r $ROOT/dist/root/python3/lib/site-packages.zip . popd # remove junk - rm -rf dist/root/python3/lib/python3.10 + rm -rf dist/root/python3/lib/python3.11 CMD + puts `#{prepare_command}` + + # Directory path + dir_path = "dist/xcframework" + + # Get the list of directories + dirs = Dir.glob("#{dir_path}/*.xcframework") + + # Create an array of directory names without the extension + ios_frameworks = dirs.map do |dir| + dir_path + '/' + Pathname.new(dir).basename.to_s + end + s.libraries = 'z', 'bz2', 'c++', 'sqlite3' - s.ios.vendored_libraries = 'dist/lib/*.a' - s.vendored_frameworks = python_framework + s.ios.vendored_frameworks = ios_frameworks s.ios.resource = ['dist/root/python3/lib'] + + s.osx.vendored_frameworks = python_macos_framework s.osx.resource = ['dist_macos/python-stdlib'] end diff --git a/src/serious_python_darwin/pubspec.yaml b/src/serious_python_darwin/pubspec.yaml index b7fe1338..7c8d632c 100644 --- a/src/serious_python_darwin/pubspec.yaml +++ b/src/serious_python_darwin/pubspec.yaml @@ -2,7 +2,7 @@ name: serious_python_darwin description: iOS and macOS implementations of the serious_python plugin homepage: https://flet.dev repository: https://github.com/flet-dev/serious-python -version: 0.4.1 +version: 0.5.0 environment: sdk: ">=3.0.0 <4.0.0" diff --git a/src/serious_python_linux/CHANGELOG.md b/src/serious_python_linux/CHANGELOG.md index 8654ac1f..0d0dc423 100644 --- a/src/serious_python_linux/CHANGELOG.md +++ b/src/serious_python_linux/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.5.0 + +* Python 3.11.6. + ## 0.4.1 * Bumping version after fixing pubspec.yaml. diff --git a/src/serious_python_linux/linux/CMakeLists.txt b/src/serious_python_linux/linux/CMakeLists.txt index 2ce6ccac..625d0704 100644 --- a/src/serious_python_linux/linux/CMakeLists.txt +++ b/src/serious_python_linux/linux/CMakeLists.txt @@ -9,7 +9,7 @@ cmake_minimum_required(VERSION 3.10) # Project-level configuration. set(PROJECT_NAME "serious_python_linux") set(GITHUB_RELEASE_DATE "20231002") -set(PYTHON_VERSION "3.10.13") +set(PYTHON_VERSION "3.11.6") set(PYTHON_ARCH ${CMAKE_HOST_SYSTEM_PROCESSOR}) project(${PROJECT_NAME} LANGUAGES CXX) @@ -30,7 +30,7 @@ add_custom_command(TARGET OPTIMIZE_PYTHON_DIST PRE_BUILD COMMAND "${PYTHON_PACKAGE}/bin/python3" -m compileall -b . COMMAND rm -rf `find . -type d -name __pycache__` COMMAND find . -name \"*.py\" -type f -delete - WORKING_DIRECTORY "${PYTHON_PACKAGE}/lib/python3.10" + WORKING_DIRECTORY "${PYTHON_PACKAGE}/lib/python3.11" ) # Any new source files that you add to the plugin should be added here. @@ -62,7 +62,7 @@ target_include_directories(${PLUGIN_NAME} INTERFACE "${CMAKE_CURRENT_SOURCE_DIR}/include" ) include_directories( - "${PYTHON_PACKAGE}/include/python3.10" + "${PYTHON_PACKAGE}/include/python3.11" ) target_link_libraries(${PLUGIN_NAME} PRIVATE flutter) @@ -76,9 +76,9 @@ target_link_libraries(${PLUGIN_NAME} PRIVATE # external build triggered from this build file. set(serious_python_linux_bundled_libraries "${PYTHON_PACKAGE}/lib/libpython3.so" - "${PYTHON_PACKAGE}/lib/libpython3.10.so.1.0" + "${PYTHON_PACKAGE}/lib/libpython3.11.so.1.0" PARENT_SCOPE ) -install(DIRECTORY "${PYTHON_PACKAGE}/lib/python3.10" +install(DIRECTORY "${PYTHON_PACKAGE}/lib/python3.11" DESTINATION "${CMAKE_BINARY_DIR}/bundle") \ No newline at end of file diff --git a/src/serious_python_linux/linux/serious_python_linux_plugin.cc b/src/serious_python_linux/linux/serious_python_linux_plugin.cc index 1e6f8e99..c9729407 100644 --- a/src/serious_python_linux/linux/serious_python_linux_plugin.cc +++ b/src/serious_python_linux/linux/serious_python_linux_plugin.cc @@ -11,11 +11,12 @@ #include -#define SERIOUS_PYTHON_LINUX_PLUGIN(obj) \ +#define SERIOUS_PYTHON_LINUX_PLUGIN(obj) \ (G_TYPE_CHECK_INSTANCE_CAST((obj), serious_python_linux_plugin_get_type(), \ SeriousPythonLinuxPlugin)) -struct _SeriousPythonLinuxPlugin { +struct _SeriousPythonLinuxPlugin +{ GObject parent_instance; }; @@ -23,41 +24,49 @@ G_DEFINE_TYPE(SeriousPythonLinuxPlugin, serious_python_linux_plugin, g_object_ge // Called when a method call is received from Flutter. static void serious_python_linux_plugin_handle_method_call( - SeriousPythonLinuxPlugin* self, - FlMethodCall* method_call) { + SeriousPythonLinuxPlugin *self, + FlMethodCall *method_call) +{ g_autoptr(FlMethodResponse) response = nullptr; - const gchar* method = fl_method_call_get_name(method_call); - FlValue* args = fl_method_call_get_args(method_call); + const gchar *method = fl_method_call_get_name(method_call); + FlValue *args = fl_method_call_get_args(method_call); - if (strcmp(method, "getPlatformVersion") == 0) { + if (strcmp(method, "getPlatformVersion") == 0) + { response = get_platform_version(); - } else if (strcmp(method, "runPython") == 0) { - if (fl_value_get_type(args) != FL_VALUE_TYPE_MAP) { + } + else if (strcmp(method, "runPython") == 0) + { + if (fl_value_get_type(args) != FL_VALUE_TYPE_MAP) + { return; } // exePath - FlValue* exe_path = fl_value_lookup_string(args, "exePath"); - if (exe_path == nullptr) { + FlValue *exe_path = fl_value_lookup_string(args, "exePath"); + if (exe_path == nullptr) + { return; } - gchar* exe_dir = g_path_get_dirname(fl_value_to_string(exe_path)); + gchar *exe_dir = g_path_get_dirname(fl_value_to_string(exe_path)); // appPath - FlValue* app_path = fl_value_lookup_string(args, "appPath"); - if (app_path == nullptr) { + FlValue *app_path = fl_value_lookup_string(args, "appPath"); + if (app_path == nullptr) + { return; } - gchar* app_dir = g_path_get_dirname(fl_value_to_string(app_path)); + gchar *app_dir = g_path_get_dirname(fl_value_to_string(app_path)); // sync bool sync = false; g_autoptr(FlValue) sync_key = fl_value_new_string("sync"); - FlValue* sync_value = fl_value_lookup(args, sync_key); - if (sync_value != nullptr && fl_value_get_type(sync_value) == FL_VALUE_TYPE_BOOL) { + FlValue *sync_value = fl_value_lookup(args, sync_key); + if (sync_value != nullptr && fl_value_get_type(sync_value) == FL_VALUE_TYPE_BOOL) + { sync = fl_value_get_bool(sync_value); } @@ -65,19 +74,22 @@ static void serious_python_linux_plugin_handle_method_call( size_t module_paths_size = 0; g_autoptr(FlValue) module_paths_key = fl_value_new_string("modulePaths"); - FlValue* module_paths = fl_value_lookup(args, module_paths_key); - if (module_paths != nullptr && fl_value_get_type(module_paths) == FL_VALUE_TYPE_LIST) { + FlValue *module_paths = fl_value_lookup(args, module_paths_key); + if (module_paths != nullptr && fl_value_get_type(module_paths) == FL_VALUE_TYPE_LIST) + { module_paths_size = fl_value_get_length(module_paths); printf("modulePaths is a LIST: %zu\n", module_paths_size); } - gchar **module_paths_str_array = g_new(gchar*, module_paths_size + 4 /* standard modules */ + 1 /* for the NULL at the end */); + gchar **module_paths_str_array = g_new(gchar *, module_paths_size + 4 /* standard modules */ + 1 /* for the NULL at the end */); // user module paths size_t i = 0; - if (module_paths_size > 0) { - for (; i < module_paths_size; i++) { - FlValue* v = fl_value_get_list_value(module_paths, i); + if (module_paths_size > 0) + { + for (; i < module_paths_size; i++) + { + FlValue *v = fl_value_get_list_value(module_paths, i); printf("modulePath: %s\n", fl_value_to_string(v)); module_paths_str_array[i] = g_strdup(fl_value_to_string(v)); } @@ -86,8 +98,8 @@ static void serious_python_linux_plugin_handle_method_call( // system module paths module_paths_str_array[i++] = g_strdup_printf("%s", app_dir); module_paths_str_array[i++] = g_strdup_printf("%s/__pypackages__", app_dir); - module_paths_str_array[i++] = g_strdup_printf("%s/python3.10", exe_dir); - module_paths_str_array[i++] = g_strdup_printf("%s/python3.10/site-packages", exe_dir); + module_paths_str_array[i++] = g_strdup_printf("%s/python3.11", exe_dir); + module_paths_str_array[i++] = g_strdup_printf("%s/python3.11/site-packages", exe_dir); module_paths_str_array[i++] = NULL; gchar *module_paths_str = g_strjoinv(":", module_paths_str_array); // join with comma and space as separators @@ -104,13 +116,15 @@ static void serious_python_linux_plugin_handle_method_call( g_setenv("PYTHONPATH", module_paths_str, TRUE); g_autoptr(FlValue) env_vars_key = fl_value_new_string("environmentVariables"); - FlValue* env_vars_map = fl_value_lookup(args, env_vars_key); - if (env_vars_map != nullptr && fl_value_get_type(env_vars_map) == FL_VALUE_TYPE_MAP) { + FlValue *env_vars_map = fl_value_lookup(args, env_vars_key); + if (env_vars_map != nullptr && fl_value_get_type(env_vars_map) == FL_VALUE_TYPE_MAP) + { size_t size = fl_value_get_length(env_vars_map); printf("environmentVariables is a MAP: %zu\n", size); - for (size_t i = 0; i < size; i++) { - FlValue* key = fl_value_get_map_key(env_vars_map, i); - FlValue* val = fl_value_lookup(env_vars_map, key); + for (size_t i = 0; i < size; i++) + { + FlValue *key = fl_value_get_map_key(env_vars_map, i); + FlValue *val = fl_value_lookup(env_vars_map, key); printf("env var %s=%s\n", fl_value_to_string(key), fl_value_to_string(val)); g_setenv(fl_value_to_string(key), fl_value_to_string(val), TRUE); } @@ -121,41 +135,52 @@ static void serious_python_linux_plugin_handle_method_call( printf("sync: %s\n", sync ? "true" : "false"); g_strfreev(module_paths_str_array); // free the array and its elements - g_free(module_paths_str); // free the joined string + g_free(module_paths_str); // free the joined string - if (sync) { + if (sync) + { run_python_script(fl_value_to_string(app_path)); - } else { + } + else + { g_thread_new(NULL, run_python_script_async, g_strdup(fl_value_to_string(app_path))); } response = FL_METHOD_RESPONSE(fl_method_success_response_new(fl_value_new_string(""))); - } else { + } + else + { response = FL_METHOD_RESPONSE(fl_method_not_implemented_response_new()); } fl_method_call_respond(method_call, response, nullptr); } -void run_python_script(gchar* appPath) { - Py_Initialize(); +void run_python_script(gchar *appPath) +{ + Py_Initialize(); - FILE* file = fopen(appPath, "r"); - if (file != NULL) { - PyRun_SimpleFileEx(file, appPath, 1); - } else { - printf("Failed to open Python app file: %s\n", appPath); - } + FILE *file = fopen(appPath, "r"); + if (file != NULL) + { + PyRun_SimpleFileEx(file, appPath, 1); + } + else + { + printf("Failed to open Python app file: %s\n", appPath); + } - Py_Finalize(); + Py_Finalize(); } -gpointer run_python_script_async(gpointer data) { - run_python_script((gchar*)data); - return NULL; +gpointer run_python_script_async(gpointer data) +{ + run_python_script((gchar *)data); + return NULL; } -FlMethodResponse* get_platform_version() { +FlMethodResponse *get_platform_version() +{ struct utsname uname_data = {}; uname(&uname_data); g_autofree gchar *version = g_strdup_printf("Linux %s", uname_data.version); @@ -163,24 +188,28 @@ FlMethodResponse* get_platform_version() { return FL_METHOD_RESPONSE(fl_method_success_response_new(result)); } -static void serious_python_linux_plugin_dispose(GObject* object) { +static void serious_python_linux_plugin_dispose(GObject *object) +{ G_OBJECT_CLASS(serious_python_linux_plugin_parent_class)->dispose(object); } -static void serious_python_linux_plugin_class_init(SeriousPythonLinuxPluginClass* klass) { +static void serious_python_linux_plugin_class_init(SeriousPythonLinuxPluginClass *klass) +{ G_OBJECT_CLASS(klass)->dispose = serious_python_linux_plugin_dispose; } -static void serious_python_linux_plugin_init(SeriousPythonLinuxPlugin* self) {} +static void serious_python_linux_plugin_init(SeriousPythonLinuxPlugin *self) {} -static void method_call_cb(FlMethodChannel* channel, FlMethodCall* method_call, - gpointer user_data) { - SeriousPythonLinuxPlugin* plugin = SERIOUS_PYTHON_LINUX_PLUGIN(user_data); +static void method_call_cb(FlMethodChannel *channel, FlMethodCall *method_call, + gpointer user_data) +{ + SeriousPythonLinuxPlugin *plugin = SERIOUS_PYTHON_LINUX_PLUGIN(user_data); serious_python_linux_plugin_handle_method_call(plugin, method_call); } -void serious_python_linux_plugin_register_with_registrar(FlPluginRegistrar* registrar) { - SeriousPythonLinuxPlugin* plugin = SERIOUS_PYTHON_LINUX_PLUGIN( +void serious_python_linux_plugin_register_with_registrar(FlPluginRegistrar *registrar) +{ + SeriousPythonLinuxPlugin *plugin = SERIOUS_PYTHON_LINUX_PLUGIN( g_object_new(serious_python_linux_plugin_get_type(), nullptr)); g_autoptr(FlStandardMethodCodec) codec = fl_standard_method_codec_new(); diff --git a/src/serious_python_linux/pubspec.yaml b/src/serious_python_linux/pubspec.yaml index 4c713d85..a8e89406 100644 --- a/src/serious_python_linux/pubspec.yaml +++ b/src/serious_python_linux/pubspec.yaml @@ -2,7 +2,7 @@ name: serious_python_linux description: Linux implementations of the serious_python plugin homepage: https://flet.dev repository: https://github.com/flet-dev/serious-python -version: 0.4.1 +version: 0.5.0 environment: sdk: '>=3.1.3 <4.0.0' diff --git a/src/serious_python_platform_interface/CHANGELOG.md b/src/serious_python_platform_interface/CHANGELOG.md index dcd25429..439d9a17 100644 --- a/src/serious_python_platform_interface/CHANGELOG.md +++ b/src/serious_python_platform_interface/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.5.0 + +* Python 3.11.6. + ## 0.4.1 * Bumping version after fixing pubspec.yaml. diff --git a/src/serious_python_platform_interface/lib/src/cpython.dart b/src/serious_python_platform_interface/lib/src/cpython.dart index 897b4a77..548a0426 100644 --- a/src/serious_python_platform_interface/lib/src/cpython.dart +++ b/src/serious_python_platform_interface/lib/src/cpython.dart @@ -44,7 +44,7 @@ int main(int argc, char *argv[]) Build: -gcc -o myprogram myprogram.c -I$HOME/.pyenv/versions/3.10.10/include/python3.10 -L$HOME/.pyenv/versions/3.10.10/lib -lpython3.10 +gcc -o myprogram myprogram.c -I$HOME/.pyenv/versions/3.11.3/include/python3.11 -L$HOME/.pyenv/versions/3.11.3/lib -lpython3.11 Run: @@ -52,9 +52,9 @@ Run: */ -const pyConfigPythonpathEnvOffset = 248; -const pyConfigHomeOffset = 256; -const pyConfigModuleSearchPathsOffset = 280; +const pyConfigPythonpathEnvOffset = 272; +const pyConfigHomeOffset = 280; +const pyConfigModuleSearchPathsOffset = 304; Future runPythonProgramFFI( bool sync, diff --git a/src/serious_python_platform_interface/lib/src/gen.dart b/src/serious_python_platform_interface/lib/src/gen.dart index 438b660b..fd7a7c80 100644 --- a/src/serious_python_platform_interface/lib/src/gen.dart +++ b/src/serious_python_platform_interface/lib/src/gen.dart @@ -107,9 +107,9 @@ class CPython { } late final _PyMem_RawCallocPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Size, ffi.Size)>>('PyMem_RawCalloc'); + ffi + .NativeFunction Function(ffi.Size, ffi.Size)>>( + 'PyMem_RawCalloc'); late final _PyMem_RawCalloc = _PyMem_RawCallocPtr.asFunction< ffi.Pointer Function(int, int)>(); @@ -243,6 +243,221 @@ class CPython { late final _PyMem_SetupDebugHooks = _PyMem_SetupDebugHooksPtr.asFunction(); + int PyObject_CheckBuffer( + ffi.Pointer obj, + ) { + return _PyObject_CheckBuffer( + obj, + ); + } + + late final _PyObject_CheckBufferPtr = + _lookup)>>( + 'PyObject_CheckBuffer'); + late final _PyObject_CheckBuffer = _PyObject_CheckBufferPtr.asFunction< + int Function(ffi.Pointer)>(); + + int PyObject_GetBuffer( + ffi.Pointer obj, + ffi.Pointer view, + int flags, + ) { + return _PyObject_GetBuffer( + obj, + view, + flags, + ); + } + + late final _PyObject_GetBufferPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Int)>>('PyObject_GetBuffer'); + late final _PyObject_GetBuffer = _PyObject_GetBufferPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); + + ffi.Pointer PyBuffer_GetPointer( + ffi.Pointer view, + ffi.Pointer indices, + ) { + return _PyBuffer_GetPointer( + view, + indices, + ); + } + + late final _PyBuffer_GetPointerPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyBuffer_GetPointer'); + late final _PyBuffer_GetPointer = _PyBuffer_GetPointerPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); + + int PyBuffer_SizeFromFormat( + ffi.Pointer format, + ) { + return _PyBuffer_SizeFromFormat( + format, + ); + } + + late final _PyBuffer_SizeFromFormatPtr = + _lookup)>>( + 'PyBuffer_SizeFromFormat'); + late final _PyBuffer_SizeFromFormat = _PyBuffer_SizeFromFormatPtr.asFunction< + int Function(ffi.Pointer)>(); + + int PyBuffer_ToContiguous( + ffi.Pointer buf, + ffi.Pointer view, + int len, + int order, + ) { + return _PyBuffer_ToContiguous( + buf, + view, + len, + order, + ); + } + + late final _PyBuffer_ToContiguousPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + Py_ssize_t, ffi.Char)>>('PyBuffer_ToContiguous'); + late final _PyBuffer_ToContiguous = _PyBuffer_ToContiguousPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, int)>(); + + int PyBuffer_FromContiguous( + ffi.Pointer view, + ffi.Pointer buf, + int len, + int order, + ) { + return _PyBuffer_FromContiguous( + view, + buf, + len, + order, + ); + } + + late final _PyBuffer_FromContiguousPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + Py_ssize_t, ffi.Char)>>('PyBuffer_FromContiguous'); + late final _PyBuffer_FromContiguous = _PyBuffer_FromContiguousPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, int)>(); + + int PyObject_CopyData( + ffi.Pointer dest, + ffi.Pointer src, + ) { + return _PyObject_CopyData( + dest, + src, + ); + } + + late final _PyObject_CopyDataPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_CopyData'); + late final _PyObject_CopyData = _PyObject_CopyDataPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); + + int PyBuffer_IsContiguous( + ffi.Pointer view, + int fort, + ) { + return _PyBuffer_IsContiguous( + view, + fort, + ); + } + + late final _PyBuffer_IsContiguousPtr = _lookup< + ffi + .NativeFunction, ffi.Char)>>( + 'PyBuffer_IsContiguous'); + late final _PyBuffer_IsContiguous = _PyBuffer_IsContiguousPtr.asFunction< + int Function(ffi.Pointer, int)>(); + + void PyBuffer_FillContiguousStrides( + int ndims, + ffi.Pointer shape, + ffi.Pointer strides, + int itemsize, + int fort, + ) { + return _PyBuffer_FillContiguousStrides( + ndims, + shape, + strides, + itemsize, + fort, + ); + } + + late final _PyBuffer_FillContiguousStridesPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function( + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Char)>>('PyBuffer_FillContiguousStrides'); + late final _PyBuffer_FillContiguousStrides = + _PyBuffer_FillContiguousStridesPtr.asFunction< + void Function(int, ffi.Pointer, ffi.Pointer, + int, int)>(); + + int PyBuffer_FillInfo( + ffi.Pointer view, + ffi.Pointer o, + ffi.Pointer buf, + int len, + int readonly, + int flags, + ) { + return _PyBuffer_FillInfo( + view, + o, + buf, + len, + readonly, + flags, + ); + } + + late final _PyBuffer_FillInfoPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + Py_ssize_t, + ffi.Int, + ffi.Int)>>('PyBuffer_FillInfo'); + late final _PyBuffer_FillInfo = _PyBuffer_FillInfoPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, int, int, int)>(); + + void PyBuffer_Release( + ffi.Pointer view, + ) { + return _PyBuffer_Release( + view, + ); + } + + late final _PyBuffer_ReleasePtr = + _lookup)>>( + 'PyBuffer_Release'); + late final _PyBuffer_Release = + _PyBuffer_ReleasePtr.asFunction)>(); + int Py_Is( ffi.Pointer x, ffi.Pointer y, @@ -335,7 +550,7 @@ class CPython { ffi.Pointer, ffi.Pointer)>(); ffi.Pointer PyType_GetModule( - ffi.Pointer<_typeobject> arg0, + ffi.Pointer arg0, ) { return _PyType_GetModule( arg0, @@ -345,12 +560,12 @@ class CPython { late final _PyType_GetModulePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer<_typeobject>)>>('PyType_GetModule'); + ffi.Pointer)>>('PyType_GetModule'); late final _PyType_GetModule = _PyType_GetModulePtr.asFunction< - ffi.Pointer Function(ffi.Pointer<_typeobject>)>(); + ffi.Pointer Function(ffi.Pointer)>(); ffi.Pointer PyType_GetModuleState( - ffi.Pointer<_typeobject> arg0, + ffi.Pointer arg0, ) { return _PyType_GetModuleState( arg0, @@ -360,9 +575,39 @@ class CPython { late final _PyType_GetModuleStatePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer<_typeobject>)>>('PyType_GetModuleState'); + ffi.Pointer)>>('PyType_GetModuleState'); late final _PyType_GetModuleState = _PyType_GetModuleStatePtr.asFunction< - ffi.Pointer Function(ffi.Pointer<_typeobject>)>(); + ffi.Pointer Function(ffi.Pointer)>(); + + ffi.Pointer PyType_GetName( + ffi.Pointer arg0, + ) { + return _PyType_GetName( + arg0, + ); + } + + late final _PyType_GetNamePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyType_GetName'); + late final _PyType_GetName = _PyType_GetNamePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + + ffi.Pointer PyType_GetQualName( + ffi.Pointer arg0, + ) { + return _PyType_GetQualName( + arg0, + ); + } + + late final _PyType_GetQualNamePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyType_GetQualName'); + late final _PyType_GetQualName = _PyType_GetQualNamePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); int PyType_IsSubtype( ffi.Pointer arg0, @@ -870,6 +1115,21 @@ class CPython { late final _PyObject_Dir = _PyObject_DirPtr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer _PyObject_GetState( + ffi.Pointer arg0, + ) { + return __PyObject_GetState( + arg0, + ); + } + + late final __PyObject_GetStatePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('_PyObject_GetState'); + late final __PyObject_GetState = __PyObject_GetStatePtr + .asFunction Function(ffi.Pointer)>(); + int Py_ReprEnter( ffi.Pointer arg0, ) { @@ -1085,23 +1345,24 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer<_Py_Identifier>)>(); - ffi.Pointer _PyObject_LookupSpecial( + ffi.Pointer _PyObject_LookupSpecialId( ffi.Pointer arg0, ffi.Pointer<_Py_Identifier> arg1, ) { - return __PyObject_LookupSpecial( + return __PyObject_LookupSpecialId( arg0, arg1, ); } - late final __PyObject_LookupSpecialPtr = _lookup< + late final __PyObject_LookupSpecialIdPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer<_Py_Identifier>)>>('_PyObject_LookupSpecial'); - late final __PyObject_LookupSpecial = __PyObject_LookupSpecialPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer<_Py_Identifier>)>(); + ffi.Pointer<_Py_Identifier>)>>('_PyObject_LookupSpecialId'); + late final __PyObject_LookupSpecialId = + __PyObject_LookupSpecialIdPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer<_Py_Identifier>)>(); ffi.Pointer _PyType_CalculateMetaclass( ffi.Pointer arg0, @@ -1161,21 +1422,21 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyType_GetModuleByDef( + ffi.Pointer PyType_GetModuleByDef( ffi.Pointer arg0, ffi.Pointer arg1, ) { - return __PyType_GetModuleByDef( + return _PyType_GetModuleByDef( arg0, arg1, ); } - late final __PyType_GetModuleByDefPtr = _lookup< + late final _PyType_GetModuleByDefPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyType_GetModuleByDef'); - late final __PyType_GetModuleByDef = __PyType_GetModuleByDefPtr.asFunction< + ffi.Pointer)>>('PyType_GetModuleByDef'); + late final _PyType_GetModuleByDef = _PyType_GetModuleByDefPtr.asFunction< ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); @@ -1576,58 +1837,9 @@ class CPython { late final __PyObject_CheckConsistency = __PyObject_CheckConsistencyPtr .asFunction, int)>(); - void _PyTrash_deposit_object( - ffi.Pointer arg0, - ) { - return __PyTrash_deposit_object( - arg0, - ); - } - - late final __PyTrash_deposit_objectPtr = - _lookup)>>( - '_PyTrash_deposit_object'); - late final __PyTrash_deposit_object = __PyTrash_deposit_objectPtr - .asFunction)>(); - - void _PyTrash_destroy_chain() { - return __PyTrash_destroy_chain(); - } - - late final __PyTrash_destroy_chainPtr = - _lookup>( - '_PyTrash_destroy_chain'); - late final __PyTrash_destroy_chain = - __PyTrash_destroy_chainPtr.asFunction(); - - void _PyTrash_thread_deposit_object( - ffi.Pointer arg0, - ) { - return __PyTrash_thread_deposit_object( - arg0, - ); - } - - late final __PyTrash_thread_deposit_objectPtr = - _lookup)>>( - '_PyTrash_thread_deposit_object'); - late final __PyTrash_thread_deposit_object = - __PyTrash_thread_deposit_objectPtr - .asFunction)>(); - - void _PyTrash_thread_destroy_chain() { - return __PyTrash_thread_destroy_chain(); - } - - late final __PyTrash_thread_destroy_chainPtr = - _lookup>( - '_PyTrash_thread_destroy_chain'); - late final __PyTrash_thread_destroy_chain = - __PyTrash_thread_destroy_chainPtr.asFunction(); - - int _PyTrash_begin( - ffi.Pointer<_ts> tstate, - ffi.Pointer op, + int _PyTrash_begin( + ffi.Pointer tstate, + ffi.Pointer op, ) { return __PyTrash_begin( tstate, @@ -1637,24 +1849,24 @@ class CPython { late final __PyTrash_beginPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_ts>, ffi.Pointer)>>('_PyTrash_begin'); - late final __PyTrash_begin = __PyTrash_beginPtr - .asFunction, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyTrash_begin'); + late final __PyTrash_begin = __PyTrash_beginPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); void _PyTrash_end( - ffi.Pointer<_ts> tstate, + ffi.Pointer tstate, ) { return __PyTrash_end( tstate, ); } - late final __PyTrash_endPtr = - _lookup)>>( - '_PyTrash_end'); + late final __PyTrash_endPtr = _lookup< + ffi.NativeFunction)>>( + '_PyTrash_end'); late final __PyTrash_end = - __PyTrash_endPtr.asFunction)>(); + __PyTrash_endPtr.asFunction)>(); int _PyTrash_cond( ffi.Pointer op, @@ -1667,9 +1879,9 @@ class CPython { } late final __PyTrash_condPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, destructor)>>('_PyTrash_cond'); + ffi + .NativeFunction, destructor)>>( + '_PyTrash_cond'); late final __PyTrash_cond = __PyTrash_condPtr .asFunction, destructor)>(); @@ -1698,9 +1910,9 @@ class CPython { } late final _PyObject_CallocPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Size, ffi.Size)>>('PyObject_Calloc'); + ffi + .NativeFunction Function(ffi.Size, ffi.Size)>>( + 'PyObject_Calloc'); late final _PyObject_Calloc = _PyObject_CallocPtr.asFunction< ffi.Pointer Function(int, int)>(); @@ -1956,30 +2168,6 @@ class CPython { late final _PyObject_GC_IsFinalized = _PyObject_GC_IsFinalizedPtr.asFunction< int Function(ffi.Pointer)>(); - int _Py_GetAllocatedBlocks() { - return __Py_GetAllocatedBlocks(); - } - - late final __Py_GetAllocatedBlocksPtr = - _lookup>( - '_Py_GetAllocatedBlocks'); - late final __Py_GetAllocatedBlocks = - __Py_GetAllocatedBlocksPtr.asFunction(); - - int _PyObject_DebugMallocStats( - ffi.Pointer out, - ) { - return __PyObject_DebugMallocStats( - out, - ); - } - - late final __PyObject_DebugMallocStatsPtr = - _lookup)>>( - '_PyObject_DebugMallocStats'); - late final __PyObject_DebugMallocStats = __PyObject_DebugMallocStatsPtr - .asFunction)>(); - void PyObject_GetArenaAllocator( ffi.Pointer allocator, ) { @@ -2024,33 +2212,19 @@ class CPython { late final _PyObject_IS_GC = _PyObject_IS_GCPtr.asFunction)>(); - ffi.Pointer _PyObject_GC_Malloc( - int size, - ) { - return __PyObject_GC_Malloc( - size, - ); - } - - late final __PyObject_GC_MallocPtr = - _lookup Function(ffi.Size)>>( - '_PyObject_GC_Malloc'); - late final __PyObject_GC_Malloc = - __PyObject_GC_MallocPtr.asFunction Function(int)>(); - - ffi.Pointer _PyObject_GC_Calloc( - int size, + int PyType_SUPPORTS_WEAKREFS( + ffi.Pointer type, ) { - return __PyObject_GC_Calloc( - size, + return _PyType_SUPPORTS_WEAKREFS( + type, ); } - late final __PyObject_GC_CallocPtr = - _lookup Function(ffi.Size)>>( - '_PyObject_GC_Calloc'); - late final __PyObject_GC_Calloc = - __PyObject_GC_CallocPtr.asFunction Function(int)>(); + late final _PyType_SUPPORTS_WEAKREFSPtr = + _lookup)>>( + 'PyType_SUPPORTS_WEAKREFS'); + late final _PyType_SUPPORTS_WEAKREFS = _PyType_SUPPORTS_WEAKREFSPtr + .asFunction)>(); ffi.Pointer> PyObject_GET_WEAKREFS_LISTPTR( ffi.Pointer op, @@ -2255,6 +2429,20 @@ class CPython { set Py_IsolatedFlag(int value) => _Py_IsolatedFlag.value = value; + ffi.Pointer Py_GETENV( + ffi.Pointer name, + ) { + return _Py_GETENV( + name, + ); + } + + late final _Py_GETENVPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer)>>('Py_GETENV'); + late final _Py_GETENV = _Py_GETENVPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + late final ffi.Pointer _PyByteArray_Type = _lookup('PyByteArray_Type'); @@ -2355,9 +2543,9 @@ class CPython { } late final _PyByteArray_ResizePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, Py_ssize_t)>>('PyByteArray_Resize'); + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyByteArray_Resize'); late final _PyByteArray_Resize = _PyByteArray_ResizePtr.asFunction< int Function(ffi.Pointer, int)>(); @@ -2956,9 +3144,9 @@ class CPython { } late final _PyUnicode_ReadCharPtr = _lookup< - ffi.NativeFunction< - Py_UCS4 Function( - ffi.Pointer, Py_ssize_t)>>('PyUnicode_ReadChar'); + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicode_ReadChar'); late final _PyUnicode_ReadChar = _PyUnicode_ReadCharPtr.asFunction< int Function(ffi.Pointer, int)>(); @@ -4380,9 +4568,9 @@ class CPython { } late final _PyUnicode_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - Py_ssize_t, Py_UCS4)>>('PyUnicode_New'); + ffi + .NativeFunction Function(Py_ssize_t, Py_UCS4)>>( + 'PyUnicode_New'); late final _PyUnicode_New = _PyUnicode_NewPtr.asFunction Function(int, int)>(); @@ -4515,23 +4703,6 @@ class CPython { late final __PyUnicode_FastFill = __PyUnicode_FastFillPtr .asFunction, int, int, int)>(); - ffi.Pointer PyUnicode_FromUnicode( - ffi.Pointer u, - int size, - ) { - return _PyUnicode_FromUnicode( - u, - size, - ); - } - - late final _PyUnicode_FromUnicodePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, Py_ssize_t)>>('PyUnicode_FromUnicode'); - late final _PyUnicode_FromUnicode = _PyUnicode_FromUnicodePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); - ffi.Pointer PyUnicode_FromKindAndData( int kind, ffi.Pointer buffer, @@ -4588,6 +4759,23 @@ class CPython { late final __PyUnicode_FindMaxChar = __PyUnicode_FindMaxCharPtr .asFunction, int, int)>(); + ffi.Pointer PyUnicode_FromUnicode( + ffi.Pointer u, + int size, + ) { + return _PyUnicode_FromUnicode( + u, + size, + ); + } + + late final _PyUnicode_FromUnicodePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, Py_ssize_t)>>('PyUnicode_FromUnicode'); + late final _PyUnicode_FromUnicode = _PyUnicode_FromUnicodePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); + ffi.Pointer PyUnicode_AsUnicode( ffi.Pointer unicode, ) { @@ -4862,59 +5050,6 @@ class CPython { late final _PyUnicode_AsUTF8 = _PyUnicode_AsUTF8Ptr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyUnicode_Encode( - ffi.Pointer s, - int size, - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return _PyUnicode_Encode( - s, - size, - encoding, - errors, - ); - } - - late final _PyUnicode_EncodePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer)>>('PyUnicode_Encode'); - late final _PyUnicode_Encode = _PyUnicode_EncodePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int, - ffi.Pointer, ffi.Pointer)>(); - - ffi.Pointer PyUnicode_EncodeUTF7( - ffi.Pointer data, - int length, - int base64SetO, - int base64WhiteSpace, - ffi.Pointer errors, - ) { - return _PyUnicode_EncodeUTF71( - data, - length, - base64SetO, - base64WhiteSpace, - errors, - ); - } - - late final _PyUnicode_EncodeUTF7Ptr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - ffi.Int, - ffi.Int, - ffi.Pointer)>>('PyUnicode_EncodeUTF7'); - late final _PyUnicode_EncodeUTF71 = _PyUnicode_EncodeUTF7Ptr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, int, int, ffi.Pointer)>(); - ffi.Pointer _PyUnicode_EncodeUTF7( ffi.Pointer unicode, int base64SetO, @@ -4955,48 +5090,6 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyUnicode_EncodeUTF8( - ffi.Pointer data, - int length, - ffi.Pointer errors, - ) { - return _PyUnicode_EncodeUTF8( - data, - length, - errors, - ); - } - - late final _PyUnicode_EncodeUTF8Ptr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PyUnicode_EncodeUTF8'); - late final _PyUnicode_EncodeUTF8 = _PyUnicode_EncodeUTF8Ptr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, ffi.Pointer)>(); - - ffi.Pointer PyUnicode_EncodeUTF32( - ffi.Pointer data, - int length, - ffi.Pointer errors, - int byteorder, - ) { - return _PyUnicode_EncodeUTF321( - data, - length, - errors, - byteorder, - ); - } - - late final _PyUnicode_EncodeUTF32Ptr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer, ffi.Int)>>('PyUnicode_EncodeUTF32'); - late final _PyUnicode_EncodeUTF321 = _PyUnicode_EncodeUTF32Ptr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, ffi.Pointer, int)>(); - ffi.Pointer _PyUnicode_EncodeUTF32( ffi.Pointer object, ffi.Pointer errors, @@ -5017,28 +5110,6 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer, int)>(); - ffi.Pointer PyUnicode_EncodeUTF16( - ffi.Pointer data, - int length, - ffi.Pointer errors, - int byteorder, - ) { - return _PyUnicode_EncodeUTF161( - data, - length, - errors, - byteorder, - ); - } - - late final _PyUnicode_EncodeUTF16Ptr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer, ffi.Int)>>('PyUnicode_EncodeUTF16'); - late final _PyUnicode_EncodeUTF161 = _PyUnicode_EncodeUTF16Ptr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, ffi.Pointer, int)>(); - ffi.Pointer _PyUnicode_EncodeUTF16( ffi.Pointer unicode, ffi.Pointer errors, @@ -5117,42 +5188,6 @@ class CPython { ffi.Pointer, ffi.Pointer>)>(); - ffi.Pointer PyUnicode_EncodeUnicodeEscape( - ffi.Pointer data, - int length, - ) { - return _PyUnicode_EncodeUnicodeEscape( - data, - length, - ); - } - - late final _PyUnicode_EncodeUnicodeEscapePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicode_EncodeUnicodeEscape'); - late final _PyUnicode_EncodeUnicodeEscape = - _PyUnicode_EncodeUnicodeEscapePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); - - ffi.Pointer PyUnicode_EncodeRawUnicodeEscape( - ffi.Pointer data, - int length, - ) { - return _PyUnicode_EncodeRawUnicodeEscape( - data, - length, - ); - } - - late final _PyUnicode_EncodeRawUnicodeEscapePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicode_EncodeRawUnicodeEscape'); - late final _PyUnicode_EncodeRawUnicodeEscape = - _PyUnicode_EncodeRawUnicodeEscapePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); - ffi.Pointer _PyUnicode_DecodeRawUnicodeEscapeStateful( ffi.Pointer string, int length, @@ -5196,26 +5231,6 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyUnicode_EncodeLatin1( - ffi.Pointer data, - int length, - ffi.Pointer errors, - ) { - return _PyUnicode_EncodeLatin1( - data, - length, - errors, - ); - } - - late final _PyUnicode_EncodeLatin1Ptr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PyUnicode_EncodeLatin1'); - late final _PyUnicode_EncodeLatin1 = _PyUnicode_EncodeLatin1Ptr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, ffi.Pointer)>(); - ffi.Pointer _PyUnicode_AsASCIIString( ffi.Pointer unicode, ffi.Pointer errors, @@ -5235,51 +5250,6 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyUnicode_EncodeASCII( - ffi.Pointer data, - int length, - ffi.Pointer errors, - ) { - return _PyUnicode_EncodeASCII( - data, - length, - errors, - ); - } - - late final _PyUnicode_EncodeASCIIPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PyUnicode_EncodeASCII'); - late final _PyUnicode_EncodeASCII = _PyUnicode_EncodeASCIIPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, ffi.Pointer)>(); - - ffi.Pointer PyUnicode_EncodeCharmap( - ffi.Pointer data, - int length, - ffi.Pointer mapping, - ffi.Pointer errors, - ) { - return _PyUnicode_EncodeCharmap1( - data, - length, - mapping, - errors, - ); - } - - late final _PyUnicode_EncodeCharmapPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer)>>('PyUnicode_EncodeCharmap'); - late final _PyUnicode_EncodeCharmap1 = _PyUnicode_EncodeCharmapPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int, - ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyUnicode_EncodeCharmap( ffi.Pointer unicode, ffi.Pointer mapping, @@ -5303,90 +5273,21 @@ class CPython { ffi.Pointer Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyUnicode_TranslateCharmap( - ffi.Pointer data, - int length, - ffi.Pointer table, - ffi.Pointer errors, + ffi.Pointer _PyUnicode_TransformDecimalAndSpaceToASCII( + ffi.Pointer unicode, ) { - return _PyUnicode_TranslateCharmap( - data, - length, - table, - errors, + return __PyUnicode_TransformDecimalAndSpaceToASCII( + unicode, ); } - late final _PyUnicode_TranslateCharmapPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer)>>('PyUnicode_TranslateCharmap'); - late final _PyUnicode_TranslateCharmap = - _PyUnicode_TranslateCharmapPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int, - ffi.Pointer, ffi.Pointer)>(); - - int PyUnicode_EncodeDecimal( - ffi.Pointer s, - int length, - ffi.Pointer output, - ffi.Pointer errors, - ) { - return _PyUnicode_EncodeDecimal( - s, - length, - output, - errors, - ); - } - - late final _PyUnicode_EncodeDecimalPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer)>>('PyUnicode_EncodeDecimal'); - late final _PyUnicode_EncodeDecimal = _PyUnicode_EncodeDecimalPtr.asFunction< - int Function(ffi.Pointer, int, ffi.Pointer, - ffi.Pointer)>(); - - ffi.Pointer PyUnicode_TransformDecimalToASCII( - ffi.Pointer s, - int length, - ) { - return _PyUnicode_TransformDecimalToASCII( - s, - length, - ); - } - - late final _PyUnicode_TransformDecimalToASCIIPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicode_TransformDecimalToASCII'); - late final _PyUnicode_TransformDecimalToASCII = - _PyUnicode_TransformDecimalToASCIIPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); - - ffi.Pointer _PyUnicode_TransformDecimalAndSpaceToASCII( - ffi.Pointer unicode, - ) { - return __PyUnicode_TransformDecimalAndSpaceToASCII( - unicode, - ); - } - - late final __PyUnicode_TransformDecimalAndSpaceToASCIIPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer)>>( - '_PyUnicode_TransformDecimalAndSpaceToASCII'); - late final __PyUnicode_TransformDecimalAndSpaceToASCII = - __PyUnicode_TransformDecimalAndSpaceToASCIIPtr - .asFunction Function(ffi.Pointer)>(); + late final __PyUnicode_TransformDecimalAndSpaceToASCIIPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer)>>( + '_PyUnicode_TransformDecimalAndSpaceToASCII'); + late final __PyUnicode_TransformDecimalAndSpaceToASCII = + __PyUnicode_TransformDecimalAndSpaceToASCIIPtr + .asFunction Function(ffi.Pointer)>(); ffi.Pointer _PyUnicode_JoinArray( ffi.Pointer separator, @@ -5920,6 +5821,23 @@ class CPython { late final __PyUnicode_EQ = __PyUnicode_EQPtr .asFunction, ffi.Pointer)>(); + int _PyUnicode_Equal( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return __PyUnicode_Equal( + arg0, + arg1, + ); + } + + late final __PyUnicode_EqualPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyUnicode_Equal'); + late final __PyUnicode_Equal = __PyUnicode_EqualPtr + .asFunction, ffi.Pointer)>(); + int _PyUnicode_WideCharString_Converter( ffi.Pointer arg0, ffi.Pointer arg1, @@ -6132,20 +6050,6 @@ class CPython { late final _PyLong_AsUnsignedLongMask = _PyLong_AsUnsignedLongMaskPtr .asFunction)>(); - int _PyLong_AsInt( - ffi.Pointer arg0, - ) { - return __PyLong_AsInt( - arg0, - ); - } - - late final __PyLong_AsIntPtr = - _lookup)>>( - '_PyLong_AsInt'); - late final __PyLong_AsInt = - __PyLong_AsIntPtr.asFunction)>(); - ffi.Pointer PyLong_GetInfo() { return _PyLong_GetInfo(); } @@ -6156,120 +6060,6 @@ class CPython { late final _PyLong_GetInfo = _PyLong_GetInfoPtr.asFunction Function()>(); - int _PyLong_UnsignedShort_Converter( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return __PyLong_UnsignedShort_Converter( - arg0, - arg1, - ); - } - - late final __PyLong_UnsignedShort_ConverterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyLong_UnsignedShort_Converter'); - late final __PyLong_UnsignedShort_Converter = - __PyLong_UnsignedShort_ConverterPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); - - int _PyLong_UnsignedInt_Converter( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return __PyLong_UnsignedInt_Converter( - arg0, - arg1, - ); - } - - late final __PyLong_UnsignedInt_ConverterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyLong_UnsignedInt_Converter'); - late final __PyLong_UnsignedInt_Converter = __PyLong_UnsignedInt_ConverterPtr - .asFunction, ffi.Pointer)>(); - - int _PyLong_UnsignedLong_Converter( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return __PyLong_UnsignedLong_Converter( - arg0, - arg1, - ); - } - - late final __PyLong_UnsignedLong_ConverterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyLong_UnsignedLong_Converter'); - late final __PyLong_UnsignedLong_Converter = - __PyLong_UnsignedLong_ConverterPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); - - int _PyLong_UnsignedLongLong_Converter( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return __PyLong_UnsignedLongLong_Converter( - arg0, - arg1, - ); - } - - late final __PyLong_UnsignedLongLong_ConverterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyLong_UnsignedLongLong_Converter'); - late final __PyLong_UnsignedLongLong_Converter = - __PyLong_UnsignedLongLong_ConverterPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); - - int _PyLong_Size_t_Converter( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return __PyLong_Size_t_Converter( - arg0, - arg1, - ); - } - - late final __PyLong_Size_t_ConverterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyLong_Size_t_Converter'); - late final __PyLong_Size_t_Converter = __PyLong_Size_t_ConverterPtr - .asFunction, ffi.Pointer)>(); - - late final ffi.Pointer> __PyLong_DigitValue = - _lookup>('_PyLong_DigitValue'); - - ffi.Pointer get _PyLong_DigitValue => - __PyLong_DigitValue.value; - - set _PyLong_DigitValue(ffi.Pointer value) => - __PyLong_DigitValue.value = value; - - double _PyLong_Frexp( - ffi.Pointer a, - ffi.Pointer e, - ) { - return __PyLong_Frexp( - a, - e, - ); - } - - late final __PyLong_FrexpPtr = _lookup< - ffi.NativeFunction< - ffi.Double Function(ffi.Pointer, - ffi.Pointer)>>('_PyLong_Frexp'); - late final __PyLong_Frexp = __PyLong_FrexpPtr.asFunction< - double Function(ffi.Pointer, ffi.Pointer)>(); - double PyLong_AsDouble( ffi.Pointer arg0, ) { @@ -6426,75 +6216,234 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer>, int)>(); - ffi.Pointer PyLong_FromUnicodeObject( - ffi.Pointer u, - int base, + int PyOS_strtoul( + ffi.Pointer arg0, + ffi.Pointer> arg1, + int arg2, ) { - return _PyLong_FromUnicodeObject( - u, - base, + return _PyOS_strtoul( + arg0, + arg1, + arg2, ); } - late final _PyLong_FromUnicodeObjectPtr = _lookup< + late final _PyOS_strtoulPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Int)>>('PyLong_FromUnicodeObject'); - late final _PyLong_FromUnicodeObject = _PyLong_FromUnicodeObjectPtr - .asFunction Function(ffi.Pointer, int)>(); + ffi.UnsignedLong Function(ffi.Pointer, + ffi.Pointer>, ffi.Int)>>('PyOS_strtoul'); + late final _PyOS_strtoul = _PyOS_strtoulPtr.asFunction< + int Function( + ffi.Pointer, ffi.Pointer>, int)>(); - ffi.Pointer _PyLong_FromBytes( + int PyOS_strtol( ffi.Pointer arg0, - int arg1, + ffi.Pointer> arg1, int arg2, ) { - return __PyLong_FromBytes( + return _PyOS_strtol( arg0, arg1, arg2, ); } - late final __PyLong_FromBytesPtr = _lookup< + late final _PyOS_strtolPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - ffi.Int)>>('_PyLong_FromBytes'); - late final __PyLong_FromBytes = __PyLong_FromBytesPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int, int)>(); + ffi.Long Function(ffi.Pointer, + ffi.Pointer>, ffi.Int)>>('PyOS_strtol'); + late final _PyOS_strtol = _PyOS_strtolPtr.asFunction< + int Function( + ffi.Pointer, ffi.Pointer>, int)>(); - int _PyLong_Sign( - ffi.Pointer v, + int _PyLong_AsInt( + ffi.Pointer arg0, ) { - return __PyLong_Sign( - v, + return __PyLong_AsInt( + arg0, ); } - late final __PyLong_SignPtr = + late final __PyLong_AsIntPtr = _lookup)>>( - '_PyLong_Sign'); - late final __PyLong_Sign = - __PyLong_SignPtr.asFunction)>(); + '_PyLong_AsInt'); + late final __PyLong_AsInt = + __PyLong_AsIntPtr.asFunction)>(); - int _PyLong_NumBits( - ffi.Pointer v, + int _PyLong_UnsignedShort_Converter( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __PyLong_NumBits( - v, + return __PyLong_UnsignedShort_Converter( + arg0, + arg1, ); } - late final __PyLong_NumBitsPtr = - _lookup)>>( - '_PyLong_NumBits'); - late final __PyLong_NumBits = - __PyLong_NumBitsPtr.asFunction)>(); + late final __PyLong_UnsignedShort_ConverterPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyLong_UnsignedShort_Converter'); + late final __PyLong_UnsignedShort_Converter = + __PyLong_UnsignedShort_ConverterPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyLong_DivmodNear( + int _PyLong_UnsignedInt_Converter( ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer arg1, ) { - return __PyLong_DivmodNear( + return __PyLong_UnsignedInt_Converter( + arg0, + arg1, + ); + } + + late final __PyLong_UnsignedInt_ConverterPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyLong_UnsignedInt_Converter'); + late final __PyLong_UnsignedInt_Converter = __PyLong_UnsignedInt_ConverterPtr + .asFunction, ffi.Pointer)>(); + + int _PyLong_UnsignedLong_Converter( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return __PyLong_UnsignedLong_Converter( + arg0, + arg1, + ); + } + + late final __PyLong_UnsignedLong_ConverterPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyLong_UnsignedLong_Converter'); + late final __PyLong_UnsignedLong_Converter = + __PyLong_UnsignedLong_ConverterPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); + + int _PyLong_UnsignedLongLong_Converter( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return __PyLong_UnsignedLongLong_Converter( + arg0, + arg1, + ); + } + + late final __PyLong_UnsignedLongLong_ConverterPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyLong_UnsignedLongLong_Converter'); + late final __PyLong_UnsignedLongLong_Converter = + __PyLong_UnsignedLongLong_ConverterPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); + + int _PyLong_Size_t_Converter( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return __PyLong_Size_t_Converter( + arg0, + arg1, + ); + } + + late final __PyLong_Size_t_ConverterPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyLong_Size_t_Converter'); + late final __PyLong_Size_t_Converter = __PyLong_Size_t_ConverterPtr + .asFunction, ffi.Pointer)>(); + + double _PyLong_Frexp( + ffi.Pointer a, + ffi.Pointer e, + ) { + return __PyLong_Frexp( + a, + e, + ); + } + + late final __PyLong_FrexpPtr = _lookup< + ffi.NativeFunction< + ffi.Double Function(ffi.Pointer, + ffi.Pointer)>>('_PyLong_Frexp'); + late final __PyLong_Frexp = __PyLong_FrexpPtr.asFunction< + double Function(ffi.Pointer, ffi.Pointer)>(); + + ffi.Pointer PyLong_FromUnicodeObject( + ffi.Pointer u, + int base, + ) { + return _PyLong_FromUnicodeObject( + u, + base, + ); + } + + late final _PyLong_FromUnicodeObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Int)>>('PyLong_FromUnicodeObject'); + late final _PyLong_FromUnicodeObject = _PyLong_FromUnicodeObjectPtr + .asFunction Function(ffi.Pointer, int)>(); + + ffi.Pointer _PyLong_FromBytes( + ffi.Pointer arg0, + int arg1, + int arg2, + ) { + return __PyLong_FromBytes( + arg0, + arg1, + arg2, + ); + } + + late final __PyLong_FromBytesPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, Py_ssize_t, + ffi.Int)>>('_PyLong_FromBytes'); + late final __PyLong_FromBytes = __PyLong_FromBytesPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int, int)>(); + + int _PyLong_Sign( + ffi.Pointer v, + ) { + return __PyLong_Sign( + v, + ); + } + + late final __PyLong_SignPtr = + _lookup)>>( + '_PyLong_Sign'); + late final __PyLong_Sign = + __PyLong_SignPtr.asFunction)>(); + + int _PyLong_NumBits( + ffi.Pointer v, + ) { + return __PyLong_NumBits( + v, + ); + } + + late final __PyLong_NumBitsPtr = + _lookup)>>( + '_PyLong_NumBits'); + late final __PyLong_NumBits = + __PyLong_NumBitsPtr.asFunction)>(); + + ffi.Pointer _PyLong_DivmodNear( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return __PyLong_DivmodNear( arg0, arg1, ); @@ -6575,126 +6524,6 @@ class CPython { late final __PyLong_Format = __PyLong_FormatPtr .asFunction Function(ffi.Pointer, int)>(); - int _PyLong_FormatWriter( - ffi.Pointer<_PyUnicodeWriter> writer, - ffi.Pointer obj, - int base, - int alternate, - ) { - return __PyLong_FormatWriter( - writer, - obj, - base, - alternate, - ); - } - - late final __PyLong_FormatWriterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_PyUnicodeWriter>, ffi.Pointer, - ffi.Int, ffi.Int)>>('_PyLong_FormatWriter'); - late final __PyLong_FormatWriter = __PyLong_FormatWriterPtr.asFunction< - int Function( - ffi.Pointer<_PyUnicodeWriter>, ffi.Pointer, int, int)>(); - - ffi.Pointer _PyLong_FormatBytesWriter( - ffi.Pointer<_PyBytesWriter> writer, - ffi.Pointer str, - ffi.Pointer obj, - int base, - int alternate, - ) { - return __PyLong_FormatBytesWriter( - writer, - str, - obj, - base, - alternate, - ); - } - - late final __PyLong_FormatBytesWriterPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer<_PyBytesWriter>, - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Int)>>('_PyLong_FormatBytesWriter'); - late final __PyLong_FormatBytesWriter = - __PyLong_FormatBytesWriterPtr.asFunction< - ffi.Pointer Function(ffi.Pointer<_PyBytesWriter>, - ffi.Pointer, ffi.Pointer, int, int)>(); - - int _PyLong_FormatAdvancedWriter( - ffi.Pointer<_PyUnicodeWriter> writer, - ffi.Pointer obj, - ffi.Pointer format_spec, - int start, - int end, - ) { - return __PyLong_FormatAdvancedWriter( - writer, - obj, - format_spec, - start, - end, - ); - } - - late final __PyLong_FormatAdvancedWriterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_PyUnicodeWriter>, - ffi.Pointer, - ffi.Pointer, - Py_ssize_t, - Py_ssize_t)>>('_PyLong_FormatAdvancedWriter'); - late final __PyLong_FormatAdvancedWriter = - __PyLong_FormatAdvancedWriterPtr.asFunction< - int Function(ffi.Pointer<_PyUnicodeWriter>, ffi.Pointer, - ffi.Pointer, int, int)>(); - - int PyOS_strtoul( - ffi.Pointer arg0, - ffi.Pointer> arg1, - int arg2, - ) { - return _PyOS_strtoul( - arg0, - arg1, - arg2, - ); - } - - late final _PyOS_strtoulPtr = _lookup< - ffi.NativeFunction< - ffi.UnsignedLong Function(ffi.Pointer, - ffi.Pointer>, ffi.Int)>>('PyOS_strtoul'); - late final _PyOS_strtoul = _PyOS_strtoulPtr.asFunction< - int Function( - ffi.Pointer, ffi.Pointer>, int)>(); - - int PyOS_strtol( - ffi.Pointer arg0, - ffi.Pointer> arg1, - int arg2, - ) { - return _PyOS_strtol( - arg0, - arg1, - arg2, - ); - } - - late final _PyOS_strtolPtr = _lookup< - ffi.NativeFunction< - ffi.Long Function(ffi.Pointer, - ffi.Pointer>, ffi.Int)>>('PyOS_strtol'); - late final _PyOS_strtol = _PyOS_strtolPtr.asFunction< - int Function( - ffi.Pointer, ffi.Pointer>, int)>(); - ffi.Pointer _PyLong_GCD( ffi.Pointer arg0, ffi.Pointer arg1, @@ -6781,15 +6610,15 @@ class CPython { PyTypeObject get PyBool_Type => _PyBool_Type.ref; - late final ffi.Pointer<_longobject> __Py_FalseStruct = - _lookup<_longobject>('_Py_FalseStruct'); + late final ffi.Pointer __Py_FalseStruct = + _lookup('_Py_FalseStruct'); - _longobject get _Py_FalseStruct => __Py_FalseStruct.ref; + PyLongObject get _Py_FalseStruct => __Py_FalseStruct.ref; - late final ffi.Pointer<_longobject> __Py_TrueStruct = - _lookup<_longobject>('_Py_TrueStruct'); + late final ffi.Pointer __Py_TrueStruct = + _lookup('_Py_TrueStruct'); - _longobject get _Py_TrueStruct => __Py_TrueStruct.ref; + PyLongObject get _Py_TrueStruct => __Py_TrueStruct.ref; int Py_IsTrue( ffi.Pointer x, @@ -6909,156 +6738,163 @@ class CPython { late final _PyFloat_AsDouble = _PyFloat_AsDoublePtr.asFunction)>(); - int _PyFloat_Pack2( + int PyFloat_Pack2( double x, - ffi.Pointer p, + ffi.Pointer p, int le, ) { - return __PyFloat_Pack2( + return _PyFloat_Pack2( x, p, le, ); } - late final __PyFloat_Pack2Ptr = _lookup< + late final _PyFloat_Pack2Ptr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Double, ffi.Pointer, - ffi.Int)>>('_PyFloat_Pack2'); - late final __PyFloat_Pack2 = __PyFloat_Pack2Ptr - .asFunction, int)>(); + ffi.Int Function( + ffi.Double, ffi.Pointer, ffi.Int)>>('PyFloat_Pack2'); + late final _PyFloat_Pack2 = _PyFloat_Pack2Ptr.asFunction< + int Function(double, ffi.Pointer, int)>(); - int _PyFloat_Pack4( + int PyFloat_Pack4( double x, - ffi.Pointer p, + ffi.Pointer p, int le, ) { - return __PyFloat_Pack4( + return _PyFloat_Pack4( x, p, le, ); } - late final __PyFloat_Pack4Ptr = _lookup< + late final _PyFloat_Pack4Ptr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Double, ffi.Pointer, - ffi.Int)>>('_PyFloat_Pack4'); - late final __PyFloat_Pack4 = __PyFloat_Pack4Ptr - .asFunction, int)>(); + ffi.Int Function( + ffi.Double, ffi.Pointer, ffi.Int)>>('PyFloat_Pack4'); + late final _PyFloat_Pack4 = _PyFloat_Pack4Ptr.asFunction< + int Function(double, ffi.Pointer, int)>(); - int _PyFloat_Pack8( + int PyFloat_Pack8( double x, - ffi.Pointer p, + ffi.Pointer p, int le, ) { - return __PyFloat_Pack8( + return _PyFloat_Pack8( x, p, le, ); } - late final __PyFloat_Pack8Ptr = _lookup< + late final _PyFloat_Pack8Ptr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Double, ffi.Pointer, - ffi.Int)>>('_PyFloat_Pack8'); - late final __PyFloat_Pack8 = __PyFloat_Pack8Ptr - .asFunction, int)>(); + ffi.Int Function( + ffi.Double, ffi.Pointer, ffi.Int)>>('PyFloat_Pack8'); + late final _PyFloat_Pack8 = _PyFloat_Pack8Ptr.asFunction< + int Function(double, ffi.Pointer, int)>(); - double _PyFloat_Unpack2( - ffi.Pointer p, + double PyFloat_Unpack2( + ffi.Pointer p, int le, ) { - return __PyFloat_Unpack2( + return _PyFloat_Unpack2( p, le, ); } - late final __PyFloat_Unpack2Ptr = _lookup< - ffi.NativeFunction< - ffi.Double Function( - ffi.Pointer, ffi.Int)>>('_PyFloat_Unpack2'); - late final __PyFloat_Unpack2 = __PyFloat_Unpack2Ptr - .asFunction, int)>(); + late final _PyFloat_Unpack2Ptr = _lookup< + ffi + .NativeFunction, ffi.Int)>>( + 'PyFloat_Unpack2'); + late final _PyFloat_Unpack2 = _PyFloat_Unpack2Ptr.asFunction< + double Function(ffi.Pointer, int)>(); - double _PyFloat_Unpack4( - ffi.Pointer p, + double PyFloat_Unpack4( + ffi.Pointer p, int le, ) { - return __PyFloat_Unpack4( + return _PyFloat_Unpack4( p, le, ); } - late final __PyFloat_Unpack4Ptr = _lookup< - ffi.NativeFunction< - ffi.Double Function( - ffi.Pointer, ffi.Int)>>('_PyFloat_Unpack4'); - late final __PyFloat_Unpack4 = __PyFloat_Unpack4Ptr - .asFunction, int)>(); + late final _PyFloat_Unpack4Ptr = _lookup< + ffi + .NativeFunction, ffi.Int)>>( + 'PyFloat_Unpack4'); + late final _PyFloat_Unpack4 = _PyFloat_Unpack4Ptr.asFunction< + double Function(ffi.Pointer, int)>(); - double _PyFloat_Unpack8( - ffi.Pointer p, + double PyFloat_Unpack8( + ffi.Pointer p, int le, ) { - return __PyFloat_Unpack8( + return _PyFloat_Unpack8( p, le, ); } - late final __PyFloat_Unpack8Ptr = _lookup< + late final _PyFloat_Unpack8Ptr = _lookup< + ffi + .NativeFunction, ffi.Int)>>( + 'PyFloat_Unpack8'); + late final _PyFloat_Unpack8 = _PyFloat_Unpack8Ptr.asFunction< + double Function(ffi.Pointer, int)>(); + + late final ffi.Pointer _PyComplex_Type = + _lookup('PyComplex_Type'); + + PyTypeObject get PyComplex_Type => _PyComplex_Type.ref; + + ffi.Pointer PyComplex_FromDoubles( + double real, + double imag, + ) { + return _PyComplex_FromDoubles( + real, + imag, + ); + } + + late final _PyComplex_FromDoublesPtr = _lookup< ffi.NativeFunction< - ffi.Double Function( - ffi.Pointer, ffi.Int)>>('_PyFloat_Unpack8'); - late final __PyFloat_Unpack8 = __PyFloat_Unpack8Ptr - .asFunction, int)>(); + ffi.Pointer Function( + ffi.Double, ffi.Double)>>('PyComplex_FromDoubles'); + late final _PyComplex_FromDoubles = _PyComplex_FromDoublesPtr.asFunction< + ffi.Pointer Function(double, double)>(); - void _PyFloat_DebugMallocStats( - ffi.Pointer out, + double PyComplex_RealAsDouble( + ffi.Pointer op, ) { - return __PyFloat_DebugMallocStats( - out, + return _PyComplex_RealAsDouble( + op, ); } - late final __PyFloat_DebugMallocStatsPtr = - _lookup)>>( - '_PyFloat_DebugMallocStats'); - late final __PyFloat_DebugMallocStats = __PyFloat_DebugMallocStatsPtr - .asFunction)>(); + late final _PyComplex_RealAsDoublePtr = + _lookup)>>( + 'PyComplex_RealAsDouble'); + late final _PyComplex_RealAsDouble = _PyComplex_RealAsDoublePtr.asFunction< + double Function(ffi.Pointer)>(); - int _PyFloat_FormatAdvancedWriter( - ffi.Pointer<_PyUnicodeWriter> writer, - ffi.Pointer obj, - ffi.Pointer format_spec, - int start, - int end, + double PyComplex_ImagAsDouble( + ffi.Pointer op, ) { - return __PyFloat_FormatAdvancedWriter( - writer, - obj, - format_spec, - start, - end, + return _PyComplex_ImagAsDouble( + op, ); } - late final __PyFloat_FormatAdvancedWriterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_PyUnicodeWriter>, - ffi.Pointer, - ffi.Pointer, - Py_ssize_t, - Py_ssize_t)>>('_PyFloat_FormatAdvancedWriter'); - late final __PyFloat_FormatAdvancedWriter = - __PyFloat_FormatAdvancedWriterPtr.asFunction< - int Function(ffi.Pointer<_PyUnicodeWriter>, ffi.Pointer, - ffi.Pointer, int, int)>(); + late final _PyComplex_ImagAsDoublePtr = + _lookup)>>( + 'PyComplex_ImagAsDouble'); + late final _PyComplex_ImagAsDouble = _PyComplex_ImagAsDoublePtr.asFunction< + double Function(ffi.Pointer)>(); Py_complex _Py_c_sum( Py_complex arg0, @@ -7166,11 +7002,6 @@ class CPython { late final __Py_c_abs = __Py_c_absPtr.asFunction(); - late final ffi.Pointer _PyComplex_Type = - _lookup('PyComplex_Type'); - - PyTypeObject get PyComplex_Type => _PyComplex_Type.ref; - ffi.Pointer PyComplex_FromCComplex( Py_complex arg0, ) { @@ -7185,51 +7016,6 @@ class CPython { late final _PyComplex_FromCComplex = _PyComplex_FromCComplexPtr.asFunction< ffi.Pointer Function(Py_complex)>(); - ffi.Pointer PyComplex_FromDoubles( - double real, - double imag, - ) { - return _PyComplex_FromDoubles( - real, - imag, - ); - } - - late final _PyComplex_FromDoublesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Double, ffi.Double)>>('PyComplex_FromDoubles'); - late final _PyComplex_FromDoubles = _PyComplex_FromDoublesPtr.asFunction< - ffi.Pointer Function(double, double)>(); - - double PyComplex_RealAsDouble( - ffi.Pointer op, - ) { - return _PyComplex_RealAsDouble( - op, - ); - } - - late final _PyComplex_RealAsDoublePtr = - _lookup)>>( - 'PyComplex_RealAsDouble'); - late final _PyComplex_RealAsDouble = _PyComplex_RealAsDoublePtr.asFunction< - double Function(ffi.Pointer)>(); - - double PyComplex_ImagAsDouble( - ffi.Pointer op, - ) { - return _PyComplex_ImagAsDouble( - op, - ); - } - - late final _PyComplex_ImagAsDoublePtr = - _lookup)>>( - 'PyComplex_ImagAsDouble'); - late final _PyComplex_ImagAsDouble = _PyComplex_ImagAsDoublePtr.asFunction< - double Function(ffi.Pointer)>(); - Py_complex PyComplex_AsCComplex( ffi.Pointer op, ) { @@ -7244,35 +7030,6 @@ class CPython { late final _PyComplex_AsCComplex = _PyComplex_AsCComplexPtr.asFunction< Py_complex Function(ffi.Pointer)>(); - int _PyComplex_FormatAdvancedWriter( - ffi.Pointer<_PyUnicodeWriter> writer, - ffi.Pointer obj, - ffi.Pointer format_spec, - int start, - int end, - ) { - return __PyComplex_FormatAdvancedWriter( - writer, - obj, - format_spec, - start, - end, - ); - } - - late final __PyComplex_FormatAdvancedWriterPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_PyUnicodeWriter>, - ffi.Pointer, - ffi.Pointer, - Py_ssize_t, - Py_ssize_t)>>('_PyComplex_FormatAdvancedWriter'); - late final __PyComplex_FormatAdvancedWriter = - __PyComplex_FormatAdvancedWriterPtr.asFunction< - int Function(ffi.Pointer<_PyUnicodeWriter>, ffi.Pointer, - ffi.Pointer, int, int)>(); - late final ffi.Pointer _PyRange_Type = _lookup('PyRange_Type'); @@ -7786,7 +7543,7 @@ class CPython { ffi.Pointer mp, ffi.Pointer key, ) { - return _PyDict_GetItemWithError( + return _PyDict_GetItemWithError1( mp, key, ); @@ -7796,7 +7553,7 @@ class CPython { ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, ffi.Pointer)>>('PyDict_GetItemWithError'); - late final _PyDict_GetItemWithError = _PyDict_GetItemWithErrorPtr.asFunction< + late final _PyDict_GetItemWithError1 = _PyDict_GetItemWithErrorPtr.asFunction< ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); @@ -8164,6 +7921,25 @@ class CPython { ffi.Pointer Function( ffi.Pointer, ffi.Pointer, int)>(); + ffi.Pointer _PyDict_GetItemWithError( + ffi.Pointer dp, + ffi.Pointer key, + ) { + return __PyDict_GetItemWithError( + dp, + key, + ); + } + + late final __PyDict_GetItemWithErrorPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyDict_GetItemWithError'); + late final __PyDict_GetItemWithError = + __PyDict_GetItemWithErrorPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer _PyDict_GetItemIdWithError( ffi.Pointer dp, ffi.Pointer<_Py_Identifier> key, @@ -8298,16 +8074,6 @@ class CPython { ffi.NativeFunction< ffi.Int Function(ffi.Pointer value)>>)>(); - ffi.Pointer _PyDict_NewKeysForClass() { - return __PyDict_NewKeysForClass(); - } - - late final __PyDict_NewKeysForClassPtr = - _lookup Function()>>( - '_PyDict_NewKeysForClass'); - late final __PyDict_NewKeysForClass = __PyDict_NewKeysForClassPtr - .asFunction Function()>(); - int _PyDict_Next( ffi.Pointer mp, ffi.Pointer pos, @@ -8419,21 +8185,6 @@ class CPython { late final __PyDict_HasOnlyStringKeys = __PyDict_HasOnlyStringKeysPtr .asFunction)>(); - int _PyDict_KeysSize( - ffi.Pointer keys, - ) { - return __PyDict_KeysSize( - keys, - ); - } - - late final __PyDict_KeysSizePtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function( - ffi.Pointer)>>('_PyDict_KeysSize'); - late final __PyDict_KeysSize = __PyDict_KeysSizePtr - .asFunction)>(); - int _PyDict_SizeOf( ffi.Pointer arg0, ) { @@ -8468,53 +8219,6 @@ class CPython { ffi.Pointer Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyDict_Pop_KnownHash( - ffi.Pointer arg0, - ffi.Pointer arg1, - int arg2, - ffi.Pointer arg3, - ) { - return __PyDict_Pop_KnownHash( - arg0, - arg1, - arg2, - arg3, - ); - } - - late final __PyDict_Pop_KnownHashPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - Py_hash_t, - ffi.Pointer)>>('_PyDict_Pop_KnownHash'); - late final __PyDict_Pop_KnownHash = __PyDict_Pop_KnownHashPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, int, ffi.Pointer)>(); - - ffi.Pointer _PyDict_FromKeys( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ) { - return __PyDict_FromKeys( - arg0, - arg1, - arg2, - ); - } - - late final __PyDict_FromKeysPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyDict_FromKeys'); - late final __PyDict_FromKeys = __PyDict_FromKeysPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); - int _PyDict_MergeEx( ffi.Pointer mp, ffi.Pointer other, @@ -8585,81 +8289,6 @@ class CPython { late final __PyDict_DebugMallocStats = __PyDict_DebugMallocStatsPtr .asFunction)>(); - int _PyObjectDict_SetItem( - ffi.Pointer tp, - ffi.Pointer> dictptr, - ffi.Pointer name, - ffi.Pointer value, - ) { - return __PyObjectDict_SetItem( - tp, - dictptr, - name, - value, - ); - } - - late final __PyObjectDict_SetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer, - ffi.Pointer)>>('_PyObjectDict_SetItem'); - late final __PyObjectDict_SetItem = __PyObjectDict_SetItemPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer, - ffi.Pointer)>(); - - ffi.Pointer _PyDict_LoadGlobal( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ) { - return __PyDict_LoadGlobal( - arg0, - arg1, - arg2, - ); - } - - late final __PyDict_LoadGlobalPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyDict_LoadGlobal'); - late final __PyDict_LoadGlobal = __PyDict_LoadGlobalPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); - - int _PyDict_GetItemHint( - ffi.Pointer arg0, - ffi.Pointer arg1, - int arg2, - ffi.Pointer> arg3, - ) { - return __PyDict_GetItemHint( - arg0, - arg1, - arg2, - arg3, - ); - } - - late final __PyDict_GetItemHintPtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function( - ffi.Pointer, - ffi.Pointer, - Py_ssize_t, - ffi.Pointer>)>>('_PyDict_GetItemHint'); - late final __PyDict_GetItemHint = __PyDict_GetItemHintPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, - ffi.Pointer>)>(); - ffi.Pointer _PyDictView_New( ffi.Pointer arg0, ffi.Pointer arg1, @@ -8778,62 +8407,13 @@ class CPython { PyTypeObject get PyReversed_Type => _PyReversed_Type.ref; - late final ffi.Pointer> __PySet_Dummy = - _lookup>('_PySet_Dummy'); + late final ffi.Pointer _PySet_Type = + _lookup('PySet_Type'); - ffi.Pointer get _PySet_Dummy => __PySet_Dummy.value; + PyTypeObject get PySet_Type => _PySet_Type.ref; - set _PySet_Dummy(ffi.Pointer value) => __PySet_Dummy.value = value; - - int _PySet_NextEntry( - ffi.Pointer set1, - ffi.Pointer pos, - ffi.Pointer> key, - ffi.Pointer hash, - ) { - return __PySet_NextEntry( - set1, - pos, - key, - hash, - ); - } - - late final __PySet_NextEntryPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer)>>('_PySet_NextEntry'); - late final __PySet_NextEntry = __PySet_NextEntryPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer>, ffi.Pointer)>(); - - int _PySet_Update( - ffi.Pointer set1, - ffi.Pointer iterable, - ) { - return __PySet_Update( - set1, - iterable, - ); - } - - late final __PySet_UpdatePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('_PySet_Update'); - late final __PySet_Update = __PySet_UpdatePtr - .asFunction, ffi.Pointer)>(); - - late final ffi.Pointer _PySet_Type = - _lookup('PySet_Type'); - - PyTypeObject get PySet_Type => _PySet_Type.ref; - - late final ffi.Pointer _PyFrozenSet_Type = - _lookup('PyFrozenSet_Type'); + late final ffi.Pointer _PyFrozenSet_Type = + _lookup('PyFrozenSet_Type'); PyTypeObject get PyFrozenSet_Type => _PyFrozenSet_Type.ref; @@ -8964,6 +8544,55 @@ class CPython { late final _PySet_Size = _PySet_SizePtr.asFunction)>(); + late final ffi.Pointer> __PySet_Dummy = + _lookup>('_PySet_Dummy'); + + ffi.Pointer get _PySet_Dummy => __PySet_Dummy.value; + + set _PySet_Dummy(ffi.Pointer value) => __PySet_Dummy.value = value; + + int _PySet_NextEntry( + ffi.Pointer set1, + ffi.Pointer pos, + ffi.Pointer> key, + ffi.Pointer hash, + ) { + return __PySet_NextEntry( + set1, + pos, + key, + hash, + ); + } + + late final __PySet_NextEntryPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer)>>('_PySet_NextEntry'); + late final __PySet_NextEntry = __PySet_NextEntryPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer>, ffi.Pointer)>(); + + int _PySet_Update( + ffi.Pointer set1, + ffi.Pointer iterable, + ) { + return __PySet_Update( + set1, + iterable, + ); + } + + late final __PySet_UpdatePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, ffi.Pointer)>>('_PySet_Update'); + late final __PySet_Update = __PySet_UpdatePtr + .asFunction, ffi.Pointer)>(); + late final ffi.Pointer _PyCFunction_Type = _lookup('PyCFunction_Type'); @@ -9853,6 +9482,39 @@ class CPython { ffi.Pointer Function(ffi.Pointer, int, ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer _Py_UniversalNewlineFgetsWithSize( + ffi.Pointer arg0, + int arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4, + ) { + return __Py_UniversalNewlineFgetsWithSize( + arg0, + arg1, + arg2, + arg3, + arg4, + ); + } + + late final __Py_UniversalNewlineFgetsWithSizePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_Py_UniversalNewlineFgetsWithSize'); + late final __Py_UniversalNewlineFgetsWithSize = + __Py_UniversalNewlineFgetsWithSizePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); + ffi.Pointer PyFile_NewStdPrinter( int arg0, ) { @@ -10146,8 +9808,10 @@ class CPython { ffi.Pointer arg10, ffi.Pointer arg11, ffi.Pointer arg12, - int arg13, - ffi.Pointer arg14, + ffi.Pointer arg13, + int arg14, + ffi.Pointer arg15, + ffi.Pointer arg16, ) { return _PyCode_New( arg0, @@ -10165,6 +9829,8 @@ class CPython { arg12, arg13, arg14, + arg15, + arg16, ); } @@ -10184,7 +9850,9 @@ class CPython { ffi.Pointer, ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Int, + ffi.Pointer, ffi.Pointer)>>('PyCode_New'); late final _PyCode_New = _PyCode_NewPtr.asFunction< ffi.Pointer Function( @@ -10201,7 +9869,9 @@ class CPython { ffi.Pointer, ffi.Pointer, ffi.Pointer, + ffi.Pointer, int, + ffi.Pointer, ffi.Pointer)>(); ffi.Pointer PyCode_NewWithPosOnlyArgs( @@ -10219,8 +9889,10 @@ class CPython { ffi.Pointer arg11, ffi.Pointer arg12, ffi.Pointer arg13, - int arg14, - ffi.Pointer arg15, + ffi.Pointer arg14, + int arg15, + ffi.Pointer arg16, + ffi.Pointer arg17, ) { return _PyCode_NewWithPosOnlyArgs( arg0, @@ -10239,6 +9911,8 @@ class CPython { arg13, arg14, arg15, + arg16, + arg17, ); } @@ -10259,7 +9933,9 @@ class CPython { ffi.Pointer, ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Int, + ffi.Pointer, ffi.Pointer)>>('PyCode_NewWithPosOnlyArgs'); late final _PyCode_NewWithPosOnlyArgs = _PyCode_NewWithPosOnlyArgsPtr.asFunction< @@ -10278,7 +9954,9 @@ class CPython { ffi.Pointer, ffi.Pointer, ffi.Pointer, + ffi.Pointer, int, + ffi.Pointer, ffi.Pointer)>(); ffi.Pointer PyCode_NewEmpty( @@ -10318,6 +9996,37 @@ class CPython { late final _PyCode_Addr2Line = _PyCode_Addr2LinePtr.asFunction< int Function(ffi.Pointer, int)>(); + int PyCode_Addr2Location( + ffi.Pointer arg0, + int arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4, + ffi.Pointer arg5, + ) { + return _PyCode_Addr2Location( + arg0, + arg1, + arg2, + arg3, + arg4, + arg5, + ); + } + + late final _PyCode_Addr2LocationPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyCode_Addr2Location'); + late final _PyCode_Addr2Location = _PyCode_Addr2LocationPtr.asFunction< + int Function(ffi.Pointer, int, ffi.Pointer, + ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); + int _PyCode_CheckLineNumber( int lasti, ffi.Pointer bounds, @@ -10417,82 +10126,65 @@ class CPython { late final __PyCode_SetExtra = __PyCode_SetExtraPtr.asFunction< int Function(ffi.Pointer, int, ffi.Pointer)>(); - /// API for initializing the line number table. - int _PyCode_InitAddressRange( - ffi.Pointer co, - ffi.Pointer bounds, + ffi.Pointer PyCode_GetCode( + ffi.Pointer code, ) { - return __PyCode_InitAddressRange( - co, - bounds, + return _PyCode_GetCode( + code, ); } - late final __PyCode_InitAddressRangePtr = _lookup< + late final _PyCode_GetCodePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyCode_InitAddressRange'); - late final __PyCode_InitAddressRange = - __PyCode_InitAddressRangePtr.asFunction< - int Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyCode_GetCode'); + late final _PyCode_GetCode = _PyCode_GetCodePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - /// Out of process API for initializing the line number table. - void PyLineTable_InitAddressRange( - ffi.Pointer linetable, - int length, - int firstlineno, - ffi.Pointer range, + ffi.Pointer PyCode_GetVarnames( + ffi.Pointer code, ) { - return _PyLineTable_InitAddressRange( - linetable, - length, - firstlineno, - range, + return _PyCode_GetVarnames( + code, ); } - late final _PyLineTable_InitAddressRangePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, Py_ssize_t, ffi.Int, - ffi.Pointer)>>( - 'PyLineTable_InitAddressRange'); - late final _PyLineTable_InitAddressRange = - _PyLineTable_InitAddressRangePtr.asFunction< - void Function(ffi.Pointer, int, int, - ffi.Pointer)>(); + late final _PyCode_GetVarnamesPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyCode_GetVarnames'); + late final _PyCode_GetVarnames = _PyCode_GetVarnamesPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - /// API for traversing the line number table. - int PyLineTable_NextAddressRange( - ffi.Pointer range, + ffi.Pointer PyCode_GetCellvars( + ffi.Pointer code, ) { - return _PyLineTable_NextAddressRange( - range, + return _PyCode_GetCellvars( + code, ); } - late final _PyLineTable_NextAddressRangePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer)>>( - 'PyLineTable_NextAddressRange'); - late final _PyLineTable_NextAddressRange = _PyLineTable_NextAddressRangePtr - .asFunction)>(); + late final _PyCode_GetCellvarsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyCode_GetCellvars'); + late final _PyCode_GetCellvars = _PyCode_GetCellvarsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyLineTable_PreviousAddressRange( - ffi.Pointer range, + ffi.Pointer PyCode_GetFreevars( + ffi.Pointer code, ) { - return _PyLineTable_PreviousAddressRange( - range, + return _PyCode_GetFreevars( + code, ); } - late final _PyLineTable_PreviousAddressRangePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer)>>( - 'PyLineTable_PreviousAddressRange'); - late final _PyLineTable_PreviousAddressRange = - _PyLineTable_PreviousAddressRangePtr.asFunction< - int Function(ffi.Pointer)>(); + late final _PyCode_GetFreevarsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyCode_GetFreevars'); + late final _PyCode_GetFreevars = _PyCode_GetFreevarsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); int PyFrame_GetLineNumber( ffi.Pointer arg0, @@ -10523,6 +10215,100 @@ class CPython { late final _PyFrame_GetCode = _PyFrame_GetCodePtr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); + late final ffi.Pointer _PyFrame_Type = + _lookup('PyFrame_Type'); + + PyTypeObject get PyFrame_Type => _PyFrame_Type.ref; + + ffi.Pointer PyFrame_GetBack( + ffi.Pointer frame, + ) { + return _PyFrame_GetBack( + frame, + ); + } + + late final _PyFrame_GetBackPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyFrame_GetBack'); + late final _PyFrame_GetBack = _PyFrame_GetBackPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + + ffi.Pointer PyFrame_GetLocals( + ffi.Pointer frame, + ) { + return _PyFrame_GetLocals( + frame, + ); + } + + late final _PyFrame_GetLocalsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyFrame_GetLocals'); + late final _PyFrame_GetLocals = _PyFrame_GetLocalsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + + ffi.Pointer PyFrame_GetGlobals( + ffi.Pointer frame, + ) { + return _PyFrame_GetGlobals( + frame, + ); + } + + late final _PyFrame_GetGlobalsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyFrame_GetGlobals'); + late final _PyFrame_GetGlobals = _PyFrame_GetGlobalsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + + ffi.Pointer PyFrame_GetBuiltins( + ffi.Pointer frame, + ) { + return _PyFrame_GetBuiltins( + frame, + ); + } + + late final _PyFrame_GetBuiltinsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyFrame_GetBuiltins'); + late final _PyFrame_GetBuiltins = _PyFrame_GetBuiltinsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + + ffi.Pointer PyFrame_GetGenerator( + ffi.Pointer frame, + ) { + return _PyFrame_GetGenerator( + frame, + ); + } + + late final _PyFrame_GetGeneratorPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyFrame_GetGenerator'); + late final _PyFrame_GetGenerator = _PyFrame_GetGeneratorPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); + + int PyFrame_GetLasti( + ffi.Pointer frame, + ) { + return _PyFrame_GetLasti( + frame, + ); + } + + late final _PyFrame_GetLastiPtr = + _lookup)>>( + 'PyFrame_GetLasti'); + late final _PyFrame_GetLasti = _PyFrame_GetLastiPtr.asFunction< + int Function(ffi.Pointer)>(); + int PyTraceBack_Here( ffi.Pointer arg0, ) { @@ -10564,21 +10350,31 @@ class CPython { ffi.Pointer arg1, int arg2, int arg3, + ffi.Pointer arg4, + ffi.Pointer> arg5, ) { return __Py_DisplaySourceLine( arg0, arg1, arg2, arg3, + arg4, + arg5, ); } late final __Py_DisplaySourceLinePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Int, ffi.Int)>>('_Py_DisplaySourceLine'); + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Int, + ffi.Pointer, + ffi.Pointer>)>>('_Py_DisplaySourceLine'); late final __Py_DisplaySourceLine = __Py_DisplaySourceLinePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, int)>(); + int Function(ffi.Pointer, ffi.Pointer, int, int, + ffi.Pointer, ffi.Pointer>)>(); void _PyTraceback_Add( ffi.Pointer arg0, @@ -11248,9 +11044,9 @@ class CPython { } late final _PyInterpreterState_ClearPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer)>>('PyInterpreterState_Clear'); + ffi + .NativeFunction)>>( + 'PyInterpreterState_Clear'); late final _PyInterpreterState_Clear = _PyInterpreterState_ClearPtr .asFunction)>(); @@ -11263,9 +11059,9 @@ class CPython { } late final _PyInterpreterState_DeletePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer)>>('PyInterpreterState_Delete'); + ffi + .NativeFunction)>>( + 'PyInterpreterState_Delete'); late final _PyInterpreterState_Delete = _PyInterpreterState_DeletePtr .asFunction)>(); @@ -11304,9 +11100,9 @@ class CPython { } late final _PyInterpreterState_GetIDPtr = _lookup< - ffi.NativeFunction< - ffi.Int64 Function( - ffi.Pointer)>>('PyInterpreterState_GetID'); + ffi + .NativeFunction)>>( + 'PyInterpreterState_GetID'); late final _PyInterpreterState_GetID = _PyInterpreterState_GetIDPtr .asFunction)>(); @@ -11539,8 +11335,8 @@ class CPython { } late final __PyInterpreterState_RequiresIDRefPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer)>>( + ffi + .NativeFunction)>>( '_PyInterpreterState_RequiresIDRef'); late final __PyInterpreterState_RequiresIDRef = __PyInterpreterState_RequiresIDRefPtr @@ -11620,6 +11416,34 @@ class CPython { late final __PyThreadState_GetDict = __PyThreadState_GetDictPtr .asFunction Function(ffi.Pointer)>(); + void PyThreadState_EnterTracing( + ffi.Pointer tstate, + ) { + return _PyThreadState_EnterTracing( + tstate, + ); + } + + late final _PyThreadState_EnterTracingPtr = _lookup< + ffi.NativeFunction)>>( + 'PyThreadState_EnterTracing'); + late final _PyThreadState_EnterTracing = _PyThreadState_EnterTracingPtr + .asFunction)>(); + + void PyThreadState_LeaveTracing( + ffi.Pointer tstate, + ) { + return _PyThreadState_LeaveTracing( + tstate, + ); + } + + late final _PyThreadState_LeaveTracingPtr = _lookup< + ffi.NativeFunction)>>( + 'PyThreadState_LeaveTracing'); + late final _PyThreadState_LeaveTracing = _PyThreadState_LeaveTracingPtr + .asFunction)>(); + int PyGILState_Check() { return _PyGILState_Check(); } @@ -11925,11232 +11749,10631 @@ class CPython { } late final __PyCrossInterpreterData_LookupPtr = _lookup< - ffi.NativeFunction< - crossinterpdatafunc Function( - ffi.Pointer)>>('_PyCrossInterpreterData_Lookup'); + ffi + .NativeFunction)>>( + '_PyCrossInterpreterData_Lookup'); late final __PyCrossInterpreterData_Lookup = __PyCrossInterpreterData_LookupPtr .asFunction)>(); - ffi.Pointer PyObject_CallNoArgs( - ffi.Pointer func, + late final ffi.Pointer _PyGen_Type = + _lookup('PyGen_Type'); + + PyTypeObject get PyGen_Type => _PyGen_Type.ref; + + ffi.Pointer PyGen_New( + ffi.Pointer arg0, ) { - return _PyObject_CallNoArgs( - func, + return _PyGen_New( + arg0, ); } - late final _PyObject_CallNoArgsPtr = _lookup< + late final _PyGen_NewPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyObject_CallNoArgs'); - late final _PyObject_CallNoArgs = _PyObject_CallNoArgsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer)>>('PyGen_New'); + late final _PyGen_New = _PyGen_NewPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyObject_Call( - ffi.Pointer callable, - ffi.Pointer args, - ffi.Pointer kwargs, + ffi.Pointer PyGen_NewWithQualName( + ffi.Pointer arg0, + ffi.Pointer name, + ffi.Pointer qualname, ) { - return _PyObject_Call( - callable, - args, - kwargs, + return _PyGen_NewWithQualName( + arg0, + name, + qualname, ); } - late final _PyObject_CallPtr = _lookup< + late final _PyGen_NewWithQualNamePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>('PyObject_Call'); - late final _PyObject_Call = _PyObject_CallPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyGen_NewWithQualName'); + late final _PyGen_NewWithQualName = _PyGen_NewWithQualNamePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyObject_CallObject( - ffi.Pointer callable, - ffi.Pointer args, + int _PyGen_SetStopIterationValue( + ffi.Pointer arg0, ) { - return _PyObject_CallObject( - callable, - args, + return __PyGen_SetStopIterationValue( + arg0, ); } - late final _PyObject_CallObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_CallObject'); - late final _PyObject_CallObject = _PyObject_CallObjectPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyGen_SetStopIterationValuePtr = + _lookup)>>( + '_PyGen_SetStopIterationValue'); + late final __PyGen_SetStopIterationValue = __PyGen_SetStopIterationValuePtr + .asFunction)>(); - ffi.Pointer PyObject_CallFunction( - ffi.Pointer callable, - ffi.Pointer format, + int _PyGen_FetchStopIterationValue( + ffi.Pointer> arg0, ) { - return _PyObject_CallFunction( - callable, - format, + return __PyGen_FetchStopIterationValue( + arg0, ); } - late final _PyObject_CallFunctionPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_CallFunction'); - late final _PyObject_CallFunction = _PyObject_CallFunctionPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyGen_FetchStopIterationValuePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer>)>>( + '_PyGen_FetchStopIterationValue'); + late final __PyGen_FetchStopIterationValue = + __PyGen_FetchStopIterationValuePtr + .asFunction>)>(); - ffi.Pointer PyObject_CallMethod( - ffi.Pointer obj, - ffi.Pointer name, - ffi.Pointer format, + void _PyGen_Finalize( + ffi.Pointer self, ) { - return _PyObject_CallMethod( - obj, - name, - format, + return __PyGen_Finalize( + self, ); } - late final _PyObject_CallMethodPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyObject_CallMethod'); - late final _PyObject_CallMethod = _PyObject_CallMethodPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + late final __PyGen_FinalizePtr = + _lookup)>>( + '_PyGen_Finalize'); + late final __PyGen_Finalize = + __PyGen_FinalizePtr.asFunction)>(); - ffi.Pointer _PyObject_CallFunction_SizeT( - ffi.Pointer callable, - ffi.Pointer format, - ) { - return __PyObject_CallFunction_SizeT( - callable, - format, - ); - } + late final ffi.Pointer _PyCoro_Type = + _lookup('PyCoro_Type'); - late final __PyObject_CallFunction_SizeTPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyObject_CallFunction_SizeT'); - late final __PyObject_CallFunction_SizeT = - __PyObject_CallFunction_SizeTPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + PyTypeObject get PyCoro_Type => _PyCoro_Type.ref; - ffi.Pointer _PyObject_CallMethod_SizeT( - ffi.Pointer obj, - ffi.Pointer name, - ffi.Pointer format, + late final ffi.Pointer __PyCoroWrapper_Type = + _lookup('_PyCoroWrapper_Type'); + + PyTypeObject get _PyCoroWrapper_Type => __PyCoroWrapper_Type.ref; + + ffi.Pointer PyCoro_New( + ffi.Pointer arg0, + ffi.Pointer name, + ffi.Pointer qualname, ) { - return __PyObject_CallMethod_SizeT( - obj, + return _PyCoro_New( + arg0, name, - format, + qualname, ); } - late final __PyObject_CallMethod_SizeTPtr = _lookup< + late final _PyCoro_NewPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyObject_CallMethod_SizeT'); - late final __PyObject_CallMethod_SizeT = - __PyObject_CallMethod_SizeTPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>('PyCoro_New'); + late final _PyCoro_New = _PyCoro_NewPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyObject_CallFunctionObjArgs( - ffi.Pointer callable, - ) { - return _PyObject_CallFunctionObjArgs( - callable, - ); - } + late final ffi.Pointer _PyAsyncGen_Type = + _lookup('PyAsyncGen_Type'); - late final _PyObject_CallFunctionObjArgsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyObject_CallFunctionObjArgs'); - late final _PyObject_CallFunctionObjArgs = _PyObject_CallFunctionObjArgsPtr - .asFunction Function(ffi.Pointer)>(); + PyTypeObject get PyAsyncGen_Type => _PyAsyncGen_Type.ref; - ffi.Pointer PyObject_CallMethodObjArgs( - ffi.Pointer obj, + late final ffi.Pointer __PyAsyncGenASend_Type = + _lookup('_PyAsyncGenASend_Type'); + + PyTypeObject get _PyAsyncGenASend_Type => __PyAsyncGenASend_Type.ref; + + late final ffi.Pointer __PyAsyncGenWrappedValue_Type = + _lookup('_PyAsyncGenWrappedValue_Type'); + + PyTypeObject get _PyAsyncGenWrappedValue_Type => + __PyAsyncGenWrappedValue_Type.ref; + + late final ffi.Pointer __PyAsyncGenAThrow_Type = + _lookup('_PyAsyncGenAThrow_Type'); + + PyTypeObject get _PyAsyncGenAThrow_Type => __PyAsyncGenAThrow_Type.ref; + + ffi.Pointer PyAsyncGen_New( + ffi.Pointer arg0, ffi.Pointer name, + ffi.Pointer qualname, ) { - return _PyObject_CallMethodObjArgs( - obj, + return _PyAsyncGen_New( + arg0, name, + qualname, ); } - late final _PyObject_CallMethodObjArgsPtr = _lookup< + late final _PyAsyncGen_NewPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_CallMethodObjArgs'); - late final _PyObject_CallMethodObjArgs = - _PyObject_CallMethodObjArgsPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>('PyAsyncGen_New'); + late final _PyAsyncGen_New = _PyAsyncGen_NewPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyObject_Type( - ffi.Pointer o, - ) { - return _PyObject_Type( - o, - ); - } + late final ffi.Pointer _PyClassMethodDescr_Type = + _lookup('PyClassMethodDescr_Type'); - late final _PyObject_TypePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyObject_Type'); - late final _PyObject_Type = _PyObject_TypePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + PyTypeObject get PyClassMethodDescr_Type => _PyClassMethodDescr_Type.ref; - int PyObject_Size( - ffi.Pointer o, - ) { - return _PyObject_Size( - o, - ); - } + late final ffi.Pointer _PyGetSetDescr_Type = + _lookup('PyGetSetDescr_Type'); - late final _PyObject_SizePtr = - _lookup)>>( - 'PyObject_Size'); - late final _PyObject_Size = - _PyObject_SizePtr.asFunction)>(); + PyTypeObject get PyGetSetDescr_Type => _PyGetSetDescr_Type.ref; - int PyObject_Length( - ffi.Pointer o, - ) { - return _PyObject_Length( - o, - ); - } + late final ffi.Pointer _PyMemberDescr_Type = + _lookup('PyMemberDescr_Type'); - late final _PyObject_LengthPtr = - _lookup)>>( - 'PyObject_Length'); - late final _PyObject_Length = - _PyObject_LengthPtr.asFunction)>(); + PyTypeObject get PyMemberDescr_Type => _PyMemberDescr_Type.ref; - ffi.Pointer PyObject_GetItem( - ffi.Pointer o, - ffi.Pointer key, - ) { - return _PyObject_GetItem( - o, - key, - ); - } + late final ffi.Pointer _PyMethodDescr_Type = + _lookup('PyMethodDescr_Type'); - late final _PyObject_GetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_GetItem'); - late final _PyObject_GetItem = _PyObject_GetItemPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + PyTypeObject get PyMethodDescr_Type => _PyMethodDescr_Type.ref; - int PyObject_SetItem( - ffi.Pointer o, - ffi.Pointer key, - ffi.Pointer v, - ) { - return _PyObject_SetItem( - o, - key, - v, - ); - } + late final ffi.Pointer _PyWrapperDescr_Type = + _lookup('PyWrapperDescr_Type'); - late final _PyObject_SetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyObject_SetItem'); - late final _PyObject_SetItem = _PyObject_SetItemPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + PyTypeObject get PyWrapperDescr_Type => _PyWrapperDescr_Type.ref; - int PyObject_DelItemString( - ffi.Pointer o, - ffi.Pointer key, - ) { - return _PyObject_DelItemString( - o, - key, - ); - } + late final ffi.Pointer _PyDictProxy_Type = + _lookup('PyDictProxy_Type'); - late final _PyObject_DelItemStringPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_DelItemString'); - late final _PyObject_DelItemString = _PyObject_DelItemStringPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + PyTypeObject get PyDictProxy_Type => _PyDictProxy_Type.ref; - int PyObject_DelItem( - ffi.Pointer o, - ffi.Pointer key, - ) { - return _PyObject_DelItem( - o, - key, - ); - } + late final ffi.Pointer _PyProperty_Type = + _lookup('PyProperty_Type'); - late final _PyObject_DelItemPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_DelItem'); - late final _PyObject_DelItem = _PyObject_DelItemPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + PyTypeObject get PyProperty_Type => _PyProperty_Type.ref; - int PyObject_AsCharBuffer( - ffi.Pointer obj, - ffi.Pointer> buffer, - ffi.Pointer buffer_len, + ffi.Pointer PyDescr_NewMethod( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyObject_AsCharBuffer( - obj, - buffer, - buffer_len, + return _PyDescr_NewMethod( + arg0, + arg1, ); } - late final _PyObject_AsCharBufferPtr = _lookup< + late final _PyDescr_NewMethodPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer)>>('PyObject_AsCharBuffer'); - late final _PyObject_AsCharBuffer = _PyObject_AsCharBufferPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer>, - ffi.Pointer)>(); - - int PyObject_CheckReadBuffer( - ffi.Pointer obj, - ) { - return _PyObject_CheckReadBuffer( - obj, - ); - } - - late final _PyObject_CheckReadBufferPtr = - _lookup)>>( - 'PyObject_CheckReadBuffer'); - late final _PyObject_CheckReadBuffer = _PyObject_CheckReadBufferPtr - .asFunction)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyDescr_NewMethod'); + late final _PyDescr_NewMethod = _PyDescr_NewMethodPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyObject_AsReadBuffer( - ffi.Pointer obj, - ffi.Pointer> buffer, - ffi.Pointer buffer_len, + ffi.Pointer PyDescr_NewClassMethod( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyObject_AsReadBuffer( - obj, - buffer, - buffer_len, + return _PyDescr_NewClassMethod( + arg0, + arg1, ); } - late final _PyObject_AsReadBufferPtr = _lookup< + late final _PyDescr_NewClassMethodPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer)>>('PyObject_AsReadBuffer'); - late final _PyObject_AsReadBuffer = _PyObject_AsReadBufferPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer>, - ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyDescr_NewClassMethod'); + late final _PyDescr_NewClassMethod = _PyDescr_NewClassMethodPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyObject_AsWriteBuffer( - ffi.Pointer obj, - ffi.Pointer> buffer, - ffi.Pointer buffer_len, + ffi.Pointer PyDescr_NewMember( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyObject_AsWriteBuffer( - obj, - buffer, - buffer_len, + return _PyDescr_NewMember( + arg0, + arg1, ); } - late final _PyObject_AsWriteBufferPtr = _lookup< + late final _PyDescr_NewMemberPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer)>>('PyObject_AsWriteBuffer'); - late final _PyObject_AsWriteBuffer = _PyObject_AsWriteBufferPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer>, - ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyDescr_NewMember'); + late final _PyDescr_NewMember = _PyDescr_NewMemberPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyObject_Format( - ffi.Pointer obj, - ffi.Pointer format_spec, + ffi.Pointer PyDescr_NewGetSet( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyObject_Format( - obj, - format_spec, + return _PyDescr_NewGetSet( + arg0, + arg1, ); } - late final _PyObject_FormatPtr = _lookup< + late final _PyDescr_NewGetSetPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_Format'); - late final _PyObject_Format = _PyObject_FormatPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyDescr_NewGetSet'); + late final _PyDescr_NewGetSet = _PyDescr_NewGetSetPtr.asFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyObject_GetIter( + ffi.Pointer PyDictProxy_New( ffi.Pointer arg0, ) { - return _PyObject_GetIter( + return _PyDictProxy_New( arg0, ); } - late final _PyObject_GetIterPtr = _lookup< + late final _PyDictProxy_NewPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyObject_GetIter'); - late final _PyObject_GetIter = _PyObject_GetIterPtr.asFunction< + ffi.Pointer)>>('PyDictProxy_New'); + late final _PyDictProxy_New = _PyDictProxy_NewPtr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyObject_GetAIter( + ffi.Pointer PyWrapper_New( ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyObject_GetAIter( + return _PyWrapper_New( arg0, + arg1, ); } - late final _PyObject_GetAIterPtr = _lookup< + late final _PyWrapper_NewPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyObject_GetAIter'); - late final _PyObject_GetAIter = _PyObject_GetAIterPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); - - int PyIter_Check( - ffi.Pointer arg0, - ) { - return _PyIter_Check( - arg0, - ); - } + ffi.Pointer, ffi.Pointer)>>('PyWrapper_New'); + late final _PyWrapper_New = _PyWrapper_NewPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - late final _PyIter_CheckPtr = - _lookup)>>( - 'PyIter_Check'); - late final _PyIter_Check = - _PyIter_CheckPtr.asFunction)>(); + late final ffi.Pointer __PyMethodWrapper_Type = + _lookup('_PyMethodWrapper_Type'); - int PyAIter_Check( - ffi.Pointer arg0, + PyTypeObject get _PyMethodWrapper_Type => __PyMethodWrapper_Type.ref; + + ffi.Pointer PyDescr_NewWrapper( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyAIter_Check( + return _PyDescr_NewWrapper( arg0, + arg1, + arg2, ); } - late final _PyAIter_CheckPtr = - _lookup)>>( - 'PyAIter_Check'); - late final _PyAIter_Check = - _PyAIter_CheckPtr.asFunction)>(); + late final _PyDescr_NewWrapperPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyDescr_NewWrapper'); + late final _PyDescr_NewWrapper = _PyDescr_NewWrapperPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyIter_Next( + int PyDescr_IsData( ffi.Pointer arg0, ) { - return _PyIter_Next( + return _PyDescr_IsData( arg0, ); } - late final _PyIter_NextPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyIter_Next'); - late final _PyIter_Next = _PyIter_NextPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final _PyDescr_IsDataPtr = + _lookup)>>( + 'PyDescr_IsData'); + late final _PyDescr_IsData = + _PyDescr_IsDataPtr.asFunction)>(); - int PyIter_Send( + ffi.Pointer Py_GenericAlias( ffi.Pointer arg0, ffi.Pointer arg1, - ffi.Pointer> arg2, ) { - return _PyIter_Send( + return _Py_GenericAlias( arg0, arg1, - arg2, ); } - late final _PyIter_SendPtr = _lookup< + late final _Py_GenericAliasPtr = _lookup< ffi.NativeFunction< - ffi.Int32 Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer>)>>('PyIter_Send'); - late final _PyIter_Send = _PyIter_SendPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer>)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('Py_GenericAlias'); + late final _Py_GenericAlias = _Py_GenericAliasPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyNumber_Check( - ffi.Pointer o, - ) { - return _PyNumber_Check( - o, - ); - } + late final ffi.Pointer _Py_GenericAliasType = + _lookup('Py_GenericAliasType'); - late final _PyNumber_CheckPtr = - _lookup)>>( - 'PyNumber_Check'); - late final _PyNumber_Check = - _PyNumber_CheckPtr.asFunction)>(); + PyTypeObject get Py_GenericAliasType => _Py_GenericAliasType.ref; - ffi.Pointer PyNumber_Add( - ffi.Pointer o1, - ffi.Pointer o2, + int PyErr_WarnEx( + ffi.Pointer category, + ffi.Pointer message, + int stack_level, ) { - return _PyNumber_Add( - o1, - o2, + return _PyErr_WarnEx( + category, + message, + stack_level, ); } - late final _PyNumber_AddPtr = _lookup< + late final _PyErr_WarnExPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('PyNumber_Add'); - late final _PyNumber_Add = _PyNumber_AddPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + Py_ssize_t)>>('PyErr_WarnEx'); + late final _PyErr_WarnEx = _PyErr_WarnExPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - ffi.Pointer PyNumber_Subtract( - ffi.Pointer o1, - ffi.Pointer o2, + int PyErr_WarnFormat( + ffi.Pointer category, + int stack_level, + ffi.Pointer format, ) { - return _PyNumber_Subtract( - o1, - o2, + return _PyErr_WarnFormat( + category, + stack_level, + format, ); } - late final _PyNumber_SubtractPtr = _lookup< + late final _PyErr_WarnFormatPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_Subtract'); - late final _PyNumber_Subtract = _PyNumber_SubtractPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, Py_ssize_t, + ffi.Pointer)>>('PyErr_WarnFormat'); + late final _PyErr_WarnFormat = _PyErr_WarnFormatPtr.asFunction< + int Function(ffi.Pointer, int, ffi.Pointer)>(); - ffi.Pointer PyNumber_Multiply( - ffi.Pointer o1, - ffi.Pointer o2, + int PyErr_ResourceWarning( + ffi.Pointer source, + int stack_level, + ffi.Pointer format, ) { - return _PyNumber_Multiply( - o1, - o2, + return _PyErr_ResourceWarning( + source, + stack_level, + format, ); } - late final _PyNumber_MultiplyPtr = _lookup< + late final _PyErr_ResourceWarningPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_Multiply'); - late final _PyNumber_Multiply = _PyNumber_MultiplyPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, Py_ssize_t, + ffi.Pointer)>>('PyErr_ResourceWarning'); + late final _PyErr_ResourceWarning = _PyErr_ResourceWarningPtr.asFunction< + int Function(ffi.Pointer, int, ffi.Pointer)>(); - ffi.Pointer PyNumber_MatrixMultiply( - ffi.Pointer o1, - ffi.Pointer o2, + int PyErr_WarnExplicit( + ffi.Pointer category, + ffi.Pointer message, + ffi.Pointer filename, + int lineno, + ffi.Pointer module, + ffi.Pointer registry, ) { - return _PyNumber_MatrixMultiply( - o1, - o2, + return _PyErr_WarnExplicit( + category, + message, + filename, + lineno, + module, + registry, ); } - late final _PyNumber_MatrixMultiplyPtr = _lookup< + late final _PyErr_WarnExplicitPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_MatrixMultiply'); - late final _PyNumber_MatrixMultiply = _PyNumber_MatrixMultiplyPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer)>>('PyErr_WarnExplicit'); + late final _PyErr_WarnExplicit = _PyErr_WarnExplicitPtr.asFunction< + int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer PyNumber_FloorDivide( - ffi.Pointer o1, - ffi.Pointer o2, + int PyErr_WarnExplicitObject( + ffi.Pointer category, + ffi.Pointer message, + ffi.Pointer filename, + int lineno, + ffi.Pointer module, + ffi.Pointer registry, ) { - return _PyNumber_FloorDivide( - o1, - o2, + return _PyErr_WarnExplicitObject( + category, + message, + filename, + lineno, + module, + registry, ); } - late final _PyNumber_FloorDividePtr = _lookup< + late final _PyErr_WarnExplicitObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_FloorDivide'); - late final _PyNumber_FloorDivide = _PyNumber_FloorDividePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer)>>('PyErr_WarnExplicitObject'); + late final _PyErr_WarnExplicitObject = + _PyErr_WarnExplicitObjectPtr.asFunction< + int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer PyNumber_TrueDivide( - ffi.Pointer o1, - ffi.Pointer o2, - ) { - return _PyNumber_TrueDivide( - o1, - o2, + int PyErr_WarnExplicitFormat( + ffi.Pointer category, + ffi.Pointer filename, + int lineno, + ffi.Pointer module, + ffi.Pointer registry, + ffi.Pointer format, + ) { + return _PyErr_WarnExplicitFormat( + category, + filename, + lineno, + module, + registry, + format, ); } - late final _PyNumber_TrueDividePtr = _lookup< + late final _PyErr_WarnExplicitFormatPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_TrueDivide'); - late final _PyNumber_TrueDivide = _PyNumber_TrueDividePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyErr_WarnExplicitFormat'); + late final _PyErr_WarnExplicitFormat = + _PyErr_WarnExplicitFormatPtr.asFunction< + int Function( + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer PyNumber_Remainder( - ffi.Pointer o1, - ffi.Pointer o2, - ) { - return _PyNumber_Remainder( - o1, - o2, - ); - } + late final ffi.Pointer __PyWeakref_RefType = + _lookup('_PyWeakref_RefType'); - late final _PyNumber_RemainderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_Remainder'); - late final _PyNumber_Remainder = _PyNumber_RemainderPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + PyTypeObject get _PyWeakref_RefType => __PyWeakref_RefType.ref; - ffi.Pointer PyNumber_Divmod( - ffi.Pointer o1, - ffi.Pointer o2, + late final ffi.Pointer __PyWeakref_ProxyType = + _lookup('_PyWeakref_ProxyType'); + + PyTypeObject get _PyWeakref_ProxyType => __PyWeakref_ProxyType.ref; + + late final ffi.Pointer __PyWeakref_CallableProxyType = + _lookup('_PyWeakref_CallableProxyType'); + + PyTypeObject get _PyWeakref_CallableProxyType => + __PyWeakref_CallableProxyType.ref; + + ffi.Pointer PyWeakref_NewRef( + ffi.Pointer ob, + ffi.Pointer callback, ) { - return _PyNumber_Divmod( - o1, - o2, + return _PyWeakref_NewRef( + ob, + callback, ); } - late final _PyNumber_DivmodPtr = _lookup< + late final _PyWeakref_NewRefPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_Divmod'); - late final _PyNumber_Divmod = _PyNumber_DivmodPtr.asFunction< + ffi.Pointer)>>('PyWeakref_NewRef'); + late final _PyWeakref_NewRef = _PyWeakref_NewRefPtr.asFunction< ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyNumber_Power( - ffi.Pointer o1, - ffi.Pointer o2, - ffi.Pointer o3, + ffi.Pointer PyWeakref_NewProxy( + ffi.Pointer ob, + ffi.Pointer callback, ) { - return _PyNumber_Power( - o1, - o2, - o3, + return _PyWeakref_NewProxy( + ob, + callback, ); } - late final _PyNumber_PowerPtr = _lookup< + late final _PyWeakref_NewProxyPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>('PyNumber_Power'); - late final _PyNumber_Power = _PyNumber_PowerPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyWeakref_NewProxy'); + late final _PyWeakref_NewProxy = _PyWeakref_NewProxyPtr.asFunction< + ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyNumber_Negative( - ffi.Pointer o, + ffi.Pointer PyWeakref_GetObject( + ffi.Pointer ref, ) { - return _PyNumber_Negative( - o, + return _PyWeakref_GetObject( + ref, ); } - late final _PyNumber_NegativePtr = _lookup< + late final _PyWeakref_GetObjectPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Negative'); - late final _PyNumber_Negative = _PyNumber_NegativePtr.asFunction< + ffi.Pointer)>>('PyWeakref_GetObject'); + late final _PyWeakref_GetObject = _PyWeakref_GetObjectPtr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyNumber_Positive( - ffi.Pointer o, + int _PyWeakref_GetWeakrefCount( + ffi.Pointer head, ) { - return _PyNumber_Positive( - o, + return __PyWeakref_GetWeakrefCount( + head, ); } - late final _PyNumber_PositivePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Positive'); - late final _PyNumber_Positive = _PyNumber_PositivePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final __PyWeakref_GetWeakrefCountPtr = _lookup< + ffi + .NativeFunction)>>( + '_PyWeakref_GetWeakrefCount'); + late final __PyWeakref_GetWeakrefCount = __PyWeakref_GetWeakrefCountPtr + .asFunction)>(); - ffi.Pointer PyNumber_Absolute( - ffi.Pointer o, + void _PyWeakref_ClearRef( + ffi.Pointer self, ) { - return _PyNumber_Absolute( - o, + return __PyWeakref_ClearRef( + self, ); } - late final _PyNumber_AbsolutePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Absolute'); - late final _PyNumber_Absolute = _PyNumber_AbsolutePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final __PyWeakref_ClearRefPtr = _lookup< + ffi.NativeFunction)>>( + '_PyWeakref_ClearRef'); + late final __PyWeakref_ClearRef = __PyWeakref_ClearRefPtr + .asFunction)>(); - ffi.Pointer PyNumber_Invert( - ffi.Pointer o, + late final ffi.Pointer> _PyStructSequence_UnnamedField = + _lookup>('PyStructSequence_UnnamedField'); + + ffi.Pointer get PyStructSequence_UnnamedField => + _PyStructSequence_UnnamedField.value; + + set PyStructSequence_UnnamedField(ffi.Pointer value) => + _PyStructSequence_UnnamedField.value = value; + + void PyStructSequence_InitType( + ffi.Pointer type, + ffi.Pointer desc, ) { - return _PyNumber_Invert( - o, + return _PyStructSequence_InitType( + type, + desc, ); } - late final _PyNumber_InvertPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Invert'); - late final _PyNumber_Invert = _PyNumber_InvertPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final _PyStructSequence_InitTypePtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>( + 'PyStructSequence_InitType'); + late final _PyStructSequence_InitType = + _PyStructSequence_InitTypePtr.asFunction< + void Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyNumber_Lshift( - ffi.Pointer o1, - ffi.Pointer o2, + int PyStructSequence_InitType2( + ffi.Pointer type, + ffi.Pointer desc, ) { - return _PyNumber_Lshift( - o1, - o2, + return _PyStructSequence_InitType2( + type, + desc, ); } - late final _PyNumber_LshiftPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_Lshift'); - late final _PyNumber_Lshift = _PyNumber_LshiftPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final _PyStructSequence_InitType2Ptr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>( + 'PyStructSequence_InitType2'); + late final _PyStructSequence_InitType2 = + _PyStructSequence_InitType2Ptr.asFunction< + int Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyNumber_Rshift( - ffi.Pointer o1, - ffi.Pointer o2, + ffi.Pointer PyStructSequence_NewType( + ffi.Pointer desc, ) { - return _PyNumber_Rshift( - o1, - o2, + return _PyStructSequence_NewType( + desc, ); } - late final _PyNumber_RshiftPtr = _lookup< + late final _PyStructSequence_NewTypePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_Rshift'); - late final _PyNumber_Rshift = _PyNumber_RshiftPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyStructSequence_NewType'); + late final _PyStructSequence_NewType = + _PyStructSequence_NewTypePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer)>(); - ffi.Pointer PyNumber_And( - ffi.Pointer o1, - ffi.Pointer o2, + ffi.Pointer PyStructSequence_New( + ffi.Pointer type, ) { - return _PyNumber_And( - o1, - o2, + return _PyStructSequence_New( + type, ); } - late final _PyNumber_AndPtr = _lookup< + late final _PyStructSequence_NewPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('PyNumber_And'); - late final _PyNumber_And = _PyNumber_AndPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PyStructSequence_New'); + late final _PyStructSequence_New = _PyStructSequence_NewPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyNumber_Xor( - ffi.Pointer o1, - ffi.Pointer o2, + void PyStructSequence_SetItem( + ffi.Pointer arg0, + int arg1, + ffi.Pointer arg2, ) { - return _PyNumber_Xor( - o1, - o2, + return _PyStructSequence_SetItem( + arg0, + arg1, + arg2, ); } - late final _PyNumber_XorPtr = _lookup< + late final _PyStructSequence_SetItemPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('PyNumber_Xor'); - late final _PyNumber_Xor = _PyNumber_XorPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Void Function(ffi.Pointer, Py_ssize_t, + ffi.Pointer)>>('PyStructSequence_SetItem'); + late final _PyStructSequence_SetItem = + _PyStructSequence_SetItemPtr.asFunction< + void Function(ffi.Pointer, int, ffi.Pointer)>(); - ffi.Pointer PyNumber_Or( - ffi.Pointer o1, - ffi.Pointer o2, + ffi.Pointer PyStructSequence_GetItem( + ffi.Pointer arg0, + int arg1, ) { - return _PyNumber_Or( - o1, - o2, + return _PyStructSequence_GetItem( + arg0, + arg1, ); } - late final _PyNumber_OrPtr = _lookup< + late final _PyStructSequence_GetItemPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('PyNumber_Or'); - late final _PyNumber_Or = _PyNumber_OrPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer, Py_ssize_t)>>('PyStructSequence_GetItem'); + late final _PyStructSequence_GetItem = _PyStructSequence_GetItemPtr + .asFunction Function(ffi.Pointer, int)>(); - int PyIndex_Check( + late final ffi.Pointer _PyPickleBuffer_Type = + _lookup('PyPickleBuffer_Type'); + + PyTypeObject get PyPickleBuffer_Type => _PyPickleBuffer_Type.ref; + + ffi.Pointer PyPickleBuffer_FromObject( ffi.Pointer arg0, ) { - return _PyIndex_Check( + return _PyPickleBuffer_FromObject( arg0, ); } - late final _PyIndex_CheckPtr = - _lookup)>>( - 'PyIndex_Check'); - late final _PyIndex_Check = - _PyIndex_CheckPtr.asFunction)>(); + late final _PyPickleBuffer_FromObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyPickleBuffer_FromObject'); + late final _PyPickleBuffer_FromObject = _PyPickleBuffer_FromObjectPtr + .asFunction Function(ffi.Pointer)>(); - ffi.Pointer PyNumber_Index( - ffi.Pointer o, + ffi.Pointer PyPickleBuffer_GetBuffer( + ffi.Pointer arg0, ) { - return _PyNumber_Index1( - o, + return _PyPickleBuffer_GetBuffer( + arg0, ); } - late final _PyNumber_IndexPtr = _lookup< + late final _PyPickleBuffer_GetBufferPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Index'); - late final _PyNumber_Index1 = _PyNumber_IndexPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyPickleBuffer_GetBuffer'); + late final _PyPickleBuffer_GetBuffer = _PyPickleBuffer_GetBufferPtr + .asFunction Function(ffi.Pointer)>(); - int PyNumber_AsSsize_t( - ffi.Pointer o, - ffi.Pointer exc, + int PyPickleBuffer_Release( + ffi.Pointer arg0, ) { - return _PyNumber_AsSsize_t( - o, - exc, + return _PyPickleBuffer_Release( + arg0, ); } - late final _PyNumber_AsSsize_tPtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_AsSsize_t'); - late final _PyNumber_AsSsize_t = _PyNumber_AsSsize_tPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final _PyPickleBuffer_ReleasePtr = + _lookup)>>( + 'PyPickleBuffer_Release'); + late final _PyPickleBuffer_Release = _PyPickleBuffer_ReleasePtr.asFunction< + int Function(ffi.Pointer)>(); - ffi.Pointer PyNumber_Long( - ffi.Pointer o, + ffi.Pointer _PyLong_FromTime_t( + int sec, ) { - return _PyNumber_Long( - o, + return __PyLong_FromTime_t( + sec, ); } - late final _PyNumber_LongPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Long'); - late final _PyNumber_Long = _PyNumber_LongPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final __PyLong_FromTime_tPtr = + _lookup Function(time_t)>>( + '_PyLong_FromTime_t'); + late final __PyLong_FromTime_t = + __PyLong_FromTime_tPtr.asFunction Function(int)>(); - ffi.Pointer PyNumber_Float( - ffi.Pointer o, + int _PyLong_AsTime_t( + ffi.Pointer obj, ) { - return _PyNumber_Float( - o, + return __PyLong_AsTime_t( + obj, ); } - late final _PyNumber_FloatPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyNumber_Float'); - late final _PyNumber_Float = _PyNumber_FloatPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final __PyLong_AsTime_tPtr = + _lookup)>>( + '_PyLong_AsTime_t'); + late final __PyLong_AsTime_t = + __PyLong_AsTime_tPtr.asFunction)>(); - ffi.Pointer PyNumber_InPlaceAdd( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_ObjectToTime_t( + ffi.Pointer obj, + ffi.Pointer sec, + int arg2, ) { - return _PyNumber_InPlaceAdd( - o1, - o2, + return __PyTime_ObjectToTime_t( + obj, + sec, + arg2, ); } - late final _PyNumber_InPlaceAddPtr = _lookup< + late final __PyTime_ObjectToTime_tPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceAdd'); - late final _PyNumber_InPlaceAdd = _PyNumber_InPlaceAddPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Int32)>>('_PyTime_ObjectToTime_t'); + late final __PyTime_ObjectToTime_t = __PyTime_ObjectToTime_tPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - ffi.Pointer PyNumber_InPlaceSubtract( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_ObjectToTimeval( + ffi.Pointer obj, + ffi.Pointer sec, + ffi.Pointer usec, + int arg3, ) { - return _PyNumber_InPlaceSubtract( - o1, - o2, + return __PyTime_ObjectToTimeval( + obj, + sec, + usec, + arg3, ); } - late final _PyNumber_InPlaceSubtractPtr = _lookup< + late final __PyTime_ObjectToTimevalPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceSubtract'); - late final _PyNumber_InPlaceSubtract = - _PyNumber_InPlaceSubtractPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Int32)>>('_PyTime_ObjectToTimeval'); + late final __PyTime_ObjectToTimeval = __PyTime_ObjectToTimevalPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, int)>(); - ffi.Pointer PyNumber_InPlaceMultiply( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_ObjectToTimespec( + ffi.Pointer obj, + ffi.Pointer sec, + ffi.Pointer nsec, + int arg3, ) { - return _PyNumber_InPlaceMultiply( - o1, - o2, + return __PyTime_ObjectToTimespec( + obj, + sec, + nsec, + arg3, ); } - late final _PyNumber_InPlaceMultiplyPtr = _lookup< + late final __PyTime_ObjectToTimespecPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceMultiply'); - late final _PyNumber_InPlaceMultiply = - _PyNumber_InPlaceMultiplyPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Int32)>>('_PyTime_ObjectToTimespec'); + late final __PyTime_ObjectToTimespec = + __PyTime_ObjectToTimespecPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, int)>(); - ffi.Pointer PyNumber_InPlaceMatrixMultiply( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_FromSeconds( + int seconds, ) { - return _PyNumber_InPlaceMatrixMultiply( - o1, - o2, + return __PyTime_FromSeconds( + seconds, ); } - late final _PyNumber_InPlaceMatrixMultiplyPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceMatrixMultiply'); - late final _PyNumber_InPlaceMatrixMultiply = - _PyNumber_InPlaceMatrixMultiplyPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); - - ffi.Pointer PyNumber_InPlaceFloorDivide( - ffi.Pointer o1, - ffi.Pointer o2, + late final __PyTime_FromSecondsPtr = + _lookup>( + '_PyTime_FromSeconds'); + late final __PyTime_FromSeconds = + __PyTime_FromSecondsPtr.asFunction(); + + int _PyTime_FromNanoseconds( + int ns, ) { - return _PyNumber_InPlaceFloorDivide( - o1, - o2, + return __PyTime_FromNanoseconds( + ns, ); } - late final _PyNumber_InPlaceFloorDividePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceFloorDivide'); - late final _PyNumber_InPlaceFloorDivide = - _PyNumber_InPlaceFloorDividePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_FromNanosecondsPtr = + _lookup>( + '_PyTime_FromNanoseconds'); + late final __PyTime_FromNanoseconds = + __PyTime_FromNanosecondsPtr.asFunction(); - ffi.Pointer PyNumber_InPlaceTrueDivide( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_FromNanosecondsObject( + ffi.Pointer<_PyTime_t> t, + ffi.Pointer obj, ) { - return _PyNumber_InPlaceTrueDivide( - o1, - o2, + return __PyTime_FromNanosecondsObject( + t, + obj, ); } - late final _PyNumber_InPlaceTrueDividePtr = _lookup< + late final __PyTime_FromNanosecondsObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceTrueDivide'); - late final _PyNumber_InPlaceTrueDivide = - _PyNumber_InPlaceTrueDividePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer<_PyTime_t>, + ffi.Pointer)>>('_PyTime_FromNanosecondsObject'); + late final __PyTime_FromNanosecondsObject = + __PyTime_FromNanosecondsObjectPtr.asFunction< + int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer)>(); - ffi.Pointer PyNumber_InPlaceRemainder( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_FromSecondsObject( + ffi.Pointer<_PyTime_t> t, + ffi.Pointer obj, + int round, ) { - return _PyNumber_InPlaceRemainder( - o1, - o2, + return __PyTime_FromSecondsObject( + t, + obj, + round, ); } - late final _PyNumber_InPlaceRemainderPtr = _lookup< + late final __PyTime_FromSecondsObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceRemainder'); - late final _PyNumber_InPlaceRemainder = - _PyNumber_InPlaceRemainderPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, + ffi.Int32)>>('_PyTime_FromSecondsObject'); + late final __PyTime_FromSecondsObject = + __PyTime_FromSecondsObjectPtr.asFunction< + int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, int)>(); - ffi.Pointer PyNumber_InPlacePower( - ffi.Pointer o1, - ffi.Pointer o2, - ffi.Pointer o3, + int _PyTime_FromMillisecondsObject( + ffi.Pointer<_PyTime_t> t, + ffi.Pointer obj, + int round, ) { - return _PyNumber_InPlacePower( - o1, - o2, - o3, + return __PyTime_FromMillisecondsObject( + t, + obj, + round, ); } - late final _PyNumber_InPlacePowerPtr = _lookup< + late final __PyTime_FromMillisecondsObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlacePower'); - late final _PyNumber_InPlacePower = _PyNumber_InPlacePowerPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, + ffi.Int32)>>('_PyTime_FromMillisecondsObject'); + late final __PyTime_FromMillisecondsObject = + __PyTime_FromMillisecondsObjectPtr.asFunction< + int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, int)>(); - ffi.Pointer PyNumber_InPlaceLshift( - ffi.Pointer o1, - ffi.Pointer o2, + double _PyTime_AsSecondsDouble( + int t, ) { - return _PyNumber_InPlaceLshift( - o1, - o2, + return __PyTime_AsSecondsDouble( + t, ); } - late final _PyNumber_InPlaceLshiftPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceLshift'); - late final _PyNumber_InPlaceLshift = _PyNumber_InPlaceLshiftPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_AsSecondsDoublePtr = + _lookup>( + '_PyTime_AsSecondsDouble'); + late final __PyTime_AsSecondsDouble = + __PyTime_AsSecondsDoublePtr.asFunction(); - ffi.Pointer PyNumber_InPlaceRshift( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_AsMilliseconds( + int t, + int round, ) { - return _PyNumber_InPlaceRshift( - o1, - o2, + return __PyTime_AsMilliseconds( + t, + round, ); } - late final _PyNumber_InPlaceRshiftPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceRshift'); - late final _PyNumber_InPlaceRshift = _PyNumber_InPlaceRshiftPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_AsMillisecondsPtr = + _lookup>( + '_PyTime_AsMilliseconds'); + late final __PyTime_AsMilliseconds = + __PyTime_AsMillisecondsPtr.asFunction(); - ffi.Pointer PyNumber_InPlaceAnd( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_AsMicroseconds( + int t, + int round, ) { - return _PyNumber_InPlaceAnd( - o1, - o2, + return __PyTime_AsMicroseconds( + t, + round, ); } - late final _PyNumber_InPlaceAndPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceAnd'); - late final _PyNumber_InPlaceAnd = _PyNumber_InPlaceAndPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_AsMicrosecondsPtr = + _lookup>( + '_PyTime_AsMicroseconds'); + late final __PyTime_AsMicroseconds = + __PyTime_AsMicrosecondsPtr.asFunction(); - ffi.Pointer PyNumber_InPlaceXor( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_AsNanoseconds( + int t, ) { - return _PyNumber_InPlaceXor( - o1, - o2, + return __PyTime_AsNanoseconds( + t, ); } - late final _PyNumber_InPlaceXorPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceXor'); - late final _PyNumber_InPlaceXor = _PyNumber_InPlaceXorPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_AsNanosecondsPtr = + _lookup>( + '_PyTime_AsNanoseconds'); + late final __PyTime_AsNanoseconds = + __PyTime_AsNanosecondsPtr.asFunction(); - ffi.Pointer PyNumber_InPlaceOr( - ffi.Pointer o1, - ffi.Pointer o2, + ffi.Pointer _PyTime_AsNanosecondsObject( + int t, ) { - return _PyNumber_InPlaceOr( - o1, - o2, + return __PyTime_AsNanosecondsObject( + t, ); } - late final _PyNumber_InPlaceOrPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyNumber_InPlaceOr'); - late final _PyNumber_InPlaceOr = _PyNumber_InPlaceOrPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_AsNanosecondsObjectPtr = + _lookup Function(_PyTime_t)>>( + '_PyTime_AsNanosecondsObject'); + late final __PyTime_AsNanosecondsObject = __PyTime_AsNanosecondsObjectPtr + .asFunction Function(int)>(); - ffi.Pointer PyNumber_ToBase( - ffi.Pointer n, - int base, + int _PyTime_FromTimeval( + ffi.Pointer<_PyTime_t> tp, + ffi.Pointer tv, ) { - return _PyNumber_ToBase( - n, - base, + return __PyTime_FromTimeval( + tp, + tv, ); } - late final _PyNumber_ToBasePtr = _lookup< + late final __PyTime_FromTimevalPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Int)>>('PyNumber_ToBase'); - late final _PyNumber_ToBase = _PyNumber_ToBasePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + ffi.Int Function(ffi.Pointer<_PyTime_t>, + ffi.Pointer)>>('_PyTime_FromTimeval'); + late final __PyTime_FromTimeval = __PyTime_FromTimevalPtr + .asFunction, ffi.Pointer)>(); - int PySequence_Check( - ffi.Pointer o, + int _PyTime_AsTimeval( + int t, + ffi.Pointer tv, + int round, ) { - return _PySequence_Check( - o, + return __PyTime_AsTimeval( + t, + tv, + round, ); } - late final _PySequence_CheckPtr = - _lookup)>>( - 'PySequence_Check'); - late final _PySequence_Check = - _PySequence_CheckPtr.asFunction)>(); + late final __PyTime_AsTimevalPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(_PyTime_t, ffi.Pointer, + ffi.Int32)>>('_PyTime_AsTimeval'); + late final __PyTime_AsTimeval = __PyTime_AsTimevalPtr + .asFunction, int)>(); - int PySequence_Size( - ffi.Pointer o, + void _PyTime_AsTimeval_clamp( + int t, + ffi.Pointer tv, + int round, ) { - return _PySequence_Size( - o, + return __PyTime_AsTimeval_clamp( + t, + tv, + round, ); } - late final _PySequence_SizePtr = - _lookup)>>( - 'PySequence_Size'); - late final _PySequence_Size = - _PySequence_SizePtr.asFunction)>(); + late final __PyTime_AsTimeval_clampPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(_PyTime_t, ffi.Pointer, + ffi.Int32)>>('_PyTime_AsTimeval_clamp'); + late final __PyTime_AsTimeval_clamp = __PyTime_AsTimeval_clampPtr + .asFunction, int)>(); - int PySequence_Length( - ffi.Pointer o, + int _PyTime_AsTimevalTime_t( + int t, + ffi.Pointer secs, + ffi.Pointer us, + int round, ) { - return _PySequence_Length( - o, + return __PyTime_AsTimevalTime_t( + t, + secs, + us, + round, ); } - late final _PySequence_LengthPtr = - _lookup)>>( - 'PySequence_Length'); - late final _PySequence_Length = - _PySequence_LengthPtr.asFunction)>(); + late final __PyTime_AsTimevalTime_tPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(_PyTime_t, ffi.Pointer, ffi.Pointer, + ffi.Int32)>>('_PyTime_AsTimevalTime_t'); + late final __PyTime_AsTimevalTime_t = __PyTime_AsTimevalTime_tPtr.asFunction< + int Function(int, ffi.Pointer, ffi.Pointer, int)>(); - ffi.Pointer PySequence_Concat( - ffi.Pointer o1, - ffi.Pointer o2, + int _PyTime_FromTimespec( + ffi.Pointer<_PyTime_t> tp, + ffi.Pointer ts, ) { - return _PySequence_Concat( - o1, - o2, + return __PyTime_FromTimespec( + tp, + ts, ); } - late final _PySequence_ConcatPtr = _lookup< + late final __PyTime_FromTimespecPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PySequence_Concat'); - late final _PySequence_Concat = _PySequence_ConcatPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer<_PyTime_t>, + ffi.Pointer)>>('_PyTime_FromTimespec'); + late final __PyTime_FromTimespec = __PyTime_FromTimespecPtr.asFunction< + int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer)>(); - ffi.Pointer PySequence_Repeat( - ffi.Pointer o, - int count, + int _PyTime_AsTimespec( + int t, + ffi.Pointer ts, ) { - return _PySequence_Repeat( - o, - count, + return __PyTime_AsTimespec( + t, + ts, ); } - late final _PySequence_RepeatPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, Py_ssize_t)>>('PySequence_Repeat'); - late final _PySequence_Repeat = _PySequence_RepeatPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + late final __PyTime_AsTimespecPtr = _lookup< + ffi + .NativeFunction)>>( + '_PyTime_AsTimespec'); + late final __PyTime_AsTimespec = __PyTime_AsTimespecPtr + .asFunction)>(); - ffi.Pointer PySequence_GetItem( - ffi.Pointer o, - int i, + void _PyTime_AsTimespec_clamp( + int t, + ffi.Pointer ts, ) { - return _PySequence_GetItem( - o, - i, + return __PyTime_AsTimespec_clamp( + t, + ts, ); } - late final _PySequence_GetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, Py_ssize_t)>>('PySequence_GetItem'); - late final _PySequence_GetItem = _PySequence_GetItemPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + late final __PyTime_AsTimespec_clampPtr = _lookup< + ffi + .NativeFunction)>>( + '_PyTime_AsTimespec_clamp'); + late final __PyTime_AsTimespec_clamp = __PyTime_AsTimespec_clampPtr + .asFunction)>(); - ffi.Pointer PySequence_GetSlice( - ffi.Pointer o, - int i1, - int i2, + int _PyTime_Add( + int t1, + int t2, ) { - return _PySequence_GetSlice( - o, - i1, - i2, + return __PyTime_Add( + t1, + t2, ); } - late final _PySequence_GetSlicePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t, - Py_ssize_t)>>('PySequence_GetSlice'); - late final _PySequence_GetSlice = _PySequence_GetSlicePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int, int)>(); + late final __PyTime_AddPtr = + _lookup>( + '_PyTime_Add'); + late final __PyTime_Add = + __PyTime_AddPtr.asFunction(); - int PySequence_SetItem( - ffi.Pointer o, - int i, - ffi.Pointer v, + int _PyTime_MulDiv( + int ticks, + int mul, + int div, ) { - return _PySequence_SetItem( - o, - i, - v, + return __PyTime_MulDiv( + ticks, + mul, + div, ); } - late final _PySequence_SetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PySequence_SetItem'); - late final _PySequence_SetItem = _PySequence_SetItemPtr.asFunction< - int Function(ffi.Pointer, int, ffi.Pointer)>(); + late final __PyTime_MulDivPtr = _lookup< + ffi + .NativeFunction<_PyTime_t Function(_PyTime_t, _PyTime_t, _PyTime_t)>>( + '_PyTime_MulDiv'); + late final __PyTime_MulDiv = + __PyTime_MulDivPtr.asFunction(); - int PySequence_DelItem( - ffi.Pointer o, - int i, - ) { - return _PySequence_DelItem( - o, - i, - ); + int _PyTime_GetSystemClock() { + return __PyTime_GetSystemClock(); } - late final _PySequence_DelItemPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, Py_ssize_t)>>('PySequence_DelItem'); - late final _PySequence_DelItem = _PySequence_DelItemPtr.asFunction< - int Function(ffi.Pointer, int)>(); + late final __PyTime_GetSystemClockPtr = + _lookup>( + '_PyTime_GetSystemClock'); + late final __PyTime_GetSystemClock = + __PyTime_GetSystemClockPtr.asFunction(); - int PySequence_SetSlice( - ffi.Pointer o, - int i1, - int i2, - ffi.Pointer v, + int _PyTime_GetSystemClockWithInfo( + ffi.Pointer<_PyTime_t> t, + ffi.Pointer<_Py_clock_info_t> info, ) { - return _PySequence_SetSlice( - o, - i1, - i2, - v, + return __PyTime_GetSystemClockWithInfo( + t, + info, ); } - late final _PySequence_SetSlicePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_ssize_t, Py_ssize_t, - ffi.Pointer)>>('PySequence_SetSlice'); - late final _PySequence_SetSlice = _PySequence_SetSlicePtr.asFunction< - int Function(ffi.Pointer, int, int, ffi.Pointer)>(); + late final __PyTime_GetSystemClockWithInfoPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>>( + '_PyTime_GetSystemClockWithInfo'); + late final __PyTime_GetSystemClockWithInfo = + __PyTime_GetSystemClockWithInfoPtr.asFunction< + int Function( + ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>(); - int PySequence_DelSlice( - ffi.Pointer o, - int i1, - int i2, - ) { - return _PySequence_DelSlice( - o, - i1, - i2, - ); + int _PyTime_GetMonotonicClock() { + return __PyTime_GetMonotonicClock(); } - late final _PySequence_DelSlicePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_ssize_t, - Py_ssize_t)>>('PySequence_DelSlice'); - late final _PySequence_DelSlice = _PySequence_DelSlicePtr.asFunction< - int Function(ffi.Pointer, int, int)>(); + late final __PyTime_GetMonotonicClockPtr = + _lookup>( + '_PyTime_GetMonotonicClock'); + late final __PyTime_GetMonotonicClock = + __PyTime_GetMonotonicClockPtr.asFunction(); - ffi.Pointer PySequence_Tuple( - ffi.Pointer o, + int _PyTime_GetMonotonicClockWithInfo( + ffi.Pointer<_PyTime_t> t, + ffi.Pointer<_Py_clock_info_t> info, ) { - return _PySequence_Tuple( - o, + return __PyTime_GetMonotonicClockWithInfo( + t, + info, ); } - late final _PySequence_TuplePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PySequence_Tuple'); - late final _PySequence_Tuple = _PySequence_TuplePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final __PyTime_GetMonotonicClockWithInfoPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>>( + '_PyTime_GetMonotonicClockWithInfo'); + late final __PyTime_GetMonotonicClockWithInfo = + __PyTime_GetMonotonicClockWithInfoPtr.asFunction< + int Function( + ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>(); - ffi.Pointer PySequence_List( - ffi.Pointer o, + int _PyTime_localtime( + int t, + ffi.Pointer tm, ) { - return _PySequence_List( - o, + return __PyTime_localtime( + t, + tm, ); } - late final _PySequence_ListPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PySequence_List'); - late final _PySequence_List = _PySequence_ListPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final __PyTime_localtimePtr = + _lookup)>>( + '_PyTime_localtime'); + late final __PyTime_localtime = + __PyTime_localtimePtr.asFunction)>(); - ffi.Pointer PySequence_Fast( - ffi.Pointer o, - ffi.Pointer m, + int _PyTime_gmtime( + int t, + ffi.Pointer tm, ) { - return _PySequence_Fast( - o, - m, + return __PyTime_gmtime( + t, + tm, ); } - late final _PySequence_FastPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PySequence_Fast'); - late final _PySequence_Fast = _PySequence_FastPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_gmtimePtr = + _lookup)>>( + '_PyTime_gmtime'); + late final __PyTime_gmtime = + __PyTime_gmtimePtr.asFunction)>(); - int PySequence_Count( - ffi.Pointer o, - ffi.Pointer value, + int _PyTime_GetPerfCounter() { + return __PyTime_GetPerfCounter(); + } + + late final __PyTime_GetPerfCounterPtr = + _lookup>( + '_PyTime_GetPerfCounter'); + late final __PyTime_GetPerfCounter = + __PyTime_GetPerfCounterPtr.asFunction(); + + int _PyTime_GetPerfCounterWithInfo( + ffi.Pointer<_PyTime_t> t, + ffi.Pointer<_Py_clock_info_t> info, ) { - return _PySequence_Count( - o, - value, + return __PyTime_GetPerfCounterWithInfo( + t, + info, ); } - late final _PySequence_CountPtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function(ffi.Pointer, - ffi.Pointer)>>('PySequence_Count'); - late final _PySequence_Count = _PySequence_CountPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __PyTime_GetPerfCounterWithInfoPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>>( + '_PyTime_GetPerfCounterWithInfo'); + late final __PyTime_GetPerfCounterWithInfo = + __PyTime_GetPerfCounterWithInfoPtr.asFunction< + int Function( + ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>(); - int PySequence_Contains( - ffi.Pointer seq, - ffi.Pointer ob, + int _PyDeadline_Init( + int timeout, ) { - return _PySequence_Contains( - seq, - ob, + return __PyDeadline_Init( + timeout, ); } - late final _PySequence_ContainsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PySequence_Contains'); - late final _PySequence_Contains = _PySequence_ContainsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __PyDeadline_InitPtr = + _lookup>( + '_PyDeadline_Init'); + late final __PyDeadline_Init = + __PyDeadline_InitPtr.asFunction(); - int PySequence_In( - ffi.Pointer o, - ffi.Pointer value, + int _PyDeadline_Get( + int deadline, ) { - return _PySequence_In( - o, - value, + return __PyDeadline_Get( + deadline, ); } - late final _PySequence_InPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('PySequence_In'); - late final _PySequence_In = _PySequence_InPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __PyDeadline_GetPtr = + _lookup>( + '_PyDeadline_Get'); + late final __PyDeadline_Get = + __PyDeadline_GetPtr.asFunction(); - int PySequence_Index( - ffi.Pointer o, - ffi.Pointer value, + int PyCodec_Register( + ffi.Pointer search_function, ) { - return _PySequence_Index( - o, - value, + return _PyCodec_Register( + search_function, ); } - late final _PySequence_IndexPtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function(ffi.Pointer, - ffi.Pointer)>>('PySequence_Index'); - late final _PySequence_Index = _PySequence_IndexPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final _PyCodec_RegisterPtr = + _lookup)>>( + 'PyCodec_Register'); + late final _PyCodec_Register = + _PyCodec_RegisterPtr.asFunction)>(); - ffi.Pointer PySequence_InPlaceConcat( - ffi.Pointer o1, - ffi.Pointer o2, + int PyCodec_Unregister( + ffi.Pointer search_function, ) { - return _PySequence_InPlaceConcat( - o1, - o2, + return _PyCodec_Unregister( + search_function, ); } - late final _PySequence_InPlaceConcatPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PySequence_InPlaceConcat'); - late final _PySequence_InPlaceConcat = - _PySequence_InPlaceConcatPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final _PyCodec_UnregisterPtr = + _lookup)>>( + 'PyCodec_Unregister'); + late final _PyCodec_Unregister = + _PyCodec_UnregisterPtr.asFunction)>(); - ffi.Pointer PySequence_InPlaceRepeat( - ffi.Pointer o, - int count, + ffi.Pointer _PyCodec_Lookup( + ffi.Pointer encoding, ) { - return _PySequence_InPlaceRepeat( - o, - count, + return __PyCodec_Lookup( + encoding, ); } - late final _PySequence_InPlaceRepeatPtr = _lookup< + late final __PyCodec_LookupPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, Py_ssize_t)>>('PySequence_InPlaceRepeat'); - late final _PySequence_InPlaceRepeat = _PySequence_InPlaceRepeatPtr - .asFunction Function(ffi.Pointer, int)>(); + ffi.Pointer)>>('_PyCodec_Lookup'); + late final __PyCodec_Lookup = __PyCodec_LookupPtr + .asFunction Function(ffi.Pointer)>(); - int PyMapping_Check( - ffi.Pointer o, + int _PyCodec_Forget( + ffi.Pointer encoding, ) { - return _PyMapping_Check( - o, + return __PyCodec_Forget( + encoding, ); } - late final _PyMapping_CheckPtr = - _lookup)>>( - 'PyMapping_Check'); - late final _PyMapping_Check = - _PyMapping_CheckPtr.asFunction)>(); + late final __PyCodec_ForgetPtr = + _lookup)>>( + '_PyCodec_Forget'); + late final __PyCodec_Forget = + __PyCodec_ForgetPtr.asFunction)>(); - int PyMapping_Size( - ffi.Pointer o, + int PyCodec_KnownEncoding( + ffi.Pointer encoding, ) { - return _PyMapping_Size( - o, + return _PyCodec_KnownEncoding( + encoding, ); } - late final _PyMapping_SizePtr = - _lookup)>>( - 'PyMapping_Size'); - late final _PyMapping_Size = - _PyMapping_SizePtr.asFunction)>(); + late final _PyCodec_KnownEncodingPtr = + _lookup)>>( + 'PyCodec_KnownEncoding'); + late final _PyCodec_KnownEncoding = _PyCodec_KnownEncodingPtr.asFunction< + int Function(ffi.Pointer)>(); - int PyMapping_Length( - ffi.Pointer o, + ffi.Pointer PyCodec_Encode( + ffi.Pointer object, + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return _PyMapping_Length( - o, + return _PyCodec_Encode( + object, + encoding, + errors, ); } - late final _PyMapping_LengthPtr = - _lookup)>>( - 'PyMapping_Length'); - late final _PyMapping_Length = - _PyMapping_LengthPtr.asFunction)>(); + late final _PyCodec_EncodePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>('PyCodec_Encode'); + late final _PyCodec_Encode = _PyCodec_EncodePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - int PyMapping_HasKeyString( - ffi.Pointer o, - ffi.Pointer key, + ffi.Pointer PyCodec_Decode( + ffi.Pointer object, + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return _PyMapping_HasKeyString( - o, - key, + return _PyCodec_Decode( + object, + encoding, + errors, ); } - late final _PyMapping_HasKeyStringPtr = _lookup< + late final _PyCodec_DecodePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyMapping_HasKeyString'); - late final _PyMapping_HasKeyString = _PyMapping_HasKeyStringPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>('PyCodec_Decode'); + late final _PyCodec_Decode = _PyCodec_DecodePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - int PyMapping_HasKey( - ffi.Pointer o, - ffi.Pointer key, + ffi.Pointer _PyCodec_LookupTextEncoding( + ffi.Pointer encoding, + ffi.Pointer alternate_command, ) { - return _PyMapping_HasKey( - o, - key, + return __PyCodec_LookupTextEncoding( + encoding, + alternate_command, ); } - late final _PyMapping_HasKeyPtr = _lookup< + late final __PyCodec_LookupTextEncodingPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyMapping_HasKey'); - late final _PyMapping_HasKey = _PyMapping_HasKeyPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyCodec_LookupTextEncoding'); + late final __PyCodec_LookupTextEncoding = + __PyCodec_LookupTextEncodingPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyMapping_Keys( - ffi.Pointer o, + ffi.Pointer _PyCodec_EncodeText( + ffi.Pointer object, + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return _PyMapping_Keys( - o, + return __PyCodec_EncodeText( + object, + encoding, + errors, ); } - late final _PyMapping_KeysPtr = _lookup< + late final __PyCodec_EncodeTextPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyMapping_Keys'); - late final _PyMapping_Keys = _PyMapping_KeysPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_PyCodec_EncodeText'); + late final __PyCodec_EncodeText = __PyCodec_EncodeTextPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyMapping_Values( - ffi.Pointer o, + ffi.Pointer _PyCodec_DecodeText( + ffi.Pointer object, + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return _PyMapping_Values( - o, + return __PyCodec_DecodeText( + object, + encoding, + errors, ); } - late final _PyMapping_ValuesPtr = _lookup< + late final __PyCodec_DecodeTextPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyMapping_Values'); - late final _PyMapping_Values = _PyMapping_ValuesPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_PyCodec_DecodeText'); + late final __PyCodec_DecodeText = __PyCodec_DecodeTextPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyMapping_Items( - ffi.Pointer o, + ffi.Pointer _PyCodecInfo_GetIncrementalDecoder( + ffi.Pointer codec_info, + ffi.Pointer errors, ) { - return _PyMapping_Items( - o, + return __PyCodecInfo_GetIncrementalDecoder( + codec_info, + errors, ); } - late final _PyMapping_ItemsPtr = _lookup< + late final __PyCodecInfo_GetIncrementalDecoderPtr = _lookup< ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyCodecInfo_GetIncrementalDecoder'); + late final __PyCodecInfo_GetIncrementalDecoder = + __PyCodecInfo_GetIncrementalDecoderPtr.asFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyMapping_Items'); - late final _PyMapping_Items = _PyMapping_ItemsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyMapping_GetItemString( - ffi.Pointer o, - ffi.Pointer key, + ffi.Pointer _PyCodecInfo_GetIncrementalEncoder( + ffi.Pointer codec_info, + ffi.Pointer errors, ) { - return _PyMapping_GetItemString( - o, - key, + return __PyCodecInfo_GetIncrementalEncoder( + codec_info, + errors, ); } - late final _PyMapping_GetItemStringPtr = _lookup< + late final __PyCodecInfo_GetIncrementalEncoderPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyMapping_GetItemString'); - late final _PyMapping_GetItemString = _PyMapping_GetItemStringPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('_PyCodecInfo_GetIncrementalEncoder'); + late final __PyCodecInfo_GetIncrementalEncoder = + __PyCodecInfo_GetIncrementalEncoderPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyMapping_SetItemString( - ffi.Pointer o, - ffi.Pointer key, - ffi.Pointer value, + ffi.Pointer PyCodec_Encoder( + ffi.Pointer encoding, ) { - return _PyMapping_SetItemString( - o, - key, - value, + return _PyCodec_Encoder( + encoding, ); } - late final _PyMapping_SetItemStringPtr = _lookup< + late final _PyCodec_EncoderPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyMapping_SetItemString'); - late final _PyMapping_SetItemString = _PyMapping_SetItemStringPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyCodec_Encoder'); + late final _PyCodec_Encoder = _PyCodec_EncoderPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyObject_IsInstance( - ffi.Pointer object, - ffi.Pointer typeorclass, + ffi.Pointer PyCodec_Decoder( + ffi.Pointer encoding, ) { - return _PyObject_IsInstance( - object, - typeorclass, + return _PyCodec_Decoder( + encoding, ); } - late final _PyObject_IsInstancePtr = _lookup< + late final _PyCodec_DecoderPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_IsInstance'); - late final _PyObject_IsInstance = _PyObject_IsInstancePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyCodec_Decoder'); + late final _PyCodec_Decoder = _PyCodec_DecoderPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyObject_IsSubclass( - ffi.Pointer object, - ffi.Pointer typeorclass, + ffi.Pointer PyCodec_IncrementalEncoder( + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return _PyObject_IsSubclass( - object, - typeorclass, + return _PyCodec_IncrementalEncoder( + encoding, + errors, ); } - late final _PyObject_IsSubclassPtr = _lookup< + late final _PyCodec_IncrementalEncoderPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_IsSubclass'); - late final _PyObject_IsSubclass = _PyObject_IsSubclassPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyCodec_IncrementalEncoder'); + late final _PyCodec_IncrementalEncoder = + _PyCodec_IncrementalEncoderPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyStack_AsDict( - ffi.Pointer> values, - ffi.Pointer kwnames, + ffi.Pointer PyCodec_IncrementalDecoder( + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return __PyStack_AsDict( - values, - kwnames, + return _PyCodec_IncrementalDecoder( + encoding, + errors, ); } - late final __PyStack_AsDictPtr = _lookup< + late final _PyCodec_IncrementalDecoderPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer>, - ffi.Pointer)>>('_PyStack_AsDict'); - late final __PyStack_AsDict = __PyStack_AsDictPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer>, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyCodec_IncrementalDecoder'); + late final _PyCodec_IncrementalDecoder = + _PyCodec_IncrementalDecoderPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _Py_CheckFunctionResult( - ffi.Pointer tstate, - ffi.Pointer callable, - ffi.Pointer result, - ffi.Pointer where, + ffi.Pointer PyCodec_StreamReader( + ffi.Pointer encoding, + ffi.Pointer stream, + ffi.Pointer errors, ) { - return __Py_CheckFunctionResult( - tstate, - callable, - result, - where, + return _PyCodec_StreamReader( + encoding, + stream, + errors, ); } - late final __Py_CheckFunctionResultPtr = _lookup< + late final _PyCodec_StreamReaderPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, + ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('_Py_CheckFunctionResult'); - late final __Py_CheckFunctionResult = __Py_CheckFunctionResultPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + ffi.Pointer)>>('PyCodec_StreamReader'); + late final _PyCodec_StreamReader = _PyCodec_StreamReaderPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyObject_MakeTpCall( - ffi.Pointer tstate, - ffi.Pointer callable, - ffi.Pointer> args, - int nargs, - ffi.Pointer keywords, + ffi.Pointer PyCodec_StreamWriter( + ffi.Pointer encoding, + ffi.Pointer stream, + ffi.Pointer errors, ) { - return __PyObject_MakeTpCall( - tstate, - callable, - args, - nargs, - keywords, + return _PyCodec_StreamWriter( + encoding, + stream, + errors, ); } - late final __PyObject_MakeTpCallPtr = _lookup< + late final _PyCodec_StreamWriterPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, + ffi.Pointer, ffi.Pointer, - ffi.Pointer>, - Py_ssize_t, - ffi.Pointer)>>('_PyObject_MakeTpCall'); - late final __PyObject_MakeTpCall = __PyObject_MakeTpCallPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>, - int, - ffi.Pointer)>(); + ffi.Pointer)>>('PyCodec_StreamWriter'); + late final _PyCodec_StreamWriter = _PyCodec_StreamWriterPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyObject_VectorcallDict( - ffi.Pointer callable, - ffi.Pointer> args, - int nargsf, - ffi.Pointer kwargs, + int PyCodec_RegisterError( + ffi.Pointer name, + ffi.Pointer error, ) { - return _PyObject_VectorcallDict( - callable, - args, - nargsf, - kwargs, + return _PyCodec_RegisterError( + name, + error, ); } - late final _PyObject_VectorcallDictPtr = _lookup< + late final _PyCodec_RegisterErrorPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Size, - ffi.Pointer)>>('PyObject_VectorcallDict'); - late final _PyObject_VectorcallDict = _PyObject_VectorcallDictPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer>, int, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyCodec_RegisterError'); + late final _PyCodec_RegisterError = _PyCodec_RegisterErrorPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyVectorcall_Call( - ffi.Pointer callable, - ffi.Pointer tuple, - ffi.Pointer dict, + ffi.Pointer PyCodec_LookupError( + ffi.Pointer name, ) { - return _PyVectorcall_Call( - callable, - tuple, - dict, + return _PyCodec_LookupError( + name, ); } - late final _PyVectorcall_CallPtr = _lookup< + late final _PyCodec_LookupErrorPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyVectorcall_Call'); - late final _PyVectorcall_Call = _PyVectorcall_CallPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PyCodec_LookupError'); + late final _PyCodec_LookupError = _PyCodec_LookupErrorPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyObject_VectorcallMethod( - ffi.Pointer name, - ffi.Pointer> args, - int nargsf, - ffi.Pointer kwnames, + ffi.Pointer PyCodec_StrictErrors( + ffi.Pointer exc, ) { - return _PyObject_VectorcallMethod( - name, - args, - nargsf, - kwnames, + return _PyCodec_StrictErrors( + exc, ); } - late final _PyObject_VectorcallMethodPtr = _lookup< + late final _PyCodec_StrictErrorsPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Size, - ffi.Pointer)>>('PyObject_VectorcallMethod'); - late final _PyObject_VectorcallMethod = - _PyObject_VectorcallMethodPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer>, - int, - ffi.Pointer)>(); + ffi.Pointer)>>('PyCodec_StrictErrors'); + late final _PyCodec_StrictErrors = _PyCodec_StrictErrorsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer _PyObject_CallMethodId( - ffi.Pointer obj, - ffi.Pointer<_Py_Identifier> name, - ffi.Pointer format, + ffi.Pointer PyCodec_IgnoreErrors( + ffi.Pointer exc, ) { - return __PyObject_CallMethodId( - obj, - name, - format, + return _PyCodec_IgnoreErrors( + exc, ); } - late final __PyObject_CallMethodIdPtr = _lookup< + late final _PyCodec_IgnoreErrorsPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer<_Py_Identifier>, - ffi.Pointer)>>('_PyObject_CallMethodId'); - late final __PyObject_CallMethodId = __PyObject_CallMethodIdPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer<_Py_Identifier>, ffi.Pointer)>(); + ffi.Pointer)>>('PyCodec_IgnoreErrors'); + late final _PyCodec_IgnoreErrors = _PyCodec_IgnoreErrorsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer _PyObject_CallMethodId_SizeT( - ffi.Pointer obj, - ffi.Pointer<_Py_Identifier> name, - ffi.Pointer format, + ffi.Pointer PyCodec_ReplaceErrors( + ffi.Pointer exc, ) { - return __PyObject_CallMethodId_SizeT( - obj, - name, - format, + return _PyCodec_ReplaceErrors( + exc, ); } - late final __PyObject_CallMethodId_SizeTPtr = _lookup< + late final _PyCodec_ReplaceErrorsPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer<_Py_Identifier>, - ffi.Pointer)>>('_PyObject_CallMethodId_SizeT'); - late final __PyObject_CallMethodId_SizeT = - __PyObject_CallMethodId_SizeTPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer<_Py_Identifier>, ffi.Pointer)>(); + ffi.Pointer)>>('PyCodec_ReplaceErrors'); + late final _PyCodec_ReplaceErrors = _PyCodec_ReplaceErrorsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer _PyObject_CallMethodIdObjArgs( - ffi.Pointer obj, - ffi.Pointer<_Py_Identifier> name, + ffi.Pointer PyCodec_XMLCharRefReplaceErrors( + ffi.Pointer exc, ) { - return __PyObject_CallMethodIdObjArgs( - obj, - name, + return _PyCodec_XMLCharRefReplaceErrors( + exc, ); } - late final __PyObject_CallMethodIdObjArgsPtr = _lookup< + late final _PyCodec_XMLCharRefReplaceErrorsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer<_Py_Identifier>)>>('_PyObject_CallMethodIdObjArgs'); - late final __PyObject_CallMethodIdObjArgs = - __PyObject_CallMethodIdObjArgsPtr.asFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer<_Py_Identifier>)>(); + ffi.Pointer)>>('PyCodec_XMLCharRefReplaceErrors'); + late final _PyCodec_XMLCharRefReplaceErrors = + _PyCodec_XMLCharRefReplaceErrorsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PyObject_HasLen( - ffi.Pointer o, + ffi.Pointer PyCodec_BackslashReplaceErrors( + ffi.Pointer exc, ) { - return __PyObject_HasLen( - o, + return _PyCodec_BackslashReplaceErrors( + exc, ); } - late final __PyObject_HasLenPtr = - _lookup)>>( - '_PyObject_HasLen'); - late final __PyObject_HasLen = - __PyObject_HasLenPtr.asFunction)>(); + late final _PyCodec_BackslashReplaceErrorsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyCodec_BackslashReplaceErrors'); + late final _PyCodec_BackslashReplaceErrors = + _PyCodec_BackslashReplaceErrorsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyObject_LengthHint( - ffi.Pointer o, - int arg1, + ffi.Pointer PyCodec_NameReplaceErrors( + ffi.Pointer exc, ) { - return _PyObject_LengthHint( - o, - arg1, + return _PyCodec_NameReplaceErrors( + exc, ); } - late final _PyObject_LengthHintPtr = _lookup< + late final _PyCodec_NameReplaceErrorsPtr = _lookup< ffi.NativeFunction< - Py_ssize_t Function( - ffi.Pointer, Py_ssize_t)>>('PyObject_LengthHint'); - late final _PyObject_LengthHint = _PyObject_LengthHintPtr.asFunction< - int Function(ffi.Pointer, int)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyCodec_NameReplaceErrors'); + late final _PyCodec_NameReplaceErrors = _PyCodec_NameReplaceErrorsPtr + .asFunction Function(ffi.Pointer)>(); - int PyObject_CheckBuffer( - ffi.Pointer obj, - ) { - return _PyObject_CheckBuffer( - obj, - ); - } + late final ffi.Pointer> _Py_hexdigits = + _lookup>('Py_hexdigits'); - late final _PyObject_CheckBufferPtr = - _lookup)>>( - 'PyObject_CheckBuffer'); - late final _PyObject_CheckBuffer = _PyObject_CheckBufferPtr.asFunction< - int Function(ffi.Pointer)>(); + ffi.Pointer get Py_hexdigits => _Py_hexdigits.value; - int PyObject_GetBuffer( - ffi.Pointer obj, - ffi.Pointer view, - int flags, + set Py_hexdigits(ffi.Pointer value) => _Py_hexdigits.value = value; + + void PyErr_SetNone( + ffi.Pointer arg0, ) { - return _PyObject_GetBuffer( - obj, - view, - flags, + return _PyErr_SetNone( + arg0, ); } - late final _PyObject_GetBufferPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Int)>>('PyObject_GetBuffer'); - late final _PyObject_GetBuffer = _PyObject_GetBufferPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); + late final _PyErr_SetNonePtr = + _lookup)>>( + 'PyErr_SetNone'); + late final _PyErr_SetNone = + _PyErr_SetNonePtr.asFunction)>(); - ffi.Pointer PyBuffer_GetPointer( - ffi.Pointer view, - ffi.Pointer indices, + void PyErr_SetObject( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyBuffer_GetPointer( - view, - indices, + return _PyErr_SetObject( + arg0, + arg1, ); } - late final _PyBuffer_GetPointerPtr = _lookup< + late final _PyErr_SetObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyBuffer_GetPointer'); - late final _PyBuffer_GetPointer = _PyBuffer_GetPointerPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('PyErr_SetObject'); + late final _PyErr_SetObject = _PyErr_SetObjectPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - int PyBuffer_SizeFromFormat( - ffi.Pointer format, + void PyErr_SetString( + ffi.Pointer exception, + ffi.Pointer string, ) { - return _PyBuffer_SizeFromFormat( - format, + return _PyErr_SetString( + exception, + string, ); } - late final _PyBuffer_SizeFromFormatPtr = - _lookup)>>( - 'PyBuffer_SizeFromFormat'); - late final _PyBuffer_SizeFromFormat = _PyBuffer_SizeFromFormatPtr.asFunction< - int Function(ffi.Pointer)>(); + late final _PyErr_SetStringPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('PyErr_SetString'); + late final _PyErr_SetString = _PyErr_SetStringPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - int PyBuffer_ToContiguous( - ffi.Pointer buf, - ffi.Pointer view, - int len, - int order, - ) { - return _PyBuffer_ToContiguous( - buf, - view, - len, - order, - ); + ffi.Pointer PyErr_Occurred() { + return _PyErr_Occurred(); } - late final _PyBuffer_ToContiguousPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - Py_ssize_t, ffi.Char)>>('PyBuffer_ToContiguous'); - late final _PyBuffer_ToContiguous = _PyBuffer_ToContiguousPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, int)>(); + late final _PyErr_OccurredPtr = + _lookup Function()>>( + 'PyErr_Occurred'); + late final _PyErr_Occurred = + _PyErr_OccurredPtr.asFunction Function()>(); - int PyBuffer_FromContiguous( - ffi.Pointer view, - ffi.Pointer buf, - int len, - int order, + void PyErr_Clear() { + return _PyErr_Clear(); + } + + late final _PyErr_ClearPtr = + _lookup>('PyErr_Clear'); + late final _PyErr_Clear = _PyErr_ClearPtr.asFunction(); + + void PyErr_Fetch( + ffi.Pointer> arg0, + ffi.Pointer> arg1, + ffi.Pointer> arg2, ) { - return _PyBuffer_FromContiguous( - view, - buf, - len, - order, + return _PyErr_Fetch( + arg0, + arg1, + arg2, ); } - late final _PyBuffer_FromContiguousPtr = _lookup< + late final _PyErr_FetchPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - Py_ssize_t, ffi.Char)>>('PyBuffer_FromContiguous'); - late final _PyBuffer_FromContiguous = _PyBuffer_FromContiguousPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, int)>(); + ffi.Void Function( + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>>('PyErr_Fetch'); + late final _PyErr_Fetch = _PyErr_FetchPtr.asFunction< + void Function( + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>(); - int PyObject_CopyData( - ffi.Pointer dest, - ffi.Pointer src, + void PyErr_Restore( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyObject_CopyData( - dest, - src, + return _PyErr_Restore( + arg0, + arg1, + arg2, ); } - late final _PyObject_CopyDataPtr = _lookup< + late final _PyErr_RestorePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyObject_CopyData'); - late final _PyObject_CopyData = _PyObject_CopyDataPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyErr_Restore'); + late final _PyErr_Restore = _PyErr_RestorePtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - int PyBuffer_IsContiguous( - ffi.Pointer view, - int fort, + ffi.Pointer PyErr_GetHandledException() { + return _PyErr_GetHandledException1(); + } + + late final _PyErr_GetHandledExceptionPtr = + _lookup Function()>>( + 'PyErr_GetHandledException'); + late final _PyErr_GetHandledException1 = _PyErr_GetHandledExceptionPtr + .asFunction Function()>(); + + void PyErr_SetHandledException( + ffi.Pointer arg0, ) { - return _PyBuffer_IsContiguous( - view, - fort, + return _PyErr_SetHandledException1( + arg0, ); } - late final _PyBuffer_IsContiguousPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Char)>>('PyBuffer_IsContiguous'); - late final _PyBuffer_IsContiguous = _PyBuffer_IsContiguousPtr.asFunction< - int Function(ffi.Pointer, int)>(); + late final _PyErr_SetHandledExceptionPtr = + _lookup)>>( + 'PyErr_SetHandledException'); + late final _PyErr_SetHandledException1 = _PyErr_SetHandledExceptionPtr + .asFunction)>(); - void PyBuffer_FillContiguousStrides( - int ndims, - ffi.Pointer shape, - ffi.Pointer strides, - int itemsize, - int fort, + void PyErr_GetExcInfo( + ffi.Pointer> arg0, + ffi.Pointer> arg1, + ffi.Pointer> arg2, ) { - return _PyBuffer_FillContiguousStrides( - ndims, - shape, - strides, - itemsize, - fort, + return _PyErr_GetExcInfo1( + arg0, + arg1, + arg2, ); } - late final _PyBuffer_FillContiguousStridesPtr = _lookup< + late final _PyErr_GetExcInfoPtr = _lookup< ffi.NativeFunction< ffi.Void Function( - ffi.Int, - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Char)>>('PyBuffer_FillContiguousStrides'); - late final _PyBuffer_FillContiguousStrides = - _PyBuffer_FillContiguousStridesPtr.asFunction< - void Function(int, ffi.Pointer, ffi.Pointer, - int, int)>(); + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>>('PyErr_GetExcInfo'); + late final _PyErr_GetExcInfo1 = _PyErr_GetExcInfoPtr.asFunction< + void Function( + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>(); - int PyBuffer_FillInfo( - ffi.Pointer view, - ffi.Pointer o, - ffi.Pointer buf, - int len, - int readonly, - int flags, + void PyErr_SetExcInfo( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyBuffer_FillInfo( - view, - o, - buf, - len, - readonly, - flags, + return _PyErr_SetExcInfo( + arg0, + arg1, + arg2, ); } - late final _PyBuffer_FillInfoPtr = _lookup< + late final _PyErr_SetExcInfoPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - Py_ssize_t, - ffi.Int, - ffi.Int)>>('PyBuffer_FillInfo'); - late final _PyBuffer_FillInfo = _PyBuffer_FillInfoPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, int, int, int)>(); + ffi.Void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyErr_SetExcInfo'); + late final _PyErr_SetExcInfo = _PyErr_SetExcInfoPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - void PyBuffer_Release( - ffi.Pointer view, + void Py_FatalError( + ffi.Pointer message, ) { - return _PyBuffer_Release( - view, + return _Py_FatalError( + message, ); } - late final _PyBuffer_ReleasePtr = - _lookup)>>( - 'PyBuffer_Release'); - late final _PyBuffer_Release = - _PyBuffer_ReleasePtr.asFunction)>(); + late final _Py_FatalErrorPtr = + _lookup)>>( + 'Py_FatalError'); + late final _Py_FatalError = + _Py_FatalErrorPtr.asFunction)>(); - int _PySequence_IterSearch( - ffi.Pointer seq, - ffi.Pointer obj, - int operation, + int PyErr_GivenExceptionMatches( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __PySequence_IterSearch( - seq, - obj, - operation, + return _PyErr_GivenExceptionMatches( + arg0, + arg1, ); } - late final __PySequence_IterSearchPtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function(ffi.Pointer, ffi.Pointer, - ffi.Int)>>('_PySequence_IterSearch'); - late final __PySequence_IterSearch = __PySequence_IterSearchPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); - - int _PyObject_RealIsInstance( - ffi.Pointer inst, - ffi.Pointer cls, - ) { - return __PyObject_RealIsInstance( - inst, - cls, - ); - } - - late final __PyObject_RealIsInstancePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyObject_RealIsInstance'); - late final __PyObject_RealIsInstance = __PyObject_RealIsInstancePtr - .asFunction, ffi.Pointer)>(); - - int _PyObject_RealIsSubclass( - ffi.Pointer derived, - ffi.Pointer cls, - ) { - return __PyObject_RealIsSubclass( - derived, - cls, - ); - } - - late final __PyObject_RealIsSubclassPtr = _lookup< + late final _PyErr_GivenExceptionMatchesPtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyObject_RealIsSubclass'); - late final __PyObject_RealIsSubclass = __PyObject_RealIsSubclassPtr + ffi.Pointer)>>('PyErr_GivenExceptionMatches'); + late final _PyErr_GivenExceptionMatches = _PyErr_GivenExceptionMatchesPtr .asFunction, ffi.Pointer)>(); - ffi.Pointer> _PySequence_BytesToCharpArray( - ffi.Pointer self, + int PyErr_ExceptionMatches( + ffi.Pointer arg0, ) { - return __PySequence_BytesToCharpArray( - self, + return _PyErr_ExceptionMatches( + arg0, ); } - late final __PySequence_BytesToCharpArrayPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer> Function( - ffi.Pointer)>>('_PySequence_BytesToCharpArray'); - late final __PySequence_BytesToCharpArray = - __PySequence_BytesToCharpArrayPtr.asFunction< - ffi.Pointer> Function(ffi.Pointer)>(); + late final _PyErr_ExceptionMatchesPtr = + _lookup)>>( + 'PyErr_ExceptionMatches'); + late final _PyErr_ExceptionMatches = _PyErr_ExceptionMatchesPtr.asFunction< + int Function(ffi.Pointer)>(); - void _Py_FreeCharPArray( - ffi.Pointer> array, + void PyErr_NormalizeException( + ffi.Pointer> arg0, + ffi.Pointer> arg1, + ffi.Pointer> arg2, ) { - return __Py_FreeCharPArray( - array, + return _PyErr_NormalizeException( + arg0, + arg1, + arg2, ); } - late final __Py_FreeCharPArrayPtr = _lookup< + late final _PyErr_NormalizeExceptionPtr = _lookup< ffi.NativeFunction< ffi.Void Function( - ffi.Pointer>)>>('_Py_FreeCharPArray'); - late final __Py_FreeCharPArray = __Py_FreeCharPArrayPtr - .asFunction>)>(); - - void _Py_add_one_to_index_F( - int nd, - ffi.Pointer index, - ffi.Pointer shape, - ) { - return __Py_add_one_to_index_F( - nd, - index, - shape, - ); - } - - late final __Py_add_one_to_index_FPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Int, ffi.Pointer, - ffi.Pointer)>>('_Py_add_one_to_index_F'); - late final __Py_add_one_to_index_F = __Py_add_one_to_index_FPtr.asFunction< - void Function(int, ffi.Pointer, ffi.Pointer)>(); - - void _Py_add_one_to_index_C( - int nd, - ffi.Pointer index, - ffi.Pointer shape, - ) { - return __Py_add_one_to_index_C( - nd, - index, - shape, - ); - } - - late final __Py_add_one_to_index_CPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Int, ffi.Pointer, - ffi.Pointer)>>('_Py_add_one_to_index_C'); - late final __Py_add_one_to_index_C = __Py_add_one_to_index_CPtr.asFunction< - void Function(int, ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>>('PyErr_NormalizeException'); + late final _PyErr_NormalizeException = + _PyErr_NormalizeExceptionPtr.asFunction< + void Function( + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>(); - int _Py_convert_optional_to_ssize_t( + int PyException_SetTraceback( ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer arg1, ) { - return __Py_convert_optional_to_ssize_t( + return _PyException_SetTraceback( arg0, arg1, ); } - late final __Py_convert_optional_to_ssize_tPtr = _lookup< + late final _PyException_SetTracebackPtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_Py_convert_optional_to_ssize_t'); - late final __Py_convert_optional_to_ssize_t = - __Py_convert_optional_to_ssize_tPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PyException_SetTraceback'); + late final _PyException_SetTraceback = _PyException_SetTracebackPtr + .asFunction, ffi.Pointer)>(); - ffi.Pointer _PyNumber_Index( - ffi.Pointer o, + ffi.Pointer PyException_GetTraceback( + ffi.Pointer arg0, ) { - return __PyNumber_Index( - o, + return _PyException_GetTraceback( + arg0, ); } - late final __PyNumber_IndexPtr = _lookup< + late final _PyException_GetTracebackPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('_PyNumber_Index'); - late final __PyNumber_Index = __PyNumber_IndexPtr + ffi.Pointer)>>('PyException_GetTraceback'); + late final _PyException_GetTraceback = _PyException_GetTracebackPtr .asFunction Function(ffi.Pointer)>(); - late final ffi.Pointer _PyGen_Type = - _lookup('PyGen_Type'); - - PyTypeObject get PyGen_Type => _PyGen_Type.ref; - - ffi.Pointer PyGen_New( - ffi.Pointer arg0, + ffi.Pointer PyException_GetCause( + ffi.Pointer arg0, ) { - return _PyGen_New( + return _PyException_GetCause( arg0, ); } - late final _PyGen_NewPtr = _lookup< + late final _PyException_GetCausePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyGen_New'); - late final _PyGen_New = _PyGen_NewPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer)>>('PyException_GetCause'); + late final _PyException_GetCause = _PyException_GetCausePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyGen_NewWithQualName( - ffi.Pointer arg0, - ffi.Pointer name, - ffi.Pointer qualname, + void PyException_SetCause( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyGen_NewWithQualName( + return _PyException_SetCause( arg0, - name, - qualname, + arg1, ); } - late final _PyGen_NewWithQualNamePtr = _lookup< + late final _PyException_SetCausePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyGen_NewWithQualName'); - late final _PyGen_NewWithQualName = _PyGen_NewWithQualNamePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('PyException_SetCause'); + late final _PyException_SetCause = _PyException_SetCausePtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - int _PyGen_SetStopIterationValue( + ffi.Pointer PyException_GetContext( ffi.Pointer arg0, ) { - return __PyGen_SetStopIterationValue( + return _PyException_GetContext( arg0, ); } - late final __PyGen_SetStopIterationValuePtr = - _lookup)>>( - '_PyGen_SetStopIterationValue'); - late final __PyGen_SetStopIterationValue = __PyGen_SetStopIterationValuePtr - .asFunction)>(); + late final _PyException_GetContextPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyException_GetContext'); + late final _PyException_GetContext = _PyException_GetContextPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PyGen_FetchStopIterationValue( - ffi.Pointer> arg0, + void PyException_SetContext( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __PyGen_FetchStopIterationValue( + return _PyException_SetContext( arg0, + arg1, ); } - late final __PyGen_FetchStopIterationValuePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer>)>>( - '_PyGen_FetchStopIterationValue'); - late final __PyGen_FetchStopIterationValue = - __PyGen_FetchStopIterationValuePtr - .asFunction>)>(); + late final _PyException_SetContextPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('PyException_SetContext'); + late final _PyException_SetContext = _PyException_SetContextPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyGen_yf( - ffi.Pointer arg0, + ffi.Pointer PyExceptionClass_Name( + ffi.Pointer arg0, ) { - return __PyGen_yf( + return _PyExceptionClass_Name( arg0, ); } - late final __PyGen_yfPtr = _lookup< + late final _PyExceptionClass_NamePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_PyGen_yf'); - late final __PyGen_yf = __PyGen_yfPtr - .asFunction Function(ffi.Pointer)>(); - - void _PyGen_Finalize( - ffi.Pointer self, - ) { - return __PyGen_Finalize( - self, - ); - } + ffi.Pointer Function( + ffi.Pointer)>>('PyExceptionClass_Name'); + late final _PyExceptionClass_Name = _PyExceptionClass_NamePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - late final __PyGen_FinalizePtr = - _lookup)>>( - '_PyGen_Finalize'); - late final __PyGen_Finalize = - __PyGen_FinalizePtr.asFunction)>(); + late final ffi.Pointer> _PyExc_BaseException = + _lookup>('PyExc_BaseException'); - late final ffi.Pointer _PyCoro_Type = - _lookup('PyCoro_Type'); + ffi.Pointer get PyExc_BaseException => _PyExc_BaseException.value; - PyTypeObject get PyCoro_Type => _PyCoro_Type.ref; + set PyExc_BaseException(ffi.Pointer value) => + _PyExc_BaseException.value = value; - late final ffi.Pointer __PyCoroWrapper_Type = - _lookup('_PyCoroWrapper_Type'); - - PyTypeObject get _PyCoroWrapper_Type => __PyCoroWrapper_Type.ref; + late final ffi.Pointer> _PyExc_Exception = + _lookup>('PyExc_Exception'); - ffi.Pointer _PyCoro_GetAwaitableIter( - ffi.Pointer o, - ) { - return __PyCoro_GetAwaitableIter( - o, - ); - } + ffi.Pointer get PyExc_Exception => _PyExc_Exception.value; - late final __PyCoro_GetAwaitableIterPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_PyCoro_GetAwaitableIter'); - late final __PyCoro_GetAwaitableIter = __PyCoro_GetAwaitableIterPtr - .asFunction Function(ffi.Pointer)>(); + set PyExc_Exception(ffi.Pointer value) => + _PyExc_Exception.value = value; - ffi.Pointer PyCoro_New( - ffi.Pointer arg0, - ffi.Pointer name, - ffi.Pointer qualname, - ) { - return _PyCoro_New( - arg0, - name, - qualname, - ); - } + late final ffi.Pointer> _PyExc_BaseExceptionGroup = + _lookup>('PyExc_BaseExceptionGroup'); - late final _PyCoro_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>('PyCoro_New'); - late final _PyCoro_New = _PyCoro_NewPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_BaseExceptionGroup => + _PyExc_BaseExceptionGroup.value; - late final ffi.Pointer _PyAsyncGen_Type = - _lookup('PyAsyncGen_Type'); + set PyExc_BaseExceptionGroup(ffi.Pointer value) => + _PyExc_BaseExceptionGroup.value = value; - PyTypeObject get PyAsyncGen_Type => _PyAsyncGen_Type.ref; + late final ffi.Pointer> _PyExc_StopAsyncIteration = + _lookup>('PyExc_StopAsyncIteration'); - late final ffi.Pointer __PyAsyncGenASend_Type = - _lookup('_PyAsyncGenASend_Type'); + ffi.Pointer get PyExc_StopAsyncIteration => + _PyExc_StopAsyncIteration.value; - PyTypeObject get _PyAsyncGenASend_Type => __PyAsyncGenASend_Type.ref; + set PyExc_StopAsyncIteration(ffi.Pointer value) => + _PyExc_StopAsyncIteration.value = value; - late final ffi.Pointer __PyAsyncGenWrappedValue_Type = - _lookup('_PyAsyncGenWrappedValue_Type'); + late final ffi.Pointer> _PyExc_StopIteration = + _lookup>('PyExc_StopIteration'); - PyTypeObject get _PyAsyncGenWrappedValue_Type => - __PyAsyncGenWrappedValue_Type.ref; + ffi.Pointer get PyExc_StopIteration => _PyExc_StopIteration.value; - late final ffi.Pointer __PyAsyncGenAThrow_Type = - _lookup('_PyAsyncGenAThrow_Type'); + set PyExc_StopIteration(ffi.Pointer value) => + _PyExc_StopIteration.value = value; - PyTypeObject get _PyAsyncGenAThrow_Type => __PyAsyncGenAThrow_Type.ref; + late final ffi.Pointer> _PyExc_GeneratorExit = + _lookup>('PyExc_GeneratorExit'); - ffi.Pointer PyAsyncGen_New( - ffi.Pointer arg0, - ffi.Pointer name, - ffi.Pointer qualname, - ) { - return _PyAsyncGen_New( - arg0, - name, - qualname, - ); - } + ffi.Pointer get PyExc_GeneratorExit => _PyExc_GeneratorExit.value; - late final _PyAsyncGen_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>('PyAsyncGen_New'); - late final _PyAsyncGen_New = _PyAsyncGen_NewPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + set PyExc_GeneratorExit(ffi.Pointer value) => + _PyExc_GeneratorExit.value = value; - ffi.Pointer _PyAsyncGenValueWrapperNew( - ffi.Pointer arg0, - ) { - return __PyAsyncGenValueWrapperNew( - arg0, - ); - } + late final ffi.Pointer> _PyExc_ArithmeticError = + _lookup>('PyExc_ArithmeticError'); - late final __PyAsyncGenValueWrapperNewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_PyAsyncGenValueWrapperNew'); - late final __PyAsyncGenValueWrapperNew = __PyAsyncGenValueWrapperNewPtr - .asFunction Function(ffi.Pointer)>(); + ffi.Pointer get PyExc_ArithmeticError => + _PyExc_ArithmeticError.value; - late final ffi.Pointer _PyClassMethodDescr_Type = - _lookup('PyClassMethodDescr_Type'); + set PyExc_ArithmeticError(ffi.Pointer value) => + _PyExc_ArithmeticError.value = value; - PyTypeObject get PyClassMethodDescr_Type => _PyClassMethodDescr_Type.ref; + late final ffi.Pointer> _PyExc_LookupError = + _lookup>('PyExc_LookupError'); - late final ffi.Pointer _PyGetSetDescr_Type = - _lookup('PyGetSetDescr_Type'); + ffi.Pointer get PyExc_LookupError => _PyExc_LookupError.value; - PyTypeObject get PyGetSetDescr_Type => _PyGetSetDescr_Type.ref; + set PyExc_LookupError(ffi.Pointer value) => + _PyExc_LookupError.value = value; - late final ffi.Pointer _PyMemberDescr_Type = - _lookup('PyMemberDescr_Type'); + late final ffi.Pointer> _PyExc_AssertionError = + _lookup>('PyExc_AssertionError'); - PyTypeObject get PyMemberDescr_Type => _PyMemberDescr_Type.ref; + ffi.Pointer get PyExc_AssertionError => _PyExc_AssertionError.value; - late final ffi.Pointer _PyMethodDescr_Type = - _lookup('PyMethodDescr_Type'); + set PyExc_AssertionError(ffi.Pointer value) => + _PyExc_AssertionError.value = value; - PyTypeObject get PyMethodDescr_Type => _PyMethodDescr_Type.ref; + late final ffi.Pointer> _PyExc_AttributeError = + _lookup>('PyExc_AttributeError'); - late final ffi.Pointer _PyWrapperDescr_Type = - _lookup('PyWrapperDescr_Type'); + ffi.Pointer get PyExc_AttributeError => _PyExc_AttributeError.value; - PyTypeObject get PyWrapperDescr_Type => _PyWrapperDescr_Type.ref; + set PyExc_AttributeError(ffi.Pointer value) => + _PyExc_AttributeError.value = value; - late final ffi.Pointer _PyDictProxy_Type = - _lookup('PyDictProxy_Type'); + late final ffi.Pointer> _PyExc_BufferError = + _lookup>('PyExc_BufferError'); - PyTypeObject get PyDictProxy_Type => _PyDictProxy_Type.ref; + ffi.Pointer get PyExc_BufferError => _PyExc_BufferError.value; - late final ffi.Pointer __PyMethodWrapper_Type = - _lookup('_PyMethodWrapper_Type'); + set PyExc_BufferError(ffi.Pointer value) => + _PyExc_BufferError.value = value; - PyTypeObject get _PyMethodWrapper_Type => __PyMethodWrapper_Type.ref; + late final ffi.Pointer> _PyExc_EOFError = + _lookup>('PyExc_EOFError'); - ffi.Pointer PyDescr_NewMethod( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyDescr_NewMethod( - arg0, - arg1, - ); - } + ffi.Pointer get PyExc_EOFError => _PyExc_EOFError.value; - late final _PyDescr_NewMethodPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyDescr_NewMethod'); - late final _PyDescr_NewMethod = _PyDescr_NewMethodPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + set PyExc_EOFError(ffi.Pointer value) => + _PyExc_EOFError.value = value; - ffi.Pointer PyDescr_NewClassMethod( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyDescr_NewClassMethod( - arg0, - arg1, - ); - } + late final ffi.Pointer> _PyExc_FloatingPointError = + _lookup>('PyExc_FloatingPointError'); - late final _PyDescr_NewClassMethodPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyDescr_NewClassMethod'); - late final _PyDescr_NewClassMethod = _PyDescr_NewClassMethodPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_FloatingPointError => + _PyExc_FloatingPointError.value; - ffi.Pointer PyDescr_NewMember( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyDescr_NewMember( - arg0, - arg1, - ); - } + set PyExc_FloatingPointError(ffi.Pointer value) => + _PyExc_FloatingPointError.value = value; - late final _PyDescr_NewMemberPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyDescr_NewMember'); - late final _PyDescr_NewMember = _PyDescr_NewMemberPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_OSError = + _lookup>('PyExc_OSError'); - ffi.Pointer PyDescr_NewGetSet( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyDescr_NewGetSet( - arg0, - arg1, - ); - } + ffi.Pointer get PyExc_OSError => _PyExc_OSError.value; - late final _PyDescr_NewGetSetPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyDescr_NewGetSet'); - late final _PyDescr_NewGetSet = _PyDescr_NewGetSetPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + set PyExc_OSError(ffi.Pointer value) => + _PyExc_OSError.value = value; - ffi.Pointer PyDescr_NewWrapper( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ) { - return _PyDescr_NewWrapper( - arg0, - arg1, - arg2, - ); - } + late final ffi.Pointer> _PyExc_ImportError = + _lookup>('PyExc_ImportError'); - late final _PyDescr_NewWrapperPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyDescr_NewWrapper'); - late final _PyDescr_NewWrapper = _PyDescr_NewWrapperPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_ImportError => _PyExc_ImportError.value; - int PyDescr_IsData( - ffi.Pointer arg0, - ) { - return _PyDescr_IsData( - arg0, - ); - } + set PyExc_ImportError(ffi.Pointer value) => + _PyExc_ImportError.value = value; - late final _PyDescr_IsDataPtr = - _lookup)>>( - 'PyDescr_IsData'); - late final _PyDescr_IsData = - _PyDescr_IsDataPtr.asFunction)>(); + late final ffi.Pointer> _PyExc_ModuleNotFoundError = + _lookup>('PyExc_ModuleNotFoundError'); - ffi.Pointer PyDictProxy_New( - ffi.Pointer arg0, - ) { - return _PyDictProxy_New( - arg0, - ); - } - - late final _PyDictProxy_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyDictProxy_New'); - late final _PyDictProxy_New = _PyDictProxy_NewPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); - - ffi.Pointer PyWrapper_New( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyWrapper_New( - arg0, - arg1, - ); - } - - late final _PyWrapper_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('PyWrapper_New'); - late final _PyWrapper_New = _PyWrapper_NewPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); - - late final ffi.Pointer _PyProperty_Type = - _lookup('PyProperty_Type'); - - PyTypeObject get PyProperty_Type => _PyProperty_Type.ref; - - ffi.Pointer Py_GenericAlias( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _Py_GenericAlias( - arg0, - arg1, - ); - } - - late final _Py_GenericAliasPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('Py_GenericAlias'); - late final _Py_GenericAlias = _Py_GenericAliasPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); - - late final ffi.Pointer _Py_GenericAliasType = - _lookup('Py_GenericAliasType'); - - PyTypeObject get Py_GenericAliasType => _Py_GenericAliasType.ref; - - ffi.Pointer _PyWarnings_Init() { - return __PyWarnings_Init(); - } - - late final __PyWarnings_InitPtr = - _lookup Function()>>( - '_PyWarnings_Init'); - late final __PyWarnings_Init = - __PyWarnings_InitPtr.asFunction Function()>(); - - int PyErr_WarnEx( - ffi.Pointer category, - ffi.Pointer message, - int stack_level, - ) { - return _PyErr_WarnEx( - category, - message, - stack_level, - ); - } - - late final _PyErr_WarnExPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - Py_ssize_t)>>('PyErr_WarnEx'); - late final _PyErr_WarnEx = _PyErr_WarnExPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); - - int PyErr_WarnFormat( - ffi.Pointer category, - int stack_level, - ffi.Pointer format, - ) { - return _PyErr_WarnFormat( - category, - stack_level, - format, - ); - } - - late final _PyErr_WarnFormatPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PyErr_WarnFormat'); - late final _PyErr_WarnFormat = _PyErr_WarnFormatPtr.asFunction< - int Function(ffi.Pointer, int, ffi.Pointer)>(); - - int PyErr_ResourceWarning( - ffi.Pointer source, - int stack_level, - ffi.Pointer format, - ) { - return _PyErr_ResourceWarning( - source, - stack_level, - format, - ); - } - - late final _PyErr_ResourceWarningPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PyErr_ResourceWarning'); - late final _PyErr_ResourceWarning = _PyErr_ResourceWarningPtr.asFunction< - int Function(ffi.Pointer, int, ffi.Pointer)>(); - - int PyErr_WarnExplicitObject( - ffi.Pointer category, - ffi.Pointer message, - ffi.Pointer filename, - int lineno, - ffi.Pointer module, - ffi.Pointer registry, - ) { - return _PyErr_WarnExplicitObject( - category, - message, - filename, - lineno, - module, - registry, - ); - } - - late final _PyErr_WarnExplicitObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer)>>('PyErr_WarnExplicitObject'); - late final _PyErr_WarnExplicitObject = - _PyErr_WarnExplicitObjectPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - int, - ffi.Pointer, - ffi.Pointer)>(); - - int PyErr_WarnExplicit( - ffi.Pointer category, - ffi.Pointer message, - ffi.Pointer filename, - int lineno, - ffi.Pointer module, - ffi.Pointer registry, - ) { - return _PyErr_WarnExplicit( - category, - message, - filename, - lineno, - module, - registry, - ); - } - - late final _PyErr_WarnExplicitPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer)>>('PyErr_WarnExplicit'); - late final _PyErr_WarnExplicit = _PyErr_WarnExplicitPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - int, - ffi.Pointer, - ffi.Pointer)>(); - - int PyErr_WarnExplicitFormat( - ffi.Pointer category, - ffi.Pointer filename, - int lineno, - ffi.Pointer module, - ffi.Pointer registry, - ffi.Pointer format, - ) { - return _PyErr_WarnExplicitFormat( - category, - filename, - lineno, - module, - registry, - format, - ); - } - - late final _PyErr_WarnExplicitFormatPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyErr_WarnExplicitFormat'); - late final _PyErr_WarnExplicitFormat = - _PyErr_WarnExplicitFormatPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer, - int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); - - void _PyErr_WarnUnawaitedCoroutine( - ffi.Pointer coro, - ) { - return __PyErr_WarnUnawaitedCoroutine( - coro, - ); - } - - late final __PyErr_WarnUnawaitedCoroutinePtr = - _lookup)>>( - '_PyErr_WarnUnawaitedCoroutine'); - late final __PyErr_WarnUnawaitedCoroutine = __PyErr_WarnUnawaitedCoroutinePtr - .asFunction)>(); - - late final ffi.Pointer __PyWeakref_RefType = - _lookup('_PyWeakref_RefType'); - - PyTypeObject get _PyWeakref_RefType => __PyWeakref_RefType.ref; - - late final ffi.Pointer __PyWeakref_ProxyType = - _lookup('_PyWeakref_ProxyType'); - - PyTypeObject get _PyWeakref_ProxyType => __PyWeakref_ProxyType.ref; - - late final ffi.Pointer __PyWeakref_CallableProxyType = - _lookup('_PyWeakref_CallableProxyType'); - - PyTypeObject get _PyWeakref_CallableProxyType => - __PyWeakref_CallableProxyType.ref; - - ffi.Pointer PyWeakref_NewRef( - ffi.Pointer ob, - ffi.Pointer callback, - ) { - return _PyWeakref_NewRef( - ob, - callback, - ); - } - - late final _PyWeakref_NewRefPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyWeakref_NewRef'); - late final _PyWeakref_NewRef = _PyWeakref_NewRefPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); - - ffi.Pointer PyWeakref_NewProxy( - ffi.Pointer ob, - ffi.Pointer callback, - ) { - return _PyWeakref_NewProxy( - ob, - callback, - ); - } - - late final _PyWeakref_NewProxyPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyWeakref_NewProxy'); - late final _PyWeakref_NewProxy = _PyWeakref_NewProxyPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); - - ffi.Pointer PyWeakref_GetObject( - ffi.Pointer ref, - ) { - return _PyWeakref_GetObject( - ref, - ); - } - - late final _PyWeakref_GetObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyWeakref_GetObject'); - late final _PyWeakref_GetObject = _PyWeakref_GetObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); - - int _PyWeakref_GetWeakrefCount( - ffi.Pointer head, - ) { - return __PyWeakref_GetWeakrefCount( - head, - ); - } - - late final __PyWeakref_GetWeakrefCountPtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function( - ffi.Pointer)>>('_PyWeakref_GetWeakrefCount'); - late final __PyWeakref_GetWeakrefCount = __PyWeakref_GetWeakrefCountPtr - .asFunction)>(); - - void _PyWeakref_ClearRef( - ffi.Pointer self, - ) { - return __PyWeakref_ClearRef( - self, - ); - } - - late final __PyWeakref_ClearRefPtr = _lookup< - ffi.NativeFunction)>>( - '_PyWeakref_ClearRef'); - late final __PyWeakref_ClearRef = __PyWeakref_ClearRefPtr - .asFunction)>(); - - late final ffi.Pointer> _PyStructSequence_UnnamedField = - _lookup>('PyStructSequence_UnnamedField'); - - ffi.Pointer get PyStructSequence_UnnamedField => - _PyStructSequence_UnnamedField.value; - - set PyStructSequence_UnnamedField(ffi.Pointer value) => - _PyStructSequence_UnnamedField.value = value; - - void PyStructSequence_InitType( - ffi.Pointer type, - ffi.Pointer desc, - ) { - return _PyStructSequence_InitType( - type, - desc, - ); - } - - late final _PyStructSequence_InitTypePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>( - 'PyStructSequence_InitType'); - late final _PyStructSequence_InitType = - _PyStructSequence_InitTypePtr.asFunction< - void Function( - ffi.Pointer, ffi.Pointer)>(); - - int PyStructSequence_InitType2( - ffi.Pointer type, - ffi.Pointer desc, - ) { - return _PyStructSequence_InitType2( - type, - desc, - ); - } - - late final _PyStructSequence_InitType2Ptr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>( - 'PyStructSequence_InitType2'); - late final _PyStructSequence_InitType2 = - _PyStructSequence_InitType2Ptr.asFunction< - int Function( - ffi.Pointer, ffi.Pointer)>(); - - ffi.Pointer PyStructSequence_NewType( - ffi.Pointer desc, - ) { - return _PyStructSequence_NewType( - desc, - ); - } - - late final _PyStructSequence_NewTypePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyStructSequence_NewType'); - late final _PyStructSequence_NewType = - _PyStructSequence_NewTypePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer)>(); - - ffi.Pointer PyStructSequence_New( - ffi.Pointer type, - ) { - return _PyStructSequence_New( - type, - ); - } - - late final _PyStructSequence_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyStructSequence_New'); - late final _PyStructSequence_New = _PyStructSequence_NewPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); - - void PyStructSequence_SetItem( - ffi.Pointer arg0, - int arg1, - ffi.Pointer arg2, - ) { - return _PyStructSequence_SetItem( - arg0, - arg1, - arg2, - ); - } - - late final _PyStructSequence_SetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer)>>('PyStructSequence_SetItem'); - late final _PyStructSequence_SetItem = - _PyStructSequence_SetItemPtr.asFunction< - void Function(ffi.Pointer, int, ffi.Pointer)>(); - - ffi.Pointer PyStructSequence_GetItem( - ffi.Pointer arg0, - int arg1, - ) { - return _PyStructSequence_GetItem( - arg0, - arg1, - ); - } - - late final _PyStructSequence_GetItemPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, Py_ssize_t)>>('PyStructSequence_GetItem'); - late final _PyStructSequence_GetItem = _PyStructSequence_GetItemPtr - .asFunction Function(ffi.Pointer, int)>(); - - late final ffi.Pointer __PyNamespace_Type = - _lookup('_PyNamespace_Type'); - - PyTypeObject get _PyNamespace_Type => __PyNamespace_Type.ref; - - ffi.Pointer _PyNamespace_New( - ffi.Pointer kwds, - ) { - return __PyNamespace_New( - kwds, - ); - } - - late final __PyNamespace_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_PyNamespace_New'); - late final __PyNamespace_New = __PyNamespace_NewPtr - .asFunction Function(ffi.Pointer)>(); - - late final ffi.Pointer _PyPickleBuffer_Type = - _lookup('PyPickleBuffer_Type'); - - PyTypeObject get PyPickleBuffer_Type => _PyPickleBuffer_Type.ref; - - ffi.Pointer PyPickleBuffer_FromObject( - ffi.Pointer arg0, - ) { - return _PyPickleBuffer_FromObject( - arg0, - ); - } - - late final _PyPickleBuffer_FromObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyPickleBuffer_FromObject'); - late final _PyPickleBuffer_FromObject = _PyPickleBuffer_FromObjectPtr - .asFunction Function(ffi.Pointer)>(); - - ffi.Pointer PyPickleBuffer_GetBuffer( - ffi.Pointer arg0, - ) { - return _PyPickleBuffer_GetBuffer( - arg0, - ); - } - - late final _PyPickleBuffer_GetBufferPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyPickleBuffer_GetBuffer'); - late final _PyPickleBuffer_GetBuffer = _PyPickleBuffer_GetBufferPtr - .asFunction Function(ffi.Pointer)>(); - - int PyPickleBuffer_Release( - ffi.Pointer arg0, - ) { - return _PyPickleBuffer_Release( - arg0, - ); - } - - late final _PyPickleBuffer_ReleasePtr = - _lookup)>>( - 'PyPickleBuffer_Release'); - late final _PyPickleBuffer_Release = _PyPickleBuffer_ReleasePtr.asFunction< - int Function(ffi.Pointer)>(); - - ffi.Pointer _PyLong_FromTime_t( - int sec, - ) { - return __PyLong_FromTime_t( - sec, - ); - } - - late final __PyLong_FromTime_tPtr = - _lookup Function(time_t)>>( - '_PyLong_FromTime_t'); - late final __PyLong_FromTime_t = - __PyLong_FromTime_tPtr.asFunction Function(int)>(); - - int _PyLong_AsTime_t( - ffi.Pointer obj, - ) { - return __PyLong_AsTime_t( - obj, - ); - } - - late final __PyLong_AsTime_tPtr = - _lookup)>>( - '_PyLong_AsTime_t'); - late final __PyLong_AsTime_t = - __PyLong_AsTime_tPtr.asFunction)>(); - - int _PyTime_ObjectToTime_t( - ffi.Pointer obj, - ffi.Pointer sec, - int arg2, - ) { - return __PyTime_ObjectToTime_t( - obj, - sec, - arg2, - ); - } - - late final __PyTime_ObjectToTime_tPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Int32)>>('_PyTime_ObjectToTime_t'); - late final __PyTime_ObjectToTime_t = __PyTime_ObjectToTime_tPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); - - int _PyTime_ObjectToTimeval( - ffi.Pointer obj, - ffi.Pointer sec, - ffi.Pointer usec, - int arg3, - ) { - return __PyTime_ObjectToTimeval( - obj, - sec, - usec, - arg3, - ); - } - - late final __PyTime_ObjectToTimevalPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, ffi.Int32)>>('_PyTime_ObjectToTimeval'); - late final __PyTime_ObjectToTimeval = __PyTime_ObjectToTimevalPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, int)>(); - - int _PyTime_ObjectToTimespec( - ffi.Pointer obj, - ffi.Pointer sec, - ffi.Pointer nsec, - int arg3, - ) { - return __PyTime_ObjectToTimespec( - obj, - sec, - nsec, - arg3, - ); - } - - late final __PyTime_ObjectToTimespecPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, ffi.Int32)>>('_PyTime_ObjectToTimespec'); - late final __PyTime_ObjectToTimespec = - __PyTime_ObjectToTimespecPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, int)>(); - - int _PyTime_FromSeconds( - int seconds, - ) { - return __PyTime_FromSeconds( - seconds, - ); - } - - late final __PyTime_FromSecondsPtr = - _lookup>( - '_PyTime_FromSeconds'); - late final __PyTime_FromSeconds = - __PyTime_FromSecondsPtr.asFunction(); - - int _PyTime_FromNanoseconds( - int ns, - ) { - return __PyTime_FromNanoseconds( - ns, - ); - } - - late final __PyTime_FromNanosecondsPtr = - _lookup>( - '_PyTime_FromNanoseconds'); - late final __PyTime_FromNanoseconds = - __PyTime_FromNanosecondsPtr.asFunction(); - - int _PyTime_FromNanosecondsObject( - ffi.Pointer<_PyTime_t> t, - ffi.Pointer obj, - ) { - return __PyTime_FromNanosecondsObject( - t, - obj, - ); - } - - late final __PyTime_FromNanosecondsObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_PyTime_t>, - ffi.Pointer)>>('_PyTime_FromNanosecondsObject'); - late final __PyTime_FromNanosecondsObject = - __PyTime_FromNanosecondsObjectPtr.asFunction< - int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer)>(); - - int _PyTime_FromSecondsObject( - ffi.Pointer<_PyTime_t> t, - ffi.Pointer obj, - int round, - ) { - return __PyTime_FromSecondsObject( - t, - obj, - round, - ); - } - - late final __PyTime_FromSecondsObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, - ffi.Int32)>>('_PyTime_FromSecondsObject'); - late final __PyTime_FromSecondsObject = - __PyTime_FromSecondsObjectPtr.asFunction< - int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, int)>(); - - int _PyTime_FromMillisecondsObject( - ffi.Pointer<_PyTime_t> t, - ffi.Pointer obj, - int round, - ) { - return __PyTime_FromMillisecondsObject( - t, - obj, - round, - ); - } - - late final __PyTime_FromMillisecondsObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, - ffi.Int32)>>('_PyTime_FromMillisecondsObject'); - late final __PyTime_FromMillisecondsObject = - __PyTime_FromMillisecondsObjectPtr.asFunction< - int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer, int)>(); - - double _PyTime_AsSecondsDouble( - int t, - ) { - return __PyTime_AsSecondsDouble( - t, - ); - } - - late final __PyTime_AsSecondsDoublePtr = - _lookup>( - '_PyTime_AsSecondsDouble'); - late final __PyTime_AsSecondsDouble = - __PyTime_AsSecondsDoublePtr.asFunction(); - - int _PyTime_AsMilliseconds( - int t, - int round, - ) { - return __PyTime_AsMilliseconds( - t, - round, - ); - } - - late final __PyTime_AsMillisecondsPtr = - _lookup>( - '_PyTime_AsMilliseconds'); - late final __PyTime_AsMilliseconds = - __PyTime_AsMillisecondsPtr.asFunction(); - - int _PyTime_AsMicroseconds( - int t, - int round, - ) { - return __PyTime_AsMicroseconds( - t, - round, - ); - } - - late final __PyTime_AsMicrosecondsPtr = - _lookup>( - '_PyTime_AsMicroseconds'); - late final __PyTime_AsMicroseconds = - __PyTime_AsMicrosecondsPtr.asFunction(); - - ffi.Pointer _PyTime_AsNanosecondsObject( - int t, - ) { - return __PyTime_AsNanosecondsObject( - t, - ); - } - - late final __PyTime_AsNanosecondsObjectPtr = - _lookup Function(_PyTime_t)>>( - '_PyTime_AsNanosecondsObject'); - late final __PyTime_AsNanosecondsObject = __PyTime_AsNanosecondsObjectPtr - .asFunction Function(int)>(); - - int _PyTime_FromTimeval( - ffi.Pointer<_PyTime_t> tp, - ffi.Pointer tv, - ) { - return __PyTime_FromTimeval( - tp, - tv, - ); - } - - late final __PyTime_FromTimevalPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_PyTime_t>, - ffi.Pointer)>>('_PyTime_FromTimeval'); - late final __PyTime_FromTimeval = __PyTime_FromTimevalPtr - .asFunction, ffi.Pointer)>(); - - int _PyTime_AsTimeval( - int t, - ffi.Pointer tv, - int round, - ) { - return __PyTime_AsTimeval( - t, - tv, - round, - ); - } - - late final __PyTime_AsTimevalPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(_PyTime_t, ffi.Pointer, - ffi.Int32)>>('_PyTime_AsTimeval'); - late final __PyTime_AsTimeval = __PyTime_AsTimevalPtr - .asFunction, int)>(); - - int _PyTime_AsTimeval_noraise( - int t, - ffi.Pointer tv, - int round, - ) { - return __PyTime_AsTimeval_noraise( - t, - tv, - round, - ); - } - - late final __PyTime_AsTimeval_noraisePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(_PyTime_t, ffi.Pointer, - ffi.Int32)>>('_PyTime_AsTimeval_noraise'); - late final __PyTime_AsTimeval_noraise = __PyTime_AsTimeval_noraisePtr - .asFunction, int)>(); - - int _PyTime_AsTimevalTime_t( - int t, - ffi.Pointer secs, - ffi.Pointer us, - int round, - ) { - return __PyTime_AsTimevalTime_t( - t, - secs, - us, - round, - ); - } + ffi.Pointer get PyExc_ModuleNotFoundError => + _PyExc_ModuleNotFoundError.value; - late final __PyTime_AsTimevalTime_tPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(_PyTime_t, ffi.Pointer, ffi.Pointer, - ffi.Int32)>>('_PyTime_AsTimevalTime_t'); - late final __PyTime_AsTimevalTime_t = __PyTime_AsTimevalTime_tPtr.asFunction< - int Function(int, ffi.Pointer, ffi.Pointer, int)>(); + set PyExc_ModuleNotFoundError(ffi.Pointer value) => + _PyExc_ModuleNotFoundError.value = value; - int _PyTime_FromTimespec( - ffi.Pointer<_PyTime_t> tp, - ffi.Pointer ts, - ) { - return __PyTime_FromTimespec( - tp, - ts, - ); - } + late final ffi.Pointer> _PyExc_IndexError = + _lookup>('PyExc_IndexError'); - late final __PyTime_FromTimespecPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_PyTime_t>, - ffi.Pointer)>>('_PyTime_FromTimespec'); - late final __PyTime_FromTimespec = __PyTime_FromTimespecPtr.asFunction< - int Function(ffi.Pointer<_PyTime_t>, ffi.Pointer)>(); + ffi.Pointer get PyExc_IndexError => _PyExc_IndexError.value; - int _PyTime_AsTimespec( - int t, - ffi.Pointer ts, - ) { - return __PyTime_AsTimespec( - t, - ts, - ); - } + set PyExc_IndexError(ffi.Pointer value) => + _PyExc_IndexError.value = value; - late final __PyTime_AsTimespecPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - _PyTime_t, ffi.Pointer)>>('_PyTime_AsTimespec'); - late final __PyTime_AsTimespec = __PyTime_AsTimespecPtr - .asFunction)>(); + late final ffi.Pointer> _PyExc_KeyError = + _lookup>('PyExc_KeyError'); - int _PyTime_MulDiv( - int ticks, - int mul, - int div, - ) { - return __PyTime_MulDiv( - ticks, - mul, - div, - ); - } + ffi.Pointer get PyExc_KeyError => _PyExc_KeyError.value; - late final __PyTime_MulDivPtr = _lookup< - ffi.NativeFunction< - _PyTime_t Function( - _PyTime_t, _PyTime_t, _PyTime_t)>>('_PyTime_MulDiv'); - late final __PyTime_MulDiv = - __PyTime_MulDivPtr.asFunction(); + set PyExc_KeyError(ffi.Pointer value) => + _PyExc_KeyError.value = value; - int _PyTime_GetSystemClock() { - return __PyTime_GetSystemClock(); - } + late final ffi.Pointer> _PyExc_KeyboardInterrupt = + _lookup>('PyExc_KeyboardInterrupt'); - late final __PyTime_GetSystemClockPtr = - _lookup>( - '_PyTime_GetSystemClock'); - late final __PyTime_GetSystemClock = - __PyTime_GetSystemClockPtr.asFunction(); + ffi.Pointer get PyExc_KeyboardInterrupt => + _PyExc_KeyboardInterrupt.value; - int _PyTime_GetSystemClockWithInfo( - ffi.Pointer<_PyTime_t> t, - ffi.Pointer<_Py_clock_info_t> info, - ) { - return __PyTime_GetSystemClockWithInfo( - t, - info, - ); - } + set PyExc_KeyboardInterrupt(ffi.Pointer value) => + _PyExc_KeyboardInterrupt.value = value; - late final __PyTime_GetSystemClockWithInfoPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>>( - '_PyTime_GetSystemClockWithInfo'); - late final __PyTime_GetSystemClockWithInfo = - __PyTime_GetSystemClockWithInfoPtr.asFunction< - int Function( - ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>(); + late final ffi.Pointer> _PyExc_MemoryError = + _lookup>('PyExc_MemoryError'); - int _PyTime_GetMonotonicClock() { - return __PyTime_GetMonotonicClock(); - } + ffi.Pointer get PyExc_MemoryError => _PyExc_MemoryError.value; - late final __PyTime_GetMonotonicClockPtr = - _lookup>( - '_PyTime_GetMonotonicClock'); - late final __PyTime_GetMonotonicClock = - __PyTime_GetMonotonicClockPtr.asFunction(); + set PyExc_MemoryError(ffi.Pointer value) => + _PyExc_MemoryError.value = value; - int _PyTime_GetMonotonicClockWithInfo( - ffi.Pointer<_PyTime_t> t, - ffi.Pointer<_Py_clock_info_t> info, - ) { - return __PyTime_GetMonotonicClockWithInfo( - t, - info, - ); - } + late final ffi.Pointer> _PyExc_NameError = + _lookup>('PyExc_NameError'); - late final __PyTime_GetMonotonicClockWithInfoPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>>( - '_PyTime_GetMonotonicClockWithInfo'); - late final __PyTime_GetMonotonicClockWithInfo = - __PyTime_GetMonotonicClockWithInfoPtr.asFunction< - int Function( - ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>(); + ffi.Pointer get PyExc_NameError => _PyExc_NameError.value; - int _PyTime_localtime( - int t, - ffi.Pointer tm, - ) { - return __PyTime_localtime( - t, - tm, - ); - } + set PyExc_NameError(ffi.Pointer value) => + _PyExc_NameError.value = value; - late final __PyTime_localtimePtr = - _lookup)>>( - '_PyTime_localtime'); - late final __PyTime_localtime = - __PyTime_localtimePtr.asFunction)>(); + late final ffi.Pointer> _PyExc_OverflowError = + _lookup>('PyExc_OverflowError'); - int _PyTime_gmtime( - int t, - ffi.Pointer tm, - ) { - return __PyTime_gmtime( - t, - tm, - ); - } + ffi.Pointer get PyExc_OverflowError => _PyExc_OverflowError.value; - late final __PyTime_gmtimePtr = - _lookup)>>( - '_PyTime_gmtime'); - late final __PyTime_gmtime = - __PyTime_gmtimePtr.asFunction)>(); + set PyExc_OverflowError(ffi.Pointer value) => + _PyExc_OverflowError.value = value; - int _PyTime_GetPerfCounter() { - return __PyTime_GetPerfCounter(); - } + late final ffi.Pointer> _PyExc_RuntimeError = + _lookup>('PyExc_RuntimeError'); - late final __PyTime_GetPerfCounterPtr = - _lookup>( - '_PyTime_GetPerfCounter'); - late final __PyTime_GetPerfCounter = - __PyTime_GetPerfCounterPtr.asFunction(); + ffi.Pointer get PyExc_RuntimeError => _PyExc_RuntimeError.value; - int _PyTime_GetPerfCounterWithInfo( - ffi.Pointer<_PyTime_t> t, - ffi.Pointer<_Py_clock_info_t> info, - ) { - return __PyTime_GetPerfCounterWithInfo( - t, - info, - ); - } + set PyExc_RuntimeError(ffi.Pointer value) => + _PyExc_RuntimeError.value = value; - late final __PyTime_GetPerfCounterWithInfoPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>>( - '_PyTime_GetPerfCounterWithInfo'); - late final __PyTime_GetPerfCounterWithInfo = - __PyTime_GetPerfCounterWithInfoPtr.asFunction< - int Function( - ffi.Pointer<_PyTime_t>, ffi.Pointer<_Py_clock_info_t>)>(); + late final ffi.Pointer> _PyExc_RecursionError = + _lookup>('PyExc_RecursionError'); - int PyCodec_Register( - ffi.Pointer search_function, - ) { - return _PyCodec_Register( - search_function, - ); - } + ffi.Pointer get PyExc_RecursionError => _PyExc_RecursionError.value; - late final _PyCodec_RegisterPtr = - _lookup)>>( - 'PyCodec_Register'); - late final _PyCodec_Register = - _PyCodec_RegisterPtr.asFunction)>(); + set PyExc_RecursionError(ffi.Pointer value) => + _PyExc_RecursionError.value = value; - int PyCodec_Unregister( - ffi.Pointer search_function, - ) { - return _PyCodec_Unregister( - search_function, - ); - } + late final ffi.Pointer> _PyExc_NotImplementedError = + _lookup>('PyExc_NotImplementedError'); - late final _PyCodec_UnregisterPtr = - _lookup)>>( - 'PyCodec_Unregister'); - late final _PyCodec_Unregister = - _PyCodec_UnregisterPtr.asFunction)>(); + ffi.Pointer get PyExc_NotImplementedError => + _PyExc_NotImplementedError.value; - ffi.Pointer _PyCodec_Lookup( - ffi.Pointer encoding, - ) { - return __PyCodec_Lookup( - encoding, - ); - } + set PyExc_NotImplementedError(ffi.Pointer value) => + _PyExc_NotImplementedError.value = value; - late final __PyCodec_LookupPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_PyCodec_Lookup'); - late final __PyCodec_Lookup = __PyCodec_LookupPtr - .asFunction Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_SyntaxError = + _lookup>('PyExc_SyntaxError'); - int _PyCodec_Forget( - ffi.Pointer encoding, - ) { - return __PyCodec_Forget( - encoding, - ); - } + ffi.Pointer get PyExc_SyntaxError => _PyExc_SyntaxError.value; - late final __PyCodec_ForgetPtr = - _lookup)>>( - '_PyCodec_Forget'); - late final __PyCodec_Forget = - __PyCodec_ForgetPtr.asFunction)>(); + set PyExc_SyntaxError(ffi.Pointer value) => + _PyExc_SyntaxError.value = value; - int PyCodec_KnownEncoding( - ffi.Pointer encoding, - ) { - return _PyCodec_KnownEncoding( - encoding, - ); - } + late final ffi.Pointer> _PyExc_IndentationError = + _lookup>('PyExc_IndentationError'); - late final _PyCodec_KnownEncodingPtr = - _lookup)>>( - 'PyCodec_KnownEncoding'); - late final _PyCodec_KnownEncoding = _PyCodec_KnownEncodingPtr.asFunction< - int Function(ffi.Pointer)>(); + ffi.Pointer get PyExc_IndentationError => + _PyExc_IndentationError.value; - ffi.Pointer PyCodec_Encode( - ffi.Pointer object, - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return _PyCodec_Encode( - object, - encoding, - errors, - ); - } + set PyExc_IndentationError(ffi.Pointer value) => + _PyExc_IndentationError.value = value; - late final _PyCodec_EncodePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>('PyCodec_Encode'); - late final _PyCodec_Encode = _PyCodec_EncodePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_TabError = + _lookup>('PyExc_TabError'); - ffi.Pointer PyCodec_Decode( - ffi.Pointer object, - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return _PyCodec_Decode( - object, - encoding, - errors, - ); - } + ffi.Pointer get PyExc_TabError => _PyExc_TabError.value; - late final _PyCodec_DecodePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>('PyCodec_Decode'); - late final _PyCodec_Decode = _PyCodec_DecodePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + set PyExc_TabError(ffi.Pointer value) => + _PyExc_TabError.value = value; - ffi.Pointer _PyCodec_LookupTextEncoding( - ffi.Pointer encoding, - ffi.Pointer alternate_command, - ) { - return __PyCodec_LookupTextEncoding( - encoding, - alternate_command, - ); - } + late final ffi.Pointer> _PyExc_ReferenceError = + _lookup>('PyExc_ReferenceError'); - late final __PyCodec_LookupTextEncodingPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyCodec_LookupTextEncoding'); - late final __PyCodec_LookupTextEncoding = - __PyCodec_LookupTextEncodingPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_ReferenceError => _PyExc_ReferenceError.value; - ffi.Pointer _PyCodec_EncodeText( - ffi.Pointer object, - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return __PyCodec_EncodeText( - object, - encoding, - errors, - ); - } + set PyExc_ReferenceError(ffi.Pointer value) => + _PyExc_ReferenceError.value = value; - late final __PyCodec_EncodeTextPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyCodec_EncodeText'); - late final __PyCodec_EncodeText = __PyCodec_EncodeTextPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_SystemError = + _lookup>('PyExc_SystemError'); + + ffi.Pointer get PyExc_SystemError => _PyExc_SystemError.value; - ffi.Pointer _PyCodec_DecodeText( - ffi.Pointer object, - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return __PyCodec_DecodeText( - object, - encoding, - errors, - ); - } + set PyExc_SystemError(ffi.Pointer value) => + _PyExc_SystemError.value = value; - late final __PyCodec_DecodeTextPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyCodec_DecodeText'); - late final __PyCodec_DecodeText = __PyCodec_DecodeTextPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_SystemExit = + _lookup>('PyExc_SystemExit'); - ffi.Pointer _PyCodecInfo_GetIncrementalDecoder( - ffi.Pointer codec_info, - ffi.Pointer errors, - ) { - return __PyCodecInfo_GetIncrementalDecoder( - codec_info, - errors, - ); - } + ffi.Pointer get PyExc_SystemExit => _PyExc_SystemExit.value; - late final __PyCodecInfo_GetIncrementalDecoderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyCodecInfo_GetIncrementalDecoder'); - late final __PyCodecInfo_GetIncrementalDecoder = - __PyCodecInfo_GetIncrementalDecoderPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + set PyExc_SystemExit(ffi.Pointer value) => + _PyExc_SystemExit.value = value; - ffi.Pointer _PyCodecInfo_GetIncrementalEncoder( - ffi.Pointer codec_info, - ffi.Pointer errors, - ) { - return __PyCodecInfo_GetIncrementalEncoder( - codec_info, - errors, - ); - } + late final ffi.Pointer> _PyExc_TypeError = + _lookup>('PyExc_TypeError'); - late final __PyCodecInfo_GetIncrementalEncoderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyCodecInfo_GetIncrementalEncoder'); - late final __PyCodecInfo_GetIncrementalEncoder = - __PyCodecInfo_GetIncrementalEncoderPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_TypeError => _PyExc_TypeError.value; - ffi.Pointer PyCodec_Encoder( - ffi.Pointer encoding, - ) { - return _PyCodec_Encoder( - encoding, - ); - } + set PyExc_TypeError(ffi.Pointer value) => + _PyExc_TypeError.value = value; - late final _PyCodec_EncoderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_Encoder'); - late final _PyCodec_Encoder = _PyCodec_EncoderPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_UnboundLocalError = + _lookup>('PyExc_UnboundLocalError'); - ffi.Pointer PyCodec_Decoder( - ffi.Pointer encoding, - ) { - return _PyCodec_Decoder( - encoding, - ); - } + ffi.Pointer get PyExc_UnboundLocalError => + _PyExc_UnboundLocalError.value; - late final _PyCodec_DecoderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_Decoder'); - late final _PyCodec_Decoder = _PyCodec_DecoderPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + set PyExc_UnboundLocalError(ffi.Pointer value) => + _PyExc_UnboundLocalError.value = value; - ffi.Pointer PyCodec_IncrementalEncoder( - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return _PyCodec_IncrementalEncoder( - encoding, - errors, - ); - } + late final ffi.Pointer> _PyExc_UnicodeError = + _lookup>('PyExc_UnicodeError'); - late final _PyCodec_IncrementalEncoderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyCodec_IncrementalEncoder'); - late final _PyCodec_IncrementalEncoder = - _PyCodec_IncrementalEncoderPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_UnicodeError => _PyExc_UnicodeError.value; - ffi.Pointer PyCodec_IncrementalDecoder( - ffi.Pointer encoding, - ffi.Pointer errors, - ) { - return _PyCodec_IncrementalDecoder( - encoding, - errors, - ); - } + set PyExc_UnicodeError(ffi.Pointer value) => + _PyExc_UnicodeError.value = value; - late final _PyCodec_IncrementalDecoderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyCodec_IncrementalDecoder'); - late final _PyCodec_IncrementalDecoder = - _PyCodec_IncrementalDecoderPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_UnicodeEncodeError = + _lookup>('PyExc_UnicodeEncodeError'); - ffi.Pointer PyCodec_StreamReader( - ffi.Pointer encoding, - ffi.Pointer stream, - ffi.Pointer errors, - ) { - return _PyCodec_StreamReader( - encoding, - stream, - errors, - ); - } + ffi.Pointer get PyExc_UnicodeEncodeError => + _PyExc_UnicodeEncodeError.value; - late final _PyCodec_StreamReaderPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyCodec_StreamReader'); - late final _PyCodec_StreamReader = _PyCodec_StreamReaderPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + set PyExc_UnicodeEncodeError(ffi.Pointer value) => + _PyExc_UnicodeEncodeError.value = value; - ffi.Pointer PyCodec_StreamWriter( - ffi.Pointer encoding, - ffi.Pointer stream, - ffi.Pointer errors, - ) { - return _PyCodec_StreamWriter( - encoding, - stream, - errors, - ); - } + late final ffi.Pointer> _PyExc_UnicodeDecodeError = + _lookup>('PyExc_UnicodeDecodeError'); - late final _PyCodec_StreamWriterPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyCodec_StreamWriter'); - late final _PyCodec_StreamWriter = _PyCodec_StreamWriterPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_UnicodeDecodeError => + _PyExc_UnicodeDecodeError.value; - int PyCodec_RegisterError( - ffi.Pointer name, - ffi.Pointer error, - ) { - return _PyCodec_RegisterError( - name, - error, - ); - } + set PyExc_UnicodeDecodeError(ffi.Pointer value) => + _PyExc_UnicodeDecodeError.value = value; - late final _PyCodec_RegisterErrorPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyCodec_RegisterError'); - late final _PyCodec_RegisterError = _PyCodec_RegisterErrorPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_UnicodeTranslateError = + _lookup>('PyExc_UnicodeTranslateError'); - ffi.Pointer PyCodec_LookupError( - ffi.Pointer name, - ) { - return _PyCodec_LookupError( - name, - ); - } + ffi.Pointer get PyExc_UnicodeTranslateError => + _PyExc_UnicodeTranslateError.value; - late final _PyCodec_LookupErrorPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_LookupError'); - late final _PyCodec_LookupError = _PyCodec_LookupErrorPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + set PyExc_UnicodeTranslateError(ffi.Pointer value) => + _PyExc_UnicodeTranslateError.value = value; - ffi.Pointer PyCodec_StrictErrors( - ffi.Pointer exc, - ) { - return _PyCodec_StrictErrors( - exc, - ); - } + late final ffi.Pointer> _PyExc_ValueError = + _lookup>('PyExc_ValueError'); - late final _PyCodec_StrictErrorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_StrictErrors'); - late final _PyCodec_StrictErrors = _PyCodec_StrictErrorsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer get PyExc_ValueError => _PyExc_ValueError.value; - ffi.Pointer PyCodec_IgnoreErrors( - ffi.Pointer exc, - ) { - return _PyCodec_IgnoreErrors( - exc, - ); - } + set PyExc_ValueError(ffi.Pointer value) => + _PyExc_ValueError.value = value; - late final _PyCodec_IgnoreErrorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_IgnoreErrors'); - late final _PyCodec_IgnoreErrors = _PyCodec_IgnoreErrorsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_ZeroDivisionError = + _lookup>('PyExc_ZeroDivisionError'); - ffi.Pointer PyCodec_ReplaceErrors( - ffi.Pointer exc, - ) { - return _PyCodec_ReplaceErrors( - exc, - ); - } + ffi.Pointer get PyExc_ZeroDivisionError => + _PyExc_ZeroDivisionError.value; - late final _PyCodec_ReplaceErrorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_ReplaceErrors'); - late final _PyCodec_ReplaceErrors = _PyCodec_ReplaceErrorsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + set PyExc_ZeroDivisionError(ffi.Pointer value) => + _PyExc_ZeroDivisionError.value = value; - ffi.Pointer PyCodec_XMLCharRefReplaceErrors( - ffi.Pointer exc, - ) { - return _PyCodec_XMLCharRefReplaceErrors( - exc, - ); - } + late final ffi.Pointer> _PyExc_BlockingIOError = + _lookup>('PyExc_BlockingIOError'); - late final _PyCodec_XMLCharRefReplaceErrorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_XMLCharRefReplaceErrors'); - late final _PyCodec_XMLCharRefReplaceErrors = - _PyCodec_XMLCharRefReplaceErrorsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer get PyExc_BlockingIOError => + _PyExc_BlockingIOError.value; - ffi.Pointer PyCodec_BackslashReplaceErrors( - ffi.Pointer exc, - ) { - return _PyCodec_BackslashReplaceErrors( - exc, - ); - } + set PyExc_BlockingIOError(ffi.Pointer value) => + _PyExc_BlockingIOError.value = value; - late final _PyCodec_BackslashReplaceErrorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_BackslashReplaceErrors'); - late final _PyCodec_BackslashReplaceErrors = - _PyCodec_BackslashReplaceErrorsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_BrokenPipeError = + _lookup>('PyExc_BrokenPipeError'); - ffi.Pointer PyCodec_NameReplaceErrors( - ffi.Pointer exc, - ) { - return _PyCodec_NameReplaceErrors( - exc, - ); - } + ffi.Pointer get PyExc_BrokenPipeError => + _PyExc_BrokenPipeError.value; - late final _PyCodec_NameReplaceErrorsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyCodec_NameReplaceErrors'); - late final _PyCodec_NameReplaceErrors = _PyCodec_NameReplaceErrorsPtr - .asFunction Function(ffi.Pointer)>(); + set PyExc_BrokenPipeError(ffi.Pointer value) => + _PyExc_BrokenPipeError.value = value; - late final ffi.Pointer> _Py_hexdigits = - _lookup>('Py_hexdigits'); + late final ffi.Pointer> _PyExc_ChildProcessError = + _lookup>('PyExc_ChildProcessError'); - ffi.Pointer get Py_hexdigits => _Py_hexdigits.value; + ffi.Pointer get PyExc_ChildProcessError => + _PyExc_ChildProcessError.value; - set Py_hexdigits(ffi.Pointer value) => _Py_hexdigits.value = value; + set PyExc_ChildProcessError(ffi.Pointer value) => + _PyExc_ChildProcessError.value = value; - void PyErr_SetNone( - ffi.Pointer arg0, - ) { - return _PyErr_SetNone( - arg0, - ); - } + late final ffi.Pointer> _PyExc_ConnectionError = + _lookup>('PyExc_ConnectionError'); - late final _PyErr_SetNonePtr = - _lookup)>>( - 'PyErr_SetNone'); - late final _PyErr_SetNone = - _PyErr_SetNonePtr.asFunction)>(); + ffi.Pointer get PyExc_ConnectionError => + _PyExc_ConnectionError.value; - void PyErr_SetObject( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyErr_SetObject( - arg0, - arg1, - ); - } + set PyExc_ConnectionError(ffi.Pointer value) => + _PyExc_ConnectionError.value = value; - late final _PyErr_SetObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('PyErr_SetObject'); - late final _PyErr_SetObject = _PyErr_SetObjectPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_ConnectionAbortedError = + _lookup>('PyExc_ConnectionAbortedError'); - void PyErr_SetString( - ffi.Pointer exception, - ffi.Pointer string, - ) { - return _PyErr_SetString( - exception, - string, - ); - } + ffi.Pointer get PyExc_ConnectionAbortedError => + _PyExc_ConnectionAbortedError.value; - late final _PyErr_SetStringPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('PyErr_SetString'); - late final _PyErr_SetString = _PyErr_SetStringPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); + set PyExc_ConnectionAbortedError(ffi.Pointer value) => + _PyExc_ConnectionAbortedError.value = value; - ffi.Pointer PyErr_Occurred() { - return _PyErr_Occurred(); - } + late final ffi.Pointer> _PyExc_ConnectionRefusedError = + _lookup>('PyExc_ConnectionRefusedError'); - late final _PyErr_OccurredPtr = - _lookup Function()>>( - 'PyErr_Occurred'); - late final _PyErr_Occurred = - _PyErr_OccurredPtr.asFunction Function()>(); + ffi.Pointer get PyExc_ConnectionRefusedError => + _PyExc_ConnectionRefusedError.value; - void PyErr_Clear() { - return _PyErr_Clear(); - } + set PyExc_ConnectionRefusedError(ffi.Pointer value) => + _PyExc_ConnectionRefusedError.value = value; - late final _PyErr_ClearPtr = - _lookup>('PyErr_Clear'); - late final _PyErr_Clear = _PyErr_ClearPtr.asFunction(); + late final ffi.Pointer> _PyExc_ConnectionResetError = + _lookup>('PyExc_ConnectionResetError'); - void PyErr_Fetch( - ffi.Pointer> arg0, - ffi.Pointer> arg1, - ffi.Pointer> arg2, - ) { - return _PyErr_Fetch( - arg0, - arg1, - arg2, - ); - } + ffi.Pointer get PyExc_ConnectionResetError => + _PyExc_ConnectionResetError.value; - late final _PyErr_FetchPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>>('PyErr_Fetch'); - late final _PyErr_Fetch = _PyErr_FetchPtr.asFunction< - void Function( - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>(); + set PyExc_ConnectionResetError(ffi.Pointer value) => + _PyExc_ConnectionResetError.value = value; - void PyErr_Restore( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ) { - return _PyErr_Restore( - arg0, - arg1, - arg2, - ); - } + late final ffi.Pointer> _PyExc_FileExistsError = + _lookup>('PyExc_FileExistsError'); - late final _PyErr_RestorePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyErr_Restore'); - late final _PyErr_Restore = _PyErr_RestorePtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + ffi.Pointer get PyExc_FileExistsError => + _PyExc_FileExistsError.value; - void PyErr_GetExcInfo( - ffi.Pointer> arg0, - ffi.Pointer> arg1, - ffi.Pointer> arg2, - ) { - return _PyErr_GetExcInfo1( - arg0, - arg1, - arg2, - ); - } + set PyExc_FileExistsError(ffi.Pointer value) => + _PyExc_FileExistsError.value = value; - late final _PyErr_GetExcInfoPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>>('PyErr_GetExcInfo'); - late final _PyErr_GetExcInfo1 = _PyErr_GetExcInfoPtr.asFunction< - void Function( - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>(); + late final ffi.Pointer> _PyExc_FileNotFoundError = + _lookup>('PyExc_FileNotFoundError'); - void PyErr_SetExcInfo( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ) { - return _PyErr_SetExcInfo( - arg0, - arg1, - arg2, - ); - } + ffi.Pointer get PyExc_FileNotFoundError => + _PyExc_FileNotFoundError.value; - late final _PyErr_SetExcInfoPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyErr_SetExcInfo'); - late final _PyErr_SetExcInfo = _PyErr_SetExcInfoPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + set PyExc_FileNotFoundError(ffi.Pointer value) => + _PyExc_FileNotFoundError.value = value; + + late final ffi.Pointer> _PyExc_InterruptedError = + _lookup>('PyExc_InterruptedError'); - void Py_FatalError( - ffi.Pointer message, - ) { - return _Py_FatalError( - message, - ); - } + ffi.Pointer get PyExc_InterruptedError => + _PyExc_InterruptedError.value; - late final _Py_FatalErrorPtr = - _lookup)>>( - 'Py_FatalError'); - late final _Py_FatalError = - _Py_FatalErrorPtr.asFunction)>(); + set PyExc_InterruptedError(ffi.Pointer value) => + _PyExc_InterruptedError.value = value; - int PyErr_GivenExceptionMatches( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyErr_GivenExceptionMatches( - arg0, - arg1, - ); - } + late final ffi.Pointer> _PyExc_IsADirectoryError = + _lookup>('PyExc_IsADirectoryError'); - late final _PyErr_GivenExceptionMatchesPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyErr_GivenExceptionMatches'); - late final _PyErr_GivenExceptionMatches = _PyErr_GivenExceptionMatchesPtr - .asFunction, ffi.Pointer)>(); + ffi.Pointer get PyExc_IsADirectoryError => + _PyExc_IsADirectoryError.value; - int PyErr_ExceptionMatches( - ffi.Pointer arg0, - ) { - return _PyErr_ExceptionMatches( - arg0, - ); - } + set PyExc_IsADirectoryError(ffi.Pointer value) => + _PyExc_IsADirectoryError.value = value; - late final _PyErr_ExceptionMatchesPtr = - _lookup)>>( - 'PyErr_ExceptionMatches'); - late final _PyErr_ExceptionMatches = _PyErr_ExceptionMatchesPtr.asFunction< - int Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_NotADirectoryError = + _lookup>('PyExc_NotADirectoryError'); - void PyErr_NormalizeException( - ffi.Pointer> arg0, - ffi.Pointer> arg1, - ffi.Pointer> arg2, - ) { - return _PyErr_NormalizeException( - arg0, - arg1, - arg2, - ); - } + ffi.Pointer get PyExc_NotADirectoryError => + _PyExc_NotADirectoryError.value; - late final _PyErr_NormalizeExceptionPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>>('PyErr_NormalizeException'); - late final _PyErr_NormalizeException = - _PyErr_NormalizeExceptionPtr.asFunction< - void Function( - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>(); + set PyExc_NotADirectoryError(ffi.Pointer value) => + _PyExc_NotADirectoryError.value = value; - int PyException_SetTraceback( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyException_SetTraceback( - arg0, - arg1, - ); - } + late final ffi.Pointer> _PyExc_PermissionError = + _lookup>('PyExc_PermissionError'); - late final _PyException_SetTracebackPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyException_SetTraceback'); - late final _PyException_SetTraceback = _PyException_SetTracebackPtr - .asFunction, ffi.Pointer)>(); + ffi.Pointer get PyExc_PermissionError => + _PyExc_PermissionError.value; - ffi.Pointer PyException_GetTraceback( - ffi.Pointer arg0, - ) { - return _PyException_GetTraceback( - arg0, - ); - } + set PyExc_PermissionError(ffi.Pointer value) => + _PyExc_PermissionError.value = value; - late final _PyException_GetTracebackPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyException_GetTraceback'); - late final _PyException_GetTraceback = _PyException_GetTracebackPtr - .asFunction Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_ProcessLookupError = + _lookup>('PyExc_ProcessLookupError'); - ffi.Pointer PyException_GetCause( - ffi.Pointer arg0, - ) { - return _PyException_GetCause( - arg0, - ); - } + ffi.Pointer get PyExc_ProcessLookupError => + _PyExc_ProcessLookupError.value; - late final _PyException_GetCausePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyException_GetCause'); - late final _PyException_GetCause = _PyException_GetCausePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + set PyExc_ProcessLookupError(ffi.Pointer value) => + _PyExc_ProcessLookupError.value = value; - void PyException_SetCause( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyException_SetCause( - arg0, - arg1, - ); - } + late final ffi.Pointer> _PyExc_TimeoutError = + _lookup>('PyExc_TimeoutError'); - late final _PyException_SetCausePtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('PyException_SetCause'); - late final _PyException_SetCause = _PyException_SetCausePtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get PyExc_TimeoutError => _PyExc_TimeoutError.value; - ffi.Pointer PyException_GetContext( - ffi.Pointer arg0, - ) { - return _PyException_GetContext( - arg0, - ); - } + set PyExc_TimeoutError(ffi.Pointer value) => + _PyExc_TimeoutError.value = value; - late final _PyException_GetContextPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyException_GetContext'); - late final _PyException_GetContext = _PyException_GetContextPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final ffi.Pointer> _PyExc_EnvironmentError = + _lookup>('PyExc_EnvironmentError'); - void PyException_SetContext( - ffi.Pointer arg0, - ffi.Pointer arg1, - ) { - return _PyException_SetContext( - arg0, - arg1, - ); - } + ffi.Pointer get PyExc_EnvironmentError => + _PyExc_EnvironmentError.value; - late final _PyException_SetContextPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('PyException_SetContext'); - late final _PyException_SetContext = _PyException_SetContextPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); + set PyExc_EnvironmentError(ffi.Pointer value) => + _PyExc_EnvironmentError.value = value; - ffi.Pointer PyExceptionClass_Name( - ffi.Pointer arg0, - ) { - return _PyExceptionClass_Name( - arg0, - ); - } + late final ffi.Pointer> _PyExc_IOError = + _lookup>('PyExc_IOError'); - late final _PyExceptionClass_NamePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyExceptionClass_Name'); - late final _PyExceptionClass_Name = _PyExceptionClass_NamePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer get PyExc_IOError => _PyExc_IOError.value; - late final ffi.Pointer> _PyExc_BaseException = - _lookup>('PyExc_BaseException'); + set PyExc_IOError(ffi.Pointer value) => + _PyExc_IOError.value = value; - ffi.Pointer get PyExc_BaseException => _PyExc_BaseException.value; + late final ffi.Pointer> _PyExc_Warning = + _lookup>('PyExc_Warning'); - set PyExc_BaseException(ffi.Pointer value) => - _PyExc_BaseException.value = value; + ffi.Pointer get PyExc_Warning => _PyExc_Warning.value; - late final ffi.Pointer> _PyExc_Exception = - _lookup>('PyExc_Exception'); + set PyExc_Warning(ffi.Pointer value) => + _PyExc_Warning.value = value; - ffi.Pointer get PyExc_Exception => _PyExc_Exception.value; + late final ffi.Pointer> _PyExc_UserWarning = + _lookup>('PyExc_UserWarning'); - set PyExc_Exception(ffi.Pointer value) => - _PyExc_Exception.value = value; + ffi.Pointer get PyExc_UserWarning => _PyExc_UserWarning.value; - late final ffi.Pointer> _PyExc_StopAsyncIteration = - _lookup>('PyExc_StopAsyncIteration'); + set PyExc_UserWarning(ffi.Pointer value) => + _PyExc_UserWarning.value = value; - ffi.Pointer get PyExc_StopAsyncIteration => - _PyExc_StopAsyncIteration.value; + late final ffi.Pointer> _PyExc_DeprecationWarning = + _lookup>('PyExc_DeprecationWarning'); - set PyExc_StopAsyncIteration(ffi.Pointer value) => - _PyExc_StopAsyncIteration.value = value; + ffi.Pointer get PyExc_DeprecationWarning => + _PyExc_DeprecationWarning.value; - late final ffi.Pointer> _PyExc_StopIteration = - _lookup>('PyExc_StopIteration'); + set PyExc_DeprecationWarning(ffi.Pointer value) => + _PyExc_DeprecationWarning.value = value; - ffi.Pointer get PyExc_StopIteration => _PyExc_StopIteration.value; + late final ffi.Pointer> + _PyExc_PendingDeprecationWarning = + _lookup>('PyExc_PendingDeprecationWarning'); - set PyExc_StopIteration(ffi.Pointer value) => - _PyExc_StopIteration.value = value; + ffi.Pointer get PyExc_PendingDeprecationWarning => + _PyExc_PendingDeprecationWarning.value; - late final ffi.Pointer> _PyExc_GeneratorExit = - _lookup>('PyExc_GeneratorExit'); + set PyExc_PendingDeprecationWarning(ffi.Pointer value) => + _PyExc_PendingDeprecationWarning.value = value; - ffi.Pointer get PyExc_GeneratorExit => _PyExc_GeneratorExit.value; + late final ffi.Pointer> _PyExc_SyntaxWarning = + _lookup>('PyExc_SyntaxWarning'); - set PyExc_GeneratorExit(ffi.Pointer value) => - _PyExc_GeneratorExit.value = value; + ffi.Pointer get PyExc_SyntaxWarning => _PyExc_SyntaxWarning.value; + + set PyExc_SyntaxWarning(ffi.Pointer value) => + _PyExc_SyntaxWarning.value = value; - late final ffi.Pointer> _PyExc_ArithmeticError = - _lookup>('PyExc_ArithmeticError'); + late final ffi.Pointer> _PyExc_RuntimeWarning = + _lookup>('PyExc_RuntimeWarning'); - ffi.Pointer get PyExc_ArithmeticError => - _PyExc_ArithmeticError.value; + ffi.Pointer get PyExc_RuntimeWarning => _PyExc_RuntimeWarning.value; - set PyExc_ArithmeticError(ffi.Pointer value) => - _PyExc_ArithmeticError.value = value; + set PyExc_RuntimeWarning(ffi.Pointer value) => + _PyExc_RuntimeWarning.value = value; - late final ffi.Pointer> _PyExc_LookupError = - _lookup>('PyExc_LookupError'); + late final ffi.Pointer> _PyExc_FutureWarning = + _lookup>('PyExc_FutureWarning'); - ffi.Pointer get PyExc_LookupError => _PyExc_LookupError.value; + ffi.Pointer get PyExc_FutureWarning => _PyExc_FutureWarning.value; - set PyExc_LookupError(ffi.Pointer value) => - _PyExc_LookupError.value = value; + set PyExc_FutureWarning(ffi.Pointer value) => + _PyExc_FutureWarning.value = value; - late final ffi.Pointer> _PyExc_AssertionError = - _lookup>('PyExc_AssertionError'); + late final ffi.Pointer> _PyExc_ImportWarning = + _lookup>('PyExc_ImportWarning'); - ffi.Pointer get PyExc_AssertionError => _PyExc_AssertionError.value; + ffi.Pointer get PyExc_ImportWarning => _PyExc_ImportWarning.value; - set PyExc_AssertionError(ffi.Pointer value) => - _PyExc_AssertionError.value = value; + set PyExc_ImportWarning(ffi.Pointer value) => + _PyExc_ImportWarning.value = value; - late final ffi.Pointer> _PyExc_AttributeError = - _lookup>('PyExc_AttributeError'); + late final ffi.Pointer> _PyExc_UnicodeWarning = + _lookup>('PyExc_UnicodeWarning'); - ffi.Pointer get PyExc_AttributeError => _PyExc_AttributeError.value; + ffi.Pointer get PyExc_UnicodeWarning => _PyExc_UnicodeWarning.value; - set PyExc_AttributeError(ffi.Pointer value) => - _PyExc_AttributeError.value = value; + set PyExc_UnicodeWarning(ffi.Pointer value) => + _PyExc_UnicodeWarning.value = value; - late final ffi.Pointer> _PyExc_BufferError = - _lookup>('PyExc_BufferError'); + late final ffi.Pointer> _PyExc_BytesWarning = + _lookup>('PyExc_BytesWarning'); - ffi.Pointer get PyExc_BufferError => _PyExc_BufferError.value; + ffi.Pointer get PyExc_BytesWarning => _PyExc_BytesWarning.value; - set PyExc_BufferError(ffi.Pointer value) => - _PyExc_BufferError.value = value; + set PyExc_BytesWarning(ffi.Pointer value) => + _PyExc_BytesWarning.value = value; - late final ffi.Pointer> _PyExc_EOFError = - _lookup>('PyExc_EOFError'); + late final ffi.Pointer> _PyExc_EncodingWarning = + _lookup>('PyExc_EncodingWarning'); - ffi.Pointer get PyExc_EOFError => _PyExc_EOFError.value; + ffi.Pointer get PyExc_EncodingWarning => + _PyExc_EncodingWarning.value; - set PyExc_EOFError(ffi.Pointer value) => - _PyExc_EOFError.value = value; + set PyExc_EncodingWarning(ffi.Pointer value) => + _PyExc_EncodingWarning.value = value; - late final ffi.Pointer> _PyExc_FloatingPointError = - _lookup>('PyExc_FloatingPointError'); + late final ffi.Pointer> _PyExc_ResourceWarning = + _lookup>('PyExc_ResourceWarning'); - ffi.Pointer get PyExc_FloatingPointError => - _PyExc_FloatingPointError.value; + ffi.Pointer get PyExc_ResourceWarning => + _PyExc_ResourceWarning.value; - set PyExc_FloatingPointError(ffi.Pointer value) => - _PyExc_FloatingPointError.value = value; + set PyExc_ResourceWarning(ffi.Pointer value) => + _PyExc_ResourceWarning.value = value; - late final ffi.Pointer> _PyExc_OSError = - _lookup>('PyExc_OSError'); + int PyErr_BadArgument() { + return _PyErr_BadArgument(); + } - ffi.Pointer get PyExc_OSError => _PyExc_OSError.value; + late final _PyErr_BadArgumentPtr = + _lookup>('PyErr_BadArgument'); + late final _PyErr_BadArgument = + _PyErr_BadArgumentPtr.asFunction(); - set PyExc_OSError(ffi.Pointer value) => - _PyExc_OSError.value = value; + ffi.Pointer PyErr_NoMemory() { + return _PyErr_NoMemory(); + } - late final ffi.Pointer> _PyExc_ImportError = - _lookup>('PyExc_ImportError'); + late final _PyErr_NoMemoryPtr = + _lookup Function()>>( + 'PyErr_NoMemory'); + late final _PyErr_NoMemory = + _PyErr_NoMemoryPtr.asFunction Function()>(); - ffi.Pointer get PyExc_ImportError => _PyExc_ImportError.value; + ffi.Pointer PyErr_SetFromErrno( + ffi.Pointer arg0, + ) { + return _PyErr_SetFromErrno( + arg0, + ); + } - set PyExc_ImportError(ffi.Pointer value) => - _PyExc_ImportError.value = value; + late final _PyErr_SetFromErrnoPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyErr_SetFromErrno'); + late final _PyErr_SetFromErrno = _PyErr_SetFromErrnoPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_ModuleNotFoundError = - _lookup>('PyExc_ModuleNotFoundError'); + ffi.Pointer PyErr_SetFromErrnoWithFilenameObject( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyErr_SetFromErrnoWithFilenameObject( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_ModuleNotFoundError => - _PyExc_ModuleNotFoundError.value; + late final _PyErr_SetFromErrnoWithFilenameObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyErr_SetFromErrnoWithFilenameObject'); + late final _PyErr_SetFromErrnoWithFilenameObject = + _PyErr_SetFromErrnoWithFilenameObjectPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - set PyExc_ModuleNotFoundError(ffi.Pointer value) => - _PyExc_ModuleNotFoundError.value = value; + ffi.Pointer PyErr_SetFromErrnoWithFilenameObjects( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ) { + return _PyErr_SetFromErrnoWithFilenameObjects( + arg0, + arg1, + arg2, + ); + } - late final ffi.Pointer> _PyExc_IndexError = - _lookup>('PyExc_IndexError'); + late final _PyErr_SetFromErrnoWithFilenameObjectsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyErr_SetFromErrnoWithFilenameObjects'); + late final _PyErr_SetFromErrnoWithFilenameObjects = + _PyErr_SetFromErrnoWithFilenameObjectsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer get PyExc_IndexError => _PyExc_IndexError.value; + ffi.Pointer PyErr_SetFromErrnoWithFilename( + ffi.Pointer exc, + ffi.Pointer filename, + ) { + return _PyErr_SetFromErrnoWithFilename( + exc, + filename, + ); + } - set PyExc_IndexError(ffi.Pointer value) => - _PyExc_IndexError.value = value; + late final _PyErr_SetFromErrnoWithFilenamePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyErr_SetFromErrnoWithFilename'); + late final _PyErr_SetFromErrnoWithFilename = + _PyErr_SetFromErrnoWithFilenamePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_KeyError = - _lookup>('PyExc_KeyError'); + ffi.Pointer PyErr_Format( + ffi.Pointer exception, + ffi.Pointer format, + ) { + return _PyErr_Format( + exception, + format, + ); + } - ffi.Pointer get PyExc_KeyError => _PyExc_KeyError.value; + late final _PyErr_FormatPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>('PyErr_Format'); + late final _PyErr_Format = _PyErr_FormatPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - set PyExc_KeyError(ffi.Pointer value) => - _PyExc_KeyError.value = value; + ffi.Pointer PyErr_FormatV( + ffi.Pointer exception, + ffi.Pointer format, + va_list vargs, + ) { + return _PyErr_FormatV( + exception, + format, + vargs, + ); + } - late final ffi.Pointer> _PyExc_KeyboardInterrupt = - _lookup>('PyExc_KeyboardInterrupt'); + late final _PyErr_FormatVPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, va_list)>>('PyErr_FormatV'); + late final _PyErr_FormatV = _PyErr_FormatVPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, va_list)>(); - ffi.Pointer get PyExc_KeyboardInterrupt => - _PyExc_KeyboardInterrupt.value; + ffi.Pointer PyErr_SetImportErrorSubclass( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ) { + return _PyErr_SetImportErrorSubclass( + arg0, + arg1, + arg2, + arg3, + ); + } - set PyExc_KeyboardInterrupt(ffi.Pointer value) => - _PyExc_KeyboardInterrupt.value = value; + late final _PyErr_SetImportErrorSubclassPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyErr_SetImportErrorSubclass'); + late final _PyErr_SetImportErrorSubclass = + _PyErr_SetImportErrorSubclassPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_MemoryError = - _lookup>('PyExc_MemoryError'); + ffi.Pointer PyErr_SetImportError( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ) { + return _PyErr_SetImportError( + arg0, + arg1, + arg2, + ); + } - ffi.Pointer get PyExc_MemoryError => _PyExc_MemoryError.value; + late final _PyErr_SetImportErrorPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyErr_SetImportError'); + late final _PyErr_SetImportError = _PyErr_SetImportErrorPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - set PyExc_MemoryError(ffi.Pointer value) => - _PyExc_MemoryError.value = value; + void PyErr_BadInternalCall() { + return _PyErr_BadInternalCall1(); + } - late final ffi.Pointer> _PyExc_NameError = - _lookup>('PyExc_NameError'); + late final _PyErr_BadInternalCallPtr = + _lookup>('PyErr_BadInternalCall'); + late final _PyErr_BadInternalCall1 = + _PyErr_BadInternalCallPtr.asFunction(); - ffi.Pointer get PyExc_NameError => _PyExc_NameError.value; + void _PyErr_BadInternalCall( + ffi.Pointer filename, + int lineno, + ) { + return __PyErr_BadInternalCall( + filename, + lineno, + ); + } - set PyExc_NameError(ffi.Pointer value) => - _PyExc_NameError.value = value; + late final __PyErr_BadInternalCallPtr = _lookup< + ffi + .NativeFunction, ffi.Int)>>( + '_PyErr_BadInternalCall'); + late final __PyErr_BadInternalCall = __PyErr_BadInternalCallPtr + .asFunction, int)>(); - late final ffi.Pointer> _PyExc_OverflowError = - _lookup>('PyExc_OverflowError'); + ffi.Pointer PyErr_NewException( + ffi.Pointer name, + ffi.Pointer base, + ffi.Pointer dict, + ) { + return _PyErr_NewException( + name, + base, + dict, + ); + } - ffi.Pointer get PyExc_OverflowError => _PyExc_OverflowError.value; + late final _PyErr_NewExceptionPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyErr_NewException'); + late final _PyErr_NewException = _PyErr_NewExceptionPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - set PyExc_OverflowError(ffi.Pointer value) => - _PyExc_OverflowError.value = value; + ffi.Pointer PyErr_NewExceptionWithDoc( + ffi.Pointer name, + ffi.Pointer doc, + ffi.Pointer base, + ffi.Pointer dict, + ) { + return _PyErr_NewExceptionWithDoc( + name, + doc, + base, + dict, + ); + } - late final ffi.Pointer> _PyExc_RuntimeError = - _lookup>('PyExc_RuntimeError'); + late final _PyErr_NewExceptionWithDocPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyErr_NewExceptionWithDoc'); + late final _PyErr_NewExceptionWithDoc = + _PyErr_NewExceptionWithDocPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer get PyExc_RuntimeError => _PyExc_RuntimeError.value; + void PyErr_WriteUnraisable( + ffi.Pointer arg0, + ) { + return _PyErr_WriteUnraisable( + arg0, + ); + } - set PyExc_RuntimeError(ffi.Pointer value) => - _PyExc_RuntimeError.value = value; + late final _PyErr_WriteUnraisablePtr = + _lookup)>>( + 'PyErr_WriteUnraisable'); + late final _PyErr_WriteUnraisable = _PyErr_WriteUnraisablePtr.asFunction< + void Function(ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_RecursionError = - _lookup>('PyExc_RecursionError'); + int PyErr_CheckSignals() { + return _PyErr_CheckSignals1(); + } - ffi.Pointer get PyExc_RecursionError => _PyExc_RecursionError.value; + late final _PyErr_CheckSignalsPtr = + _lookup>('PyErr_CheckSignals'); + late final _PyErr_CheckSignals1 = + _PyErr_CheckSignalsPtr.asFunction(); - set PyExc_RecursionError(ffi.Pointer value) => - _PyExc_RecursionError.value = value; + void PyErr_SetInterrupt() { + return _PyErr_SetInterrupt(); + } - late final ffi.Pointer> _PyExc_NotImplementedError = - _lookup>('PyExc_NotImplementedError'); + late final _PyErr_SetInterruptPtr = + _lookup>('PyErr_SetInterrupt'); + late final _PyErr_SetInterrupt = + _PyErr_SetInterruptPtr.asFunction(); - ffi.Pointer get PyExc_NotImplementedError => - _PyExc_NotImplementedError.value; + int PyErr_SetInterruptEx( + int signum, + ) { + return _PyErr_SetInterruptEx( + signum, + ); + } - set PyExc_NotImplementedError(ffi.Pointer value) => - _PyExc_NotImplementedError.value = value; + late final _PyErr_SetInterruptExPtr = + _lookup>( + 'PyErr_SetInterruptEx'); + late final _PyErr_SetInterruptEx = + _PyErr_SetInterruptExPtr.asFunction(); - late final ffi.Pointer> _PyExc_SyntaxError = - _lookup>('PyExc_SyntaxError'); + void PyErr_SyntaxLocation( + ffi.Pointer filename, + int lineno, + ) { + return _PyErr_SyntaxLocation( + filename, + lineno, + ); + } - ffi.Pointer get PyExc_SyntaxError => _PyExc_SyntaxError.value; + late final _PyErr_SyntaxLocationPtr = _lookup< + ffi + .NativeFunction, ffi.Int)>>( + 'PyErr_SyntaxLocation'); + late final _PyErr_SyntaxLocation = _PyErr_SyntaxLocationPtr.asFunction< + void Function(ffi.Pointer, int)>(); - set PyExc_SyntaxError(ffi.Pointer value) => - _PyExc_SyntaxError.value = value; + void PyErr_SyntaxLocationEx( + ffi.Pointer filename, + int lineno, + int col_offset, + ) { + return _PyErr_SyntaxLocationEx( + filename, + lineno, + col_offset, + ); + } - late final ffi.Pointer> _PyExc_IndentationError = - _lookup>('PyExc_IndentationError'); + late final _PyErr_SyntaxLocationExPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, ffi.Int, + ffi.Int)>>('PyErr_SyntaxLocationEx'); + late final _PyErr_SyntaxLocationEx = _PyErr_SyntaxLocationExPtr.asFunction< + void Function(ffi.Pointer, int, int)>(); - ffi.Pointer get PyExc_IndentationError => - _PyExc_IndentationError.value; + ffi.Pointer PyErr_ProgramText( + ffi.Pointer filename, + int lineno, + ) { + return _PyErr_ProgramText( + filename, + lineno, + ); + } - set PyExc_IndentationError(ffi.Pointer value) => - _PyExc_IndentationError.value = value; + late final _PyErr_ProgramTextPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Int)>>('PyErr_ProgramText'); + late final _PyErr_ProgramText = _PyErr_ProgramTextPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - late final ffi.Pointer> _PyExc_TabError = - _lookup>('PyExc_TabError'); + ffi.Pointer PyUnicodeDecodeError_Create( + ffi.Pointer encoding, + ffi.Pointer object, + int length, + int start, + int end, + ffi.Pointer reason, + ) { + return _PyUnicodeDecodeError_Create( + encoding, + object, + length, + start, + end, + reason, + ); + } - ffi.Pointer get PyExc_TabError => _PyExc_TabError.value; + late final _PyUnicodeDecodeError_CreatePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + Py_ssize_t, + Py_ssize_t, + Py_ssize_t, + ffi.Pointer)>>('PyUnicodeDecodeError_Create'); + late final _PyUnicodeDecodeError_Create = + _PyUnicodeDecodeError_CreatePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, int, int, int, ffi.Pointer)>(); - set PyExc_TabError(ffi.Pointer value) => - _PyExc_TabError.value = value; + ffi.Pointer PyUnicodeEncodeError_GetEncoding( + ffi.Pointer arg0, + ) { + return _PyUnicodeEncodeError_GetEncoding( + arg0, + ); + } - late final ffi.Pointer> _PyExc_ReferenceError = - _lookup>('PyExc_ReferenceError'); + late final _PyUnicodeEncodeError_GetEncodingPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeEncodeError_GetEncoding'); + late final _PyUnicodeEncodeError_GetEncoding = + _PyUnicodeEncodeError_GetEncodingPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer get PyExc_ReferenceError => _PyExc_ReferenceError.value; + ffi.Pointer PyUnicodeDecodeError_GetEncoding( + ffi.Pointer arg0, + ) { + return _PyUnicodeDecodeError_GetEncoding( + arg0, + ); + } - set PyExc_ReferenceError(ffi.Pointer value) => - _PyExc_ReferenceError.value = value; + late final _PyUnicodeDecodeError_GetEncodingPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeDecodeError_GetEncoding'); + late final _PyUnicodeDecodeError_GetEncoding = + _PyUnicodeDecodeError_GetEncodingPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_SystemError = - _lookup>('PyExc_SystemError'); + ffi.Pointer PyUnicodeEncodeError_GetObject( + ffi.Pointer arg0, + ) { + return _PyUnicodeEncodeError_GetObject( + arg0, + ); + } - ffi.Pointer get PyExc_SystemError => _PyExc_SystemError.value; + late final _PyUnicodeEncodeError_GetObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeEncodeError_GetObject'); + late final _PyUnicodeEncodeError_GetObject = + _PyUnicodeEncodeError_GetObjectPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - set PyExc_SystemError(ffi.Pointer value) => - _PyExc_SystemError.value = value; + ffi.Pointer PyUnicodeDecodeError_GetObject( + ffi.Pointer arg0, + ) { + return _PyUnicodeDecodeError_GetObject( + arg0, + ); + } - late final ffi.Pointer> _PyExc_SystemExit = - _lookup>('PyExc_SystemExit'); + late final _PyUnicodeDecodeError_GetObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeDecodeError_GetObject'); + late final _PyUnicodeDecodeError_GetObject = + _PyUnicodeDecodeError_GetObjectPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer get PyExc_SystemExit => _PyExc_SystemExit.value; + ffi.Pointer PyUnicodeTranslateError_GetObject( + ffi.Pointer arg0, + ) { + return _PyUnicodeTranslateError_GetObject( + arg0, + ); + } - set PyExc_SystemExit(ffi.Pointer value) => - _PyExc_SystemExit.value = value; + late final _PyUnicodeTranslateError_GetObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeTranslateError_GetObject'); + late final _PyUnicodeTranslateError_GetObject = + _PyUnicodeTranslateError_GetObjectPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_TypeError = - _lookup>('PyExc_TypeError'); + int PyUnicodeEncodeError_GetStart( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyUnicodeEncodeError_GetStart( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_TypeError => _PyExc_TypeError.value; + late final _PyUnicodeEncodeError_GetStartPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeEncodeError_GetStart'); + late final _PyUnicodeEncodeError_GetStart = + _PyUnicodeEncodeError_GetStartPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - set PyExc_TypeError(ffi.Pointer value) => - _PyExc_TypeError.value = value; + int PyUnicodeDecodeError_GetStart( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyUnicodeDecodeError_GetStart( + arg0, + arg1, + ); + } - late final ffi.Pointer> _PyExc_UnboundLocalError = - _lookup>('PyExc_UnboundLocalError'); + late final _PyUnicodeDecodeError_GetStartPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeDecodeError_GetStart'); + late final _PyUnicodeDecodeError_GetStart = + _PyUnicodeDecodeError_GetStartPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer get PyExc_UnboundLocalError => - _PyExc_UnboundLocalError.value; + int PyUnicodeTranslateError_GetStart( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyUnicodeTranslateError_GetStart( + arg0, + arg1, + ); + } - set PyExc_UnboundLocalError(ffi.Pointer value) => - _PyExc_UnboundLocalError.value = value; + late final _PyUnicodeTranslateError_GetStartPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeTranslateError_GetStart'); + late final _PyUnicodeTranslateError_GetStart = + _PyUnicodeTranslateError_GetStartPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_UnicodeError = - _lookup>('PyExc_UnicodeError'); + int PyUnicodeEncodeError_SetStart( + ffi.Pointer arg0, + int arg1, + ) { + return _PyUnicodeEncodeError_SetStart( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_UnicodeError => _PyExc_UnicodeError.value; + late final _PyUnicodeEncodeError_SetStartPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicodeEncodeError_SetStart'); + late final _PyUnicodeEncodeError_SetStart = _PyUnicodeEncodeError_SetStartPtr + .asFunction, int)>(); - set PyExc_UnicodeError(ffi.Pointer value) => - _PyExc_UnicodeError.value = value; + int PyUnicodeDecodeError_SetStart( + ffi.Pointer arg0, + int arg1, + ) { + return _PyUnicodeDecodeError_SetStart( + arg0, + arg1, + ); + } - late final ffi.Pointer> _PyExc_UnicodeEncodeError = - _lookup>('PyExc_UnicodeEncodeError'); + late final _PyUnicodeDecodeError_SetStartPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicodeDecodeError_SetStart'); + late final _PyUnicodeDecodeError_SetStart = _PyUnicodeDecodeError_SetStartPtr + .asFunction, int)>(); - ffi.Pointer get PyExc_UnicodeEncodeError => - _PyExc_UnicodeEncodeError.value; + int PyUnicodeTranslateError_SetStart( + ffi.Pointer arg0, + int arg1, + ) { + return _PyUnicodeTranslateError_SetStart( + arg0, + arg1, + ); + } - set PyExc_UnicodeEncodeError(ffi.Pointer value) => - _PyExc_UnicodeEncodeError.value = value; + late final _PyUnicodeTranslateError_SetStartPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicodeTranslateError_SetStart'); + late final _PyUnicodeTranslateError_SetStart = + _PyUnicodeTranslateError_SetStartPtr.asFunction< + int Function(ffi.Pointer, int)>(); - late final ffi.Pointer> _PyExc_UnicodeDecodeError = - _lookup>('PyExc_UnicodeDecodeError'); + int PyUnicodeEncodeError_GetEnd( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyUnicodeEncodeError_GetEnd( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_UnicodeDecodeError => - _PyExc_UnicodeDecodeError.value; + late final _PyUnicodeEncodeError_GetEndPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeEncodeError_GetEnd'); + late final _PyUnicodeEncodeError_GetEnd = + _PyUnicodeEncodeError_GetEndPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - set PyExc_UnicodeDecodeError(ffi.Pointer value) => - _PyExc_UnicodeDecodeError.value = value; + int PyUnicodeDecodeError_GetEnd( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyUnicodeDecodeError_GetEnd( + arg0, + arg1, + ); + } - late final ffi.Pointer> _PyExc_UnicodeTranslateError = - _lookup>('PyExc_UnicodeTranslateError'); + late final _PyUnicodeDecodeError_GetEndPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeDecodeError_GetEnd'); + late final _PyUnicodeDecodeError_GetEnd = + _PyUnicodeDecodeError_GetEndPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer get PyExc_UnicodeTranslateError => - _PyExc_UnicodeTranslateError.value; + int PyUnicodeTranslateError_GetEnd( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return _PyUnicodeTranslateError_GetEnd( + arg0, + arg1, + ); + } - set PyExc_UnicodeTranslateError(ffi.Pointer value) => - _PyExc_UnicodeTranslateError.value = value; + late final _PyUnicodeTranslateError_GetEndPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeTranslateError_GetEnd'); + late final _PyUnicodeTranslateError_GetEnd = + _PyUnicodeTranslateError_GetEndPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_ValueError = - _lookup>('PyExc_ValueError'); + int PyUnicodeEncodeError_SetEnd( + ffi.Pointer arg0, + int arg1, + ) { + return _PyUnicodeEncodeError_SetEnd( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_ValueError => _PyExc_ValueError.value; + late final _PyUnicodeEncodeError_SetEndPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicodeEncodeError_SetEnd'); + late final _PyUnicodeEncodeError_SetEnd = _PyUnicodeEncodeError_SetEndPtr + .asFunction, int)>(); - set PyExc_ValueError(ffi.Pointer value) => - _PyExc_ValueError.value = value; + int PyUnicodeDecodeError_SetEnd( + ffi.Pointer arg0, + int arg1, + ) { + return _PyUnicodeDecodeError_SetEnd( + arg0, + arg1, + ); + } - late final ffi.Pointer> _PyExc_ZeroDivisionError = - _lookup>('PyExc_ZeroDivisionError'); + late final _PyUnicodeDecodeError_SetEndPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicodeDecodeError_SetEnd'); + late final _PyUnicodeDecodeError_SetEnd = _PyUnicodeDecodeError_SetEndPtr + .asFunction, int)>(); - ffi.Pointer get PyExc_ZeroDivisionError => - _PyExc_ZeroDivisionError.value; + int PyUnicodeTranslateError_SetEnd( + ffi.Pointer arg0, + int arg1, + ) { + return _PyUnicodeTranslateError_SetEnd( + arg0, + arg1, + ); + } - set PyExc_ZeroDivisionError(ffi.Pointer value) => - _PyExc_ZeroDivisionError.value = value; + late final _PyUnicodeTranslateError_SetEndPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PyUnicodeTranslateError_SetEnd'); + late final _PyUnicodeTranslateError_SetEnd = + _PyUnicodeTranslateError_SetEndPtr.asFunction< + int Function(ffi.Pointer, int)>(); - late final ffi.Pointer> _PyExc_BlockingIOError = - _lookup>('PyExc_BlockingIOError'); + ffi.Pointer PyUnicodeEncodeError_GetReason( + ffi.Pointer arg0, + ) { + return _PyUnicodeEncodeError_GetReason( + arg0, + ); + } - ffi.Pointer get PyExc_BlockingIOError => - _PyExc_BlockingIOError.value; + late final _PyUnicodeEncodeError_GetReasonPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeEncodeError_GetReason'); + late final _PyUnicodeEncodeError_GetReason = + _PyUnicodeEncodeError_GetReasonPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - set PyExc_BlockingIOError(ffi.Pointer value) => - _PyExc_BlockingIOError.value = value; + ffi.Pointer PyUnicodeDecodeError_GetReason( + ffi.Pointer arg0, + ) { + return _PyUnicodeDecodeError_GetReason( + arg0, + ); + } - late final ffi.Pointer> _PyExc_BrokenPipeError = - _lookup>('PyExc_BrokenPipeError'); + late final _PyUnicodeDecodeError_GetReasonPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeDecodeError_GetReason'); + late final _PyUnicodeDecodeError_GetReason = + _PyUnicodeDecodeError_GetReasonPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer get PyExc_BrokenPipeError => - _PyExc_BrokenPipeError.value; + ffi.Pointer PyUnicodeTranslateError_GetReason( + ffi.Pointer arg0, + ) { + return _PyUnicodeTranslateError_GetReason( + arg0, + ); + } - set PyExc_BrokenPipeError(ffi.Pointer value) => - _PyExc_BrokenPipeError.value = value; + late final _PyUnicodeTranslateError_GetReasonPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyUnicodeTranslateError_GetReason'); + late final _PyUnicodeTranslateError_GetReason = + _PyUnicodeTranslateError_GetReasonPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_ChildProcessError = - _lookup>('PyExc_ChildProcessError'); + int PyUnicodeEncodeError_SetReason( + ffi.Pointer exc, + ffi.Pointer reason, + ) { + return _PyUnicodeEncodeError_SetReason( + exc, + reason, + ); + } - ffi.Pointer get PyExc_ChildProcessError => - _PyExc_ChildProcessError.value; + late final _PyUnicodeEncodeError_SetReasonPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeEncodeError_SetReason'); + late final _PyUnicodeEncodeError_SetReason = + _PyUnicodeEncodeError_SetReasonPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - set PyExc_ChildProcessError(ffi.Pointer value) => - _PyExc_ChildProcessError.value = value; + int PyUnicodeDecodeError_SetReason( + ffi.Pointer exc, + ffi.Pointer reason, + ) { + return _PyUnicodeDecodeError_SetReason( + exc, + reason, + ); + } - late final ffi.Pointer> _PyExc_ConnectionError = - _lookup>('PyExc_ConnectionError'); + late final _PyUnicodeDecodeError_SetReasonPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeDecodeError_SetReason'); + late final _PyUnicodeDecodeError_SetReason = + _PyUnicodeDecodeError_SetReasonPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer get PyExc_ConnectionError => - _PyExc_ConnectionError.value; + int PyUnicodeTranslateError_SetReason( + ffi.Pointer exc, + ffi.Pointer reason, + ) { + return _PyUnicodeTranslateError_SetReason( + exc, + reason, + ); + } - set PyExc_ConnectionError(ffi.Pointer value) => - _PyExc_ConnectionError.value = value; + late final _PyUnicodeTranslateError_SetReasonPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyUnicodeTranslateError_SetReason'); + late final _PyUnicodeTranslateError_SetReason = + _PyUnicodeTranslateError_SetReasonPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_ConnectionAbortedError = - _lookup>('PyExc_ConnectionAbortedError'); + int PyOS_snprintf( + ffi.Pointer str, + int size, + ffi.Pointer format, + ) { + return _PyOS_snprintf( + str, + size, + format, + ); + } - ffi.Pointer get PyExc_ConnectionAbortedError => - _PyExc_ConnectionAbortedError.value; + late final _PyOS_snprintfPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Size, + ffi.Pointer)>>('PyOS_snprintf'); + late final _PyOS_snprintf = _PyOS_snprintfPtr.asFunction< + int Function(ffi.Pointer, int, ffi.Pointer)>(); - set PyExc_ConnectionAbortedError(ffi.Pointer value) => - _PyExc_ConnectionAbortedError.value = value; + int PyOS_vsnprintf( + ffi.Pointer str, + int size, + ffi.Pointer format, + va_list va, + ) { + return _PyOS_vsnprintf( + str, + size, + format, + va, + ); + } - late final ffi.Pointer> _PyExc_ConnectionRefusedError = - _lookup>('PyExc_ConnectionRefusedError'); + late final _PyOS_vsnprintfPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Size, + ffi.Pointer, va_list)>>('PyOS_vsnprintf'); + late final _PyOS_vsnprintf = _PyOS_vsnprintfPtr.asFunction< + int Function( + ffi.Pointer, int, ffi.Pointer, va_list)>(); - ffi.Pointer get PyExc_ConnectionRefusedError => - _PyExc_ConnectionRefusedError.value; + void _PyErr_SetKeyError( + ffi.Pointer arg0, + ) { + return __PyErr_SetKeyError( + arg0, + ); + } - set PyExc_ConnectionRefusedError(ffi.Pointer value) => - _PyExc_ConnectionRefusedError.value = value; + late final __PyErr_SetKeyErrorPtr = + _lookup)>>( + '_PyErr_SetKeyError'); + late final __PyErr_SetKeyError = + __PyErr_SetKeyErrorPtr.asFunction)>(); - late final ffi.Pointer> _PyExc_ConnectionResetError = - _lookup>('PyExc_ConnectionResetError'); + ffi.Pointer<_PyErr_StackItem> _PyErr_GetTopmostException( + ffi.Pointer tstate, + ) { + return __PyErr_GetTopmostException( + tstate, + ); + } - ffi.Pointer get PyExc_ConnectionResetError => - _PyExc_ConnectionResetError.value; + late final __PyErr_GetTopmostExceptionPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer<_PyErr_StackItem> Function( + ffi.Pointer)>>('_PyErr_GetTopmostException'); + late final __PyErr_GetTopmostException = + __PyErr_GetTopmostExceptionPtr.asFunction< + ffi.Pointer<_PyErr_StackItem> Function(ffi.Pointer)>(); - set PyExc_ConnectionResetError(ffi.Pointer value) => - _PyExc_ConnectionResetError.value = value; + ffi.Pointer _PyErr_GetHandledException( + ffi.Pointer arg0, + ) { + return __PyErr_GetHandledException( + arg0, + ); + } - late final ffi.Pointer> _PyExc_FileExistsError = - _lookup>('PyExc_FileExistsError'); + late final __PyErr_GetHandledExceptionPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('_PyErr_GetHandledException'); + late final __PyErr_GetHandledException = __PyErr_GetHandledExceptionPtr + .asFunction Function(ffi.Pointer)>(); - ffi.Pointer get PyExc_FileExistsError => - _PyExc_FileExistsError.value; + void _PyErr_SetHandledException( + ffi.Pointer arg0, + ffi.Pointer arg1, + ) { + return __PyErr_SetHandledException( + arg0, + arg1, + ); + } - set PyExc_FileExistsError(ffi.Pointer value) => - _PyExc_FileExistsError.value = value; + late final __PyErr_SetHandledExceptionPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('_PyErr_SetHandledException'); + late final __PyErr_SetHandledException = + __PyErr_SetHandledExceptionPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_FileNotFoundError = - _lookup>('PyExc_FileNotFoundError'); + void _PyErr_GetExcInfo( + ffi.Pointer arg0, + ffi.Pointer> arg1, + ffi.Pointer> arg2, + ffi.Pointer> arg3, + ) { + return __PyErr_GetExcInfo( + arg0, + arg1, + arg2, + arg3, + ); + } - ffi.Pointer get PyExc_FileNotFoundError => - _PyExc_FileNotFoundError.value; + late final __PyErr_GetExcInfoPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>>('_PyErr_GetExcInfo'); + late final __PyErr_GetExcInfo = __PyErr_GetExcInfoPtr.asFunction< + void Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer>, + ffi.Pointer>)>(); - set PyExc_FileNotFoundError(ffi.Pointer value) => - _PyExc_FileNotFoundError.value = value; + void _PyErr_ChainExceptions( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ) { + return __PyErr_ChainExceptions( + arg0, + arg1, + arg2, + ); + } - late final ffi.Pointer> _PyExc_InterruptedError = - _lookup>('PyExc_InterruptedError'); + late final __PyErr_ChainExceptionsPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('_PyErr_ChainExceptions'); + late final __PyErr_ChainExceptions = __PyErr_ChainExceptionsPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer get PyExc_InterruptedError => - _PyExc_InterruptedError.value; + ffi.Pointer _PyErr_FormatFromCause( + ffi.Pointer exception, + ffi.Pointer format, + ) { + return __PyErr_FormatFromCause( + exception, + format, + ); + } - set PyExc_InterruptedError(ffi.Pointer value) => - _PyExc_InterruptedError.value = value; + late final __PyErr_FormatFromCausePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyErr_FormatFromCause'); + late final __PyErr_FormatFromCause = __PyErr_FormatFromCausePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_IsADirectoryError = - _lookup>('PyExc_IsADirectoryError'); + ffi.Pointer _PyErr_TrySetFromCause( + ffi.Pointer prefix_format, + ) { + return __PyErr_TrySetFromCause( + prefix_format, + ); + } - ffi.Pointer get PyExc_IsADirectoryError => - _PyExc_IsADirectoryError.value; + late final __PyErr_TrySetFromCausePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('_PyErr_TrySetFromCause'); + late final __PyErr_TrySetFromCause = __PyErr_TrySetFromCausePtr + .asFunction Function(ffi.Pointer)>(); - set PyExc_IsADirectoryError(ffi.Pointer value) => - _PyExc_IsADirectoryError.value = value; + int PySignal_SetWakeupFd( + int fd, + ) { + return _PySignal_SetWakeupFd( + fd, + ); + } - late final ffi.Pointer> _PyExc_NotADirectoryError = - _lookup>('PyExc_NotADirectoryError'); + late final _PySignal_SetWakeupFdPtr = + _lookup>( + 'PySignal_SetWakeupFd'); + late final _PySignal_SetWakeupFd = + _PySignal_SetWakeupFdPtr.asFunction(); - ffi.Pointer get PyExc_NotADirectoryError => - _PyExc_NotADirectoryError.value; + int _PyErr_CheckSignals() { + return __PyErr_CheckSignals(); + } - set PyExc_NotADirectoryError(ffi.Pointer value) => - _PyExc_NotADirectoryError.value = value; + late final __PyErr_CheckSignalsPtr = + _lookup>('_PyErr_CheckSignals'); + late final __PyErr_CheckSignals = + __PyErr_CheckSignalsPtr.asFunction(); - late final ffi.Pointer> _PyExc_PermissionError = - _lookup>('PyExc_PermissionError'); + void PyErr_SyntaxLocationObject( + ffi.Pointer filename, + int lineno, + int col_offset, + ) { + return _PyErr_SyntaxLocationObject( + filename, + lineno, + col_offset, + ); + } - ffi.Pointer get PyExc_PermissionError => - _PyExc_PermissionError.value; + late final _PyErr_SyntaxLocationObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, ffi.Int, + ffi.Int)>>('PyErr_SyntaxLocationObject'); + late final _PyErr_SyntaxLocationObject = _PyErr_SyntaxLocationObjectPtr + .asFunction, int, int)>(); - set PyExc_PermissionError(ffi.Pointer value) => - _PyExc_PermissionError.value = value; + void PyErr_RangedSyntaxLocationObject( + ffi.Pointer filename, + int lineno, + int col_offset, + int end_lineno, + int end_col_offset, + ) { + return _PyErr_RangedSyntaxLocationObject( + filename, + lineno, + col_offset, + end_lineno, + end_col_offset, + ); + } - late final ffi.Pointer> _PyExc_ProcessLookupError = - _lookup>('PyExc_ProcessLookupError'); + late final _PyErr_RangedSyntaxLocationObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, ffi.Int, ffi.Int, ffi.Int, + ffi.Int)>>('PyErr_RangedSyntaxLocationObject'); + late final _PyErr_RangedSyntaxLocationObject = + _PyErr_RangedSyntaxLocationObjectPtr.asFunction< + void Function(ffi.Pointer, int, int, int, int)>(); - ffi.Pointer get PyExc_ProcessLookupError => - _PyExc_ProcessLookupError.value; + ffi.Pointer PyErr_ProgramTextObject( + ffi.Pointer filename, + int lineno, + ) { + return _PyErr_ProgramTextObject( + filename, + lineno, + ); + } - set PyExc_ProcessLookupError(ffi.Pointer value) => - _PyExc_ProcessLookupError.value = value; + late final _PyErr_ProgramTextObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Int)>>('PyErr_ProgramTextObject'); + late final _PyErr_ProgramTextObject = _PyErr_ProgramTextObjectPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - late final ffi.Pointer> _PyExc_TimeoutError = - _lookup>('PyExc_TimeoutError'); + ffi.Pointer _PyErr_ProgramDecodedTextObject( + ffi.Pointer filename, + int lineno, + ffi.Pointer encoding, + ) { + return __PyErr_ProgramDecodedTextObject( + filename, + lineno, + encoding, + ); + } - ffi.Pointer get PyExc_TimeoutError => _PyExc_TimeoutError.value; + late final __PyErr_ProgramDecodedTextObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, ffi.Int, + ffi.Pointer)>>('_PyErr_ProgramDecodedTextObject'); + late final __PyErr_ProgramDecodedTextObject = + __PyErr_ProgramDecodedTextObjectPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, int, ffi.Pointer)>(); - set PyExc_TimeoutError(ffi.Pointer value) => - _PyExc_TimeoutError.value = value; + ffi.Pointer _PyUnicodeTranslateError_Create( + ffi.Pointer object, + int start, + int end, + ffi.Pointer reason, + ) { + return __PyUnicodeTranslateError_Create( + object, + start, + end, + reason, + ); + } - late final ffi.Pointer> _PyExc_EnvironmentError = - _lookup>('PyExc_EnvironmentError'); + late final __PyUnicodeTranslateError_CreatePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + Py_ssize_t, + Py_ssize_t, + ffi.Pointer)>>('_PyUnicodeTranslateError_Create'); + late final __PyUnicodeTranslateError_Create = + __PyUnicodeTranslateError_CreatePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, int, int, ffi.Pointer)>(); - ffi.Pointer get PyExc_EnvironmentError => - _PyExc_EnvironmentError.value; + void _PyErr_WriteUnraisableMsg( + ffi.Pointer err_msg, + ffi.Pointer obj, + ) { + return __PyErr_WriteUnraisableMsg( + err_msg, + obj, + ); + } - set PyExc_EnvironmentError(ffi.Pointer value) => - _PyExc_EnvironmentError.value = value; + late final __PyErr_WriteUnraisableMsgPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('_PyErr_WriteUnraisableMsg'); + late final __PyErr_WriteUnraisableMsg = + __PyErr_WriteUnraisableMsgPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_IOError = - _lookup>('PyExc_IOError'); + void _Py_FatalErrorFunc( + ffi.Pointer func, + ffi.Pointer message, + ) { + return __Py_FatalErrorFunc( + func, + message, + ); + } - ffi.Pointer get PyExc_IOError => _PyExc_IOError.value; + late final __Py_FatalErrorFuncPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('_Py_FatalErrorFunc'); + late final __Py_FatalErrorFunc = __Py_FatalErrorFuncPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - set PyExc_IOError(ffi.Pointer value) => - _PyExc_IOError.value = value; + void _Py_FatalErrorFormat( + ffi.Pointer func, + ffi.Pointer format, + ) { + return __Py_FatalErrorFormat( + func, + format, + ); + } - late final ffi.Pointer> _PyExc_Warning = - _lookup>('PyExc_Warning'); + late final __Py_FatalErrorFormatPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Pointer, + ffi.Pointer)>>('_Py_FatalErrorFormat'); + late final __Py_FatalErrorFormat = __Py_FatalErrorFormatPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer get PyExc_Warning => _PyExc_Warning.value; + void PyThread_init_thread() { + return _PyThread_init_thread(); + } - set PyExc_Warning(ffi.Pointer value) => - _PyExc_Warning.value = value; + late final _PyThread_init_threadPtr = + _lookup>('PyThread_init_thread'); + late final _PyThread_init_thread = + _PyThread_init_threadPtr.asFunction(); - late final ffi.Pointer> _PyExc_UserWarning = - _lookup>('PyExc_UserWarning'); + int PyThread_start_new_thread( + ffi.Pointer)>> + arg0, + ffi.Pointer arg1, + ) { + return _PyThread_start_new_thread( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_UserWarning => _PyExc_UserWarning.value; + late final _PyThread_start_new_threadPtr = _lookup< + ffi.NativeFunction< + ffi.UnsignedLong Function( + ffi.Pointer< + ffi.NativeFunction)>>, + ffi.Pointer)>>('PyThread_start_new_thread'); + late final _PyThread_start_new_thread = + _PyThread_start_new_threadPtr.asFunction< + int Function( + ffi.Pointer< + ffi.NativeFunction)>>, + ffi.Pointer)>(); - set PyExc_UserWarning(ffi.Pointer value) => - _PyExc_UserWarning.value = value; + void PyThread_exit_thread() { + return _PyThread_exit_thread(); + } - late final ffi.Pointer> _PyExc_DeprecationWarning = - _lookup>('PyExc_DeprecationWarning'); + late final _PyThread_exit_threadPtr = + _lookup>('PyThread_exit_thread'); + late final _PyThread_exit_thread = + _PyThread_exit_threadPtr.asFunction(); - ffi.Pointer get PyExc_DeprecationWarning => - _PyExc_DeprecationWarning.value; + int PyThread_get_thread_ident() { + return _PyThread_get_thread_ident(); + } - set PyExc_DeprecationWarning(ffi.Pointer value) => - _PyExc_DeprecationWarning.value = value; + late final _PyThread_get_thread_identPtr = + _lookup>( + 'PyThread_get_thread_ident'); + late final _PyThread_get_thread_ident = + _PyThread_get_thread_identPtr.asFunction(); - late final ffi.Pointer> - _PyExc_PendingDeprecationWarning = - _lookup>('PyExc_PendingDeprecationWarning'); + int PyThread_get_thread_native_id() { + return _PyThread_get_thread_native_id(); + } - ffi.Pointer get PyExc_PendingDeprecationWarning => - _PyExc_PendingDeprecationWarning.value; + late final _PyThread_get_thread_native_idPtr = + _lookup>( + 'PyThread_get_thread_native_id'); + late final _PyThread_get_thread_native_id = + _PyThread_get_thread_native_idPtr.asFunction(); - set PyExc_PendingDeprecationWarning(ffi.Pointer value) => - _PyExc_PendingDeprecationWarning.value = value; + PyThread_type_lock PyThread_allocate_lock() { + return _PyThread_allocate_lock(); + } - late final ffi.Pointer> _PyExc_SyntaxWarning = - _lookup>('PyExc_SyntaxWarning'); + late final _PyThread_allocate_lockPtr = + _lookup>( + 'PyThread_allocate_lock'); + late final _PyThread_allocate_lock = + _PyThread_allocate_lockPtr.asFunction(); - ffi.Pointer get PyExc_SyntaxWarning => _PyExc_SyntaxWarning.value; + void PyThread_free_lock( + PyThread_type_lock arg0, + ) { + return _PyThread_free_lock( + arg0, + ); + } - set PyExc_SyntaxWarning(ffi.Pointer value) => - _PyExc_SyntaxWarning.value = value; + late final _PyThread_free_lockPtr = + _lookup>( + 'PyThread_free_lock'); + late final _PyThread_free_lock = + _PyThread_free_lockPtr.asFunction(); - late final ffi.Pointer> _PyExc_RuntimeWarning = - _lookup>('PyExc_RuntimeWarning'); + int PyThread_acquire_lock( + PyThread_type_lock arg0, + int arg1, + ) { + return _PyThread_acquire_lock( + arg0, + arg1, + ); + } - ffi.Pointer get PyExc_RuntimeWarning => _PyExc_RuntimeWarning.value; + late final _PyThread_acquire_lockPtr = _lookup< + ffi.NativeFunction>( + 'PyThread_acquire_lock'); + late final _PyThread_acquire_lock = _PyThread_acquire_lockPtr.asFunction< + int Function(PyThread_type_lock, int)>(); - set PyExc_RuntimeWarning(ffi.Pointer value) => - _PyExc_RuntimeWarning.value = value; + int PyThread_acquire_lock_timed( + PyThread_type_lock arg0, + int microseconds, + int intr_flag, + ) { + return _PyThread_acquire_lock_timed( + arg0, + microseconds, + intr_flag, + ); + } - late final ffi.Pointer> _PyExc_FutureWarning = - _lookup>('PyExc_FutureWarning'); + late final _PyThread_acquire_lock_timedPtr = _lookup< + ffi.NativeFunction< + ffi.Int32 Function(PyThread_type_lock, ffi.LongLong, + ffi.Int)>>('PyThread_acquire_lock_timed'); + late final _PyThread_acquire_lock_timed = _PyThread_acquire_lock_timedPtr + .asFunction(); - ffi.Pointer get PyExc_FutureWarning => _PyExc_FutureWarning.value; + void PyThread_release_lock( + PyThread_type_lock arg0, + ) { + return _PyThread_release_lock( + arg0, + ); + } - set PyExc_FutureWarning(ffi.Pointer value) => - _PyExc_FutureWarning.value = value; + late final _PyThread_release_lockPtr = + _lookup>( + 'PyThread_release_lock'); + late final _PyThread_release_lock = + _PyThread_release_lockPtr.asFunction(); - late final ffi.Pointer> _PyExc_ImportWarning = - _lookup>('PyExc_ImportWarning'); + int PyThread_get_stacksize() { + return _PyThread_get_stacksize(); + } - ffi.Pointer get PyExc_ImportWarning => _PyExc_ImportWarning.value; + late final _PyThread_get_stacksizePtr = + _lookup>( + 'PyThread_get_stacksize'); + late final _PyThread_get_stacksize = + _PyThread_get_stacksizePtr.asFunction(); - set PyExc_ImportWarning(ffi.Pointer value) => - _PyExc_ImportWarning.value = value; + int PyThread_set_stacksize( + int arg0, + ) { + return _PyThread_set_stacksize( + arg0, + ); + } - late final ffi.Pointer> _PyExc_UnicodeWarning = - _lookup>('PyExc_UnicodeWarning'); + late final _PyThread_set_stacksizePtr = + _lookup>( + 'PyThread_set_stacksize'); + late final _PyThread_set_stacksize = + _PyThread_set_stacksizePtr.asFunction(); - ffi.Pointer get PyExc_UnicodeWarning => _PyExc_UnicodeWarning.value; + ffi.Pointer PyThread_GetInfo() { + return _PyThread_GetInfo(); + } - set PyExc_UnicodeWarning(ffi.Pointer value) => - _PyExc_UnicodeWarning.value = value; + late final _PyThread_GetInfoPtr = + _lookup Function()>>( + 'PyThread_GetInfo'); + late final _PyThread_GetInfo = + _PyThread_GetInfoPtr.asFunction Function()>(); - late final ffi.Pointer> _PyExc_BytesWarning = - _lookup>('PyExc_BytesWarning'); + int PyThread_create_key() { + return _PyThread_create_key(); + } - ffi.Pointer get PyExc_BytesWarning => _PyExc_BytesWarning.value; + late final _PyThread_create_keyPtr = + _lookup>('PyThread_create_key'); + late final _PyThread_create_key = + _PyThread_create_keyPtr.asFunction(); - set PyExc_BytesWarning(ffi.Pointer value) => - _PyExc_BytesWarning.value = value; + void PyThread_delete_key( + int key, + ) { + return _PyThread_delete_key( + key, + ); + } - late final ffi.Pointer> _PyExc_EncodingWarning = - _lookup>('PyExc_EncodingWarning'); + late final _PyThread_delete_keyPtr = + _lookup>( + 'PyThread_delete_key'); + late final _PyThread_delete_key = + _PyThread_delete_keyPtr.asFunction(); - ffi.Pointer get PyExc_EncodingWarning => - _PyExc_EncodingWarning.value; + int PyThread_set_key_value( + int key, + ffi.Pointer value, + ) { + return _PyThread_set_key_value( + key, + value, + ); + } - set PyExc_EncodingWarning(ffi.Pointer value) => - _PyExc_EncodingWarning.value = value; + late final _PyThread_set_key_valuePtr = _lookup< + ffi.NativeFunction)>>( + 'PyThread_set_key_value'); + late final _PyThread_set_key_value = _PyThread_set_key_valuePtr.asFunction< + int Function(int, ffi.Pointer)>(); - late final ffi.Pointer> _PyExc_ResourceWarning = - _lookup>('PyExc_ResourceWarning'); + ffi.Pointer PyThread_get_key_value( + int key, + ) { + return _PyThread_get_key_value( + key, + ); + } - ffi.Pointer get PyExc_ResourceWarning => - _PyExc_ResourceWarning.value; + late final _PyThread_get_key_valuePtr = + _lookup Function(ffi.Int)>>( + 'PyThread_get_key_value'); + late final _PyThread_get_key_value = _PyThread_get_key_valuePtr.asFunction< + ffi.Pointer Function(int)>(); - set PyExc_ResourceWarning(ffi.Pointer value) => - _PyExc_ResourceWarning.value = value; + void PyThread_delete_key_value( + int key, + ) { + return _PyThread_delete_key_value( + key, + ); + } - int PyErr_BadArgument() { - return _PyErr_BadArgument(); + late final _PyThread_delete_key_valuePtr = + _lookup>( + 'PyThread_delete_key_value'); + late final _PyThread_delete_key_value = + _PyThread_delete_key_valuePtr.asFunction(); + + void PyThread_ReInitTLS() { + return _PyThread_ReInitTLS(); } - late final _PyErr_BadArgumentPtr = - _lookup>('PyErr_BadArgument'); - late final _PyErr_BadArgument = - _PyErr_BadArgumentPtr.asFunction(); + late final _PyThread_ReInitTLSPtr = + _lookup>('PyThread_ReInitTLS'); + late final _PyThread_ReInitTLS = + _PyThread_ReInitTLSPtr.asFunction(); - ffi.Pointer PyErr_NoMemory() { - return _PyErr_NoMemory(); + ffi.Pointer PyThread_tss_alloc() { + return _PyThread_tss_alloc(); } - late final _PyErr_NoMemoryPtr = - _lookup Function()>>( - 'PyErr_NoMemory'); - late final _PyErr_NoMemory = - _PyErr_NoMemoryPtr.asFunction Function()>(); + late final _PyThread_tss_allocPtr = + _lookup Function()>>( + 'PyThread_tss_alloc'); + late final _PyThread_tss_alloc = + _PyThread_tss_allocPtr.asFunction Function()>(); - ffi.Pointer PyErr_SetFromErrno( - ffi.Pointer arg0, + void PyThread_tss_free( + ffi.Pointer key, ) { - return _PyErr_SetFromErrno( - arg0, + return _PyThread_tss_free( + key, ); } - late final _PyErr_SetFromErrnoPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyErr_SetFromErrno'); - late final _PyErr_SetFromErrno = _PyErr_SetFromErrnoPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final _PyThread_tss_freePtr = + _lookup)>>( + 'PyThread_tss_free'); + late final _PyThread_tss_free = + _PyThread_tss_freePtr.asFunction)>(); - ffi.Pointer PyErr_SetFromErrnoWithFilenameObject( - ffi.Pointer arg0, - ffi.Pointer arg1, + int PyThread_tss_is_created( + ffi.Pointer key, ) { - return _PyErr_SetFromErrnoWithFilenameObject( - arg0, - arg1, + return _PyThread_tss_is_created( + key, ); } - late final _PyErr_SetFromErrnoWithFilenameObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyErr_SetFromErrnoWithFilenameObject'); - late final _PyErr_SetFromErrnoWithFilenameObject = - _PyErr_SetFromErrnoWithFilenameObjectPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final _PyThread_tss_is_createdPtr = + _lookup)>>( + 'PyThread_tss_is_created'); + late final _PyThread_tss_is_created = _PyThread_tss_is_createdPtr.asFunction< + int Function(ffi.Pointer)>(); - ffi.Pointer PyErr_SetFromErrnoWithFilenameObjects( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, + int PyThread_tss_create( + ffi.Pointer key, ) { - return _PyErr_SetFromErrnoWithFilenameObjects( - arg0, - arg1, - arg2, + return _PyThread_tss_create( + key, ); } - late final _PyErr_SetFromErrnoWithFilenameObjectsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyErr_SetFromErrnoWithFilenameObjects'); - late final _PyErr_SetFromErrnoWithFilenameObjects = - _PyErr_SetFromErrnoWithFilenameObjectsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + late final _PyThread_tss_createPtr = + _lookup)>>( + 'PyThread_tss_create'); + late final _PyThread_tss_create = + _PyThread_tss_createPtr.asFunction)>(); - ffi.Pointer PyErr_SetFromErrnoWithFilename( - ffi.Pointer exc, - ffi.Pointer filename, + void PyThread_tss_delete( + ffi.Pointer key, ) { - return _PyErr_SetFromErrnoWithFilename( - exc, - filename, + return _PyThread_tss_delete( + key, ); } - late final _PyErr_SetFromErrnoWithFilenamePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyErr_SetFromErrnoWithFilename'); - late final _PyErr_SetFromErrnoWithFilename = - _PyErr_SetFromErrnoWithFilenamePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final _PyThread_tss_deletePtr = + _lookup)>>( + 'PyThread_tss_delete'); + late final _PyThread_tss_delete = _PyThread_tss_deletePtr.asFunction< + void Function(ffi.Pointer)>(); - ffi.Pointer PyErr_Format( - ffi.Pointer exception, - ffi.Pointer format, + int PyThread_tss_set( + ffi.Pointer key, + ffi.Pointer value, ) { - return _PyErr_Format( - exception, - format, + return _PyThread_tss_set( + key, + value, ); } - late final _PyErr_FormatPtr = _lookup< + late final _PyThread_tss_setPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('PyErr_Format'); - late final _PyErr_Format = _PyErr_FormatPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyThread_tss_set'); + late final _PyThread_tss_set = _PyThread_tss_setPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyErr_FormatV( - ffi.Pointer exception, - ffi.Pointer format, - va_list vargs, + ffi.Pointer PyThread_tss_get( + ffi.Pointer key, ) { - return _PyErr_FormatV( - exception, - format, - vargs, + return _PyThread_tss_get( + key, ); } - late final _PyErr_FormatVPtr = _lookup< + late final _PyThread_tss_getPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, va_list)>>('PyErr_FormatV'); - late final _PyErr_FormatV = _PyErr_FormatVPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, va_list)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyThread_tss_get'); + late final _PyThread_tss_get = _PyThread_tss_getPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyErr_SetImportErrorSubclass( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ffi.Pointer arg3, + int _PyThread_at_fork_reinit( + ffi.Pointer lock, ) { - return _PyErr_SetImportErrorSubclass( - arg0, - arg1, - arg2, - arg3, + return __PyThread_at_fork_reinit( + lock, ); } - late final _PyErr_SetImportErrorSubclassPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyErr_SetImportErrorSubclass'); - late final _PyErr_SetImportErrorSubclass = - _PyErr_SetImportErrorSubclassPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + late final __PyThread_at_fork_reinitPtr = _lookup< + ffi + .NativeFunction)>>( + '_PyThread_at_fork_reinit'); + late final __PyThread_at_fork_reinit = __PyThread_at_fork_reinitPtr + .asFunction)>(); - ffi.Pointer PyErr_SetImportError( + late final ffi.Pointer _PyContext_Type = + _lookup('PyContext_Type'); + + PyTypeObject get PyContext_Type => _PyContext_Type.ref; + + late final ffi.Pointer _PyContextVar_Type = + _lookup('PyContextVar_Type'); + + PyTypeObject get PyContextVar_Type => _PyContextVar_Type.ref; + + late final ffi.Pointer _PyContextToken_Type = + _lookup('PyContextToken_Type'); + + PyTypeObject get PyContextToken_Type => _PyContextToken_Type.ref; + + ffi.Pointer PyContext_New() { + return _PyContext_New(); + } + + late final _PyContext_NewPtr = + _lookup Function()>>( + 'PyContext_New'); + late final _PyContext_New = + _PyContext_NewPtr.asFunction Function()>(); + + ffi.Pointer PyContext_Copy( ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, ) { - return _PyErr_SetImportError( + return _PyContext_Copy( arg0, - arg1, - arg2, ); } - late final _PyErr_SetImportErrorPtr = _lookup< + late final _PyContext_CopyPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyErr_SetImportError'); - late final _PyErr_SetImportError = _PyErr_SetImportErrorPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PyContext_Copy'); + late final _PyContext_Copy = _PyContext_CopyPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - void PyErr_BadInternalCall() { - return _PyErr_BadInternalCall1(); + ffi.Pointer PyContext_CopyCurrent() { + return _PyContext_CopyCurrent(); } - late final _PyErr_BadInternalCallPtr = - _lookup>('PyErr_BadInternalCall'); - late final _PyErr_BadInternalCall1 = - _PyErr_BadInternalCallPtr.asFunction(); + late final _PyContext_CopyCurrentPtr = + _lookup Function()>>( + 'PyContext_CopyCurrent'); + late final _PyContext_CopyCurrent = + _PyContext_CopyCurrentPtr.asFunction Function()>(); - void _PyErr_BadInternalCall( - ffi.Pointer filename, - int lineno, + int PyContext_Enter( + ffi.Pointer arg0, ) { - return __PyErr_BadInternalCall( - filename, - lineno, + return _PyContext_Enter( + arg0, ); } - late final __PyErr_BadInternalCallPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer, ffi.Int)>>('_PyErr_BadInternalCall'); - late final __PyErr_BadInternalCall = __PyErr_BadInternalCallPtr - .asFunction, int)>(); + late final _PyContext_EnterPtr = + _lookup)>>( + 'PyContext_Enter'); + late final _PyContext_Enter = + _PyContext_EnterPtr.asFunction)>(); - ffi.Pointer PyErr_NewException( + int PyContext_Exit( + ffi.Pointer arg0, + ) { + return _PyContext_Exit( + arg0, + ); + } + + late final _PyContext_ExitPtr = + _lookup)>>( + 'PyContext_Exit'); + late final _PyContext_Exit = + _PyContext_ExitPtr.asFunction)>(); + + ffi.Pointer PyContextVar_New( ffi.Pointer name, - ffi.Pointer base, - ffi.Pointer dict, + ffi.Pointer default_value, ) { - return _PyErr_NewException( + return _PyContextVar_New( name, - base, - dict, + default_value, ); } - late final _PyErr_NewExceptionPtr = _lookup< + late final _PyContextVar_NewPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyErr_NewException'); - late final _PyErr_NewException = _PyErr_NewExceptionPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyContextVar_New'); + late final _PyContextVar_New = _PyContextVar_NewPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyErr_NewExceptionWithDoc( - ffi.Pointer name, - ffi.Pointer doc, - ffi.Pointer base, - ffi.Pointer dict, + int PyContextVar_Get( + ffi.Pointer var1, + ffi.Pointer default_value, + ffi.Pointer> value, ) { - return _PyErr_NewExceptionWithDoc( - name, - doc, - base, - dict, + return _PyContextVar_Get( + var1, + default_value, + value, ); } - late final _PyErr_NewExceptionWithDocPtr = _lookup< + late final _PyContextVar_GetPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyErr_NewExceptionWithDoc'); - late final _PyErr_NewExceptionWithDoc = - _PyErr_NewExceptionWithDocPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer>)>>('PyContextVar_Get'); + late final _PyContextVar_Get = _PyContextVar_GetPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer>)>(); - void PyErr_WriteUnraisable( - ffi.Pointer arg0, + ffi.Pointer PyContextVar_Set( + ffi.Pointer var1, + ffi.Pointer value, ) { - return _PyErr_WriteUnraisable( - arg0, + return _PyContextVar_Set( + var1, + value, ); } - late final _PyErr_WriteUnraisablePtr = - _lookup)>>( - 'PyErr_WriteUnraisable'); - late final _PyErr_WriteUnraisable = _PyErr_WriteUnraisablePtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PyContextVar_SetPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyContextVar_Set'); + late final _PyContextVar_Set = _PyContextVar_SetPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyErr_CheckSignals() { - return _PyErr_CheckSignals1(); + int PyContextVar_Reset( + ffi.Pointer var1, + ffi.Pointer token, + ) { + return _PyContextVar_Reset( + var1, + token, + ); } - late final _PyErr_CheckSignalsPtr = - _lookup>('PyErr_CheckSignals'); - late final _PyErr_CheckSignals1 = - _PyErr_CheckSignalsPtr.asFunction(); + late final _PyContextVar_ResetPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyContextVar_Reset'); + late final _PyContextVar_Reset = _PyContextVar_ResetPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - void PyErr_SetInterrupt() { - return _PyErr_SetInterrupt(); + ffi.Pointer _PyContext_NewHamtForTests() { + return __PyContext_NewHamtForTests(); } - late final _PyErr_SetInterruptPtr = - _lookup>('PyErr_SetInterrupt'); - late final _PyErr_SetInterrupt = - _PyErr_SetInterruptPtr.asFunction(); + late final __PyContext_NewHamtForTestsPtr = + _lookup Function()>>( + '_PyContext_NewHamtForTests'); + late final __PyContext_NewHamtForTests = __PyContext_NewHamtForTestsPtr + .asFunction Function()>(); - int PyErr_SetInterruptEx( - int signum, + int PyArg_Parse( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyErr_SetInterruptEx( - signum, + return _PyArg_Parse( + arg0, + arg1, ); } - late final _PyErr_SetInterruptExPtr = - _lookup>( - 'PyErr_SetInterruptEx'); - late final _PyErr_SetInterruptEx = - _PyErr_SetInterruptExPtr.asFunction(); + late final _PyArg_ParsePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, ffi.Pointer)>>('PyArg_Parse'); + late final _PyArg_Parse = _PyArg_ParsePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - void PyErr_SyntaxLocation( - ffi.Pointer filename, - int lineno, + int PyArg_ParseTuple( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyErr_SyntaxLocation( - filename, - lineno, + return _PyArg_ParseTuple( + arg0, + arg1, ); } - late final _PyErr_SyntaxLocationPtr = _lookup< + late final _PyArg_ParseTuplePtr = _lookup< ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer, ffi.Int)>>('PyErr_SyntaxLocation'); - late final _PyErr_SyntaxLocation = _PyErr_SyntaxLocationPtr.asFunction< - void Function(ffi.Pointer, int)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyArg_ParseTuple'); + late final _PyArg_ParseTuple = _PyArg_ParseTuplePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - void PyErr_SyntaxLocationEx( - ffi.Pointer filename, - int lineno, - int col_offset, + int PyArg_ParseTupleAndKeywords( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer> arg3, ) { - return _PyErr_SyntaxLocationEx( - filename, - lineno, - col_offset, + return _PyArg_ParseTupleAndKeywords( + arg0, + arg1, + arg2, + arg3, ); } - late final _PyErr_SyntaxLocationExPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Int, - ffi.Int)>>('PyErr_SyntaxLocationEx'); - late final _PyErr_SyntaxLocationEx = _PyErr_SyntaxLocationExPtr.asFunction< - void Function(ffi.Pointer, int, int)>(); - - ffi.Pointer PyErr_ProgramText( - ffi.Pointer filename, - int lineno, + late final _PyArg_ParseTupleAndKeywordsPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Pointer>)>>( + 'PyArg_ParseTupleAndKeywords'); + late final _PyArg_ParseTupleAndKeywords = + _PyArg_ParseTupleAndKeywordsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Pointer>)>(); + + int PyArg_VaParse( + ffi.Pointer arg0, + ffi.Pointer arg1, + va_list arg2, ) { - return _PyErr_ProgramText( - filename, - lineno, + return _PyArg_VaParse( + arg0, + arg1, + arg2, ); } - late final _PyErr_ProgramTextPtr = _lookup< + late final _PyArg_VaParsePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Int)>>('PyErr_ProgramText'); - late final _PyErr_ProgramText = _PyErr_ProgramTextPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + va_list)>>('PyArg_VaParse'); + late final _PyArg_VaParse = _PyArg_VaParsePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, va_list)>(); - ffi.Pointer PyUnicodeDecodeError_Create( - ffi.Pointer encoding, - ffi.Pointer object, - int length, - int start, - int end, - ffi.Pointer reason, + int PyArg_VaParseTupleAndKeywords( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer> arg3, + va_list arg4, ) { - return _PyUnicodeDecodeError_Create( - encoding, - object, - length, - start, - end, - reason, + return _PyArg_VaParseTupleAndKeywords( + arg0, + arg1, + arg2, + arg3, + arg4, ); } - late final _PyUnicodeDecodeError_CreatePtr = _lookup< + late final _PyArg_VaParseTupleAndKeywordsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, ffi.Pointer, + ffi.Pointer>, + va_list)>>('PyArg_VaParseTupleAndKeywords'); + late final _PyArg_VaParseTupleAndKeywords = + _PyArg_VaParseTupleAndKeywordsPtr.asFunction< + int Function( + ffi.Pointer, + ffi.Pointer, ffi.Pointer, - Py_ssize_t, - Py_ssize_t, - Py_ssize_t, - ffi.Pointer)>>('PyUnicodeDecodeError_Create'); - late final _PyUnicodeDecodeError_Create = - _PyUnicodeDecodeError_CreatePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, int, int, int, ffi.Pointer)>(); + ffi.Pointer>, + va_list)>(); - ffi.Pointer PyUnicodeEncodeError_GetEncoding( + int PyArg_ValidateKeywordArguments( ffi.Pointer arg0, ) { - return _PyUnicodeEncodeError_GetEncoding( + return _PyArg_ValidateKeywordArguments( arg0, ); } - late final _PyUnicodeEncodeError_GetEncodingPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeEncodeError_GetEncoding'); - late final _PyUnicodeEncodeError_GetEncoding = - _PyUnicodeEncodeError_GetEncodingPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + late final _PyArg_ValidateKeywordArgumentsPtr = + _lookup)>>( + 'PyArg_ValidateKeywordArguments'); + late final _PyArg_ValidateKeywordArguments = + _PyArg_ValidateKeywordArgumentsPtr.asFunction< + int Function(ffi.Pointer)>(); - ffi.Pointer PyUnicodeDecodeError_GetEncoding( + int PyArg_UnpackTuple( ffi.Pointer arg0, + ffi.Pointer arg1, + int arg2, + int arg3, ) { - return _PyUnicodeDecodeError_GetEncoding( + return _PyArg_UnpackTuple( arg0, + arg1, + arg2, + arg3, ); } - late final _PyUnicodeDecodeError_GetEncodingPtr = _lookup< + late final _PyArg_UnpackTuplePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeDecodeError_GetEncoding'); - late final _PyUnicodeDecodeError_GetEncoding = - _PyUnicodeDecodeError_GetEncodingPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + Py_ssize_t, Py_ssize_t)>>('PyArg_UnpackTuple'); + late final _PyArg_UnpackTuple = _PyArg_UnpackTuplePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, int)>(); - ffi.Pointer PyUnicodeEncodeError_GetObject( - ffi.Pointer arg0, + ffi.Pointer Py_BuildValue( + ffi.Pointer arg0, ) { - return _PyUnicodeEncodeError_GetObject( + return _Py_BuildValue( arg0, ); } - late final _PyUnicodeEncodeError_GetObjectPtr = _lookup< + late final _Py_BuildValuePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeEncodeError_GetObject'); - late final _PyUnicodeEncodeError_GetObject = - _PyUnicodeEncodeError_GetObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer)>>('Py_BuildValue'); + late final _Py_BuildValue = _Py_BuildValuePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyUnicodeDecodeError_GetObject( - ffi.Pointer arg0, + ffi.Pointer _Py_BuildValue_SizeT( + ffi.Pointer arg0, ) { - return _PyUnicodeDecodeError_GetObject( + return __Py_BuildValue_SizeT( arg0, ); } - late final _PyUnicodeDecodeError_GetObjectPtr = _lookup< + late final __Py_BuildValue_SizeTPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeDecodeError_GetObject'); - late final _PyUnicodeDecodeError_GetObject = - _PyUnicodeDecodeError_GetObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer)>>('_Py_BuildValue_SizeT'); + late final __Py_BuildValue_SizeT = __Py_BuildValue_SizeTPtr + .asFunction Function(ffi.Pointer)>(); - ffi.Pointer PyUnicodeTranslateError_GetObject( - ffi.Pointer arg0, + ffi.Pointer Py_VaBuildValue( + ffi.Pointer arg0, + va_list arg1, ) { - return _PyUnicodeTranslateError_GetObject( + return _Py_VaBuildValue( arg0, + arg1, ); } - late final _PyUnicodeTranslateError_GetObjectPtr = _lookup< + late final _Py_VaBuildValuePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeTranslateError_GetObject'); - late final _PyUnicodeTranslateError_GetObject = - _PyUnicodeTranslateError_GetObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer, va_list)>>('Py_VaBuildValue'); + late final _Py_VaBuildValue = _Py_VaBuildValuePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, va_list)>(); - int PyUnicodeEncodeError_GetStart( - ffi.Pointer arg0, - ffi.Pointer arg1, + int PyModule_AddObjectRef( + ffi.Pointer mod, + ffi.Pointer name, + ffi.Pointer value, ) { - return _PyUnicodeEncodeError_GetStart( - arg0, + return _PyModule_AddObjectRef( + mod, + name, + value, + ); + } + + late final _PyModule_AddObjectRefPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyModule_AddObjectRef'); + late final _PyModule_AddObjectRef = _PyModule_AddObjectRefPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); + + int PyModule_AddObject( + ffi.Pointer mod, + ffi.Pointer arg1, + ffi.Pointer value, + ) { + return _PyModule_AddObject( + mod, arg1, + value, ); } - late final _PyUnicodeEncodeError_GetStartPtr = _lookup< + late final _PyModule_AddObjectPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeEncodeError_GetStart'); - late final _PyUnicodeEncodeError_GetStart = - _PyUnicodeEncodeError_GetStartPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyModule_AddObject'); + late final _PyModule_AddObject = _PyModule_AddObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - int PyUnicodeDecodeError_GetStart( + int PyModule_AddIntConstant( ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer arg1, + int arg2, ) { - return _PyUnicodeDecodeError_GetStart( + return _PyModule_AddIntConstant( arg0, arg1, + arg2, ); } - late final _PyUnicodeDecodeError_GetStartPtr = _lookup< + late final _PyModule_AddIntConstantPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeDecodeError_GetStart'); - late final _PyUnicodeDecodeError_GetStart = - _PyUnicodeDecodeError_GetStartPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Long)>>('PyModule_AddIntConstant'); + late final _PyModule_AddIntConstant = _PyModule_AddIntConstantPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - int PyUnicodeTranslateError_GetStart( + int PyModule_AddStringConstant( ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyUnicodeTranslateError_GetStart( + return _PyModule_AddStringConstant( arg0, arg1, + arg2, ); } - late final _PyUnicodeTranslateError_GetStartPtr = _lookup< + late final _PyModule_AddStringConstantPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyModule_AddStringConstant'); + late final _PyModule_AddStringConstant = + _PyModule_AddStringConstantPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); + + int PyModule_AddType( + ffi.Pointer module, + ffi.Pointer type, + ) { + return _PyModule_AddType( + module, + type, + ); + } + + late final _PyModule_AddTypePtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeTranslateError_GetStart'); - late final _PyUnicodeTranslateError_GetStart = - _PyUnicodeTranslateError_GetStartPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PyModule_AddType'); + late final _PyModule_AddType = _PyModule_AddTypePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyUnicodeEncodeError_SetStart( + int PyModule_SetDocString( ffi.Pointer arg0, - int arg1, + ffi.Pointer arg1, ) { - return _PyUnicodeEncodeError_SetStart( + return _PyModule_SetDocString( arg0, arg1, ); } - late final _PyUnicodeEncodeError_SetStartPtr = _lookup< + late final _PyModule_SetDocStringPtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicodeEncodeError_SetStart'); - late final _PyUnicodeEncodeError_SetStart = _PyUnicodeEncodeError_SetStartPtr - .asFunction, int)>(); + ffi.Pointer)>>('PyModule_SetDocString'); + late final _PyModule_SetDocString = _PyModule_SetDocStringPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyUnicodeDecodeError_SetStart( + int PyModule_AddFunctions( ffi.Pointer arg0, - int arg1, + ffi.Pointer arg1, ) { - return _PyUnicodeDecodeError_SetStart( + return _PyModule_AddFunctions( arg0, arg1, ); } - late final _PyUnicodeDecodeError_SetStartPtr = _lookup< + late final _PyModule_AddFunctionsPtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicodeDecodeError_SetStart'); - late final _PyUnicodeDecodeError_SetStart = _PyUnicodeDecodeError_SetStartPtr - .asFunction, int)>(); + ffi.Pointer)>>('PyModule_AddFunctions'); + late final _PyModule_AddFunctions = _PyModule_AddFunctionsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyUnicodeTranslateError_SetStart( - ffi.Pointer arg0, - int arg1, + int PyModule_ExecDef( + ffi.Pointer module, + ffi.Pointer def, ) { - return _PyUnicodeTranslateError_SetStart( - arg0, - arg1, + return _PyModule_ExecDef( + module, + def, ); } - late final _PyUnicodeTranslateError_SetStartPtr = _lookup< + late final _PyModule_ExecDefPtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicodeTranslateError_SetStart'); - late final _PyUnicodeTranslateError_SetStart = - _PyUnicodeTranslateError_SetStartPtr.asFunction< - int Function(ffi.Pointer, int)>(); + ffi.Pointer)>>('PyModule_ExecDef'); + late final _PyModule_ExecDef = _PyModule_ExecDefPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyUnicodeEncodeError_GetEnd( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyModule_Create2( + ffi.Pointer arg0, + int apiver, ) { - return _PyUnicodeEncodeError_GetEnd( + return _PyModule_Create2( arg0, - arg1, + apiver, ); } - late final _PyUnicodeEncodeError_GetEndPtr = _lookup< + late final _PyModule_Create2Ptr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeEncodeError_GetEnd'); - late final _PyUnicodeEncodeError_GetEnd = - _PyUnicodeEncodeError_GetEndPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, ffi.Int)>>('PyModule_Create2'); + late final _PyModule_Create2 = _PyModule_Create2Ptr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - int PyUnicodeDecodeError_GetEnd( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyModule_FromDefAndSpec2( + ffi.Pointer def, + ffi.Pointer spec, + int module_api_version, ) { - return _PyUnicodeDecodeError_GetEnd( - arg0, - arg1, + return _PyModule_FromDefAndSpec2( + def, + spec, + module_api_version, ); } - late final _PyUnicodeDecodeError_GetEndPtr = _lookup< + late final _PyModule_FromDefAndSpec2Ptr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeDecodeError_GetEnd'); - late final _PyUnicodeDecodeError_GetEnd = - _PyUnicodeDecodeError_GetEndPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Int)>>('PyModule_FromDefAndSpec2'); + late final _PyModule_FromDefAndSpec2 = + _PyModule_FromDefAndSpec2Ptr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, int)>(); - int PyUnicodeTranslateError_GetEnd( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer _Py_VaBuildValue_SizeT( + ffi.Pointer arg0, + va_list arg1, ) { - return _PyUnicodeTranslateError_GetEnd( + return __Py_VaBuildValue_SizeT( arg0, arg1, ); } - late final _PyUnicodeTranslateError_GetEndPtr = _lookup< + late final __Py_VaBuildValue_SizeTPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeTranslateError_GetEnd'); - late final _PyUnicodeTranslateError_GetEnd = - _PyUnicodeTranslateError_GetEndPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, va_list)>>('_Py_VaBuildValue_SizeT'); + late final __Py_VaBuildValue_SizeT = __Py_VaBuildValue_SizeTPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, va_list)>(); - int PyUnicodeEncodeError_SetEnd( - ffi.Pointer arg0, - int arg1, + ffi.Pointer> _Py_VaBuildStack_SizeT( + ffi.Pointer> small_stack, + int small_stack_len, + ffi.Pointer format, + va_list va, + ffi.Pointer p_nargs, ) { - return _PyUnicodeEncodeError_SetEnd( - arg0, - arg1, + return __Py_VaBuildStack_SizeT( + small_stack, + small_stack_len, + format, + va, + p_nargs, ); } - late final _PyUnicodeEncodeError_SetEndPtr = _lookup< + late final __Py_VaBuildStack_SizeTPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicodeEncodeError_SetEnd'); - late final _PyUnicodeEncodeError_SetEnd = _PyUnicodeEncodeError_SetEndPtr - .asFunction, int)>(); + ffi.Pointer> Function( + ffi.Pointer>, + Py_ssize_t, + ffi.Pointer, + va_list, + ffi.Pointer)>>('_Py_VaBuildStack_SizeT'); + late final __Py_VaBuildStack_SizeT = __Py_VaBuildStack_SizeTPtr.asFunction< + ffi.Pointer> Function( + ffi.Pointer>, + int, + ffi.Pointer, + va_list, + ffi.Pointer)>(); - int PyUnicodeDecodeError_SetEnd( - ffi.Pointer arg0, - int arg1, + int _PyArg_UnpackStack( + ffi.Pointer> args, + int nargs, + ffi.Pointer name, + int min, + int max, ) { - return _PyUnicodeDecodeError_SetEnd( - arg0, - arg1, + return __PyArg_UnpackStack( + args, + nargs, + name, + min, + max, ); } - late final _PyUnicodeDecodeError_SetEndPtr = _lookup< + late final __PyArg_UnpackStackPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicodeDecodeError_SetEnd'); - late final _PyUnicodeDecodeError_SetEnd = _PyUnicodeDecodeError_SetEndPtr - .asFunction, int)>(); + ffi.Int Function( + ffi.Pointer>, + Py_ssize_t, + ffi.Pointer, + Py_ssize_t, + Py_ssize_t)>>('_PyArg_UnpackStack'); + late final __PyArg_UnpackStack = __PyArg_UnpackStackPtr.asFunction< + int Function(ffi.Pointer>, int, + ffi.Pointer, int, int)>(); - int PyUnicodeTranslateError_SetEnd( - ffi.Pointer arg0, - int arg1, + int _PyArg_NoKeywords( + ffi.Pointer funcname, + ffi.Pointer kwargs, ) { - return _PyUnicodeTranslateError_SetEnd( - arg0, - arg1, + return __PyArg_NoKeywords( + funcname, + kwargs, ); } - late final _PyUnicodeTranslateError_SetEndPtr = _lookup< + late final __PyArg_NoKeywordsPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - Py_ssize_t)>>('PyUnicodeTranslateError_SetEnd'); - late final _PyUnicodeTranslateError_SetEnd = - _PyUnicodeTranslateError_SetEndPtr.asFunction< - int Function(ffi.Pointer, int)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyArg_NoKeywords'); + late final __PyArg_NoKeywords = __PyArg_NoKeywordsPtr + .asFunction, ffi.Pointer)>(); - ffi.Pointer PyUnicodeEncodeError_GetReason( - ffi.Pointer arg0, + int _PyArg_NoKwnames( + ffi.Pointer funcname, + ffi.Pointer kwnames, ) { - return _PyUnicodeEncodeError_GetReason( - arg0, + return __PyArg_NoKwnames( + funcname, + kwnames, ); } - late final _PyUnicodeEncodeError_GetReasonPtr = _lookup< + late final __PyArg_NoKwnamesPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeEncodeError_GetReason'); - late final _PyUnicodeEncodeError_GetReason = - _PyUnicodeEncodeError_GetReasonPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyArg_NoKwnames'); + late final __PyArg_NoKwnames = __PyArg_NoKwnamesPtr + .asFunction, ffi.Pointer)>(); - ffi.Pointer PyUnicodeDecodeError_GetReason( - ffi.Pointer arg0, + int _PyArg_NoPositional( + ffi.Pointer funcname, + ffi.Pointer args, ) { - return _PyUnicodeDecodeError_GetReason( - arg0, + return __PyArg_NoPositional( + funcname, + args, ); } - late final _PyUnicodeDecodeError_GetReasonPtr = _lookup< + late final __PyArg_NoPositionalPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeDecodeError_GetReason'); - late final _PyUnicodeDecodeError_GetReason = - _PyUnicodeDecodeError_GetReasonPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyArg_NoPositional'); + late final __PyArg_NoPositional = __PyArg_NoPositionalPtr + .asFunction, ffi.Pointer)>(); - ffi.Pointer PyUnicodeTranslateError_GetReason( - ffi.Pointer arg0, + void _PyArg_BadArgument( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, ) { - return _PyUnicodeTranslateError_GetReason( + return __PyArg_BadArgument( arg0, + arg1, + arg2, + arg3, ); } - late final _PyUnicodeTranslateError_GetReasonPtr = _lookup< + late final __PyArg_BadArgumentPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyUnicodeTranslateError_GetReason'); - late final _PyUnicodeTranslateError_GetReason = - _PyUnicodeTranslateError_GetReasonPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Void Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_PyArg_BadArgument'); + late final __PyArg_BadArgument = __PyArg_BadArgumentPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - int PyUnicodeEncodeError_SetReason( - ffi.Pointer exc, - ffi.Pointer reason, + int _PyArg_CheckPositional( + ffi.Pointer arg0, + int arg1, + int arg2, + int arg3, ) { - return _PyUnicodeEncodeError_SetReason( - exc, - reason, + return __PyArg_CheckPositional( + arg0, + arg1, + arg2, + arg3, ); } - late final _PyUnicodeEncodeError_SetReasonPtr = _lookup< + late final __PyArg_CheckPositionalPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeEncodeError_SetReason'); - late final _PyUnicodeEncodeError_SetReason = - _PyUnicodeEncodeError_SetReasonPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, Py_ssize_t, Py_ssize_t, + Py_ssize_t)>>('_PyArg_CheckPositional'); + late final __PyArg_CheckPositional = __PyArg_CheckPositionalPtr + .asFunction, int, int, int)>(); - int PyUnicodeDecodeError_SetReason( - ffi.Pointer exc, - ffi.Pointer reason, + ffi.Pointer> _Py_VaBuildStack( + ffi.Pointer> small_stack, + int small_stack_len, + ffi.Pointer format, + va_list va, + ffi.Pointer p_nargs, ) { - return _PyUnicodeDecodeError_SetReason( - exc, - reason, + return __Py_VaBuildStack( + small_stack, + small_stack_len, + format, + va, + p_nargs, ); } - late final _PyUnicodeDecodeError_SetReasonPtr = _lookup< + late final __Py_VaBuildStackPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeDecodeError_SetReason'); - late final _PyUnicodeDecodeError_SetReason = - _PyUnicodeDecodeError_SetReasonPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer> Function( + ffi.Pointer>, + Py_ssize_t, + ffi.Pointer, + va_list, + ffi.Pointer)>>('_Py_VaBuildStack'); + late final __Py_VaBuildStack = __Py_VaBuildStackPtr.asFunction< + ffi.Pointer> Function( + ffi.Pointer>, + int, + ffi.Pointer, + va_list, + ffi.Pointer)>(); - int PyUnicodeTranslateError_SetReason( - ffi.Pointer exc, - ffi.Pointer reason, + int _PyArg_ParseTupleAndKeywordsFast( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer<_PyArg_Parser> arg2, ) { - return _PyUnicodeTranslateError_SetReason( - exc, - reason, + return __PyArg_ParseTupleAndKeywordsFast( + arg0, + arg1, + arg2, ); } - late final _PyUnicodeTranslateError_SetReasonPtr = _lookup< + late final __PyArg_ParseTupleAndKeywordsFastPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyUnicodeTranslateError_SetReason'); - late final _PyUnicodeTranslateError_SetReason = - _PyUnicodeTranslateError_SetReasonPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer<_PyArg_Parser>)>>('_PyArg_ParseTupleAndKeywordsFast'); + late final __PyArg_ParseTupleAndKeywordsFast = + __PyArg_ParseTupleAndKeywordsFastPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer<_PyArg_Parser>)>(); - int PyOS_snprintf( - ffi.Pointer str, - int size, + int _PyArg_ParseStack( + ffi.Pointer> args, + int nargs, ffi.Pointer format, ) { - return _PyOS_snprintf( - str, - size, + return __PyArg_ParseStack( + args, + nargs, format, ); } - late final _PyOS_snprintfPtr = _lookup< + late final __PyArg_ParseStackPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Size, - ffi.Pointer)>>('PyOS_snprintf'); - late final _PyOS_snprintf = _PyOS_snprintfPtr.asFunction< - int Function(ffi.Pointer, int, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer>, Py_ssize_t, + ffi.Pointer)>>('_PyArg_ParseStack'); + late final __PyArg_ParseStack = __PyArg_ParseStackPtr.asFunction< + int Function( + ffi.Pointer>, int, ffi.Pointer)>(); - int PyOS_vsnprintf( - ffi.Pointer str, - int size, - ffi.Pointer format, - va_list va, + int _PyArg_ParseStackAndKeywords( + ffi.Pointer> args, + int nargs, + ffi.Pointer kwnames, + ffi.Pointer<_PyArg_Parser> arg3, ) { - return _PyOS_vsnprintf( - str, - size, - format, - va, + return __PyArg_ParseStackAndKeywords( + args, + nargs, + kwnames, + arg3, ); } - late final _PyOS_vsnprintfPtr = _lookup< + late final __PyArg_ParseStackAndKeywordsPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Size, - ffi.Pointer, va_list)>>('PyOS_vsnprintf'); - late final _PyOS_vsnprintf = _PyOS_vsnprintfPtr.asFunction< - int Function( - ffi.Pointer, int, ffi.Pointer, va_list)>(); + ffi.Int Function( + ffi.Pointer>, + Py_ssize_t, + ffi.Pointer, + ffi.Pointer<_PyArg_Parser>)>>('_PyArg_ParseStackAndKeywords'); + late final __PyArg_ParseStackAndKeywords = + __PyArg_ParseStackAndKeywordsPtr.asFunction< + int Function(ffi.Pointer>, int, + ffi.Pointer, ffi.Pointer<_PyArg_Parser>)>(); - void _PyErr_SetKeyError( + int _PyArg_VaParseTupleAndKeywordsFast( ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer<_PyArg_Parser> arg2, + va_list arg3, ) { - return __PyErr_SetKeyError( + return __PyArg_VaParseTupleAndKeywordsFast( arg0, + arg1, + arg2, + arg3, ); } - late final __PyErr_SetKeyErrorPtr = - _lookup)>>( - '_PyErr_SetKeyError'); - late final __PyErr_SetKeyError = - __PyErr_SetKeyErrorPtr.asFunction)>(); + late final __PyArg_VaParseTupleAndKeywordsFastPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer<_PyArg_Parser>, + va_list)>>('_PyArg_VaParseTupleAndKeywordsFast'); + late final __PyArg_VaParseTupleAndKeywordsFast = + __PyArg_VaParseTupleAndKeywordsFastPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer<_PyArg_Parser>, va_list)>(); - ffi.Pointer<_PyErr_StackItem> _PyErr_GetTopmostException( - ffi.Pointer tstate, + ffi.Pointer> _PyArg_UnpackKeywords( + ffi.Pointer> args, + int nargs, + ffi.Pointer kwargs, + ffi.Pointer kwnames, + ffi.Pointer<_PyArg_Parser> parser, + int minpos, + int maxpos, + int minkw, + ffi.Pointer> buf, ) { - return __PyErr_GetTopmostException( - tstate, + return __PyArg_UnpackKeywords( + args, + nargs, + kwargs, + kwnames, + parser, + minpos, + maxpos, + minkw, + buf, + ); + } + + late final __PyArg_UnpackKeywordsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer> Function( + ffi.Pointer>, + Py_ssize_t, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer<_PyArg_Parser>, + ffi.Int, + ffi.Int, + ffi.Int, + ffi.Pointer>)>>('_PyArg_UnpackKeywords'); + late final __PyArg_UnpackKeywords = __PyArg_UnpackKeywordsPtr.asFunction< + ffi.Pointer> Function( + ffi.Pointer>, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer<_PyArg_Parser>, + int, + int, + int, + ffi.Pointer>)>(); + + ffi.Pointer> _PyArg_UnpackKeywordsWithVararg( + ffi.Pointer> args, + int nargs, + ffi.Pointer kwargs, + ffi.Pointer kwnames, + ffi.Pointer<_PyArg_Parser> parser, + int minpos, + int maxpos, + int minkw, + int vararg, + ffi.Pointer> buf, + ) { + return __PyArg_UnpackKeywordsWithVararg( + args, + nargs, + kwargs, + kwnames, + parser, + minpos, + maxpos, + minkw, + vararg, + buf, ); } - late final __PyErr_GetTopmostExceptionPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer<_PyErr_StackItem> Function( - ffi.Pointer)>>('_PyErr_GetTopmostException'); - late final __PyErr_GetTopmostException = - __PyErr_GetTopmostExceptionPtr.asFunction< - ffi.Pointer<_PyErr_StackItem> Function(ffi.Pointer)>(); + late final __PyArg_UnpackKeywordsWithVarargPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer> Function( + ffi.Pointer>, + Py_ssize_t, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer<_PyArg_Parser>, + ffi.Int, + ffi.Int, + ffi.Int, + ffi.Int, + ffi.Pointer>)>>( + '_PyArg_UnpackKeywordsWithVararg'); + late final __PyArg_UnpackKeywordsWithVararg = + __PyArg_UnpackKeywordsWithVarargPtr.asFunction< + ffi.Pointer> Function( + ffi.Pointer>, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer<_PyArg_Parser>, + int, + int, + int, + int, + ffi.Pointer>)>(); - void _PyErr_GetExcInfo( - ffi.Pointer arg0, - ffi.Pointer> arg1, - ffi.Pointer> arg2, - ffi.Pointer> arg3, + ffi.Pointer _PyModule_CreateInitialized( + ffi.Pointer arg0, + int apiver, ) { - return __PyErr_GetExcInfo( + return __PyModule_CreateInitialized( arg0, - arg1, - arg2, - arg3, + apiver, ); } - late final __PyErr_GetExcInfoPtr = _lookup< + late final __PyModule_CreateInitializedPtr = _lookup< ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>>('_PyErr_GetExcInfo'); - late final __PyErr_GetExcInfo = __PyErr_GetExcInfoPtr.asFunction< - void Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer>, - ffi.Pointer>)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Int)>>('_PyModule_CreateInitialized'); + late final __PyModule_CreateInitialized = + __PyModule_CreateInitializedPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - void _PyErr_ChainExceptions( + int _PyModule_Add( ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer arg1, ffi.Pointer arg2, ) { - return __PyErr_ChainExceptions( + return __PyModule_Add( arg0, arg1, arg2, ); } - late final __PyErr_ChainExceptionsPtr = _lookup< + late final __PyModule_AddPtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('_PyErr_ChainExceptions'); - late final __PyErr_ChainExceptions = __PyErr_ChainExceptionsPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer, + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('_PyModule_Add'); + late final __PyModule_Add = __PyModule_AddPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyErr_FormatFromCause( - ffi.Pointer exception, - ffi.Pointer format, - ) { - return __PyErr_FormatFromCause( - exception, - format, - ); - } + late final ffi.Pointer> __Py_PackageContext = + _lookup>('_Py_PackageContext'); - late final __PyErr_FormatFromCausePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyErr_FormatFromCause'); - late final __PyErr_FormatFromCause = __PyErr_FormatFromCausePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer get _Py_PackageContext => __Py_PackageContext.value; - ffi.Pointer _PyErr_TrySetFromCause( - ffi.Pointer prefix_format, + set _Py_PackageContext(ffi.Pointer value) => + __Py_PackageContext.value = value; + + int PyCompile_OpcodeStackEffect( + int opcode, + int oparg, ) { - return __PyErr_TrySetFromCause( - prefix_format, + return _PyCompile_OpcodeStackEffect( + opcode, + oparg, ); } - late final __PyErr_TrySetFromCausePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_PyErr_TrySetFromCause'); - late final __PyErr_TrySetFromCause = __PyErr_TrySetFromCausePtr - .asFunction Function(ffi.Pointer)>(); + late final _PyCompile_OpcodeStackEffectPtr = + _lookup>( + 'PyCompile_OpcodeStackEffect'); + late final _PyCompile_OpcodeStackEffect = + _PyCompile_OpcodeStackEffectPtr.asFunction(); - int PySignal_SetWakeupFd( - int fd, + int PyCompile_OpcodeStackEffectWithJump( + int opcode, + int oparg, + int jump, ) { - return _PySignal_SetWakeupFd( - fd, + return _PyCompile_OpcodeStackEffectWithJump( + opcode, + oparg, + jump, ); } - late final _PySignal_SetWakeupFdPtr = - _lookup>( - 'PySignal_SetWakeupFd'); - late final _PySignal_SetWakeupFd = - _PySignal_SetWakeupFdPtr.asFunction(); - - int _PyErr_CheckSignals() { - return __PyErr_CheckSignals(); - } - - late final __PyErr_CheckSignalsPtr = - _lookup>('_PyErr_CheckSignals'); - late final __PyErr_CheckSignals = - __PyErr_CheckSignalsPtr.asFunction(); + late final _PyCompile_OpcodeStackEffectWithJumpPtr = + _lookup>( + 'PyCompile_OpcodeStackEffectWithJump'); + late final _PyCompile_OpcodeStackEffectWithJump = + _PyCompile_OpcodeStackEffectWithJumpPtr.asFunction< + int Function(int, int, int)>(); - void PyErr_SyntaxLocationObject( - ffi.Pointer filename, - int lineno, - int col_offset, + ffi.Pointer Py_CompileString( + ffi.Pointer arg0, + ffi.Pointer arg1, + int arg2, ) { - return _PyErr_SyntaxLocationObject( - filename, - lineno, - col_offset, + return _Py_CompileString( + arg0, + arg1, + arg2, ); } - late final _PyErr_SyntaxLocationObjectPtr = _lookup< + late final _Py_CompileStringPtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Int, - ffi.Int)>>('PyErr_SyntaxLocationObject'); - late final _PyErr_SyntaxLocationObject = _PyErr_SyntaxLocationObjectPtr - .asFunction, int, int)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Int)>>('Py_CompileString'); + late final _Py_CompileString = _Py_CompileStringPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, int)>(); - void PyErr_RangedSyntaxLocationObject( - ffi.Pointer filename, - int lineno, - int col_offset, - int end_lineno, - int end_col_offset, - ) { - return _PyErr_RangedSyntaxLocationObject( - filename, - lineno, - col_offset, - end_lineno, - end_col_offset, - ); + void PyErr_Print() { + return _PyErr_Print(); } - late final _PyErr_RangedSyntaxLocationObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Int, ffi.Int, ffi.Int, - ffi.Int)>>('PyErr_RangedSyntaxLocationObject'); - late final _PyErr_RangedSyntaxLocationObject = - _PyErr_RangedSyntaxLocationObjectPtr.asFunction< - void Function(ffi.Pointer, int, int, int, int)>(); + late final _PyErr_PrintPtr = + _lookup>('PyErr_Print'); + late final _PyErr_Print = _PyErr_PrintPtr.asFunction(); - ffi.Pointer PyErr_ProgramTextObject( - ffi.Pointer filename, - int lineno, + void PyErr_PrintEx( + int arg0, ) { - return _PyErr_ProgramTextObject( - filename, - lineno, + return _PyErr_PrintEx( + arg0, ); } - late final _PyErr_ProgramTextObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Int)>>('PyErr_ProgramTextObject'); - late final _PyErr_ProgramTextObject = _PyErr_ProgramTextObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + late final _PyErr_PrintExPtr = + _lookup>('PyErr_PrintEx'); + late final _PyErr_PrintEx = + _PyErr_PrintExPtr.asFunction(); - ffi.Pointer PyUnicodeEncodeError_Create( - ffi.Pointer encoding, - ffi.Pointer object, - int length, - int start, - int end, - ffi.Pointer reason, + void PyErr_Display( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyUnicodeEncodeError_Create( - encoding, - object, - length, - start, - end, - reason, + return _PyErr_Display( + arg0, + arg1, + arg2, ); } - late final _PyUnicodeEncodeError_CreatePtr = _lookup< + late final _PyErr_DisplayPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - Py_ssize_t, - Py_ssize_t, - Py_ssize_t, - ffi.Pointer)>>('PyUnicodeEncodeError_Create'); - late final _PyUnicodeEncodeError_Create = - _PyUnicodeEncodeError_CreatePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, int, int, int, ffi.Pointer)>(); + ffi.Void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyErr_Display'); + late final _PyErr_Display = _PyErr_DisplayPtr.asFunction< + void Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); + + late final ffi.Pointer>> + _PyOS_InputHook = + _lookup>>( + 'PyOS_InputHook'); + + ffi.Pointer> get PyOS_InputHook => + _PyOS_InputHook.value; - ffi.Pointer PyUnicodeTranslateError_Create( - ffi.Pointer object, - int length, - int start, - int end, - ffi.Pointer reason, + set PyOS_InputHook( + ffi.Pointer> value) => + _PyOS_InputHook.value = value; + + int PyRun_SimpleStringFlags( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyUnicodeTranslateError_Create1( - object, - length, - start, - end, - reason, + return _PyRun_SimpleStringFlags( + arg0, + arg1, ); } - late final _PyUnicodeTranslateError_CreatePtr = _lookup< + late final _PyRun_SimpleStringFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - Py_ssize_t, - Py_ssize_t, - ffi.Pointer)>>('PyUnicodeTranslateError_Create'); - late final _PyUnicodeTranslateError_Create1 = - _PyUnicodeTranslateError_CreatePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, int, int, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyRun_SimpleStringFlags'); + late final _PyRun_SimpleStringFlags = _PyRun_SimpleStringFlagsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyErr_ProgramDecodedTextObject( + int _PyRun_SimpleFileObject( + ffi.Pointer fp, ffi.Pointer filename, - int lineno, - ffi.Pointer encoding, + int closeit, + ffi.Pointer flags, ) { - return __PyErr_ProgramDecodedTextObject( + return __PyRun_SimpleFileObject( + fp, filename, - lineno, - encoding, + closeit, + flags, ); } - late final __PyErr_ProgramDecodedTextObjectPtr = _lookup< + late final __PyRun_SimpleFileObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, ffi.Int, - ffi.Pointer)>>('_PyErr_ProgramDecodedTextObject'); - late final __PyErr_ProgramDecodedTextObject = - __PyErr_ProgramDecodedTextObjectPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, + ffi.Pointer)>>('_PyRun_SimpleFileObject'); + late final __PyRun_SimpleFileObject = __PyRun_SimpleFileObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, + ffi.Pointer)>(); - ffi.Pointer _PyUnicodeTranslateError_Create( - ffi.Pointer object, - int start, - int end, - ffi.Pointer reason, + int PyRun_AnyFileExFlags( + ffi.Pointer fp, + ffi.Pointer filename, + int closeit, + ffi.Pointer flags, ) { - return __PyUnicodeTranslateError_Create( - object, - start, - end, - reason, + return _PyRun_AnyFileExFlags( + fp, + filename, + closeit, + flags, ); } - late final __PyUnicodeTranslateError_CreatePtr = _lookup< + late final _PyRun_AnyFileExFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - Py_ssize_t, - ffi.Pointer)>>('_PyUnicodeTranslateError_Create'); - late final __PyUnicodeTranslateError_Create = - __PyUnicodeTranslateError_CreatePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, int, int, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, + ffi.Pointer)>>('PyRun_AnyFileExFlags'); + late final _PyRun_AnyFileExFlags = _PyRun_AnyFileExFlagsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, + ffi.Pointer)>(); - void _PyErr_WriteUnraisableMsg( - ffi.Pointer err_msg, - ffi.Pointer obj, + int _PyRun_AnyFileObject( + ffi.Pointer fp, + ffi.Pointer filename, + int closeit, + ffi.Pointer flags, ) { - return __PyErr_WriteUnraisableMsg( - err_msg, - obj, + return __PyRun_AnyFileObject( + fp, + filename, + closeit, + flags, ); } - late final __PyErr_WriteUnraisableMsgPtr = _lookup< + late final __PyRun_AnyFileObjectPtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('_PyErr_WriteUnraisableMsg'); - late final __PyErr_WriteUnraisableMsg = - __PyErr_WriteUnraisableMsgPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, + ffi.Pointer)>>('_PyRun_AnyFileObject'); + late final __PyRun_AnyFileObject = __PyRun_AnyFileObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, + ffi.Pointer)>(); - void _Py_FatalErrorFunc( - ffi.Pointer func, - ffi.Pointer message, + int PyRun_SimpleFileExFlags( + ffi.Pointer fp, + ffi.Pointer filename, + int closeit, + ffi.Pointer flags, ) { - return __Py_FatalErrorFunc( - func, - message, + return _PyRun_SimpleFileExFlags( + fp, + filename, + closeit, + flags, ); } - late final __Py_FatalErrorFuncPtr = _lookup< + late final _PyRun_SimpleFileExFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('_Py_FatalErrorFunc'); - late final __Py_FatalErrorFunc = __Py_FatalErrorFuncPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, + ffi.Pointer)>>('PyRun_SimpleFileExFlags'); + late final _PyRun_SimpleFileExFlags = _PyRun_SimpleFileExFlagsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int, + ffi.Pointer)>(); - void _Py_FatalErrorFormat( - ffi.Pointer func, - ffi.Pointer format, + int PyRun_InteractiveOneFlags( + ffi.Pointer fp, + ffi.Pointer filename, + ffi.Pointer flags, ) { - return __Py_FatalErrorFormat( - func, - format, + return _PyRun_InteractiveOneFlags( + fp, + filename, + flags, ); } - late final __Py_FatalErrorFormatPtr = _lookup< + late final _PyRun_InteractiveOneFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, - ffi.Pointer)>>('_Py_FatalErrorFormat'); - late final __Py_FatalErrorFormat = __Py_FatalErrorFormatPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer)>(); - - void PyThread_init_thread() { - return _PyThread_init_thread(); - } - - late final _PyThread_init_threadPtr = - _lookup>('PyThread_init_thread'); - late final _PyThread_init_thread = - _PyThread_init_threadPtr.asFunction(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyRun_InteractiveOneFlags'); + late final _PyRun_InteractiveOneFlags = + _PyRun_InteractiveOneFlagsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - int PyThread_start_new_thread( - ffi.Pointer)>> - arg0, - ffi.Pointer arg1, + int PyRun_InteractiveOneObject( + ffi.Pointer fp, + ffi.Pointer filename, + ffi.Pointer flags, ) { - return _PyThread_start_new_thread( - arg0, - arg1, + return _PyRun_InteractiveOneObject( + fp, + filename, + flags, ); } - late final _PyThread_start_new_threadPtr = _lookup< + late final _PyRun_InteractiveOneObjectPtr = _lookup< ffi.NativeFunction< - ffi.UnsignedLong Function( - ffi.Pointer< - ffi.NativeFunction)>>, - ffi.Pointer)>>('PyThread_start_new_thread'); - late final _PyThread_start_new_thread = - _PyThread_start_new_threadPtr.asFunction< - int Function( - ffi.Pointer< - ffi.NativeFunction)>>, - ffi.Pointer)>(); - - void PyThread_exit_thread() { - return _PyThread_exit_thread(); - } - - late final _PyThread_exit_threadPtr = - _lookup>('PyThread_exit_thread'); - late final _PyThread_exit_thread = - _PyThread_exit_threadPtr.asFunction(); - - int PyThread_get_thread_ident() { - return _PyThread_get_thread_ident(); - } - - late final _PyThread_get_thread_identPtr = - _lookup>( - 'PyThread_get_thread_ident'); - late final _PyThread_get_thread_ident = - _PyThread_get_thread_identPtr.asFunction(); - - int PyThread_get_thread_native_id() { - return _PyThread_get_thread_native_id(); - } - - late final _PyThread_get_thread_native_idPtr = - _lookup>( - 'PyThread_get_thread_native_id'); - late final _PyThread_get_thread_native_id = - _PyThread_get_thread_native_idPtr.asFunction(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyRun_InteractiveOneObject'); + late final _PyRun_InteractiveOneObject = + _PyRun_InteractiveOneObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - PyThread_type_lock PyThread_allocate_lock() { - return _PyThread_allocate_lock(); + int PyRun_InteractiveLoopFlags( + ffi.Pointer fp, + ffi.Pointer filename, + ffi.Pointer flags, + ) { + return _PyRun_InteractiveLoopFlags( + fp, + filename, + flags, + ); } - late final _PyThread_allocate_lockPtr = - _lookup>( - 'PyThread_allocate_lock'); - late final _PyThread_allocate_lock = - _PyThread_allocate_lockPtr.asFunction(); + late final _PyRun_InteractiveLoopFlagsPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyRun_InteractiveLoopFlags'); + late final _PyRun_InteractiveLoopFlags = + _PyRun_InteractiveLoopFlagsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - void PyThread_free_lock( - PyThread_type_lock arg0, + int _PyRun_InteractiveLoopObject( + ffi.Pointer fp, + ffi.Pointer filename, + ffi.Pointer flags, ) { - return _PyThread_free_lock( - arg0, + return __PyRun_InteractiveLoopObject( + fp, + filename, + flags, ); } - late final _PyThread_free_lockPtr = - _lookup>( - 'PyThread_free_lock'); - late final _PyThread_free_lock = - _PyThread_free_lockPtr.asFunction(); + late final __PyRun_InteractiveLoopObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('_PyRun_InteractiveLoopObject'); + late final __PyRun_InteractiveLoopObject = + __PyRun_InteractiveLoopObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - int PyThread_acquire_lock( - PyThread_type_lock arg0, + ffi.Pointer PyRun_StringFlags( + ffi.Pointer arg0, int arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, + ffi.Pointer arg4, ) { - return _PyThread_acquire_lock( + return _PyRun_StringFlags( arg0, arg1, + arg2, + arg3, + arg4, ); } - late final _PyThread_acquire_lockPtr = _lookup< - ffi.NativeFunction>( - 'PyThread_acquire_lock'); - late final _PyThread_acquire_lock = _PyThread_acquire_lockPtr.asFunction< - int Function(PyThread_type_lock, int)>(); + late final _PyRun_StringFlagsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyRun_StringFlags'); + late final _PyRun_StringFlags = _PyRun_StringFlagsPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - int _PyThread_at_fork_reinit( - ffi.Pointer lock, + ffi.Pointer PyRun_FileExFlags( + ffi.Pointer fp, + ffi.Pointer filename, + int start, + ffi.Pointer globals, + ffi.Pointer locals, + int closeit, + ffi.Pointer flags, ) { - return __PyThread_at_fork_reinit( - lock, + return _PyRun_FileExFlags( + fp, + filename, + start, + globals, + locals, + closeit, + flags, ); } - late final __PyThread_at_fork_reinitPtr = _lookup< + late final _PyRun_FileExFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer)>>('_PyThread_at_fork_reinit'); - late final __PyThread_at_fork_reinit = __PyThread_at_fork_reinitPtr - .asFunction)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer)>>('PyRun_FileExFlags'); + late final _PyRun_FileExFlags = _PyRun_FileExFlagsPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer)>(); - int PyThread_acquire_lock_timed( - PyThread_type_lock arg0, - int microseconds, - int intr_flag, + ffi.Pointer Py_CompileStringExFlags( + ffi.Pointer str, + ffi.Pointer filename, + int start, + ffi.Pointer flags, + int optimize, ) { - return _PyThread_acquire_lock_timed( - arg0, - microseconds, - intr_flag, + return _Py_CompileStringExFlags( + str, + filename, + start, + flags, + optimize, ); } - late final _PyThread_acquire_lock_timedPtr = _lookup< + late final _Py_CompileStringExFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Int32 Function(PyThread_type_lock, ffi.LongLong, - ffi.Int)>>('PyThread_acquire_lock_timed'); - late final _PyThread_acquire_lock_timed = _PyThread_acquire_lock_timedPtr - .asFunction(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Int)>>('Py_CompileStringExFlags'); + late final _Py_CompileStringExFlags = _Py_CompileStringExFlagsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, int, ffi.Pointer, int)>(); - void PyThread_release_lock( - PyThread_type_lock arg0, + ffi.Pointer Py_CompileStringObject( + ffi.Pointer str, + ffi.Pointer filename, + int start, + ffi.Pointer flags, + int optimize, ) { - return _PyThread_release_lock( - arg0, + return _Py_CompileStringObject( + str, + filename, + start, + flags, + optimize, ); } - late final _PyThread_release_lockPtr = - _lookup>( - 'PyThread_release_lock'); - late final _PyThread_release_lock = - _PyThread_release_lockPtr.asFunction(); - - int PyThread_get_stacksize() { - return _PyThread_get_stacksize(); - } - - late final _PyThread_get_stacksizePtr = - _lookup>( - 'PyThread_get_stacksize'); - late final _PyThread_get_stacksize = - _PyThread_get_stacksizePtr.asFunction(); + late final _Py_CompileStringObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Int)>>('Py_CompileStringObject'); + late final _Py_CompileStringObject = _Py_CompileStringObjectPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, int, ffi.Pointer, int)>(); - int PyThread_set_stacksize( - int arg0, + ffi.Pointer _Py_SourceAsString( + ffi.Pointer cmd, + ffi.Pointer funcname, + ffi.Pointer what, + ffi.Pointer cf, + ffi.Pointer> cmd_copy, ) { - return _PyThread_set_stacksize( - arg0, + return __Py_SourceAsString( + cmd, + funcname, + what, + cf, + cmd_copy, ); } - late final _PyThread_set_stacksizePtr = - _lookup>( - 'PyThread_set_stacksize'); - late final _PyThread_set_stacksize = - _PyThread_set_stacksizePtr.asFunction(); - - ffi.Pointer PyThread_GetInfo() { - return _PyThread_GetInfo(); - } - - late final _PyThread_GetInfoPtr = - _lookup Function()>>( - 'PyThread_GetInfo'); - late final _PyThread_GetInfo = - _PyThread_GetInfoPtr.asFunction Function()>(); - - int PyThread_create_key() { - return _PyThread_create_key(); - } + late final __Py_SourceAsStringPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>)>>('_Py_SourceAsString'); + late final __Py_SourceAsString = __Py_SourceAsStringPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>)>(); - late final _PyThread_create_keyPtr = - _lookup>('PyThread_create_key'); - late final _PyThread_create_key = - _PyThread_create_keyPtr.asFunction(); + ffi.Pointer PyRun_String( + ffi.Pointer str, + int s, + ffi.Pointer g, + ffi.Pointer l, + ) { + return _PyRun_String( + str, + s, + g, + l, + ); + } - void PyThread_delete_key( - int key, + late final _PyRun_StringPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, ffi.Int, + ffi.Pointer, ffi.Pointer)>>('PyRun_String'); + late final _PyRun_String = _PyRun_StringPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int, + ffi.Pointer, ffi.Pointer)>(); + + int PyRun_AnyFile( + ffi.Pointer fp, + ffi.Pointer name, ) { - return _PyThread_delete_key( - key, + return _PyRun_AnyFile( + fp, + name, ); } - late final _PyThread_delete_keyPtr = - _lookup>( - 'PyThread_delete_key'); - late final _PyThread_delete_key = - _PyThread_delete_keyPtr.asFunction(); + late final _PyRun_AnyFilePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, ffi.Pointer)>>('PyRun_AnyFile'); + late final _PyRun_AnyFile = _PyRun_AnyFilePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyThread_set_key_value( - int key, - ffi.Pointer value, + int PyRun_AnyFileEx( + ffi.Pointer fp, + ffi.Pointer name, + int closeit, ) { - return _PyThread_set_key_value( - key, - value, + return _PyRun_AnyFileEx( + fp, + name, + closeit, ); } - late final _PyThread_set_key_valuePtr = _lookup< - ffi.NativeFunction)>>( - 'PyThread_set_key_value'); - late final _PyThread_set_key_value = _PyThread_set_key_valuePtr.asFunction< - int Function(int, ffi.Pointer)>(); + late final _PyRun_AnyFileExPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Int)>>('PyRun_AnyFileEx'); + late final _PyRun_AnyFileEx = _PyRun_AnyFileExPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - ffi.Pointer PyThread_get_key_value( - int key, + int PyRun_AnyFileFlags( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyThread_get_key_value( - key, + return _PyRun_AnyFileFlags( + arg0, + arg1, + arg2, ); } - late final _PyThread_get_key_valuePtr = - _lookup Function(ffi.Int)>>( - 'PyThread_get_key_value'); - late final _PyThread_get_key_value = _PyThread_get_key_valuePtr.asFunction< - ffi.Pointer Function(int)>(); + late final _PyRun_AnyFileFlagsPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyRun_AnyFileFlags'); + late final _PyRun_AnyFileFlags = _PyRun_AnyFileFlagsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - void PyThread_delete_key_value( - int key, + int PyRun_SimpleString( + ffi.Pointer s, ) { - return _PyThread_delete_key_value( - key, + return _PyRun_SimpleString( + s, ); } - late final _PyThread_delete_key_valuePtr = - _lookup>( - 'PyThread_delete_key_value'); - late final _PyThread_delete_key_value = - _PyThread_delete_key_valuePtr.asFunction(); + late final _PyRun_SimpleStringPtr = + _lookup)>>( + 'PyRun_SimpleString'); + late final _PyRun_SimpleString = + _PyRun_SimpleStringPtr.asFunction)>(); - void PyThread_ReInitTLS() { - return _PyThread_ReInitTLS(); + int PyRun_SimpleFile( + ffi.Pointer f, + ffi.Pointer p, + ) { + return _PyRun_SimpleFile( + f, + p, + ); } - late final _PyThread_ReInitTLSPtr = - _lookup>('PyThread_ReInitTLS'); - late final _PyThread_ReInitTLS = - _PyThread_ReInitTLSPtr.asFunction(); + late final _PyRun_SimpleFilePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, ffi.Pointer)>>('PyRun_SimpleFile'); + late final _PyRun_SimpleFile = _PyRun_SimpleFilePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyThread_tss_alloc() { - return _PyThread_tss_alloc(); + int PyRun_SimpleFileEx( + ffi.Pointer f, + ffi.Pointer p, + int c, + ) { + return _PyRun_SimpleFileEx( + f, + p, + c, + ); } - late final _PyThread_tss_allocPtr = - _lookup Function()>>( - 'PyThread_tss_alloc'); - late final _PyThread_tss_alloc = - _PyThread_tss_allocPtr.asFunction Function()>(); + late final _PyRun_SimpleFileExPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Int)>>('PyRun_SimpleFileEx'); + late final _PyRun_SimpleFileEx = _PyRun_SimpleFileExPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - void PyThread_tss_free( - ffi.Pointer key, + int PyRun_InteractiveOne( + ffi.Pointer f, + ffi.Pointer p, ) { - return _PyThread_tss_free( - key, + return _PyRun_InteractiveOne( + f, + p, ); } - late final _PyThread_tss_freePtr = - _lookup)>>( - 'PyThread_tss_free'); - late final _PyThread_tss_free = - _PyThread_tss_freePtr.asFunction)>(); + late final _PyRun_InteractiveOnePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyRun_InteractiveOne'); + late final _PyRun_InteractiveOne = _PyRun_InteractiveOnePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyThread_tss_is_created( - ffi.Pointer key, + int PyRun_InteractiveLoop( + ffi.Pointer f, + ffi.Pointer p, ) { - return _PyThread_tss_is_created( - key, + return _PyRun_InteractiveLoop( + f, + p, ); } - late final _PyThread_tss_is_createdPtr = - _lookup)>>( - 'PyThread_tss_is_created'); - late final _PyThread_tss_is_created = _PyThread_tss_is_createdPtr.asFunction< - int Function(ffi.Pointer)>(); + late final _PyRun_InteractiveLoopPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyRun_InteractiveLoop'); + late final _PyRun_InteractiveLoop = _PyRun_InteractiveLoopPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyThread_tss_create( - ffi.Pointer key, + ffi.Pointer PyRun_File( + ffi.Pointer fp, + ffi.Pointer p, + int s, + ffi.Pointer g, + ffi.Pointer l, ) { - return _PyThread_tss_create( - key, + return _PyRun_File( + fp, + p, + s, + g, + l, ); } - late final _PyThread_tss_createPtr = - _lookup)>>( - 'PyThread_tss_create'); - late final _PyThread_tss_create = - _PyThread_tss_createPtr.asFunction)>(); + late final _PyRun_FilePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer)>>('PyRun_File'); + late final _PyRun_File = _PyRun_FilePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, ffi.Pointer, + int, ffi.Pointer, ffi.Pointer)>(); - void PyThread_tss_delete( - ffi.Pointer key, + ffi.Pointer PyRun_FileEx( + ffi.Pointer fp, + ffi.Pointer p, + int s, + ffi.Pointer g, + ffi.Pointer l, + int c, ) { - return _PyThread_tss_delete( - key, + return _PyRun_FileEx( + fp, + p, + s, + g, + l, + c, ); } - late final _PyThread_tss_deletePtr = - _lookup)>>( - 'PyThread_tss_delete'); - late final _PyThread_tss_delete = _PyThread_tss_deletePtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PyRun_FileExPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Int)>>('PyRun_FileEx'); + late final _PyRun_FileEx = _PyRun_FileExPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, ffi.Pointer, + int, ffi.Pointer, ffi.Pointer, int)>(); - int PyThread_tss_set( - ffi.Pointer key, - ffi.Pointer value, + ffi.Pointer PyRun_FileFlags( + ffi.Pointer fp, + ffi.Pointer p, + int s, + ffi.Pointer g, + ffi.Pointer l, + ffi.Pointer flags, ) { - return _PyThread_tss_set( - key, - value, + return _PyRun_FileFlags( + fp, + p, + s, + g, + l, + flags, ); } - late final _PyThread_tss_setPtr = _lookup< + late final _PyRun_FileFlagsPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyThread_tss_set'); - late final _PyThread_tss_set = _PyThread_tss_setPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyRun_FileFlags'); + late final _PyRun_FileFlags = _PyRun_FileFlagsPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer PyThread_tss_get( - ffi.Pointer key, + ffi.Pointer PyOS_Readline( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyThread_tss_get( - key, + return _PyOS_Readline( + arg0, + arg1, + arg2, ); } - late final _PyThread_tss_getPtr = _lookup< + late final _PyOS_ReadlinePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyThread_tss_get'); - late final _PyThread_tss_get = _PyThread_tss_getPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyOS_Readline'); + late final _PyOS_Readline = _PyOS_ReadlinePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer _PyContext_Type = - _lookup('PyContext_Type'); + late final ffi.Pointer> __PyOS_ReadlineTState = + _lookup>('_PyOS_ReadlineTState'); - PyTypeObject get PyContext_Type => _PyContext_Type.ref; + ffi.Pointer get _PyOS_ReadlineTState => + __PyOS_ReadlineTState.value; - late final ffi.Pointer _PyContextVar_Type = - _lookup('PyContextVar_Type'); + set _PyOS_ReadlineTState(ffi.Pointer value) => + __PyOS_ReadlineTState.value = value; - PyTypeObject get PyContextVar_Type => _PyContextVar_Type.ref; + late final ffi.Pointer< + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>> + _PyOS_ReadlineFunctionPointer = _lookup< + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>>('PyOS_ReadlineFunctionPointer'); - late final ffi.Pointer _PyContextToken_Type = - _lookup('PyContextToken_Type'); + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, ffi.Pointer)>> + get PyOS_ReadlineFunctionPointer => _PyOS_ReadlineFunctionPointer.value; - PyTypeObject get PyContextToken_Type => _PyContextToken_Type.ref; + set PyOS_ReadlineFunctionPointer( + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>> + value) => + _PyOS_ReadlineFunctionPointer.value = value; - ffi.Pointer PyContext_New() { - return _PyContext_New(); + void Py_Initialize() { + return _Py_Initialize(); } - late final _PyContext_NewPtr = - _lookup Function()>>( - 'PyContext_New'); - late final _PyContext_New = - _PyContext_NewPtr.asFunction Function()>(); + late final _Py_InitializePtr = + _lookup>('Py_Initialize'); + late final _Py_Initialize = _Py_InitializePtr.asFunction(); - ffi.Pointer PyContext_Copy( - ffi.Pointer arg0, + void Py_InitializeEx( + int arg0, ) { - return _PyContext_Copy( + return _Py_InitializeEx( arg0, ); } - late final _PyContext_CopyPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyContext_Copy'); - late final _PyContext_Copy = _PyContext_CopyPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); - - ffi.Pointer PyContext_CopyCurrent() { - return _PyContext_CopyCurrent(); - } - - late final _PyContext_CopyCurrentPtr = - _lookup Function()>>( - 'PyContext_CopyCurrent'); - late final _PyContext_CopyCurrent = - _PyContext_CopyCurrentPtr.asFunction Function()>(); + late final _Py_InitializeExPtr = + _lookup>( + 'Py_InitializeEx'); + late final _Py_InitializeEx = + _Py_InitializeExPtr.asFunction(); - int PyContext_Enter( - ffi.Pointer arg0, - ) { - return _PyContext_Enter( - arg0, - ); + void Py_Finalize() { + return _Py_Finalize(); } - late final _PyContext_EnterPtr = - _lookup)>>( - 'PyContext_Enter'); - late final _PyContext_Enter = - _PyContext_EnterPtr.asFunction)>(); + late final _Py_FinalizePtr = + _lookup>('Py_Finalize'); + late final _Py_Finalize = _Py_FinalizePtr.asFunction(); - int PyContext_Exit( - ffi.Pointer arg0, - ) { - return _PyContext_Exit( - arg0, - ); + int Py_FinalizeEx() { + return _Py_FinalizeEx(); } - late final _PyContext_ExitPtr = - _lookup)>>( - 'PyContext_Exit'); - late final _PyContext_Exit = - _PyContext_ExitPtr.asFunction)>(); + late final _Py_FinalizeExPtr = + _lookup>('Py_FinalizeEx'); + late final _Py_FinalizeEx = _Py_FinalizeExPtr.asFunction(); - ffi.Pointer PyContextVar_New( - ffi.Pointer name, - ffi.Pointer default_value, - ) { - return _PyContextVar_New( - name, - default_value, - ); + int Py_IsInitialized() { + return _Py_IsInitialized(); } - late final _PyContextVar_NewPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyContextVar_New'); - late final _PyContextVar_New = _PyContextVar_NewPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final _Py_IsInitializedPtr = + _lookup>('Py_IsInitialized'); + late final _Py_IsInitialized = + _Py_IsInitializedPtr.asFunction(); - int PyContextVar_Get( - ffi.Pointer var1, - ffi.Pointer default_value, - ffi.Pointer> value, - ) { - return _PyContextVar_Get( - var1, - default_value, - value, - ); + ffi.Pointer Py_NewInterpreter() { + return _Py_NewInterpreter1(); } - late final _PyContextVar_GetPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer>)>>('PyContextVar_Get'); - late final _PyContextVar_Get = _PyContextVar_GetPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer>)>(); + late final _Py_NewInterpreterPtr = + _lookup Function()>>( + 'Py_NewInterpreter'); + late final _Py_NewInterpreter1 = + _Py_NewInterpreterPtr.asFunction Function()>(); - ffi.Pointer PyContextVar_Set( - ffi.Pointer var1, - ffi.Pointer value, + void Py_EndInterpreter( + ffi.Pointer arg0, ) { - return _PyContextVar_Set( - var1, - value, + return _Py_EndInterpreter( + arg0, ); } - late final _PyContextVar_SetPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyContextVar_Set'); - late final _PyContextVar_Set = _PyContextVar_SetPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + late final _Py_EndInterpreterPtr = _lookup< + ffi.NativeFunction)>>( + 'Py_EndInterpreter'); + late final _Py_EndInterpreter = _Py_EndInterpreterPtr.asFunction< + void Function(ffi.Pointer)>(); - int PyContextVar_Reset( - ffi.Pointer var1, - ffi.Pointer token, + int Py_AtExit( + ffi.Pointer> func, ) { - return _PyContextVar_Reset( - var1, - token, + return _Py_AtExit( + func, ); } - late final _PyContextVar_ResetPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyContextVar_Reset'); - late final _PyContextVar_Reset = _PyContextVar_ResetPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); - - ffi.Pointer _PyContext_NewHamtForTests() { - return __PyContext_NewHamtForTests(); - } - - late final __PyContext_NewHamtForTestsPtr = - _lookup Function()>>( - '_PyContext_NewHamtForTests'); - late final __PyContext_NewHamtForTests = __PyContext_NewHamtForTestsPtr - .asFunction Function()>(); + late final _Py_AtExitPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer>)>>( + 'Py_AtExit'); + late final _Py_AtExit = _Py_AtExitPtr.asFunction< + int Function(ffi.Pointer>)>(); - ffi.Pointer _Py_VaBuildValue_SizeT( - ffi.Pointer arg0, - va_list arg1, + void Py_Exit( + int arg0, ) { - return __Py_VaBuildValue_SizeT( + return _Py_Exit( arg0, - arg1, ); } - late final __Py_VaBuildValue_SizeTPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, va_list)>>('_Py_VaBuildValue_SizeT'); - late final __Py_VaBuildValue_SizeT = __Py_VaBuildValue_SizeTPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, va_list)>(); + late final _Py_ExitPtr = + _lookup>('Py_Exit'); + late final _Py_Exit = _Py_ExitPtr.asFunction(); - ffi.Pointer> _Py_VaBuildStack_SizeT( - ffi.Pointer> small_stack, - int small_stack_len, - ffi.Pointer format, - va_list va, - ffi.Pointer p_nargs, + int Py_Main( + int argc, + ffi.Pointer> argv, ) { - return __Py_VaBuildStack_SizeT( - small_stack, - small_stack_len, - format, - va, - p_nargs, + return _Py_Main( + argc, + argv, ); } - late final __Py_VaBuildStack_SizeTPtr = _lookup< + late final _Py_MainPtr = _lookup< ffi.NativeFunction< - ffi.Pointer> Function( - ffi.Pointer>, - Py_ssize_t, - ffi.Pointer, - va_list, - ffi.Pointer)>>('_Py_VaBuildStack_SizeT'); - late final __Py_VaBuildStack_SizeT = __Py_VaBuildStack_SizeTPtr.asFunction< - ffi.Pointer> Function( - ffi.Pointer>, - int, - ffi.Pointer, - va_list, - ffi.Pointer)>(); + ffi.Int Function( + ffi.Int, ffi.Pointer>)>>('Py_Main'); + late final _Py_Main = _Py_MainPtr.asFunction< + int Function(int, ffi.Pointer>)>(); - int PyArg_Parse( - ffi.Pointer arg0, - ffi.Pointer arg1, + int Py_BytesMain( + int argc, + ffi.Pointer> argv, ) { - return _PyArg_Parse( - arg0, - arg1, + return _Py_BytesMain( + argc, + argv, ); } - late final _PyArg_ParsePtr = _lookup< + late final _Py_BytesMainPtr = _lookup< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('PyArg_Parse'); - late final _PyArg_Parse = _PyArg_ParsePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int, ffi.Pointer>)>>('Py_BytesMain'); + late final _Py_BytesMain = _Py_BytesMainPtr.asFunction< + int Function(int, ffi.Pointer>)>(); - int PyArg_ParseTuple( - ffi.Pointer arg0, - ffi.Pointer arg1, + void Py_SetProgramName( + ffi.Pointer arg0, ) { - return _PyArg_ParseTuple( + return _Py_SetProgramName( arg0, - arg1, ); } - late final _PyArg_ParseTuplePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyArg_ParseTuple'); - late final _PyArg_ParseTuple = _PyArg_ParseTuplePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final _Py_SetProgramNamePtr = + _lookup)>>( + 'Py_SetProgramName'); + late final _Py_SetProgramName = + _Py_SetProgramNamePtr.asFunction)>(); - int PyArg_ParseTupleAndKeywords( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ffi.Pointer> arg3, - ) { - return _PyArg_ParseTupleAndKeywords( - arg0, - arg1, - arg2, - arg3, - ); + ffi.Pointer Py_GetProgramName() { + return _Py_GetProgramName(); } - late final _PyArg_ParseTupleAndKeywordsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, ffi.Pointer>)>>( - 'PyArg_ParseTupleAndKeywords'); - late final _PyArg_ParseTupleAndKeywords = - _PyArg_ParseTupleAndKeywordsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, ffi.Pointer>)>(); + late final _Py_GetProgramNamePtr = + _lookup Function()>>( + 'Py_GetProgramName'); + late final _Py_GetProgramName = + _Py_GetProgramNamePtr.asFunction Function()>(); - int PyArg_VaParse( - ffi.Pointer arg0, - ffi.Pointer arg1, - va_list arg2, + void Py_SetPythonHome( + ffi.Pointer arg0, ) { - return _PyArg_VaParse( + return _Py_SetPythonHome( arg0, - arg1, - arg2, ); } - late final _PyArg_VaParsePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - va_list)>>('PyArg_VaParse'); - late final _PyArg_VaParse = _PyArg_VaParsePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, va_list)>(); + late final _Py_SetPythonHomePtr = + _lookup)>>( + 'Py_SetPythonHome'); + late final _Py_SetPythonHome = + _Py_SetPythonHomePtr.asFunction)>(); - int PyArg_VaParseTupleAndKeywords( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ffi.Pointer> arg3, - va_list arg4, + ffi.Pointer Py_GetPythonHome() { + return _Py_GetPythonHome(); + } + + late final _Py_GetPythonHomePtr = + _lookup Function()>>( + 'Py_GetPythonHome'); + late final _Py_GetPythonHome = + _Py_GetPythonHomePtr.asFunction Function()>(); + + ffi.Pointer Py_GetProgramFullPath() { + return _Py_GetProgramFullPath(); + } + + late final _Py_GetProgramFullPathPtr = + _lookup Function()>>( + 'Py_GetProgramFullPath'); + late final _Py_GetProgramFullPath = + _Py_GetProgramFullPathPtr.asFunction Function()>(); + + ffi.Pointer Py_GetPrefix() { + return _Py_GetPrefix(); + } + + late final _Py_GetPrefixPtr = + _lookup Function()>>( + 'Py_GetPrefix'); + late final _Py_GetPrefix = + _Py_GetPrefixPtr.asFunction Function()>(); + + ffi.Pointer Py_GetExecPrefix() { + return _Py_GetExecPrefix(); + } + + late final _Py_GetExecPrefixPtr = + _lookup Function()>>( + 'Py_GetExecPrefix'); + late final _Py_GetExecPrefix = + _Py_GetExecPrefixPtr.asFunction Function()>(); + + ffi.Pointer Py_GetPath() { + return _Py_GetPath(); + } + + late final _Py_GetPathPtr = + _lookup Function()>>( + 'Py_GetPath'); + late final _Py_GetPath = + _Py_GetPathPtr.asFunction Function()>(); + + void Py_SetPath( + ffi.Pointer arg0, ) { - return _PyArg_VaParseTupleAndKeywords( + return _Py_SetPath( arg0, - arg1, - arg2, - arg3, - arg4, ); } - late final _PyArg_VaParseTupleAndKeywordsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>, - va_list)>>('PyArg_VaParseTupleAndKeywords'); - late final _PyArg_VaParseTupleAndKeywords = - _PyArg_VaParseTupleAndKeywordsPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>, - va_list)>(); + late final _Py_SetPathPtr = + _lookup)>>( + 'Py_SetPath'); + late final _Py_SetPath = + _Py_SetPathPtr.asFunction)>(); + + ffi.Pointer Py_GetVersion() { + return _Py_GetVersion(); + } + + late final _Py_GetVersionPtr = + _lookup Function()>>( + 'Py_GetVersion'); + late final _Py_GetVersion = + _Py_GetVersionPtr.asFunction Function()>(); + + ffi.Pointer Py_GetPlatform() { + return _Py_GetPlatform(); + } + + late final _Py_GetPlatformPtr = + _lookup Function()>>( + 'Py_GetPlatform'); + late final _Py_GetPlatform = + _Py_GetPlatformPtr.asFunction Function()>(); + + ffi.Pointer Py_GetCopyright() { + return _Py_GetCopyright(); + } + + late final _Py_GetCopyrightPtr = + _lookup Function()>>( + 'Py_GetCopyright'); + late final _Py_GetCopyright = + _Py_GetCopyrightPtr.asFunction Function()>(); + + ffi.Pointer Py_GetCompiler() { + return _Py_GetCompiler(); + } + + late final _Py_GetCompilerPtr = + _lookup Function()>>( + 'Py_GetCompiler'); + late final _Py_GetCompiler = + _Py_GetCompilerPtr.asFunction Function()>(); - int PyArg_ValidateKeywordArguments( - ffi.Pointer arg0, - ) { - return _PyArg_ValidateKeywordArguments( - arg0, - ); + ffi.Pointer Py_GetBuildInfo() { + return _Py_GetBuildInfo(); } - late final _PyArg_ValidateKeywordArgumentsPtr = - _lookup)>>( - 'PyArg_ValidateKeywordArguments'); - late final _PyArg_ValidateKeywordArguments = - _PyArg_ValidateKeywordArgumentsPtr.asFunction< - int Function(ffi.Pointer)>(); + late final _Py_GetBuildInfoPtr = + _lookup Function()>>( + 'Py_GetBuildInfo'); + late final _Py_GetBuildInfo = + _Py_GetBuildInfoPtr.asFunction Function()>(); - int PyArg_UnpackTuple( - ffi.Pointer arg0, - ffi.Pointer arg1, - int arg2, - int arg3, + PyOS_sighandler_t PyOS_getsig( + int arg0, ) { - return _PyArg_UnpackTuple( + return _PyOS_getsig( arg0, - arg1, - arg2, - arg3, ); } - late final _PyArg_UnpackTuplePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - Py_ssize_t, Py_ssize_t)>>('PyArg_UnpackTuple'); - late final _PyArg_UnpackTuple = _PyArg_UnpackTuplePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, int)>(); + late final _PyOS_getsigPtr = + _lookup>( + 'PyOS_getsig'); + late final _PyOS_getsig = + _PyOS_getsigPtr.asFunction(); - ffi.Pointer Py_BuildValue( - ffi.Pointer arg0, + PyOS_sighandler_t PyOS_setsig( + int arg0, + PyOS_sighandler_t arg1, ) { - return _Py_BuildValue( + return _PyOS_setsig( arg0, + arg1, ); } - late final _Py_BuildValuePtr = _lookup< + late final _PyOS_setsigPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('Py_BuildValue'); - late final _Py_BuildValue = _Py_BuildValuePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + PyOS_sighandler_t Function( + ffi.Int, PyOS_sighandler_t)>>('PyOS_setsig'); + late final _PyOS_setsig = _PyOS_setsigPtr.asFunction< + PyOS_sighandler_t Function(int, PyOS_sighandler_t)>(); - ffi.Pointer _Py_BuildValue_SizeT( - ffi.Pointer arg0, - ) { - return __Py_BuildValue_SizeT( - arg0, - ); - } + late final ffi.Pointer _Py_Version = + _lookup('Py_Version'); - late final __Py_BuildValue_SizeTPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('_Py_BuildValue_SizeT'); - late final __Py_BuildValue_SizeT = __Py_BuildValue_SizeTPtr - .asFunction Function(ffi.Pointer)>(); + int get Py_Version => _Py_Version.value; - int _PyArg_UnpackStack( - ffi.Pointer> args, - int nargs, - ffi.Pointer name, - int min, - int max, + set Py_Version(int value) => _Py_Version.value = value; + + int Py_FrozenMain( + int argc, + ffi.Pointer> argv, ) { - return __PyArg_UnpackStack( - args, - nargs, - name, - min, - max, + return _Py_FrozenMain( + argc, + argv, ); } - late final __PyArg_UnpackStackPtr = _lookup< + late final _Py_FrozenMainPtr = _lookup< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer>, - Py_ssize_t, - ffi.Pointer, - Py_ssize_t, - Py_ssize_t)>>('_PyArg_UnpackStack'); - late final __PyArg_UnpackStack = __PyArg_UnpackStackPtr.asFunction< - int Function(ffi.Pointer>, int, - ffi.Pointer, int, int)>(); + ffi.Int, ffi.Pointer>)>>('Py_FrozenMain'); + late final _Py_FrozenMain = _Py_FrozenMainPtr.asFunction< + int Function(int, ffi.Pointer>)>(); - int _PyArg_NoKeywords( - ffi.Pointer funcname, - ffi.Pointer kwargs, + int Py_SetStandardStreamEncoding( + ffi.Pointer encoding, + ffi.Pointer errors, ) { - return __PyArg_NoKeywords( - funcname, - kwargs, + return _Py_SetStandardStreamEncoding( + encoding, + errors, ); } - late final __PyArg_NoKeywordsPtr = _lookup< + late final _Py_SetStandardStreamEncodingPtr = _lookup< ffi.NativeFunction< ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyArg_NoKeywords'); - late final __PyArg_NoKeywords = __PyArg_NoKeywordsPtr - .asFunction, ffi.Pointer)>(); + ffi.Pointer)>>('Py_SetStandardStreamEncoding'); + late final _Py_SetStandardStreamEncoding = _Py_SetStandardStreamEncodingPtr + .asFunction, ffi.Pointer)>(); - int _PyArg_NoKwnames( - ffi.Pointer funcname, - ffi.Pointer kwnames, + PyStatus Py_PreInitialize( + ffi.Pointer src_config, ) { - return __PyArg_NoKwnames( - funcname, - kwnames, + return _Py_PreInitialize( + src_config, ); } - late final __PyArg_NoKwnamesPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyArg_NoKwnames'); - late final __PyArg_NoKwnames = __PyArg_NoKwnamesPtr - .asFunction, ffi.Pointer)>(); + late final _Py_PreInitializePtr = + _lookup)>>( + 'Py_PreInitialize'); + late final _Py_PreInitialize = _Py_PreInitializePtr.asFunction< + PyStatus Function(ffi.Pointer)>(); - int _PyArg_NoPositional( - ffi.Pointer funcname, - ffi.Pointer args, + PyStatus Py_PreInitializeFromBytesArgs( + ffi.Pointer src_config, + int argc, + ffi.Pointer> argv, ) { - return __PyArg_NoPositional( - funcname, - args, + return _Py_PreInitializeFromBytesArgs( + src_config, + argc, + argv, ); } - late final __PyArg_NoPositionalPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyArg_NoPositional'); - late final __PyArg_NoPositional = __PyArg_NoPositionalPtr - .asFunction, ffi.Pointer)>(); + late final _Py_PreInitializeFromBytesArgsPtr = _lookup< + ffi.NativeFunction< + PyStatus Function(ffi.Pointer, Py_ssize_t, + ffi.Pointer>)>>( + 'Py_PreInitializeFromBytesArgs'); + late final _Py_PreInitializeFromBytesArgs = + _Py_PreInitializeFromBytesArgsPtr.asFunction< + PyStatus Function(ffi.Pointer, int, + ffi.Pointer>)>(); - void _PyArg_BadArgument( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ffi.Pointer arg3, + PyStatus Py_PreInitializeFromArgs( + ffi.Pointer src_config, + int argc, + ffi.Pointer> argv, ) { - return __PyArg_BadArgument( - arg0, - arg1, - arg2, - arg3, + return _Py_PreInitializeFromArgs( + src_config, + argc, + argv, ); } - late final __PyArg_BadArgumentPtr = _lookup< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyArg_BadArgument'); - late final __PyArg_BadArgument = __PyArg_BadArgumentPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + late final _Py_PreInitializeFromArgsPtr = _lookup< + ffi.NativeFunction< + PyStatus Function(ffi.Pointer, Py_ssize_t, + ffi.Pointer>)>>( + 'Py_PreInitializeFromArgs'); + late final _Py_PreInitializeFromArgs = + _Py_PreInitializeFromArgsPtr.asFunction< + PyStatus Function(ffi.Pointer, int, + ffi.Pointer>)>(); - int _PyArg_CheckPositional( - ffi.Pointer arg0, - int arg1, - int arg2, - int arg3, - ) { - return __PyArg_CheckPositional( - arg0, - arg1, - arg2, - arg3, + int _Py_IsCoreInitialized() { + return __Py_IsCoreInitialized(); + } + + late final __Py_IsCoreInitializedPtr = + _lookup>('_Py_IsCoreInitialized'); + late final __Py_IsCoreInitialized = + __Py_IsCoreInitializedPtr.asFunction(); + + PyStatus Py_InitializeFromConfig( + ffi.Pointer config, + ) { + return _Py_InitializeFromConfig( + config, ); } - late final __PyArg_CheckPositionalPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_ssize_t, Py_ssize_t, - Py_ssize_t)>>('_PyArg_CheckPositional'); - late final __PyArg_CheckPositional = __PyArg_CheckPositionalPtr - .asFunction, int, int, int)>(); + late final _Py_InitializeFromConfigPtr = + _lookup)>>( + 'Py_InitializeFromConfig'); + late final _Py_InitializeFromConfig = _Py_InitializeFromConfigPtr.asFunction< + PyStatus Function(ffi.Pointer)>(); - ffi.Pointer Py_VaBuildValue( - ffi.Pointer arg0, - va_list arg1, - ) { - return _Py_VaBuildValue( - arg0, - arg1, - ); + PyStatus _Py_InitializeMain() { + return __Py_InitializeMain(); } - late final _Py_VaBuildValuePtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, va_list)>>('Py_VaBuildValue'); - late final _Py_VaBuildValue = _Py_VaBuildValuePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, va_list)>(); + late final __Py_InitializeMainPtr = + _lookup>('_Py_InitializeMain'); + late final __Py_InitializeMain = + __Py_InitializeMainPtr.asFunction(); - ffi.Pointer> _Py_VaBuildStack( - ffi.Pointer> small_stack, - int small_stack_len, - ffi.Pointer format, - va_list va, - ffi.Pointer p_nargs, - ) { - return __Py_VaBuildStack( - small_stack, - small_stack_len, - format, - va, - p_nargs, - ); + int Py_RunMain() { + return _Py_RunMain(); } - late final __Py_VaBuildStackPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer> Function( - ffi.Pointer>, - Py_ssize_t, - ffi.Pointer, - va_list, - ffi.Pointer)>>('_Py_VaBuildStack'); - late final __Py_VaBuildStack = __Py_VaBuildStackPtr.asFunction< - ffi.Pointer> Function( - ffi.Pointer>, - int, - ffi.Pointer, - va_list, - ffi.Pointer)>(); + late final _Py_RunMainPtr = + _lookup>('Py_RunMain'); + late final _Py_RunMain = _Py_RunMainPtr.asFunction(); - int _PyArg_ParseTupleAndKeywordsFast( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer<_PyArg_Parser> arg2, + void Py_ExitStatusException( + PyStatus err, ) { - return __PyArg_ParseTupleAndKeywordsFast( - arg0, - arg1, - arg2, + return _Py_ExitStatusException( + err, ); } - late final __PyArg_ParseTupleAndKeywordsFastPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer<_PyArg_Parser>)>>('_PyArg_ParseTupleAndKeywordsFast'); - late final __PyArg_ParseTupleAndKeywordsFast = - __PyArg_ParseTupleAndKeywordsFastPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer<_PyArg_Parser>)>(); + late final _Py_ExitStatusExceptionPtr = + _lookup>( + 'Py_ExitStatusException'); + late final _Py_ExitStatusException = + _Py_ExitStatusExceptionPtr.asFunction(); - int _PyArg_ParseStack( - ffi.Pointer> args, - int nargs, - ffi.Pointer format, - ) { - return __PyArg_ParseStack( - args, - nargs, - format, - ); + void _Py_RestoreSignals() { + return __Py_RestoreSignals(); } - late final __PyArg_ParseStackPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer>, Py_ssize_t, - ffi.Pointer)>>('_PyArg_ParseStack'); - late final __PyArg_ParseStack = __PyArg_ParseStackPtr.asFunction< - int Function( - ffi.Pointer>, int, ffi.Pointer)>(); + late final __Py_RestoreSignalsPtr = + _lookup>('_Py_RestoreSignals'); + late final __Py_RestoreSignals = + __Py_RestoreSignalsPtr.asFunction(); - int _PyArg_ParseStackAndKeywords( - ffi.Pointer> args, - int nargs, - ffi.Pointer kwnames, - ffi.Pointer<_PyArg_Parser> arg3, + int Py_FdIsInteractive( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __PyArg_ParseStackAndKeywords( - args, - nargs, - kwnames, - arg3, + return _Py_FdIsInteractive1( + arg0, + arg1, ); } - late final __PyArg_ParseStackAndKeywordsPtr = _lookup< + late final _Py_FdIsInteractivePtr = _lookup< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer>, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer<_PyArg_Parser>)>>('_PyArg_ParseStackAndKeywords'); - late final __PyArg_ParseStackAndKeywords = - __PyArg_ParseStackAndKeywordsPtr.asFunction< - int Function(ffi.Pointer>, int, - ffi.Pointer, ffi.Pointer<_PyArg_Parser>)>(); + ffi.Pointer, ffi.Pointer)>>('Py_FdIsInteractive'); + late final _Py_FdIsInteractive1 = _Py_FdIsInteractivePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int _PyArg_VaParseTupleAndKeywordsFast( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer<_PyArg_Parser> arg2, - va_list arg3, + int _Py_FdIsInteractive( + ffi.Pointer fp, + ffi.Pointer filename, ) { - return __PyArg_VaParseTupleAndKeywordsFast( - arg0, - arg1, - arg2, - arg3, + return __Py_FdIsInteractive( + fp, + filename, ); } - late final __PyArg_VaParseTupleAndKeywordsFastPtr = _lookup< + late final __Py_FdIsInteractivePtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer<_PyArg_Parser>, - va_list)>>('_PyArg_VaParseTupleAndKeywordsFast'); - late final __PyArg_VaParseTupleAndKeywordsFast = - __PyArg_VaParseTupleAndKeywordsFastPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer<_PyArg_Parser>, va_list)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_Py_FdIsInteractive'); + late final __Py_FdIsInteractive = __Py_FdIsInteractivePtr + .asFunction, ffi.Pointer)>(); - ffi.Pointer> _PyArg_UnpackKeywords( - ffi.Pointer> args, - int nargs, - ffi.Pointer kwargs, - ffi.Pointer kwnames, - ffi.Pointer<_PyArg_Parser> parser, - int minpos, - int maxpos, - int minkw, - ffi.Pointer> buf, + void _Py_SetProgramFullPath( + ffi.Pointer arg0, ) { - return __PyArg_UnpackKeywords( - args, - nargs, - kwargs, - kwnames, - parser, - minpos, - maxpos, - minkw, - buf, + return __Py_SetProgramFullPath( + arg0, ); } - late final __PyArg_UnpackKeywordsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer> Function( - ffi.Pointer>, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer<_PyArg_Parser>, - ffi.Int, - ffi.Int, - ffi.Int, - ffi.Pointer>)>>('_PyArg_UnpackKeywords'); - late final __PyArg_UnpackKeywords = __PyArg_UnpackKeywordsPtr.asFunction< - ffi.Pointer> Function( - ffi.Pointer>, - int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer<_PyArg_Parser>, - int, - int, - int, - ffi.Pointer>)>(); + late final __Py_SetProgramFullPathPtr = + _lookup)>>( + '_Py_SetProgramFullPath'); + late final __Py_SetProgramFullPath = __Py_SetProgramFullPathPtr + .asFunction)>(); - void _PyArg_Fini() { - return __PyArg_Fini(); + ffi.Pointer _Py_gitidentifier() { + return __Py_gitidentifier(); } - late final __PyArg_FiniPtr = - _lookup>('_PyArg_Fini'); - late final __PyArg_Fini = __PyArg_FiniPtr.asFunction(); + late final __Py_gitidentifierPtr = + _lookup Function()>>( + '_Py_gitidentifier'); + late final __Py_gitidentifier = + __Py_gitidentifierPtr.asFunction Function()>(); - int PyModule_AddObjectRef( - ffi.Pointer mod, - ffi.Pointer name, - ffi.Pointer value, - ) { - return _PyModule_AddObjectRef( - mod, - name, - value, - ); + ffi.Pointer _Py_gitversion() { + return __Py_gitversion(); } - late final _PyModule_AddObjectRefPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyModule_AddObjectRef'); - late final _PyModule_AddObjectRef = _PyModule_AddObjectRefPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + late final __Py_gitversionPtr = + _lookup Function()>>( + '_Py_gitversion'); + late final __Py_gitversion = + __Py_gitversionPtr.asFunction Function()>(); - int PyModule_AddObject( - ffi.Pointer mod, - ffi.Pointer arg1, - ffi.Pointer value, - ) { - return _PyModule_AddObject( - mod, - arg1, - value, - ); + int _Py_IsFinalizing() { + return __Py_IsFinalizing(); } - late final _PyModule_AddObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyModule_AddObject'); - late final _PyModule_AddObject = _PyModule_AddObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + late final __Py_IsFinalizingPtr = + _lookup>('_Py_IsFinalizing'); + late final __Py_IsFinalizing = + __Py_IsFinalizingPtr.asFunction(); - int PyModule_AddIntConstant( - ffi.Pointer arg0, - ffi.Pointer arg1, - int arg2, + int _PyOS_URandom( + ffi.Pointer buffer, + int size, ) { - return _PyModule_AddIntConstant( - arg0, - arg1, - arg2, + return __PyOS_URandom( + buffer, + size, ); } - late final _PyModule_AddIntConstantPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Long)>>('PyModule_AddIntConstant'); - late final _PyModule_AddIntConstant = _PyModule_AddIntConstantPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); + late final __PyOS_URandomPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + '_PyOS_URandom'); + late final __PyOS_URandom = + __PyOS_URandomPtr.asFunction, int)>(); - int PyModule_AddStringConstant( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, + int _PyOS_URandomNonblock( + ffi.Pointer buffer, + int size, ) { - return _PyModule_AddStringConstant( - arg0, - arg1, - arg2, + return __PyOS_URandomNonblock( + buffer, + size, ); } - late final _PyModule_AddStringConstantPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyModule_AddStringConstant'); - late final _PyModule_AddStringConstant = - _PyModule_AddStringConstantPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + late final __PyOS_URandomNonblockPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + '_PyOS_URandomNonblock'); + late final __PyOS_URandomNonblock = __PyOS_URandomNonblockPtr + .asFunction, int)>(); - int PyModule_AddType( - ffi.Pointer module, - ffi.Pointer type, + int _Py_CoerceLegacyLocale( + int warn, ) { - return _PyModule_AddType( - module, - type, + return __Py_CoerceLegacyLocale( + warn, ); } - late final _PyModule_AddTypePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyModule_AddType'); - late final _PyModule_AddType = _PyModule_AddTypePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __Py_CoerceLegacyLocalePtr = + _lookup>( + '_Py_CoerceLegacyLocale'); + late final __Py_CoerceLegacyLocale = + __Py_CoerceLegacyLocalePtr.asFunction(); - int PyModule_SetDocString( - ffi.Pointer arg0, - ffi.Pointer arg1, + int _Py_LegacyLocaleDetected( + int warn, ) { - return _PyModule_SetDocString( - arg0, - arg1, + return __Py_LegacyLocaleDetected( + warn, ); } - late final _PyModule_SetDocStringPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyModule_SetDocString'); - late final _PyModule_SetDocString = _PyModule_SetDocStringPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __Py_LegacyLocaleDetectedPtr = + _lookup>( + '_Py_LegacyLocaleDetected'); + late final __Py_LegacyLocaleDetected = + __Py_LegacyLocaleDetectedPtr.asFunction(); - int PyModule_AddFunctions( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer _Py_SetLocaleFromEnv( + int category, ) { - return _PyModule_AddFunctions( - arg0, - arg1, + return __Py_SetLocaleFromEnv( + category, ); } - late final _PyModule_AddFunctionsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyModule_AddFunctions'); - late final _PyModule_AddFunctions = _PyModule_AddFunctionsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __Py_SetLocaleFromEnvPtr = + _lookup Function(ffi.Int)>>( + '_Py_SetLocaleFromEnv'); + late final __Py_SetLocaleFromEnv = __Py_SetLocaleFromEnvPtr + .asFunction Function(int)>(); - int PyModule_ExecDef( - ffi.Pointer module, - ffi.Pointer def, + ffi.Pointer _Py_NewInterpreter( + int isolated_subinterpreter, ) { - return _PyModule_ExecDef( - module, - def, + return __Py_NewInterpreter( + isolated_subinterpreter, ); } - late final _PyModule_ExecDefPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyModule_ExecDef'); - late final _PyModule_ExecDef = _PyModule_ExecDefPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __Py_NewInterpreterPtr = + _lookup Function(ffi.Int)>>( + '_Py_NewInterpreter'); + late final __Py_NewInterpreter = __Py_NewInterpreterPtr + .asFunction Function(int)>(); - ffi.Pointer PyModule_Create2( - ffi.Pointer arg0, - int apiver, + ffi.Pointer PyEval_EvalCode( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, ) { - return _PyModule_Create2( + return _PyEval_EvalCode( arg0, - apiver, + arg1, + arg2, ); } - late final _PyModule_Create2Ptr = _lookup< + late final _PyEval_EvalCodePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Int)>>('PyModule_Create2'); - late final _PyModule_Create2 = _PyModule_Create2Ptr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyEval_EvalCode'); + late final _PyEval_EvalCode = _PyEval_EvalCodePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyModule_CreateInitialized( - ffi.Pointer arg0, - int apiver, + ffi.Pointer PyEval_EvalCodeEx( + ffi.Pointer co, + ffi.Pointer globals, + ffi.Pointer locals, + ffi.Pointer> args, + int argc, + ffi.Pointer> kwds, + int kwdc, + ffi.Pointer> defs, + int defc, + ffi.Pointer kwdefs, + ffi.Pointer closure, ) { - return __PyModule_CreateInitialized( - arg0, - apiver, + return _PyEval_EvalCodeEx( + co, + globals, + locals, + args, + argc, + kwds, + kwdc, + defs, + defc, + kwdefs, + closure, ); } - late final __PyModule_CreateInitializedPtr = _lookup< + late final _PyEval_EvalCodeExPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Int)>>('_PyModule_CreateInitialized'); - late final __PyModule_CreateInitialized = - __PyModule_CreateInitializedPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>, + ffi.Int, + ffi.Pointer>, + ffi.Int, + ffi.Pointer>, + ffi.Int, + ffi.Pointer, + ffi.Pointer)>>('PyEval_EvalCodeEx'); + late final _PyEval_EvalCodeEx = _PyEval_EvalCodeExPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer>, + int, + ffi.Pointer>, + int, + ffi.Pointer>, + int, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer PyModule_FromDefAndSpec2( - ffi.Pointer def, - ffi.Pointer spec, - int module_api_version, + ffi.Pointer PyEval_CallObjectWithKeywords( + ffi.Pointer callable, + ffi.Pointer args, + ffi.Pointer kwargs, ) { - return _PyModule_FromDefAndSpec2( - def, - spec, - module_api_version, + return _PyEval_CallObjectWithKeywords( + callable, + args, + kwargs, ); } - late final _PyModule_FromDefAndSpec2Ptr = _lookup< + late final _PyEval_CallObjectWithKeywordsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Int)>>('PyModule_FromDefAndSpec2'); - late final _PyModule_FromDefAndSpec2 = - _PyModule_FromDefAndSpec2Ptr.asFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, int)>(); - - late final ffi.Pointer> __Py_PackageContext = - _lookup>('_Py_PackageContext'); - - ffi.Pointer get _Py_PackageContext => __Py_PackageContext.value; - - set _Py_PackageContext(ffi.Pointer value) => - __Py_PackageContext.value = value; + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyEval_CallObjectWithKeywords'); + late final _PyEval_CallObjectWithKeywords = + _PyEval_CallObjectWithKeywordsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - int PyCompile_OpcodeStackEffect( - int opcode, - int oparg, + ffi.Pointer PyEval_CallFunction( + ffi.Pointer callable, + ffi.Pointer format, ) { - return _PyCompile_OpcodeStackEffect( - opcode, - oparg, + return _PyEval_CallFunction( + callable, + format, ); } - late final _PyCompile_OpcodeStackEffectPtr = - _lookup>( - 'PyCompile_OpcodeStackEffect'); - late final _PyCompile_OpcodeStackEffect = - _PyCompile_OpcodeStackEffectPtr.asFunction(); + late final _PyEval_CallFunctionPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyEval_CallFunction'); + late final _PyEval_CallFunction = _PyEval_CallFunctionPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyCompile_OpcodeStackEffectWithJump( - int opcode, - int oparg, - int jump, + ffi.Pointer PyEval_CallMethod( + ffi.Pointer obj, + ffi.Pointer name, + ffi.Pointer format, ) { - return _PyCompile_OpcodeStackEffectWithJump( - opcode, - oparg, - jump, + return _PyEval_CallMethod( + obj, + name, + format, ); } - late final _PyCompile_OpcodeStackEffectWithJumpPtr = - _lookup>( - 'PyCompile_OpcodeStackEffectWithJump'); - late final _PyCompile_OpcodeStackEffectWithJump = - _PyCompile_OpcodeStackEffectWithJumpPtr.asFunction< - int Function(int, int, int)>(); + late final _PyEval_CallMethodPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyEval_CallMethod'); + late final _PyEval_CallMethod = _PyEval_CallMethodPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer Py_CompileString( - ffi.Pointer arg0, - ffi.Pointer arg1, - int arg2, - ) { - return _Py_CompileString( - arg0, - arg1, - arg2, - ); + ffi.Pointer PyEval_GetBuiltins() { + return _PyEval_GetBuiltins(); } - late final _Py_CompileStringPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Int)>>('Py_CompileString'); - late final _Py_CompileString = _Py_CompileStringPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, int)>(); + late final _PyEval_GetBuiltinsPtr = + _lookup Function()>>( + 'PyEval_GetBuiltins'); + late final _PyEval_GetBuiltins = + _PyEval_GetBuiltinsPtr.asFunction Function()>(); - void PyErr_Print() { - return _PyErr_Print(); + ffi.Pointer PyEval_GetGlobals() { + return _PyEval_GetGlobals(); } - late final _PyErr_PrintPtr = - _lookup>('PyErr_Print'); - late final _PyErr_Print = _PyErr_PrintPtr.asFunction(); + late final _PyEval_GetGlobalsPtr = + _lookup Function()>>( + 'PyEval_GetGlobals'); + late final _PyEval_GetGlobals = + _PyEval_GetGlobalsPtr.asFunction Function()>(); - void PyErr_PrintEx( - int arg0, - ) { - return _PyErr_PrintEx( - arg0, - ); + ffi.Pointer PyEval_GetLocals() { + return _PyEval_GetLocals(); } - late final _PyErr_PrintExPtr = - _lookup>('PyErr_PrintEx'); - late final _PyErr_PrintEx = - _PyErr_PrintExPtr.asFunction(); + late final _PyEval_GetLocalsPtr = + _lookup Function()>>( + 'PyEval_GetLocals'); + late final _PyEval_GetLocals = + _PyEval_GetLocalsPtr.asFunction Function()>(); - void PyErr_Display( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, + ffi.Pointer PyEval_GetFrame() { + return _PyEval_GetFrame(); + } + + late final _PyEval_GetFramePtr = + _lookup Function()>>( + 'PyEval_GetFrame'); + late final _PyEval_GetFrame = + _PyEval_GetFramePtr.asFunction Function()>(); + + int Py_AddPendingCall( + ffi.Pointer)>> + func, + ffi.Pointer arg, ) { - return _PyErr_Display( - arg0, - arg1, - arg2, + return _Py_AddPendingCall( + func, + arg, ); } - late final _PyErr_DisplayPtr = _lookup< + late final _Py_AddPendingCallPtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyErr_Display'); - late final _PyErr_Display = _PyErr_DisplayPtr.asFunction< - void Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); - - late final ffi.Pointer>> - _PyOS_InputHook = - _lookup>>( - 'PyOS_InputHook'); + ffi.Int Function( + ffi.Pointer< + ffi.NativeFunction)>>, + ffi.Pointer)>>('Py_AddPendingCall'); + late final _Py_AddPendingCall = _Py_AddPendingCallPtr.asFunction< + int Function( + ffi.Pointer< + ffi.NativeFunction)>>, + ffi.Pointer)>(); - ffi.Pointer> get PyOS_InputHook => - _PyOS_InputHook.value; + int Py_MakePendingCalls() { + return _Py_MakePendingCalls(); + } - set PyOS_InputHook( - ffi.Pointer> value) => - _PyOS_InputHook.value = value; + late final _Py_MakePendingCallsPtr = + _lookup>('Py_MakePendingCalls'); + late final _Py_MakePendingCalls = + _Py_MakePendingCallsPtr.asFunction(); - int PyRun_SimpleStringFlags( - ffi.Pointer arg0, - ffi.Pointer arg1, + void Py_SetRecursionLimit( + int arg0, ) { - return _PyRun_SimpleStringFlags( + return _Py_SetRecursionLimit( arg0, - arg1, ); } - late final _PyRun_SimpleStringFlagsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyRun_SimpleStringFlags'); - late final _PyRun_SimpleStringFlags = _PyRun_SimpleStringFlagsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final _Py_SetRecursionLimitPtr = + _lookup>( + 'Py_SetRecursionLimit'); + late final _Py_SetRecursionLimit = + _Py_SetRecursionLimitPtr.asFunction(); - int _PyRun_SimpleFileObject( - ffi.Pointer fp, - ffi.Pointer filename, - int closeit, - ffi.Pointer flags, - ) { - return __PyRun_SimpleFileObject( - fp, - filename, - closeit, - flags, - ); + int Py_GetRecursionLimit() { + return _Py_GetRecursionLimit(); } - late final __PyRun_SimpleFileObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, - ffi.Pointer)>>('_PyRun_SimpleFileObject'); - late final __PyRun_SimpleFileObject = __PyRun_SimpleFileObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, - ffi.Pointer)>(); + late final _Py_GetRecursionLimitPtr = + _lookup>('Py_GetRecursionLimit'); + late final _Py_GetRecursionLimit = + _Py_GetRecursionLimitPtr.asFunction(); - int PyRun_AnyFileExFlags( - ffi.Pointer fp, - ffi.Pointer filename, - int closeit, - ffi.Pointer flags, + int Py_EnterRecursiveCall( + ffi.Pointer where, ) { - return _PyRun_AnyFileExFlags( - fp, - filename, - closeit, - flags, + return _Py_EnterRecursiveCall( + where, ); } - late final _PyRun_AnyFileExFlagsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, - ffi.Pointer)>>('PyRun_AnyFileExFlags'); - late final _PyRun_AnyFileExFlags = _PyRun_AnyFileExFlagsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, - ffi.Pointer)>(); + late final _Py_EnterRecursiveCallPtr = + _lookup)>>( + 'Py_EnterRecursiveCall'); + late final _Py_EnterRecursiveCall = _Py_EnterRecursiveCallPtr.asFunction< + int Function(ffi.Pointer)>(); + + void Py_LeaveRecursiveCall() { + return _Py_LeaveRecursiveCall(); + } + + late final _Py_LeaveRecursiveCallPtr = + _lookup>('Py_LeaveRecursiveCall'); + late final _Py_LeaveRecursiveCall = + _Py_LeaveRecursiveCallPtr.asFunction(); - int _PyRun_AnyFileObject( - ffi.Pointer fp, - ffi.Pointer filename, - int closeit, - ffi.Pointer flags, + ffi.Pointer PyEval_GetFuncName( + ffi.Pointer arg0, ) { - return __PyRun_AnyFileObject( - fp, - filename, - closeit, - flags, + return _PyEval_GetFuncName( + arg0, ); } - late final __PyRun_AnyFileObjectPtr = _lookup< + late final _PyEval_GetFuncNamePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, - ffi.Pointer)>>('_PyRun_AnyFileObject'); - late final __PyRun_AnyFileObject = __PyRun_AnyFileObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, - ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyEval_GetFuncName'); + late final _PyEval_GetFuncName = _PyEval_GetFuncNamePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyRun_SimpleFileExFlags( - ffi.Pointer fp, - ffi.Pointer filename, - int closeit, - ffi.Pointer flags, + ffi.Pointer PyEval_GetFuncDesc( + ffi.Pointer arg0, ) { - return _PyRun_SimpleFileExFlags( - fp, - filename, - closeit, - flags, + return _PyEval_GetFuncDesc( + arg0, ); } - late final _PyRun_SimpleFileExFlagsPtr = _lookup< + late final _PyEval_GetFuncDescPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Int, - ffi.Pointer)>>('PyRun_SimpleFileExFlags'); - late final _PyRun_SimpleFileExFlags = _PyRun_SimpleFileExFlagsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int, - ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyEval_GetFuncDesc'); + late final _PyEval_GetFuncDesc = _PyEval_GetFuncDescPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyRun_InteractiveOneFlags( - ffi.Pointer fp, - ffi.Pointer filename, - ffi.Pointer flags, + ffi.Pointer PyEval_EvalFrame( + ffi.Pointer arg0, ) { - return _PyRun_InteractiveOneFlags( - fp, - filename, - flags, + return _PyEval_EvalFrame( + arg0, ); } - late final _PyRun_InteractiveOneFlagsPtr = _lookup< + late final _PyEval_EvalFramePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyRun_InteractiveOneFlags'); - late final _PyRun_InteractiveOneFlags = - _PyRun_InteractiveOneFlagsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyEval_EvalFrame'); + late final _PyEval_EvalFrame = _PyEval_EvalFramePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyRun_InteractiveOneObject( - ffi.Pointer fp, - ffi.Pointer filename, - ffi.Pointer flags, + ffi.Pointer PyEval_EvalFrameEx( + ffi.Pointer f, + int exc, ) { - return _PyRun_InteractiveOneObject( - fp, - filename, - flags, + return _PyEval_EvalFrameEx( + f, + exc, ); } - late final _PyRun_InteractiveOneObjectPtr = _lookup< + late final _PyEval_EvalFrameExPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyRun_InteractiveOneObject'); - late final _PyRun_InteractiveOneObject = - _PyRun_InteractiveOneObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, ffi.Int)>>('PyEval_EvalFrameEx'); + late final _PyEval_EvalFrameEx = _PyEval_EvalFrameExPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - int PyRun_InteractiveLoopFlags( - ffi.Pointer fp, - ffi.Pointer filename, - ffi.Pointer flags, - ) { - return _PyRun_InteractiveLoopFlags( - fp, - filename, - flags, - ); + ffi.Pointer PyEval_SaveThread() { + return _PyEval_SaveThread(); } - late final _PyRun_InteractiveLoopFlagsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyRun_InteractiveLoopFlags'); - late final _PyRun_InteractiveLoopFlags = - _PyRun_InteractiveLoopFlagsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + late final _PyEval_SaveThreadPtr = + _lookup Function()>>( + 'PyEval_SaveThread'); + late final _PyEval_SaveThread = + _PyEval_SaveThreadPtr.asFunction Function()>(); - int _PyRun_InteractiveLoopObject( - ffi.Pointer fp, - ffi.Pointer filename, - ffi.Pointer flags, + void PyEval_RestoreThread( + ffi.Pointer arg0, ) { - return __PyRun_InteractiveLoopObject( - fp, - filename, - flags, + return _PyEval_RestoreThread( + arg0, ); } - late final __PyRun_InteractiveLoopObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('_PyRun_InteractiveLoopObject'); - late final __PyRun_InteractiveLoopObject = - __PyRun_InteractiveLoopObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + late final _PyEval_RestoreThreadPtr = _lookup< + ffi.NativeFunction)>>( + 'PyEval_RestoreThread'); + late final _PyEval_RestoreThread = _PyEval_RestoreThreadPtr.asFunction< + void Function(ffi.Pointer)>(); - ffi.Pointer PyRun_StringFlags( - ffi.Pointer arg0, - int arg1, - ffi.Pointer arg2, - ffi.Pointer arg3, - ffi.Pointer arg4, + int PyEval_ThreadsInitialized() { + return _PyEval_ThreadsInitialized(); + } + + late final _PyEval_ThreadsInitializedPtr = + _lookup>( + 'PyEval_ThreadsInitialized'); + late final _PyEval_ThreadsInitialized = + _PyEval_ThreadsInitializedPtr.asFunction(); + + void PyEval_InitThreads() { + return _PyEval_InitThreads(); + } + + late final _PyEval_InitThreadsPtr = + _lookup>('PyEval_InitThreads'); + late final _PyEval_InitThreads = + _PyEval_InitThreadsPtr.asFunction(); + + void PyEval_AcquireLock() { + return _PyEval_AcquireLock(); + } + + late final _PyEval_AcquireLockPtr = + _lookup>('PyEval_AcquireLock'); + late final _PyEval_AcquireLock = + _PyEval_AcquireLockPtr.asFunction(); + + void PyEval_ReleaseLock() { + return _PyEval_ReleaseLock(); + } + + late final _PyEval_ReleaseLockPtr = + _lookup>('PyEval_ReleaseLock'); + late final _PyEval_ReleaseLock = + _PyEval_ReleaseLockPtr.asFunction(); + + void PyEval_AcquireThread( + ffi.Pointer tstate, ) { - return _PyRun_StringFlags( - arg0, - arg1, - arg2, - arg3, - arg4, + return _PyEval_AcquireThread( + tstate, ); } - late final _PyRun_StringFlagsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyRun_StringFlags'); - late final _PyRun_StringFlags = _PyRun_StringFlagsPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + late final _PyEval_AcquireThreadPtr = _lookup< + ffi.NativeFunction)>>( + 'PyEval_AcquireThread'); + late final _PyEval_AcquireThread = _PyEval_AcquireThreadPtr.asFunction< + void Function(ffi.Pointer)>(); - ffi.Pointer PyRun_FileExFlags( - ffi.Pointer fp, - ffi.Pointer filename, - int start, - ffi.Pointer globals, - ffi.Pointer locals, - int closeit, - ffi.Pointer flags, + void PyEval_ReleaseThread( + ffi.Pointer tstate, ) { - return _PyRun_FileExFlags( - fp, - filename, - start, - globals, - locals, - closeit, - flags, + return _PyEval_ReleaseThread( + tstate, ); } - late final _PyRun_FileExFlagsPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer)>>('PyRun_FileExFlags'); - late final _PyRun_FileExFlags = _PyRun_FileExFlagsPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - int, - ffi.Pointer, - ffi.Pointer, - int, - ffi.Pointer)>(); + late final _PyEval_ReleaseThreadPtr = _lookup< + ffi.NativeFunction)>>( + 'PyEval_ReleaseThread'); + late final _PyEval_ReleaseThread = _PyEval_ReleaseThreadPtr.asFunction< + void Function(ffi.Pointer)>(); - ffi.Pointer Py_CompileStringExFlags( - ffi.Pointer str, - ffi.Pointer filename, - int start, - ffi.Pointer flags, - int optimize, + void PyEval_SetProfile( + Py_tracefunc arg0, + ffi.Pointer arg1, ) { - return _Py_CompileStringExFlags( - str, - filename, - start, - flags, - optimize, + return _PyEval_SetProfile1( + arg0, + arg1, ); } - late final _Py_CompileStringExFlagsPtr = _lookup< + late final _PyEval_SetProfilePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Int)>>('Py_CompileStringExFlags'); - late final _Py_CompileStringExFlags = _Py_CompileStringExFlagsPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, int, ffi.Pointer, int)>(); + ffi.Void Function( + Py_tracefunc, ffi.Pointer)>>('PyEval_SetProfile'); + late final _PyEval_SetProfile1 = _PyEval_SetProfilePtr.asFunction< + void Function(Py_tracefunc, ffi.Pointer)>(); - ffi.Pointer Py_CompileStringObject( - ffi.Pointer str, - ffi.Pointer filename, - int start, - ffi.Pointer flags, - int optimize, + int _PyEval_SetProfile( + ffi.Pointer tstate, + Py_tracefunc func, + ffi.Pointer arg, ) { - return _Py_CompileStringObject( - str, - filename, - start, - flags, - optimize, + return __PyEval_SetProfile( + tstate, + func, + arg, ); } - late final _Py_CompileStringObjectPtr = _lookup< + late final __PyEval_SetProfilePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Int)>>('Py_CompileStringObject'); - late final _Py_CompileStringObject = _Py_CompileStringObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, int, ffi.Pointer, int)>(); + ffi.Int Function(ffi.Pointer, Py_tracefunc, + ffi.Pointer)>>('_PyEval_SetProfile'); + late final __PyEval_SetProfile = __PyEval_SetProfilePtr.asFunction< + int Function( + ffi.Pointer, Py_tracefunc, ffi.Pointer)>(); - ffi.Pointer _Py_SourceAsString( - ffi.Pointer cmd, - ffi.Pointer funcname, - ffi.Pointer what, - ffi.Pointer cf, - ffi.Pointer> cmd_copy, + void PyEval_SetTrace( + Py_tracefunc arg0, + ffi.Pointer arg1, ) { - return __Py_SourceAsString( - cmd, - funcname, - what, - cf, - cmd_copy, + return _PyEval_SetTrace1( + arg0, + arg1, ); } - late final __Py_SourceAsStringPtr = _lookup< + late final _PyEval_SetTracePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>)>>('_Py_SourceAsString'); - late final __Py_SourceAsString = __Py_SourceAsStringPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>)>(); + ffi.Void Function( + Py_tracefunc, ffi.Pointer)>>('PyEval_SetTrace'); + late final _PyEval_SetTrace1 = _PyEval_SetTracePtr.asFunction< + void Function(Py_tracefunc, ffi.Pointer)>(); - ffi.Pointer PyRun_String( - ffi.Pointer str, - int s, - ffi.Pointer g, - ffi.Pointer l, + int _PyEval_SetTrace( + ffi.Pointer tstate, + Py_tracefunc func, + ffi.Pointer arg, ) { - return _PyRun_String( - str, - s, - g, - l, + return __PyEval_SetTrace( + tstate, + func, + arg, ); } - late final _PyRun_StringPtr = _lookup< + late final __PyEval_SetTracePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, ffi.Int, - ffi.Pointer, ffi.Pointer)>>('PyRun_String'); - late final _PyRun_String = _PyRun_StringPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int, - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, Py_tracefunc, + ffi.Pointer)>>('_PyEval_SetTrace'); + late final __PyEval_SetTrace = __PyEval_SetTracePtr.asFunction< + int Function( + ffi.Pointer, Py_tracefunc, ffi.Pointer)>(); - int PyRun_AnyFile( - ffi.Pointer fp, - ffi.Pointer name, + ffi.Pointer _PyEval_GetBuiltin( + ffi.Pointer arg0, ) { - return _PyRun_AnyFile( - fp, - name, + return __PyEval_GetBuiltin( + arg0, ); } - late final _PyRun_AnyFilePtr = _lookup< + late final __PyEval_GetBuiltinPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('PyRun_AnyFile'); - late final _PyRun_AnyFile = _PyRun_AnyFilePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('_PyEval_GetBuiltin'); + late final __PyEval_GetBuiltin = __PyEval_GetBuiltinPtr + .asFunction Function(ffi.Pointer)>(); - int PyRun_AnyFileEx( - ffi.Pointer fp, - ffi.Pointer name, - int closeit, + ffi.Pointer _PyEval_GetBuiltinId( + ffi.Pointer<_Py_Identifier> arg0, ) { - return _PyRun_AnyFileEx( - fp, - name, - closeit, + return __PyEval_GetBuiltinId( + arg0, ); } - late final _PyRun_AnyFileExPtr = _lookup< + late final __PyEval_GetBuiltinIdPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Int)>>('PyRun_AnyFileEx'); - late final _PyRun_AnyFileEx = _PyRun_AnyFileExPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); + ffi.Pointer Function( + ffi.Pointer<_Py_Identifier>)>>('_PyEval_GetBuiltinId'); + late final __PyEval_GetBuiltinId = __PyEval_GetBuiltinIdPtr.asFunction< + ffi.Pointer Function(ffi.Pointer<_Py_Identifier>)>(); - int PyRun_AnyFileFlags( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, + int PyEval_MergeCompilerFlags( + ffi.Pointer cf, ) { - return _PyRun_AnyFileFlags( - arg0, - arg1, - arg2, + return _PyEval_MergeCompilerFlags( + cf, ); } - late final _PyRun_AnyFileFlagsPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyRun_AnyFileFlags'); - late final _PyRun_AnyFileFlags = _PyRun_AnyFileFlagsPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + late final _PyEval_MergeCompilerFlagsPtr = _lookup< + ffi.NativeFunction)>>( + 'PyEval_MergeCompilerFlags'); + late final _PyEval_MergeCompilerFlags = _PyEval_MergeCompilerFlagsPtr + .asFunction)>(); - int PyRun_SimpleString( - ffi.Pointer s, + ffi.Pointer _PyEval_EvalFrameDefault( + ffi.Pointer tstate, + ffi.Pointer<_PyInterpreterFrame> f, + int exc, ) { - return _PyRun_SimpleString( - s, + return __PyEval_EvalFrameDefault( + tstate, + f, + exc, ); } - late final _PyRun_SimpleStringPtr = - _lookup)>>( - 'PyRun_SimpleString'); - late final _PyRun_SimpleString = - _PyRun_SimpleStringPtr.asFunction)>(); + late final __PyEval_EvalFrameDefaultPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer<_PyInterpreterFrame>, + ffi.Int)>>('_PyEval_EvalFrameDefault'); + late final __PyEval_EvalFrameDefault = + __PyEval_EvalFrameDefaultPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer<_PyInterpreterFrame>, int)>(); - int PyRun_SimpleFile( - ffi.Pointer f, - ffi.Pointer p, + void _PyEval_SetSwitchInterval( + int microseconds, ) { - return _PyRun_SimpleFile( - f, - p, + return __PyEval_SetSwitchInterval( + microseconds, ); } - late final _PyRun_SimpleFilePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('PyRun_SimpleFile'); - late final _PyRun_SimpleFile = _PyRun_SimpleFilePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + late final __PyEval_SetSwitchIntervalPtr = + _lookup>( + '_PyEval_SetSwitchInterval'); + late final __PyEval_SetSwitchInterval = + __PyEval_SetSwitchIntervalPtr.asFunction(); - int PyRun_SimpleFileEx( - ffi.Pointer f, - ffi.Pointer p, - int c, + int _PyEval_GetSwitchInterval() { + return __PyEval_GetSwitchInterval(); + } + + late final __PyEval_GetSwitchIntervalPtr = + _lookup>( + '_PyEval_GetSwitchInterval'); + late final __PyEval_GetSwitchInterval = + __PyEval_GetSwitchIntervalPtr.asFunction(); + + int _PyEval_RequestCodeExtraIndex( + freefunc arg0, ) { - return _PyRun_SimpleFileEx( - f, - p, - c, + return __PyEval_RequestCodeExtraIndex( + arg0, ); } - late final _PyRun_SimpleFileExPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Int)>>('PyRun_SimpleFileEx'); - late final _PyRun_SimpleFileEx = _PyRun_SimpleFileExPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); + late final __PyEval_RequestCodeExtraIndexPtr = + _lookup>( + '_PyEval_RequestCodeExtraIndex'); + late final __PyEval_RequestCodeExtraIndex = + __PyEval_RequestCodeExtraIndexPtr.asFunction(); - int PyRun_InteractiveOne( - ffi.Pointer f, - ffi.Pointer p, + int _PyEval_SliceIndex( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyRun_InteractiveOne( - f, - p, + return __PyEval_SliceIndex( + arg0, + arg1, ); } - late final _PyRun_InteractiveOnePtr = _lookup< + late final __PyEval_SliceIndexPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyRun_InteractiveOne'); - late final _PyRun_InteractiveOne = _PyRun_InteractiveOnePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyEval_SliceIndex'); + late final __PyEval_SliceIndex = __PyEval_SliceIndexPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int PyRun_InteractiveLoop( - ffi.Pointer f, - ffi.Pointer p, + int _PyEval_SliceIndexNotNone( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyRun_InteractiveLoop( - f, - p, + return __PyEval_SliceIndexNotNone( + arg0, + arg1, ); } - late final _PyRun_InteractiveLoopPtr = _lookup< + late final __PyEval_SliceIndexNotNonePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PyRun_InteractiveLoop'); - late final _PyRun_InteractiveLoop = _PyRun_InteractiveLoopPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyEval_SliceIndexNotNone'); + late final __PyEval_SliceIndexNotNone = + __PyEval_SliceIndexNotNonePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyRun_File( - ffi.Pointer fp, - ffi.Pointer p, - int s, - ffi.Pointer g, - ffi.Pointer l, + ffi.Pointer PySys_GetObject( + ffi.Pointer arg0, ) { - return _PyRun_File( - fp, - p, - s, - g, - l, + return _PySys_GetObject( + arg0, ); } - late final _PyRun_FilePtr = _lookup< + late final _PySys_GetObjectPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer)>>('PyRun_File'); - late final _PyRun_File = _PyRun_FilePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, ffi.Pointer, - int, ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PySys_GetObject'); + late final _PySys_GetObject = _PySys_GetObjectPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyRun_FileEx( - ffi.Pointer fp, - ffi.Pointer p, - int s, - ffi.Pointer g, - ffi.Pointer l, - int c, + int PySys_SetObject( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return _PyRun_FileEx( - fp, - p, - s, - g, - l, - c, + return _PySys_SetObject( + arg0, + arg1, ); } - late final _PyRun_FileExPtr = _lookup< + late final _PySys_SetObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer, - ffi.Int)>>('PyRun_FileEx'); - late final _PyRun_FileEx = _PyRun_FileExPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, ffi.Pointer, - int, ffi.Pointer, ffi.Pointer, int)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PySys_SetObject'); + late final _PySys_SetObject = _PySys_SetObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyRun_FileFlags( - ffi.Pointer fp, - ffi.Pointer p, - int s, - ffi.Pointer g, - ffi.Pointer l, - ffi.Pointer flags, + void PySys_SetArgv( + int arg0, + ffi.Pointer> arg1, ) { - return _PyRun_FileFlags( - fp, - p, - s, - g, - l, - flags, + return _PySys_SetArgv( + arg0, + arg1, ); } - late final _PyRun_FileFlagsPtr = _lookup< + late final _PySys_SetArgvPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyRun_FileFlags'); - late final _PyRun_FileFlags = _PyRun_FileFlagsPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - int, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + ffi.Void Function( + ffi.Int, ffi.Pointer>)>>('PySys_SetArgv'); + late final _PySys_SetArgv = _PySys_SetArgvPtr.asFunction< + void Function(int, ffi.Pointer>)>(); - ffi.Pointer PyOS_Readline( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, + void PySys_SetArgvEx( + int arg0, + ffi.Pointer> arg1, + int arg2, ) { - return _PyOS_Readline( + return _PySys_SetArgvEx( arg0, arg1, arg2, ); } - late final _PyOS_ReadlinePtr = _lookup< + late final _PySys_SetArgvExPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyOS_Readline'); - late final _PyOS_Readline = _PyOS_ReadlinePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); + ffi.Void Function(ffi.Int, ffi.Pointer>, + ffi.Int)>>('PySys_SetArgvEx'); + late final _PySys_SetArgvEx = _PySys_SetArgvExPtr.asFunction< + void Function(int, ffi.Pointer>, int)>(); - late final ffi.Pointer> __PyOS_ReadlineTState = - _lookup>('_PyOS_ReadlineTState'); + void PySys_SetPath( + ffi.Pointer arg0, + ) { + return _PySys_SetPath( + arg0, + ); + } - ffi.Pointer get _PyOS_ReadlineTState => - __PyOS_ReadlineTState.value; + late final _PySys_SetPathPtr = + _lookup)>>( + 'PySys_SetPath'); + late final _PySys_SetPath = + _PySys_SetPathPtr.asFunction)>(); - set _PyOS_ReadlineTState(ffi.Pointer value) => - __PyOS_ReadlineTState.value = value; + void PySys_WriteStdout( + ffi.Pointer format, + ) { + return _PySys_WriteStdout( + format, + ); + } - late final ffi.Pointer< - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>> - _PyOS_ReadlineFunctionPointer = _lookup< - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>>('PyOS_ReadlineFunctionPointer'); + late final _PySys_WriteStdoutPtr = + _lookup)>>( + 'PySys_WriteStdout'); + late final _PySys_WriteStdout = + _PySys_WriteStdoutPtr.asFunction)>(); - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, ffi.Pointer)>> - get PyOS_ReadlineFunctionPointer => _PyOS_ReadlineFunctionPointer.value; + void PySys_WriteStderr( + ffi.Pointer format, + ) { + return _PySys_WriteStderr( + format, + ); + } - set PyOS_ReadlineFunctionPointer( - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>> - value) => - _PyOS_ReadlineFunctionPointer.value = value; + late final _PySys_WriteStderrPtr = + _lookup)>>( + 'PySys_WriteStderr'); + late final _PySys_WriteStderr = + _PySys_WriteStderrPtr.asFunction)>(); - void Py_Initialize() { - return _Py_Initialize(); + void PySys_FormatStdout( + ffi.Pointer format, + ) { + return _PySys_FormatStdout( + format, + ); } - late final _Py_InitializePtr = - _lookup>('Py_Initialize'); - late final _Py_Initialize = _Py_InitializePtr.asFunction(); + late final _PySys_FormatStdoutPtr = + _lookup)>>( + 'PySys_FormatStdout'); + late final _PySys_FormatStdout = + _PySys_FormatStdoutPtr.asFunction)>(); - void Py_InitializeEx( - int arg0, + void PySys_FormatStderr( + ffi.Pointer format, ) { - return _Py_InitializeEx( - arg0, + return _PySys_FormatStderr( + format, ); } - late final _Py_InitializeExPtr = - _lookup>( - 'Py_InitializeEx'); - late final _Py_InitializeEx = - _Py_InitializeExPtr.asFunction(); + late final _PySys_FormatStderrPtr = + _lookup)>>( + 'PySys_FormatStderr'); + late final _PySys_FormatStderr = + _PySys_FormatStderrPtr.asFunction)>(); - void Py_Finalize() { - return _Py_Finalize(); + void PySys_ResetWarnOptions() { + return _PySys_ResetWarnOptions(); } - late final _Py_FinalizePtr = - _lookup>('Py_Finalize'); - late final _Py_Finalize = _Py_FinalizePtr.asFunction(); + late final _PySys_ResetWarnOptionsPtr = + _lookup>( + 'PySys_ResetWarnOptions'); + late final _PySys_ResetWarnOptions = + _PySys_ResetWarnOptionsPtr.asFunction(); - int Py_FinalizeEx() { - return _Py_FinalizeEx(); + void PySys_AddWarnOption( + ffi.Pointer arg0, + ) { + return _PySys_AddWarnOption( + arg0, + ); } - late final _Py_FinalizeExPtr = - _lookup>('Py_FinalizeEx'); - late final _Py_FinalizeEx = _Py_FinalizeExPtr.asFunction(); + late final _PySys_AddWarnOptionPtr = + _lookup)>>( + 'PySys_AddWarnOption'); + late final _PySys_AddWarnOption = _PySys_AddWarnOptionPtr.asFunction< + void Function(ffi.Pointer)>(); - int Py_IsInitialized() { - return _Py_IsInitialized(); + void PySys_AddWarnOptionUnicode( + ffi.Pointer arg0, + ) { + return _PySys_AddWarnOptionUnicode( + arg0, + ); } - late final _Py_IsInitializedPtr = - _lookup>('Py_IsInitialized'); - late final _Py_IsInitialized = - _Py_IsInitializedPtr.asFunction(); + late final _PySys_AddWarnOptionUnicodePtr = + _lookup)>>( + 'PySys_AddWarnOptionUnicode'); + late final _PySys_AddWarnOptionUnicode = _PySys_AddWarnOptionUnicodePtr + .asFunction)>(); - ffi.Pointer Py_NewInterpreter() { - return _Py_NewInterpreter1(); + int PySys_HasWarnOptions() { + return _PySys_HasWarnOptions(); } - late final _Py_NewInterpreterPtr = - _lookup Function()>>( - 'Py_NewInterpreter'); - late final _Py_NewInterpreter1 = - _Py_NewInterpreterPtr.asFunction Function()>(); + late final _PySys_HasWarnOptionsPtr = + _lookup>('PySys_HasWarnOptions'); + late final _PySys_HasWarnOptions = + _PySys_HasWarnOptionsPtr.asFunction(); - void Py_EndInterpreter( - ffi.Pointer arg0, + void PySys_AddXOption( + ffi.Pointer arg0, ) { - return _Py_EndInterpreter( + return _PySys_AddXOption( arg0, ); } - late final _Py_EndInterpreterPtr = _lookup< - ffi.NativeFunction)>>( - 'Py_EndInterpreter'); - late final _Py_EndInterpreter = _Py_EndInterpreterPtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PySys_AddXOptionPtr = + _lookup)>>( + 'PySys_AddXOption'); + late final _PySys_AddXOption = + _PySys_AddXOptionPtr.asFunction)>(); - int Py_AtExit( - ffi.Pointer> func, + ffi.Pointer PySys_GetXOptions() { + return _PySys_GetXOptions(); + } + + late final _PySys_GetXOptionsPtr = + _lookup Function()>>( + 'PySys_GetXOptions'); + late final _PySys_GetXOptions = + _PySys_GetXOptionsPtr.asFunction Function()>(); + + ffi.Pointer _PySys_GetAttr( + ffi.Pointer tstate, + ffi.Pointer name, ) { - return _Py_AtExit( - func, + return __PySys_GetAttr( + tstate, + name, ); } - late final _Py_AtExitPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer>)>>( - 'Py_AtExit'); - late final _Py_AtExit = _Py_AtExitPtr.asFunction< - int Function(ffi.Pointer>)>(); + late final __PySys_GetAttrPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PySys_GetAttr'); + late final __PySys_GetAttr = __PySys_GetAttrPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void Py_Exit( - int arg0, + int _PySys_GetSizeOf( + ffi.Pointer arg0, ) { - return _Py_Exit( + return __PySys_GetSizeOf( arg0, ); } - late final _Py_ExitPtr = - _lookup>('Py_Exit'); - late final _Py_Exit = _Py_ExitPtr.asFunction(); + late final __PySys_GetSizeOfPtr = + _lookup)>>( + '_PySys_GetSizeOf'); + late final __PySys_GetSizeOf = + __PySys_GetSizeOfPtr.asFunction)>(); - int Py_Main( - int argc, - ffi.Pointer> argv, + int PySys_Audit( + ffi.Pointer event, + ffi.Pointer argFormat, ) { - return _Py_Main( - argc, - argv, + return _PySys_Audit( + event, + argFormat, ); } - late final _Py_MainPtr = _lookup< + late final _PySys_AuditPtr = _lookup< ffi.NativeFunction< ffi.Int Function( - ffi.Int, ffi.Pointer>)>>('Py_Main'); - late final _Py_Main = _Py_MainPtr.asFunction< - int Function(int, ffi.Pointer>)>(); + ffi.Pointer, ffi.Pointer)>>('PySys_Audit'); + late final _PySys_Audit = _PySys_AuditPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int Py_BytesMain( - int argc, - ffi.Pointer> argv, + int PySys_AddAuditHook( + Py_AuditHookFunction arg0, + ffi.Pointer arg1, ) { - return _Py_BytesMain( - argc, - argv, + return _PySys_AddAuditHook( + arg0, + arg1, ); } - late final _Py_BytesMainPtr = _lookup< + late final _PySys_AddAuditHookPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Int, ffi.Pointer>)>>('Py_BytesMain'); - late final _Py_BytesMain = _Py_BytesMainPtr.asFunction< - int Function(int, ffi.Pointer>)>(); + ffi.Int Function(Py_AuditHookFunction, + ffi.Pointer)>>('PySys_AddAuditHook'); + late final _PySys_AddAuditHook = _PySys_AddAuditHookPtr.asFunction< + int Function(Py_AuditHookFunction, ffi.Pointer)>(); - void Py_SetProgramName( - ffi.Pointer arg0, + ffi.Pointer PyOS_FSPath( + ffi.Pointer path, ) { - return _Py_SetProgramName( - arg0, + return _PyOS_FSPath( + path, ); } - late final _Py_SetProgramNamePtr = - _lookup)>>( - 'Py_SetProgramName'); - late final _Py_SetProgramName = - _Py_SetProgramNamePtr.asFunction)>(); + late final _PyOS_FSPathPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyOS_FSPath'); + late final _PyOS_FSPath = _PyOS_FSPathPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer Py_GetProgramName() { - return _Py_GetProgramName(); + int PyOS_InterruptOccurred() { + return _PyOS_InterruptOccurred(); } - late final _Py_GetProgramNamePtr = - _lookup Function()>>( - 'Py_GetProgramName'); - late final _Py_GetProgramName = - _Py_GetProgramNamePtr.asFunction Function()>(); + late final _PyOS_InterruptOccurredPtr = + _lookup>('PyOS_InterruptOccurred'); + late final _PyOS_InterruptOccurred = + _PyOS_InterruptOccurredPtr.asFunction(); + + void PyOS_BeforeFork() { + return _PyOS_BeforeFork(); + } + + late final _PyOS_BeforeForkPtr = + _lookup>('PyOS_BeforeFork'); + late final _PyOS_BeforeFork = + _PyOS_BeforeForkPtr.asFunction(); - void Py_SetPythonHome( - ffi.Pointer arg0, - ) { - return _Py_SetPythonHome( - arg0, - ); + void PyOS_AfterFork_Parent() { + return _PyOS_AfterFork_Parent(); } - late final _Py_SetPythonHomePtr = - _lookup)>>( - 'Py_SetPythonHome'); - late final _Py_SetPythonHome = - _Py_SetPythonHomePtr.asFunction)>(); + late final _PyOS_AfterFork_ParentPtr = + _lookup>('PyOS_AfterFork_Parent'); + late final _PyOS_AfterFork_Parent = + _PyOS_AfterFork_ParentPtr.asFunction(); - ffi.Pointer Py_GetPythonHome() { - return _Py_GetPythonHome(); + void PyOS_AfterFork_Child() { + return _PyOS_AfterFork_Child(); } - late final _Py_GetPythonHomePtr = - _lookup Function()>>( - 'Py_GetPythonHome'); - late final _Py_GetPythonHome = - _Py_GetPythonHomePtr.asFunction Function()>(); + late final _PyOS_AfterFork_ChildPtr = + _lookup>('PyOS_AfterFork_Child'); + late final _PyOS_AfterFork_Child = + _PyOS_AfterFork_ChildPtr.asFunction(); - ffi.Pointer Py_GetProgramFullPath() { - return _Py_GetProgramFullPath(); + void PyOS_AfterFork() { + return _PyOS_AfterFork(); } - late final _Py_GetProgramFullPathPtr = - _lookup Function()>>( - 'Py_GetProgramFullPath'); - late final _Py_GetProgramFullPath = - _Py_GetProgramFullPathPtr.asFunction Function()>(); + late final _PyOS_AfterForkPtr = + _lookup>('PyOS_AfterFork'); + late final _PyOS_AfterFork = _PyOS_AfterForkPtr.asFunction(); - ffi.Pointer Py_GetPrefix() { - return _Py_GetPrefix(); + int _PyOS_IsMainThread() { + return __PyOS_IsMainThread(); } - late final _Py_GetPrefixPtr = - _lookup Function()>>( - 'Py_GetPrefix'); - late final _Py_GetPrefix = - _Py_GetPrefixPtr.asFunction Function()>(); + late final __PyOS_IsMainThreadPtr = + _lookup>('_PyOS_IsMainThread'); + late final __PyOS_IsMainThread = + __PyOS_IsMainThreadPtr.asFunction(); - ffi.Pointer Py_GetExecPrefix() { - return _Py_GetExecPrefix(); + int PyImport_GetMagicNumber() { + return _PyImport_GetMagicNumber(); } - late final _Py_GetExecPrefixPtr = - _lookup Function()>>( - 'Py_GetExecPrefix'); - late final _Py_GetExecPrefix = - _Py_GetExecPrefixPtr.asFunction Function()>(); + late final _PyImport_GetMagicNumberPtr = + _lookup>( + 'PyImport_GetMagicNumber'); + late final _PyImport_GetMagicNumber = + _PyImport_GetMagicNumberPtr.asFunction(); - ffi.Pointer Py_GetPath() { - return _Py_GetPath(); + ffi.Pointer PyImport_GetMagicTag() { + return _PyImport_GetMagicTag(); } - late final _Py_GetPathPtr = - _lookup Function()>>( - 'Py_GetPath'); - late final _Py_GetPath = - _Py_GetPathPtr.asFunction Function()>(); + late final _PyImport_GetMagicTagPtr = + _lookup Function()>>( + 'PyImport_GetMagicTag'); + late final _PyImport_GetMagicTag = + _PyImport_GetMagicTagPtr.asFunction Function()>(); - void Py_SetPath( - ffi.Pointer arg0, + ffi.Pointer PyImport_ExecCodeModule( + ffi.Pointer name, + ffi.Pointer co, ) { - return _Py_SetPath( - arg0, + return _PyImport_ExecCodeModule( + name, + co, ); } - late final _Py_SetPathPtr = - _lookup)>>( - 'Py_SetPath'); - late final _Py_SetPath = - _Py_SetPathPtr.asFunction)>(); + late final _PyImport_ExecCodeModulePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyImport_ExecCodeModule'); + late final _PyImport_ExecCodeModule = _PyImport_ExecCodeModulePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer Py_GetVersion() { - return _Py_GetVersion(); + ffi.Pointer PyImport_ExecCodeModuleEx( + ffi.Pointer name, + ffi.Pointer co, + ffi.Pointer pathname, + ) { + return _PyImport_ExecCodeModuleEx( + name, + co, + pathname, + ); } - late final _Py_GetVersionPtr = - _lookup Function()>>( - 'Py_GetVersion'); - late final _Py_GetVersion = - _Py_GetVersionPtr.asFunction Function()>(); + late final _PyImport_ExecCodeModuleExPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyImport_ExecCodeModuleEx'); + late final _PyImport_ExecCodeModuleEx = + _PyImport_ExecCodeModuleExPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer Py_GetPlatform() { - return _Py_GetPlatform(); + ffi.Pointer PyImport_ExecCodeModuleWithPathnames( + ffi.Pointer name, + ffi.Pointer co, + ffi.Pointer pathname, + ffi.Pointer cpathname, + ) { + return _PyImport_ExecCodeModuleWithPathnames( + name, + co, + pathname, + cpathname, + ); } - late final _Py_GetPlatformPtr = - _lookup Function()>>( - 'Py_GetPlatform'); - late final _Py_GetPlatform = - _Py_GetPlatformPtr.asFunction Function()>(); + late final _PyImport_ExecCodeModuleWithPathnamesPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyImport_ExecCodeModuleWithPathnames'); + late final _PyImport_ExecCodeModuleWithPathnames = + _PyImport_ExecCodeModuleWithPathnamesPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer Py_GetCopyright() { - return _Py_GetCopyright(); + ffi.Pointer PyImport_ExecCodeModuleObject( + ffi.Pointer name, + ffi.Pointer co, + ffi.Pointer pathname, + ffi.Pointer cpathname, + ) { + return _PyImport_ExecCodeModuleObject( + name, + co, + pathname, + cpathname, + ); } - late final _Py_GetCopyrightPtr = - _lookup Function()>>( - 'Py_GetCopyright'); - late final _Py_GetCopyright = - _Py_GetCopyrightPtr.asFunction Function()>(); + late final _PyImport_ExecCodeModuleObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyImport_ExecCodeModuleObject'); + late final _PyImport_ExecCodeModuleObject = + _PyImport_ExecCodeModuleObjectPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer Py_GetCompiler() { - return _Py_GetCompiler(); + ffi.Pointer PyImport_GetModuleDict() { + return _PyImport_GetModuleDict(); } - late final _Py_GetCompilerPtr = - _lookup Function()>>( - 'Py_GetCompiler'); - late final _Py_GetCompiler = - _Py_GetCompilerPtr.asFunction Function()>(); + late final _PyImport_GetModuleDictPtr = + _lookup Function()>>( + 'PyImport_GetModuleDict'); + late final _PyImport_GetModuleDict = + _PyImport_GetModuleDictPtr.asFunction Function()>(); - ffi.Pointer Py_GetBuildInfo() { - return _Py_GetBuildInfo(); + ffi.Pointer PyImport_GetModule( + ffi.Pointer name, + ) { + return _PyImport_GetModule( + name, + ); } - late final _Py_GetBuildInfoPtr = - _lookup Function()>>( - 'Py_GetBuildInfo'); - late final _Py_GetBuildInfo = - _Py_GetBuildInfoPtr.asFunction Function()>(); + late final _PyImport_GetModulePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_GetModule'); + late final _PyImport_GetModule = _PyImport_GetModulePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - PyOS_sighandler_t PyOS_getsig( - int arg0, + ffi.Pointer PyImport_AddModuleObject( + ffi.Pointer name, ) { - return _PyOS_getsig( - arg0, + return _PyImport_AddModuleObject( + name, ); } - late final _PyOS_getsigPtr = - _lookup>( - 'PyOS_getsig'); - late final _PyOS_getsig = - _PyOS_getsigPtr.asFunction(); + late final _PyImport_AddModuleObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_AddModuleObject'); + late final _PyImport_AddModuleObject = _PyImport_AddModuleObjectPtr + .asFunction Function(ffi.Pointer)>(); - PyOS_sighandler_t PyOS_setsig( - int arg0, - PyOS_sighandler_t arg1, + ffi.Pointer PyImport_AddModule( + ffi.Pointer name, ) { - return _PyOS_setsig( - arg0, - arg1, + return _PyImport_AddModule( + name, ); } - late final _PyOS_setsigPtr = _lookup< + late final _PyImport_AddModulePtr = _lookup< ffi.NativeFunction< - PyOS_sighandler_t Function( - ffi.Int, PyOS_sighandler_t)>>('PyOS_setsig'); - late final _PyOS_setsig = _PyOS_setsigPtr.asFunction< - PyOS_sighandler_t Function(int, PyOS_sighandler_t)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_AddModule'); + late final _PyImport_AddModule = _PyImport_AddModulePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int Py_FrozenMain( - int argc, - ffi.Pointer> argv, + ffi.Pointer PyImport_ImportModule( + ffi.Pointer name, ) { - return _Py_FrozenMain( - argc, - argv, + return _PyImport_ImportModule( + name, ); } - late final _Py_FrozenMainPtr = _lookup< + late final _PyImport_ImportModulePtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Int, ffi.Pointer>)>>('Py_FrozenMain'); - late final _Py_FrozenMain = _Py_FrozenMainPtr.asFunction< - int Function(int, ffi.Pointer>)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_ImportModule'); + late final _PyImport_ImportModule = _PyImport_ImportModulePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int Py_SetStandardStreamEncoding( - ffi.Pointer encoding, - ffi.Pointer errors, + ffi.Pointer PyImport_ImportModuleNoBlock( + ffi.Pointer name, ) { - return _Py_SetStandardStreamEncoding( - encoding, - errors, + return _PyImport_ImportModuleNoBlock( + name, ); } - late final _Py_SetStandardStreamEncodingPtr = _lookup< + late final _PyImport_ImportModuleNoBlockPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('Py_SetStandardStreamEncoding'); - late final _Py_SetStandardStreamEncoding = _Py_SetStandardStreamEncodingPtr - .asFunction, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_ImportModuleNoBlock'); + late final _PyImport_ImportModuleNoBlock = _PyImport_ImportModuleNoBlockPtr + .asFunction Function(ffi.Pointer)>(); - PyStatus Py_PreInitialize( - ffi.Pointer src_config, + ffi.Pointer PyImport_ImportModuleLevel( + ffi.Pointer name, + ffi.Pointer globals, + ffi.Pointer locals, + ffi.Pointer fromlist, + int level, ) { - return _Py_PreInitialize( - src_config, + return _PyImport_ImportModuleLevel( + name, + globals, + locals, + fromlist, + level, ); } - late final _Py_PreInitializePtr = - _lookup)>>( - 'Py_PreInitialize'); - late final _Py_PreInitialize = _Py_PreInitializePtr.asFunction< - PyStatus Function(ffi.Pointer)>(); + late final _PyImport_ImportModuleLevelPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int)>>('PyImport_ImportModuleLevel'); + late final _PyImport_ImportModuleLevel = + _PyImport_ImportModuleLevelPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int)>(); - PyStatus Py_PreInitializeFromBytesArgs( - ffi.Pointer src_config, - int argc, - ffi.Pointer> argv, + ffi.Pointer PyImport_ImportModuleLevelObject( + ffi.Pointer name, + ffi.Pointer globals, + ffi.Pointer locals, + ffi.Pointer fromlist, + int level, ) { - return _Py_PreInitializeFromBytesArgs( - src_config, - argc, - argv, + return _PyImport_ImportModuleLevelObject( + name, + globals, + locals, + fromlist, + level, ); } - late final _Py_PreInitializeFromBytesArgsPtr = _lookup< - ffi.NativeFunction< - PyStatus Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer>)>>( - 'Py_PreInitializeFromBytesArgs'); - late final _Py_PreInitializeFromBytesArgs = - _Py_PreInitializeFromBytesArgsPtr.asFunction< - PyStatus Function(ffi.Pointer, int, - ffi.Pointer>)>(); + late final _PyImport_ImportModuleLevelObjectPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Int)>>('PyImport_ImportModuleLevelObject'); + late final _PyImport_ImportModuleLevelObject = + _PyImport_ImportModuleLevelObjectPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + int)>(); - PyStatus Py_PreInitializeFromArgs( - ffi.Pointer src_config, - int argc, - ffi.Pointer> argv, + ffi.Pointer PyImport_GetImporter( + ffi.Pointer path, ) { - return _Py_PreInitializeFromArgs( - src_config, - argc, - argv, + return _PyImport_GetImporter( + path, ); } - late final _Py_PreInitializeFromArgsPtr = _lookup< - ffi.NativeFunction< - PyStatus Function(ffi.Pointer, Py_ssize_t, - ffi.Pointer>)>>( - 'Py_PreInitializeFromArgs'); - late final _Py_PreInitializeFromArgs = - _Py_PreInitializeFromArgsPtr.asFunction< - PyStatus Function(ffi.Pointer, int, - ffi.Pointer>)>(); + late final _PyImport_GetImporterPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_GetImporter'); + late final _PyImport_GetImporter = _PyImport_GetImporterPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _Py_IsCoreInitialized() { - return __Py_IsCoreInitialized(); + ffi.Pointer PyImport_Import( + ffi.Pointer name, + ) { + return _PyImport_Import( + name, + ); } - late final __Py_IsCoreInitializedPtr = - _lookup>('_Py_IsCoreInitialized'); - late final __Py_IsCoreInitialized = - __Py_IsCoreInitializedPtr.asFunction(); + late final _PyImport_ImportPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_Import'); + late final _PyImport_Import = _PyImport_ImportPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - PyStatus Py_InitializeFromConfig( - ffi.Pointer config, + ffi.Pointer PyImport_ReloadModule( + ffi.Pointer m, ) { - return _Py_InitializeFromConfig( - config, + return _PyImport_ReloadModule( + m, ); } - late final _Py_InitializeFromConfigPtr = - _lookup)>>( - 'Py_InitializeFromConfig'); - late final _Py_InitializeFromConfig = _Py_InitializeFromConfigPtr.asFunction< - PyStatus Function(ffi.Pointer)>(); + late final _PyImport_ReloadModulePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyImport_ReloadModule'); + late final _PyImport_ReloadModule = _PyImport_ReloadModulePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - PyStatus _Py_InitializeMain() { - return __Py_InitializeMain(); + int PyImport_ImportFrozenModuleObject( + ffi.Pointer name, + ) { + return _PyImport_ImportFrozenModuleObject( + name, + ); } - late final __Py_InitializeMainPtr = - _lookup>('_Py_InitializeMain'); - late final __Py_InitializeMain = - __Py_InitializeMainPtr.asFunction(); + late final _PyImport_ImportFrozenModuleObjectPtr = + _lookup)>>( + 'PyImport_ImportFrozenModuleObject'); + late final _PyImport_ImportFrozenModuleObject = + _PyImport_ImportFrozenModuleObjectPtr.asFunction< + int Function(ffi.Pointer)>(); - int Py_RunMain() { - return _Py_RunMain(); + int PyImport_ImportFrozenModule( + ffi.Pointer name, + ) { + return _PyImport_ImportFrozenModule( + name, + ); } - late final _Py_RunMainPtr = - _lookup>('Py_RunMain'); - late final _Py_RunMain = _Py_RunMainPtr.asFunction(); + late final _PyImport_ImportFrozenModulePtr = + _lookup)>>( + 'PyImport_ImportFrozenModule'); + late final _PyImport_ImportFrozenModule = _PyImport_ImportFrozenModulePtr + .asFunction)>(); - void Py_ExitStatusException( - PyStatus err, + int PyImport_AppendInittab( + ffi.Pointer name, + ffi.Pointer Function()>> initfunc, ) { - return _Py_ExitStatusException( - err, + return _PyImport_AppendInittab( + name, + initfunc, ); } - late final _Py_ExitStatusExceptionPtr = - _lookup>( - 'Py_ExitStatusException'); - late final _Py_ExitStatusException = - _Py_ExitStatusExceptionPtr.asFunction(); + late final _PyImport_AppendInittabPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Pointer< + ffi.NativeFunction Function()>>)>>( + 'PyImport_AppendInittab'); + late final _PyImport_AppendInittab = _PyImport_AppendInittabPtr.asFunction< + int Function(ffi.Pointer, + ffi.Pointer Function()>>)>(); + + ffi.Pointer PyInit__imp() { + return _PyInit__imp(); + } + + late final _PyInit__impPtr = + _lookup Function()>>( + 'PyInit__imp'); + late final _PyInit__imp = + _PyInit__impPtr.asFunction Function()>(); - void _Py_RestoreSignals() { - return __Py_RestoreSignals(); + int _PyImport_IsInitialized( + ffi.Pointer arg0, + ) { + return __PyImport_IsInitialized( + arg0, + ); } - late final __Py_RestoreSignalsPtr = - _lookup>('_Py_RestoreSignals'); - late final __Py_RestoreSignals = - __Py_RestoreSignalsPtr.asFunction(); + late final __PyImport_IsInitializedPtr = _lookup< + ffi + .NativeFunction)>>( + '_PyImport_IsInitialized'); + late final __PyImport_IsInitialized = __PyImport_IsInitializedPtr + .asFunction)>(); - int Py_FdIsInteractive( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer _PyImport_GetModuleId( + ffi.Pointer<_Py_Identifier> name, ) { - return _Py_FdIsInteractive1( - arg0, - arg1, + return __PyImport_GetModuleId( + name, ); } - late final _Py_FdIsInteractivePtr = _lookup< + late final __PyImport_GetModuleIdPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('Py_FdIsInteractive'); - late final _Py_FdIsInteractive1 = _Py_FdIsInteractivePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer<_Py_Identifier>)>>('_PyImport_GetModuleId'); + late final __PyImport_GetModuleId = __PyImport_GetModuleIdPtr.asFunction< + ffi.Pointer Function(ffi.Pointer<_Py_Identifier>)>(); - int _Py_FdIsInteractive( - ffi.Pointer fp, - ffi.Pointer filename, + int _PyImport_SetModule( + ffi.Pointer name, + ffi.Pointer module, ) { - return __Py_FdIsInteractive( - fp, - filename, + return __PyImport_SetModule( + name, + module, ); } - late final __Py_FdIsInteractivePtr = _lookup< + late final __PyImport_SetModulePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_Py_FdIsInteractive'); - late final __Py_FdIsInteractive = __Py_FdIsInteractivePtr - .asFunction, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyImport_SetModule'); + late final __PyImport_SetModule = __PyImport_SetModulePtr + .asFunction, ffi.Pointer)>(); - void _Py_SetProgramFullPath( - ffi.Pointer arg0, + int _PyImport_SetModuleString( + ffi.Pointer name, + ffi.Pointer module, ) { - return __Py_SetProgramFullPath( - arg0, + return __PyImport_SetModuleString( + name, + module, ); } - late final __Py_SetProgramFullPathPtr = - _lookup)>>( - '_Py_SetProgramFullPath'); - late final __Py_SetProgramFullPath = __Py_SetProgramFullPathPtr - .asFunction)>(); + late final __PyImport_SetModuleStringPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyImport_SetModuleString'); + late final __PyImport_SetModuleString = __PyImport_SetModuleStringPtr + .asFunction, ffi.Pointer)>(); - ffi.Pointer _Py_gitidentifier() { - return __Py_gitidentifier(); + void _PyImport_AcquireLock() { + return __PyImport_AcquireLock(); } - late final __Py_gitidentifierPtr = - _lookup Function()>>( - '_Py_gitidentifier'); - late final __Py_gitidentifier = - __Py_gitidentifierPtr.asFunction Function()>(); + late final __PyImport_AcquireLockPtr = + _lookup>('_PyImport_AcquireLock'); + late final __PyImport_AcquireLock = + __PyImport_AcquireLockPtr.asFunction(); - ffi.Pointer _Py_gitversion() { - return __Py_gitversion(); + int _PyImport_ReleaseLock() { + return __PyImport_ReleaseLock(); } - late final __Py_gitversionPtr = - _lookup Function()>>( - '_Py_gitversion'); - late final __Py_gitversion = - __Py_gitversionPtr.asFunction Function()>(); + late final __PyImport_ReleaseLockPtr = + _lookup>('_PyImport_ReleaseLock'); + late final __PyImport_ReleaseLock = + __PyImport_ReleaseLockPtr.asFunction(); - int _Py_IsFinalizing() { - return __Py_IsFinalizing(); + int _PyImport_FixupBuiltin( + ffi.Pointer mod, + ffi.Pointer name, + ffi.Pointer modules, + ) { + return __PyImport_FixupBuiltin( + mod, + name, + modules, + ); } - late final __Py_IsFinalizingPtr = - _lookup>('_Py_IsFinalizing'); - late final __Py_IsFinalizing = - __Py_IsFinalizingPtr.asFunction(); + late final __PyImport_FixupBuiltinPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('_PyImport_FixupBuiltin'); + late final __PyImport_FixupBuiltin = __PyImport_FixupBuiltinPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - int _PyOS_URandom( - ffi.Pointer buffer, - int size, + int _PyImport_FixupExtensionObject( + ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer arg2, + ffi.Pointer arg3, ) { - return __PyOS_URandom( - buffer, - size, + return __PyImport_FixupExtensionObject( + arg0, + arg1, + arg2, + arg3, ); } - late final __PyOS_URandomPtr = _lookup< + late final __PyImport_FixupExtensionObjectPtr = _lookup< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer, Py_ssize_t)>>('_PyOS_URandom'); - late final __PyOS_URandom = - __PyOS_URandomPtr.asFunction, int)>(); + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_PyImport_FixupExtensionObject'); + late final __PyImport_FixupExtensionObject = + __PyImport_FixupExtensionObjectPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - int _PyOS_URandomNonblock( - ffi.Pointer buffer, - int size, + late final ffi.Pointer> _PyImport_Inittab = + _lookup>('PyImport_Inittab'); + + ffi.Pointer<_inittab> get PyImport_Inittab => _PyImport_Inittab.value; + + set PyImport_Inittab(ffi.Pointer<_inittab> value) => + _PyImport_Inittab.value = value; + + int PyImport_ExtendInittab( + ffi.Pointer<_inittab> newtab, ) { - return __PyOS_URandomNonblock( - buffer, - size, + return _PyImport_ExtendInittab( + newtab, ); } - late final __PyOS_URandomNonblockPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, Py_ssize_t)>>('_PyOS_URandomNonblock'); - late final __PyOS_URandomNonblock = __PyOS_URandomNonblockPtr - .asFunction, int)>(); + late final _PyImport_ExtendInittabPtr = + _lookup)>>( + 'PyImport_ExtendInittab'); + late final _PyImport_ExtendInittab = _PyImport_ExtendInittabPtr.asFunction< + int Function(ffi.Pointer<_inittab>)>(); - int _Py_CoerceLegacyLocale( - int warn, + late final ffi.Pointer> _PyImport_FrozenModules = + _lookup>('PyImport_FrozenModules'); + + ffi.Pointer<_frozen> get PyImport_FrozenModules => + _PyImport_FrozenModules.value; + + set PyImport_FrozenModules(ffi.Pointer<_frozen> value) => + _PyImport_FrozenModules.value = value; + + ffi.Pointer _PyImport_GetModuleAttr( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __Py_CoerceLegacyLocale( - warn, + return __PyImport_GetModuleAttr( + arg0, + arg1, ); } - late final __Py_CoerceLegacyLocalePtr = - _lookup>( - '_Py_CoerceLegacyLocale'); - late final __Py_CoerceLegacyLocale = - __Py_CoerceLegacyLocalePtr.asFunction(); + late final __PyImport_GetModuleAttrPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyImport_GetModuleAttr'); + late final __PyImport_GetModuleAttr = __PyImport_GetModuleAttrPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _Py_LegacyLocaleDetected( - int warn, + ffi.Pointer _PyImport_GetModuleAttrString( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __Py_LegacyLocaleDetected( - warn, + return __PyImport_GetModuleAttrString( + arg0, + arg1, ); } - late final __Py_LegacyLocaleDetectedPtr = - _lookup>( - '_Py_LegacyLocaleDetected'); - late final __Py_LegacyLocaleDetected = - __Py_LegacyLocaleDetectedPtr.asFunction(); + late final __PyImport_GetModuleAttrStringPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyImport_GetModuleAttrString'); + late final __PyImport_GetModuleAttrString = + __PyImport_GetModuleAttrStringPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _Py_SetLocaleFromEnv( - int category, + ffi.Pointer PyObject_CallNoArgs( + ffi.Pointer func, ) { - return __Py_SetLocaleFromEnv( - category, + return _PyObject_CallNoArgs( + func, ); } - late final __Py_SetLocaleFromEnvPtr = - _lookup Function(ffi.Int)>>( - '_Py_SetLocaleFromEnv'); - late final __Py_SetLocaleFromEnv = __Py_SetLocaleFromEnvPtr - .asFunction Function(int)>(); + late final _PyObject_CallNoArgsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyObject_CallNoArgs'); + late final _PyObject_CallNoArgs = _PyObject_CallNoArgsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer _Py_NewInterpreter( - int isolated_subinterpreter, + ffi.Pointer PyObject_Call( + ffi.Pointer callable, + ffi.Pointer args, + ffi.Pointer kwargs, ) { - return __Py_NewInterpreter( - isolated_subinterpreter, + return _PyObject_Call( + callable, + args, + kwargs, ); } - late final __Py_NewInterpreterPtr = - _lookup Function(ffi.Int)>>( - '_Py_NewInterpreter'); - late final __Py_NewInterpreter = __Py_NewInterpreterPtr - .asFunction Function(int)>(); + late final _PyObject_CallPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>('PyObject_Call'); + late final _PyObject_Call = _PyObject_CallPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyEval_CallObjectWithKeywords( + ffi.Pointer PyObject_CallObject( ffi.Pointer callable, ffi.Pointer args, - ffi.Pointer kwargs, ) { - return _PyEval_CallObjectWithKeywords( + return _PyObject_CallObject( callable, args, - kwargs, ); } - late final _PyEval_CallObjectWithKeywordsPtr = _lookup< + late final _PyObject_CallObjectPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyEval_CallObjectWithKeywords'); - late final _PyEval_CallObjectWithKeywords = - _PyEval_CallObjectWithKeywordsPtr.asFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('PyObject_CallObject'); + late final _PyObject_CallObject = _PyObject_CallObjectPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyEval_CallFunction( + ffi.Pointer PyObject_CallFunction( ffi.Pointer callable, ffi.Pointer format, ) { - return _PyEval_CallFunction( + return _PyObject_CallFunction( callable, format, ); } - late final _PyEval_CallFunctionPtr = _lookup< + late final _PyObject_CallFunctionPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyEval_CallFunction'); - late final _PyEval_CallFunction = _PyEval_CallFunctionPtr.asFunction< + ffi.Pointer)>>('PyObject_CallFunction'); + late final _PyObject_CallFunction = _PyObject_CallFunctionPtr.asFunction< ffi.Pointer Function( ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyEval_CallMethod( + ffi.Pointer PyObject_CallMethod( ffi.Pointer obj, ffi.Pointer name, ffi.Pointer format, ) { - return _PyEval_CallMethod( + return _PyObject_CallMethod1( obj, name, format, ); } - late final _PyEval_CallMethodPtr = _lookup< + late final _PyObject_CallMethodPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyEval_CallMethod'); - late final _PyEval_CallMethod = _PyEval_CallMethodPtr.asFunction< + ffi.Pointer)>>('PyObject_CallMethod'); + late final _PyObject_CallMethod1 = _PyObject_CallMethodPtr.asFunction< ffi.Pointer Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyEval_GetBuiltins() { - return _PyEval_GetBuiltins(); - } - - late final _PyEval_GetBuiltinsPtr = - _lookup Function()>>( - 'PyEval_GetBuiltins'); - late final _PyEval_GetBuiltins = - _PyEval_GetBuiltinsPtr.asFunction Function()>(); - - ffi.Pointer PyEval_GetGlobals() { - return _PyEval_GetGlobals(); - } - - late final _PyEval_GetGlobalsPtr = - _lookup Function()>>( - 'PyEval_GetGlobals'); - late final _PyEval_GetGlobals = - _PyEval_GetGlobalsPtr.asFunction Function()>(); - - ffi.Pointer PyEval_GetLocals() { - return _PyEval_GetLocals(); - } - - late final _PyEval_GetLocalsPtr = - _lookup Function()>>( - 'PyEval_GetLocals'); - late final _PyEval_GetLocals = - _PyEval_GetLocalsPtr.asFunction Function()>(); - - ffi.Pointer PyEval_GetFrame() { - return _PyEval_GetFrame(); - } - - late final _PyEval_GetFramePtr = - _lookup Function()>>( - 'PyEval_GetFrame'); - late final _PyEval_GetFrame = - _PyEval_GetFramePtr.asFunction Function()>(); - - int Py_AddPendingCall( - ffi.Pointer)>> - func, - ffi.Pointer arg, + ffi.Pointer _PyObject_CallFunction_SizeT( + ffi.Pointer callable, + ffi.Pointer format, ) { - return _Py_AddPendingCall( - func, - arg, + return __PyObject_CallFunction_SizeT( + callable, + format, ); } - late final _Py_AddPendingCallPtr = _lookup< + late final __PyObject_CallFunction_SizeTPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer< - ffi.NativeFunction)>>, - ffi.Pointer)>>('Py_AddPendingCall'); - late final _Py_AddPendingCall = _Py_AddPendingCallPtr.asFunction< - int Function( - ffi.Pointer< - ffi.NativeFunction)>>, - ffi.Pointer)>(); - - int Py_MakePendingCalls() { - return _Py_MakePendingCalls(); - } - - late final _Py_MakePendingCallsPtr = - _lookup>('Py_MakePendingCalls'); - late final _Py_MakePendingCalls = - _Py_MakePendingCallsPtr.asFunction(); - - void Py_SetRecursionLimit( - int arg0, - ) { - return _Py_SetRecursionLimit( - arg0, - ); - } - - late final _Py_SetRecursionLimitPtr = - _lookup>( - 'Py_SetRecursionLimit'); - late final _Py_SetRecursionLimit = - _Py_SetRecursionLimitPtr.asFunction(); - - int Py_GetRecursionLimit() { - return _Py_GetRecursionLimit(); - } - - late final _Py_GetRecursionLimitPtr = - _lookup>('Py_GetRecursionLimit'); - late final _Py_GetRecursionLimit = - _Py_GetRecursionLimitPtr.asFunction(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('_PyObject_CallFunction_SizeT'); + late final __PyObject_CallFunction_SizeT = + __PyObject_CallFunction_SizeTPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int Py_EnterRecursiveCall( - ffi.Pointer where, + ffi.Pointer _PyObject_CallMethod_SizeT( + ffi.Pointer obj, + ffi.Pointer name, + ffi.Pointer format, ) { - return _Py_EnterRecursiveCall( - where, + return __PyObject_CallMethod_SizeT( + obj, + name, + format, ); } - late final _Py_EnterRecursiveCallPtr = - _lookup)>>( - 'Py_EnterRecursiveCall'); - late final _Py_EnterRecursiveCall = _Py_EnterRecursiveCallPtr.asFunction< - int Function(ffi.Pointer)>(); - - void Py_LeaveRecursiveCall() { - return _Py_LeaveRecursiveCall(); - } - - late final _Py_LeaveRecursiveCallPtr = - _lookup>('Py_LeaveRecursiveCall'); - late final _Py_LeaveRecursiveCall = - _Py_LeaveRecursiveCallPtr.asFunction(); + late final __PyObject_CallMethod_SizeTPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_PyObject_CallMethod_SizeT'); + late final __PyObject_CallMethod_SizeT = + __PyObject_CallMethod_SizeTPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyEval_GetFuncName( - ffi.Pointer arg0, + ffi.Pointer PyObject_CallFunctionObjArgs( + ffi.Pointer callable, ) { - return _PyEval_GetFuncName( - arg0, + return _PyObject_CallFunctionObjArgs( + callable, ); } - late final _PyEval_GetFuncNamePtr = _lookup< + late final _PyObject_CallFunctionObjArgsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyEval_GetFuncName'); - late final _PyEval_GetFuncName = _PyEval_GetFuncNamePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyObject_CallFunctionObjArgs'); + late final _PyObject_CallFunctionObjArgs = _PyObject_CallFunctionObjArgsPtr + .asFunction Function(ffi.Pointer)>(); - ffi.Pointer PyEval_GetFuncDesc( - ffi.Pointer arg0, + ffi.Pointer PyObject_CallMethodObjArgs( + ffi.Pointer obj, + ffi.Pointer name, ) { - return _PyEval_GetFuncDesc( - arg0, + return _PyObject_CallMethodObjArgs( + obj, + name, ); } - late final _PyEval_GetFuncDescPtr = _lookup< + late final _PyObject_CallMethodObjArgsPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyEval_GetFuncDesc'); - late final _PyEval_GetFuncDesc = _PyEval_GetFuncDescPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_CallMethodObjArgs'); + late final _PyObject_CallMethodObjArgs = + _PyObject_CallMethodObjArgsPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyEval_EvalFrame( - ffi.Pointer arg0, + ffi.Pointer PyObject_Type( + ffi.Pointer o, ) { - return _PyEval_EvalFrame( - arg0, + return _PyObject_Type( + o, ); } - late final _PyEval_EvalFramePtr = _lookup< + late final _PyObject_TypePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyEval_EvalFrame'); - late final _PyEval_EvalFrame = _PyEval_EvalFramePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer)>>('PyObject_Type'); + late final _PyObject_Type = _PyObject_TypePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyEval_EvalFrameEx( - ffi.Pointer f, - int exc, + int PyObject_Size( + ffi.Pointer o, ) { - return _PyEval_EvalFrameEx( - f, - exc, + return _PyObject_Size( + o, ); } - late final _PyEval_EvalFrameExPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Int)>>('PyEval_EvalFrameEx'); - late final _PyEval_EvalFrameEx = _PyEval_EvalFrameExPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + late final _PyObject_SizePtr = + _lookup)>>( + 'PyObject_Size'); + late final _PyObject_Size = + _PyObject_SizePtr.asFunction)>(); - ffi.Pointer PyEval_SaveThread() { - return _PyEval_SaveThread(); + int PyObject_Length( + ffi.Pointer o, + ) { + return _PyObject_Length( + o, + ); } - late final _PyEval_SaveThreadPtr = - _lookup Function()>>( - 'PyEval_SaveThread'); - late final _PyEval_SaveThread = - _PyEval_SaveThreadPtr.asFunction Function()>(); + late final _PyObject_LengthPtr = + _lookup)>>( + 'PyObject_Length'); + late final _PyObject_Length = + _PyObject_LengthPtr.asFunction)>(); - void PyEval_RestoreThread( - ffi.Pointer arg0, + ffi.Pointer PyObject_GetItem( + ffi.Pointer o, + ffi.Pointer key, ) { - return _PyEval_RestoreThread( - arg0, + return _PyObject_GetItem( + o, + key, ); } - late final _PyEval_RestoreThreadPtr = _lookup< - ffi.NativeFunction)>>( - 'PyEval_RestoreThread'); - late final _PyEval_RestoreThread = _PyEval_RestoreThreadPtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PyObject_GetItemPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_GetItem'); + late final _PyObject_GetItem = _PyObject_GetItemPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyEval_ThreadsInitialized() { - return _PyEval_ThreadsInitialized(); + int PyObject_SetItem( + ffi.Pointer o, + ffi.Pointer key, + ffi.Pointer v, + ) { + return _PyObject_SetItem( + o, + key, + v, + ); } - late final _PyEval_ThreadsInitializedPtr = - _lookup>( - 'PyEval_ThreadsInitialized'); - late final _PyEval_ThreadsInitialized = - _PyEval_ThreadsInitializedPtr.asFunction(); + late final _PyObject_SetItemPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyObject_SetItem'); + late final _PyObject_SetItem = _PyObject_SetItemPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - void PyEval_InitThreads() { - return _PyEval_InitThreads(); + int PyObject_DelItemString( + ffi.Pointer o, + ffi.Pointer key, + ) { + return _PyObject_DelItemString( + o, + key, + ); } - late final _PyEval_InitThreadsPtr = - _lookup>('PyEval_InitThreads'); - late final _PyEval_InitThreads = - _PyEval_InitThreadsPtr.asFunction(); + late final _PyObject_DelItemStringPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_DelItemString'); + late final _PyObject_DelItemString = _PyObject_DelItemStringPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - void PyEval_AcquireLock() { - return _PyEval_AcquireLock(); + int PyObject_DelItem( + ffi.Pointer o, + ffi.Pointer key, + ) { + return _PyObject_DelItem( + o, + key, + ); } - late final _PyEval_AcquireLockPtr = - _lookup>('PyEval_AcquireLock'); - late final _PyEval_AcquireLock = - _PyEval_AcquireLockPtr.asFunction(); + late final _PyObject_DelItemPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_DelItem'); + late final _PyObject_DelItem = _PyObject_DelItemPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - void PyEval_ReleaseLock() { - return _PyEval_ReleaseLock(); + int PyObject_AsCharBuffer( + ffi.Pointer obj, + ffi.Pointer> buffer, + ffi.Pointer buffer_len, + ) { + return _PyObject_AsCharBuffer( + obj, + buffer, + buffer_len, + ); } - late final _PyEval_ReleaseLockPtr = - _lookup>('PyEval_ReleaseLock'); - late final _PyEval_ReleaseLock = - _PyEval_ReleaseLockPtr.asFunction(); + late final _PyObject_AsCharBufferPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer)>>('PyObject_AsCharBuffer'); + late final _PyObject_AsCharBuffer = _PyObject_AsCharBufferPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer>, + ffi.Pointer)>(); - void PyEval_AcquireThread( - ffi.Pointer tstate, + int PyObject_CheckReadBuffer( + ffi.Pointer obj, ) { - return _PyEval_AcquireThread( - tstate, + return _PyObject_CheckReadBuffer( + obj, ); } - late final _PyEval_AcquireThreadPtr = _lookup< - ffi.NativeFunction)>>( - 'PyEval_AcquireThread'); - late final _PyEval_AcquireThread = _PyEval_AcquireThreadPtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PyObject_CheckReadBufferPtr = + _lookup)>>( + 'PyObject_CheckReadBuffer'); + late final _PyObject_CheckReadBuffer = _PyObject_CheckReadBufferPtr + .asFunction)>(); - void PyEval_ReleaseThread( - ffi.Pointer tstate, + int PyObject_AsReadBuffer( + ffi.Pointer obj, + ffi.Pointer> buffer, + ffi.Pointer buffer_len, ) { - return _PyEval_ReleaseThread( - tstate, + return _PyObject_AsReadBuffer( + obj, + buffer, + buffer_len, ); } - late final _PyEval_ReleaseThreadPtr = _lookup< - ffi.NativeFunction)>>( - 'PyEval_ReleaseThread'); - late final _PyEval_ReleaseThread = _PyEval_ReleaseThreadPtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PyObject_AsReadBufferPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer)>>('PyObject_AsReadBuffer'); + late final _PyObject_AsReadBuffer = _PyObject_AsReadBufferPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer>, + ffi.Pointer)>(); - void PyEval_SetProfile( - Py_tracefunc arg0, - ffi.Pointer arg1, + int PyObject_AsWriteBuffer( + ffi.Pointer obj, + ffi.Pointer> buffer, + ffi.Pointer buffer_len, ) { - return _PyEval_SetProfile1( - arg0, - arg1, + return _PyObject_AsWriteBuffer( + obj, + buffer, + buffer_len, ); } - late final _PyEval_SetProfilePtr = _lookup< + late final _PyObject_AsWriteBufferPtr = _lookup< ffi.NativeFunction< - ffi.Void Function( - Py_tracefunc, ffi.Pointer)>>('PyEval_SetProfile'); - late final _PyEval_SetProfile1 = _PyEval_SetProfilePtr.asFunction< - void Function(Py_tracefunc, ffi.Pointer)>(); + ffi.Int Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer)>>('PyObject_AsWriteBuffer'); + late final _PyObject_AsWriteBuffer = _PyObject_AsWriteBufferPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer>, + ffi.Pointer)>(); - int _PyEval_SetProfile( - ffi.Pointer tstate, - Py_tracefunc func, - ffi.Pointer arg, + ffi.Pointer PyObject_Format( + ffi.Pointer obj, + ffi.Pointer format_spec, ) { - return __PyEval_SetProfile( - tstate, - func, - arg, + return _PyObject_Format( + obj, + format_spec, ); } - late final __PyEval_SetProfilePtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_tracefunc, - ffi.Pointer)>>('_PyEval_SetProfile'); - late final __PyEval_SetProfile = __PyEval_SetProfilePtr.asFunction< - int Function( - ffi.Pointer, Py_tracefunc, ffi.Pointer)>(); + late final _PyObject_FormatPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_Format'); + late final _PyObject_Format = _PyObject_FormatPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PyEval_SetTrace( - Py_tracefunc arg0, - ffi.Pointer arg1, + ffi.Pointer PyObject_GetIter( + ffi.Pointer arg0, ) { - return _PyEval_SetTrace1( + return _PyObject_GetIter( arg0, - arg1, ); } - late final _PyEval_SetTracePtr = _lookup< + late final _PyObject_GetIterPtr = _lookup< ffi.NativeFunction< - ffi.Void Function( - Py_tracefunc, ffi.Pointer)>>('PyEval_SetTrace'); - late final _PyEval_SetTrace1 = _PyEval_SetTracePtr.asFunction< - void Function(Py_tracefunc, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyObject_GetIter'); + late final _PyObject_GetIter = _PyObject_GetIterPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PyEval_SetTrace( - ffi.Pointer tstate, - Py_tracefunc func, - ffi.Pointer arg, + ffi.Pointer PyObject_GetAIter( + ffi.Pointer arg0, ) { - return __PyEval_SetTrace( - tstate, - func, - arg, + return _PyObject_GetAIter( + arg0, ); } - late final __PyEval_SetTracePtr = _lookup< + late final _PyObject_GetAIterPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, Py_tracefunc, - ffi.Pointer)>>('_PyEval_SetTrace'); - late final __PyEval_SetTrace = __PyEval_SetTracePtr.asFunction< - int Function( - ffi.Pointer, Py_tracefunc, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyObject_GetAIter'); + late final _PyObject_GetAIter = _PyObject_GetAIterPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PyEval_GetCoroutineOriginTrackingDepth() { - return __PyEval_GetCoroutineOriginTrackingDepth(); + int PyIter_Check( + ffi.Pointer arg0, + ) { + return _PyIter_Check( + arg0, + ); } - late final __PyEval_GetCoroutineOriginTrackingDepthPtr = - _lookup>( - '_PyEval_GetCoroutineOriginTrackingDepth'); - late final __PyEval_GetCoroutineOriginTrackingDepth = - __PyEval_GetCoroutineOriginTrackingDepthPtr.asFunction(); + late final _PyIter_CheckPtr = + _lookup)>>( + 'PyIter_Check'); + late final _PyIter_Check = + _PyIter_CheckPtr.asFunction)>(); - int _PyEval_SetAsyncGenFirstiter( + int PyAIter_Check( ffi.Pointer arg0, ) { - return __PyEval_SetAsyncGenFirstiter( + return _PyAIter_Check( arg0, ); } - late final __PyEval_SetAsyncGenFirstiterPtr = + late final _PyAIter_CheckPtr = _lookup)>>( - '_PyEval_SetAsyncGenFirstiter'); - late final __PyEval_SetAsyncGenFirstiter = __PyEval_SetAsyncGenFirstiterPtr - .asFunction)>(); + 'PyAIter_Check'); + late final _PyAIter_Check = + _PyAIter_CheckPtr.asFunction)>(); - ffi.Pointer _PyEval_GetAsyncGenFirstiter() { - return __PyEval_GetAsyncGenFirstiter(); + ffi.Pointer PyIter_Next( + ffi.Pointer arg0, + ) { + return _PyIter_Next( + arg0, + ); } - late final __PyEval_GetAsyncGenFirstiterPtr = - _lookup Function()>>( - '_PyEval_GetAsyncGenFirstiter'); - late final __PyEval_GetAsyncGenFirstiter = __PyEval_GetAsyncGenFirstiterPtr - .asFunction Function()>(); + late final _PyIter_NextPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyIter_Next'); + late final _PyIter_Next = _PyIter_NextPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PyEval_SetAsyncGenFinalizer( + int PyIter_Send( ffi.Pointer arg0, + ffi.Pointer arg1, + ffi.Pointer> arg2, ) { - return __PyEval_SetAsyncGenFinalizer( + return _PyIter_Send( arg0, + arg1, + arg2, ); } - late final __PyEval_SetAsyncGenFinalizerPtr = - _lookup)>>( - '_PyEval_SetAsyncGenFinalizer'); - late final __PyEval_SetAsyncGenFinalizer = __PyEval_SetAsyncGenFinalizerPtr - .asFunction)>(); + late final _PyIter_SendPtr = _lookup< + ffi.NativeFunction< + ffi.Int32 Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer>)>>('PyIter_Send'); + late final _PyIter_Send = _PyIter_SendPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer>)>(); - ffi.Pointer _PyEval_GetAsyncGenFinalizer() { - return __PyEval_GetAsyncGenFinalizer(); + int PyNumber_Check( + ffi.Pointer o, + ) { + return _PyNumber_Check( + o, + ); } - late final __PyEval_GetAsyncGenFinalizerPtr = - _lookup Function()>>( - '_PyEval_GetAsyncGenFinalizer'); - late final __PyEval_GetAsyncGenFinalizer = __PyEval_GetAsyncGenFinalizerPtr - .asFunction Function()>(); + late final _PyNumber_CheckPtr = + _lookup)>>( + 'PyNumber_Check'); + late final _PyNumber_Check = + _PyNumber_CheckPtr.asFunction)>(); - ffi.Pointer _PyEval_GetBuiltinId( - ffi.Pointer<_Py_Identifier> arg0, + ffi.Pointer PyNumber_Add( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyEval_GetBuiltinId( - arg0, + return _PyNumber_Add( + o1, + o2, ); } - late final __PyEval_GetBuiltinIdPtr = _lookup< + late final _PyNumber_AddPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer<_Py_Identifier>)>>('_PyEval_GetBuiltinId'); - late final __PyEval_GetBuiltinId = __PyEval_GetBuiltinIdPtr.asFunction< - ffi.Pointer Function(ffi.Pointer<_Py_Identifier>)>(); + ffi.Pointer, ffi.Pointer)>>('PyNumber_Add'); + late final _PyNumber_Add = _PyNumber_AddPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyEval_MergeCompilerFlags( - ffi.Pointer cf, + ffi.Pointer PyNumber_Subtract( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PyEval_MergeCompilerFlags( - cf, + return _PyNumber_Subtract( + o1, + o2, ); } - late final _PyEval_MergeCompilerFlagsPtr = _lookup< - ffi.NativeFunction)>>( - 'PyEval_MergeCompilerFlags'); - late final _PyEval_MergeCompilerFlags = _PyEval_MergeCompilerFlagsPtr - .asFunction)>(); + late final _PyNumber_SubtractPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_Subtract'); + late final _PyNumber_Subtract = _PyNumber_SubtractPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyEval_EvalFrameDefault( - ffi.Pointer tstate, - ffi.Pointer f, - int exc, + ffi.Pointer PyNumber_Multiply( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyEval_EvalFrameDefault( - tstate, - f, - exc, + return _PyNumber_Multiply( + o1, + o2, ); } - late final __PyEval_EvalFrameDefaultPtr = _lookup< + late final _PyNumber_MultiplyPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Int)>>('_PyEval_EvalFrameDefault'); - late final __PyEval_EvalFrameDefault = - __PyEval_EvalFrameDefaultPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, int)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_Multiply'); + late final _PyNumber_Multiply = _PyNumber_MultiplyPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void _PyEval_SetSwitchInterval( - int microseconds, + ffi.Pointer PyNumber_MatrixMultiply( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyEval_SetSwitchInterval( - microseconds, + return _PyNumber_MatrixMultiply( + o1, + o2, ); } - late final __PyEval_SetSwitchIntervalPtr = - _lookup>( - '_PyEval_SetSwitchInterval'); - late final __PyEval_SetSwitchInterval = - __PyEval_SetSwitchIntervalPtr.asFunction(); + late final _PyNumber_MatrixMultiplyPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_MatrixMultiply'); + late final _PyNumber_MatrixMultiply = _PyNumber_MatrixMultiplyPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _PyEval_GetSwitchInterval() { - return __PyEval_GetSwitchInterval(); + ffi.Pointer PyNumber_FloorDivide( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_FloorDivide( + o1, + o2, + ); } - late final __PyEval_GetSwitchIntervalPtr = - _lookup>( - '_PyEval_GetSwitchInterval'); - late final __PyEval_GetSwitchInterval = - __PyEval_GetSwitchIntervalPtr.asFunction(); + late final _PyNumber_FloorDividePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_FloorDivide'); + late final _PyNumber_FloorDivide = _PyNumber_FloorDividePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _PyEval_RequestCodeExtraIndex( - freefunc arg0, + ffi.Pointer PyNumber_TrueDivide( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyEval_RequestCodeExtraIndex( - arg0, + return _PyNumber_TrueDivide( + o1, + o2, ); } - late final __PyEval_RequestCodeExtraIndexPtr = - _lookup>( - '_PyEval_RequestCodeExtraIndex'); - late final __PyEval_RequestCodeExtraIndex = - __PyEval_RequestCodeExtraIndexPtr.asFunction(); + late final _PyNumber_TrueDividePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_TrueDivide'); + late final _PyNumber_TrueDivide = _PyNumber_TrueDividePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _PyEval_SliceIndex( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyNumber_Remainder( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyEval_SliceIndex( - arg0, - arg1, + return _PyNumber_Remainder( + o1, + o2, ); } - late final __PyEval_SliceIndexPtr = _lookup< + late final _PyNumber_RemainderPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyEval_SliceIndex'); - late final __PyEval_SliceIndex = __PyEval_SliceIndexPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_Remainder'); + late final _PyNumber_Remainder = _PyNumber_RemainderPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _PyEval_SliceIndexNotNone( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyNumber_Divmod( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyEval_SliceIndexNotNone( - arg0, - arg1, + return _PyNumber_Divmod( + o1, + o2, ); } - late final __PyEval_SliceIndexNotNonePtr = _lookup< + late final _PyNumber_DivmodPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyEval_SliceIndexNotNone'); - late final __PyEval_SliceIndexNotNone = - __PyEval_SliceIndexNotNonePtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_Divmod'); + late final _PyNumber_Divmod = _PyNumber_DivmodPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PySys_GetObject( - ffi.Pointer arg0, + ffi.Pointer PyNumber_Power( + ffi.Pointer o1, + ffi.Pointer o2, + ffi.Pointer o3, ) { - return _PySys_GetObject( - arg0, + return _PyNumber_Power( + o1, + o2, + o3, ); } - late final _PySys_GetObjectPtr = _lookup< + late final _PyNumber_PowerPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PySys_GetObject'); - late final _PySys_GetObject = _PySys_GetObjectPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>('PyNumber_Power'); + late final _PyNumber_Power = _PyNumber_PowerPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - int PySys_SetObject( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyNumber_Negative( + ffi.Pointer o, ) { - return _PySys_SetObject( - arg0, - arg1, + return _PyNumber_Negative( + o, ); } - late final _PySys_SetObjectPtr = _lookup< + late final _PyNumber_NegativePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('PySys_SetObject'); - late final _PySys_SetObject = _PySys_SetObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyNumber_Negative'); + late final _PyNumber_Negative = _PyNumber_NegativePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - void PySys_SetArgv( - int arg0, - ffi.Pointer> arg1, + ffi.Pointer PyNumber_Positive( + ffi.Pointer o, ) { - return _PySys_SetArgv( - arg0, - arg1, + return _PyNumber_Positive( + o, ); } - late final _PySys_SetArgvPtr = _lookup< + late final _PyNumber_PositivePtr = _lookup< ffi.NativeFunction< - ffi.Void Function( - ffi.Int, ffi.Pointer>)>>('PySys_SetArgv'); - late final _PySys_SetArgv = _PySys_SetArgvPtr.asFunction< - void Function(int, ffi.Pointer>)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyNumber_Positive'); + late final _PyNumber_Positive = _PyNumber_PositivePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - void PySys_SetArgvEx( - int arg0, - ffi.Pointer> arg1, - int arg2, + ffi.Pointer PyNumber_Absolute( + ffi.Pointer o, ) { - return _PySys_SetArgvEx( - arg0, - arg1, - arg2, + return _PyNumber_Absolute( + o, ); } - late final _PySys_SetArgvExPtr = _lookup< + late final _PyNumber_AbsolutePtr = _lookup< ffi.NativeFunction< - ffi.Void Function(ffi.Int, ffi.Pointer>, - ffi.Int)>>('PySys_SetArgvEx'); - late final _PySys_SetArgvEx = _PySys_SetArgvExPtr.asFunction< - void Function(int, ffi.Pointer>, int)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyNumber_Absolute'); + late final _PyNumber_Absolute = _PyNumber_AbsolutePtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - void PySys_SetPath( - ffi.Pointer arg0, + ffi.Pointer PyNumber_Invert( + ffi.Pointer o, ) { - return _PySys_SetPath( - arg0, + return _PyNumber_Invert( + o, ); } - late final _PySys_SetPathPtr = - _lookup)>>( - 'PySys_SetPath'); - late final _PySys_SetPath = - _PySys_SetPathPtr.asFunction)>(); + late final _PyNumber_InvertPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyNumber_Invert'); + late final _PyNumber_Invert = _PyNumber_InvertPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - void PySys_WriteStdout( - ffi.Pointer format, + ffi.Pointer PyNumber_Lshift( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_WriteStdout( - format, + return _PyNumber_Lshift( + o1, + o2, ); } - late final _PySys_WriteStdoutPtr = - _lookup)>>( - 'PySys_WriteStdout'); - late final _PySys_WriteStdout = - _PySys_WriteStdoutPtr.asFunction)>(); + late final _PyNumber_LshiftPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_Lshift'); + late final _PyNumber_Lshift = _PyNumber_LshiftPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PySys_WriteStderr( - ffi.Pointer format, + ffi.Pointer PyNumber_Rshift( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_WriteStderr( - format, + return _PyNumber_Rshift( + o1, + o2, ); } - late final _PySys_WriteStderrPtr = - _lookup)>>( - 'PySys_WriteStderr'); - late final _PySys_WriteStderr = - _PySys_WriteStderrPtr.asFunction)>(); + late final _PyNumber_RshiftPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_Rshift'); + late final _PyNumber_Rshift = _PyNumber_RshiftPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PySys_FormatStdout( - ffi.Pointer format, + ffi.Pointer PyNumber_And( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_FormatStdout( - format, + return _PyNumber_And( + o1, + o2, ); } - late final _PySys_FormatStdoutPtr = - _lookup)>>( - 'PySys_FormatStdout'); - late final _PySys_FormatStdout = - _PySys_FormatStdoutPtr.asFunction)>(); + late final _PyNumber_AndPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>('PyNumber_And'); + late final _PyNumber_And = _PyNumber_AndPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PySys_FormatStderr( - ffi.Pointer format, + ffi.Pointer PyNumber_Xor( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_FormatStderr( - format, + return _PyNumber_Xor( + o1, + o2, ); } - late final _PySys_FormatStderrPtr = - _lookup)>>( - 'PySys_FormatStderr'); - late final _PySys_FormatStderr = - _PySys_FormatStderrPtr.asFunction)>(); - - void PySys_ResetWarnOptions() { - return _PySys_ResetWarnOptions(); - } - - late final _PySys_ResetWarnOptionsPtr = - _lookup>( - 'PySys_ResetWarnOptions'); - late final _PySys_ResetWarnOptions = - _PySys_ResetWarnOptionsPtr.asFunction(); + late final _PyNumber_XorPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>('PyNumber_Xor'); + late final _PyNumber_Xor = _PyNumber_XorPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PySys_AddWarnOption( - ffi.Pointer arg0, + ffi.Pointer PyNumber_Or( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_AddWarnOption( - arg0, + return _PyNumber_Or( + o1, + o2, ); } - late final _PySys_AddWarnOptionPtr = - _lookup)>>( - 'PySys_AddWarnOption'); - late final _PySys_AddWarnOption = _PySys_AddWarnOptionPtr.asFunction< - void Function(ffi.Pointer)>(); + late final _PyNumber_OrPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>('PyNumber_Or'); + late final _PyNumber_Or = _PyNumber_OrPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PySys_AddWarnOptionUnicode( + int PyIndex_Check( ffi.Pointer arg0, ) { - return _PySys_AddWarnOptionUnicode( + return _PyIndex_Check( arg0, ); } - late final _PySys_AddWarnOptionUnicodePtr = - _lookup)>>( - 'PySys_AddWarnOptionUnicode'); - late final _PySys_AddWarnOptionUnicode = _PySys_AddWarnOptionUnicodePtr - .asFunction)>(); - - int PySys_HasWarnOptions() { - return _PySys_HasWarnOptions(); - } - - late final _PySys_HasWarnOptionsPtr = - _lookup>('PySys_HasWarnOptions'); - late final _PySys_HasWarnOptions = - _PySys_HasWarnOptionsPtr.asFunction(); + late final _PyIndex_CheckPtr = + _lookup)>>( + 'PyIndex_Check'); + late final _PyIndex_Check = + _PyIndex_CheckPtr.asFunction)>(); - void PySys_AddXOption( - ffi.Pointer arg0, + ffi.Pointer PyNumber_Index( + ffi.Pointer o, ) { - return _PySys_AddXOption( - arg0, + return _PyNumber_Index1( + o, ); } - late final _PySys_AddXOptionPtr = - _lookup)>>( - 'PySys_AddXOption'); - late final _PySys_AddXOption = - _PySys_AddXOptionPtr.asFunction)>(); + late final _PyNumber_IndexPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyNumber_Index'); + late final _PyNumber_Index1 = _PyNumber_IndexPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PySys_GetXOptions() { - return _PySys_GetXOptions(); + int PyNumber_AsSsize_t( + ffi.Pointer o, + ffi.Pointer exc, + ) { + return _PyNumber_AsSsize_t( + o, + exc, + ); } - late final _PySys_GetXOptionsPtr = - _lookup Function()>>( - 'PySys_GetXOptions'); - late final _PySys_GetXOptions = - _PySys_GetXOptionsPtr.asFunction Function()>(); + late final _PyNumber_AsSsize_tPtr = _lookup< + ffi.NativeFunction< + Py_ssize_t Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_AsSsize_t'); + late final _PyNumber_AsSsize_t = _PyNumber_AsSsize_tPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PySys_GetObjectId( - ffi.Pointer<_Py_Identifier> key, + ffi.Pointer PyNumber_Long( + ffi.Pointer o, ) { - return __PySys_GetObjectId( - key, + return _PyNumber_Long( + o, ); } - late final __PySys_GetObjectIdPtr = _lookup< + late final _PyNumber_LongPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer<_Py_Identifier>)>>('_PySys_GetObjectId'); - late final __PySys_GetObjectId = __PySys_GetObjectIdPtr.asFunction< - ffi.Pointer Function(ffi.Pointer<_Py_Identifier>)>(); + ffi.Pointer)>>('PyNumber_Long'); + late final _PyNumber_Long = _PyNumber_LongPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PySys_SetObjectId( - ffi.Pointer<_Py_Identifier> key, - ffi.Pointer arg1, + ffi.Pointer PyNumber_Float( + ffi.Pointer o, ) { - return __PySys_SetObjectId( - key, - arg1, + return _PyNumber_Float( + o, ); } - late final __PySys_SetObjectIdPtr = _lookup< + late final _PyNumber_FloatPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer<_Py_Identifier>, - ffi.Pointer)>>('_PySys_SetObjectId'); - late final __PySys_SetObjectId = __PySys_SetObjectIdPtr.asFunction< - int Function(ffi.Pointer<_Py_Identifier>, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer)>>('PyNumber_Float'); + late final _PyNumber_Float = _PyNumber_FloatPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int _PySys_GetSizeOf( - ffi.Pointer arg0, + ffi.Pointer PyNumber_InPlaceAdd( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PySys_GetSizeOf( - arg0, + return _PyNumber_InPlaceAdd( + o1, + o2, ); } - late final __PySys_GetSizeOfPtr = - _lookup)>>( - '_PySys_GetSizeOf'); - late final __PySys_GetSizeOf = - __PySys_GetSizeOfPtr.asFunction)>(); + late final _PyNumber_InPlaceAddPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceAdd'); + late final _PyNumber_InPlaceAdd = _PyNumber_InPlaceAddPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PySys_Audit( - ffi.Pointer event, - ffi.Pointer argFormat, + ffi.Pointer PyNumber_InPlaceSubtract( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_Audit( - event, - argFormat, + return _PyNumber_InPlaceSubtract( + o1, + o2, ); } - late final _PySys_AuditPtr = _lookup< + late final _PyNumber_InPlaceSubtractPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('PySys_Audit'); - late final _PySys_Audit = _PySys_AuditPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceSubtract'); + late final _PyNumber_InPlaceSubtract = + _PyNumber_InPlaceSubtractPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PySys_AddAuditHook( - Py_AuditHookFunction arg0, - ffi.Pointer arg1, + ffi.Pointer PyNumber_InPlaceMultiply( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PySys_AddAuditHook( - arg0, - arg1, + return _PyNumber_InPlaceMultiply( + o1, + o2, ); } - late final _PySys_AddAuditHookPtr = _lookup< + late final _PyNumber_InPlaceMultiplyPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(Py_AuditHookFunction, - ffi.Pointer)>>('PySys_AddAuditHook'); - late final _PySys_AddAuditHook = _PySys_AddAuditHookPtr.asFunction< - int Function(Py_AuditHookFunction, ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceMultiply'); + late final _PyNumber_InPlaceMultiply = + _PyNumber_InPlaceMultiplyPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyOS_FSPath( - ffi.Pointer path, + ffi.Pointer PyNumber_InPlaceMatrixMultiply( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PyOS_FSPath( - path, + return _PyNumber_InPlaceMatrixMultiply( + o1, + o2, ); } - late final _PyOS_FSPathPtr = _lookup< + late final _PyNumber_InPlaceMatrixMultiplyPtr = _lookup< ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceMatrixMultiply'); + late final _PyNumber_InPlaceMatrixMultiply = + _PyNumber_InPlaceMatrixMultiplyPtr.asFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyOS_FSPath'); - late final _PyOS_FSPath = _PyOS_FSPathPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer, ffi.Pointer)>(); - int PyOS_InterruptOccurred() { - return _PyOS_InterruptOccurred(); + ffi.Pointer PyNumber_InPlaceFloorDivide( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceFloorDivide( + o1, + o2, + ); } - late final _PyOS_InterruptOccurredPtr = - _lookup>('PyOS_InterruptOccurred'); - late final _PyOS_InterruptOccurred = - _PyOS_InterruptOccurredPtr.asFunction(); + late final _PyNumber_InPlaceFloorDividePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceFloorDivide'); + late final _PyNumber_InPlaceFloorDivide = + _PyNumber_InPlaceFloorDividePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PyOS_BeforeFork() { - return _PyOS_BeforeFork(); + ffi.Pointer PyNumber_InPlaceTrueDivide( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceTrueDivide( + o1, + o2, + ); } - late final _PyOS_BeforeForkPtr = - _lookup>('PyOS_BeforeFork'); - late final _PyOS_BeforeFork = - _PyOS_BeforeForkPtr.asFunction(); + late final _PyNumber_InPlaceTrueDividePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceTrueDivide'); + late final _PyNumber_InPlaceTrueDivide = + _PyNumber_InPlaceTrueDividePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PyOS_AfterFork_Parent() { - return _PyOS_AfterFork_Parent(); + ffi.Pointer PyNumber_InPlaceRemainder( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceRemainder( + o1, + o2, + ); } - late final _PyOS_AfterFork_ParentPtr = - _lookup>('PyOS_AfterFork_Parent'); - late final _PyOS_AfterFork_Parent = - _PyOS_AfterFork_ParentPtr.asFunction(); + late final _PyNumber_InPlaceRemainderPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceRemainder'); + late final _PyNumber_InPlaceRemainder = + _PyNumber_InPlaceRemainderPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - void PyOS_AfterFork_Child() { - return _PyOS_AfterFork_Child(); + ffi.Pointer PyNumber_InPlacePower( + ffi.Pointer o1, + ffi.Pointer o2, + ffi.Pointer o3, + ) { + return _PyNumber_InPlacePower( + o1, + o2, + o3, + ); } - late final _PyOS_AfterFork_ChildPtr = - _lookup>('PyOS_AfterFork_Child'); - late final _PyOS_AfterFork_Child = - _PyOS_AfterFork_ChildPtr.asFunction(); + late final _PyNumber_InPlacePowerPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlacePower'); + late final _PyNumber_InPlacePower = _PyNumber_InPlacePowerPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - void PyOS_AfterFork() { - return _PyOS_AfterFork(); + ffi.Pointer PyNumber_InPlaceLshift( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceLshift( + o1, + o2, + ); } - late final _PyOS_AfterForkPtr = - _lookup>('PyOS_AfterFork'); - late final _PyOS_AfterFork = _PyOS_AfterForkPtr.asFunction(); + late final _PyNumber_InPlaceLshiftPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceLshift'); + late final _PyNumber_InPlaceLshift = _PyNumber_InPlaceLshiftPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _PyOS_IsMainThread() { - return __PyOS_IsMainThread(); + ffi.Pointer PyNumber_InPlaceRshift( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceRshift( + o1, + o2, + ); } - late final __PyOS_IsMainThreadPtr = - _lookup>('_PyOS_IsMainThread'); - late final __PyOS_IsMainThread = - __PyOS_IsMainThreadPtr.asFunction(); + late final _PyNumber_InPlaceRshiftPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceRshift'); + late final _PyNumber_InPlaceRshift = _PyNumber_InPlaceRshiftPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyImport_GetMagicNumber() { - return _PyImport_GetMagicNumber(); + ffi.Pointer PyNumber_InPlaceAnd( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceAnd( + o1, + o2, + ); } - late final _PyImport_GetMagicNumberPtr = - _lookup>( - 'PyImport_GetMagicNumber'); - late final _PyImport_GetMagicNumber = - _PyImport_GetMagicNumberPtr.asFunction(); + late final _PyNumber_InPlaceAndPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceAnd'); + late final _PyNumber_InPlaceAnd = _PyNumber_InPlaceAndPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyImport_GetMagicTag() { - return _PyImport_GetMagicTag(); + ffi.Pointer PyNumber_InPlaceXor( + ffi.Pointer o1, + ffi.Pointer o2, + ) { + return _PyNumber_InPlaceXor( + o1, + o2, + ); } - late final _PyImport_GetMagicTagPtr = - _lookup Function()>>( - 'PyImport_GetMagicTag'); - late final _PyImport_GetMagicTag = - _PyImport_GetMagicTagPtr.asFunction Function()>(); + late final _PyNumber_InPlaceXorPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceXor'); + late final _PyNumber_InPlaceXor = _PyNumber_InPlaceXorPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyImport_ExecCodeModule( - ffi.Pointer name, - ffi.Pointer co, + ffi.Pointer PyNumber_InPlaceOr( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PyImport_ExecCodeModule( - name, - co, + return _PyNumber_InPlaceOr( + o1, + o2, ); } - late final _PyImport_ExecCodeModulePtr = _lookup< + late final _PyNumber_InPlaceOrPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('PyImport_ExecCodeModule'); - late final _PyImport_ExecCodeModule = _PyImport_ExecCodeModulePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyNumber_InPlaceOr'); + late final _PyNumber_InPlaceOr = _PyNumber_InPlaceOrPtr.asFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyImport_ExecCodeModuleEx( - ffi.Pointer name, - ffi.Pointer co, - ffi.Pointer pathname, + ffi.Pointer PyNumber_ToBase( + ffi.Pointer n, + int base, ) { - return _PyImport_ExecCodeModuleEx( - name, - co, - pathname, + return _PyNumber_ToBase( + n, + base, ); } - late final _PyImport_ExecCodeModuleExPtr = _lookup< + late final _PyNumber_ToBasePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyImport_ExecCodeModuleEx'); - late final _PyImport_ExecCodeModuleEx = - _PyImport_ExecCodeModuleExPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer, ffi.Int)>>('PyNumber_ToBase'); + late final _PyNumber_ToBase = _PyNumber_ToBasePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - ffi.Pointer PyImport_ExecCodeModuleWithPathnames( - ffi.Pointer name, - ffi.Pointer co, - ffi.Pointer pathname, - ffi.Pointer cpathname, + int PySequence_Check( + ffi.Pointer o, ) { - return _PyImport_ExecCodeModuleWithPathnames( - name, - co, - pathname, - cpathname, + return _PySequence_Check( + o, ); } - late final _PyImport_ExecCodeModuleWithPathnamesPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyImport_ExecCodeModuleWithPathnames'); - late final _PyImport_ExecCodeModuleWithPathnames = - _PyImport_ExecCodeModuleWithPathnamesPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + late final _PySequence_CheckPtr = + _lookup)>>( + 'PySequence_Check'); + late final _PySequence_Check = + _PySequence_CheckPtr.asFunction)>(); - ffi.Pointer PyImport_ExecCodeModuleObject( - ffi.Pointer name, - ffi.Pointer co, - ffi.Pointer pathname, - ffi.Pointer cpathname, + int PySequence_Size( + ffi.Pointer o, ) { - return _PyImport_ExecCodeModuleObject( - name, - co, - pathname, - cpathname, + return _PySequence_Size( + o, ); } - late final _PyImport_ExecCodeModuleObjectPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('PyImport_ExecCodeModuleObject'); - late final _PyImport_ExecCodeModuleObject = - _PyImport_ExecCodeModuleObjectPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>(); + late final _PySequence_SizePtr = + _lookup)>>( + 'PySequence_Size'); + late final _PySequence_Size = + _PySequence_SizePtr.asFunction)>(); - ffi.Pointer PyImport_GetModuleDict() { - return _PyImport_GetModuleDict(); + int PySequence_Length( + ffi.Pointer o, + ) { + return _PySequence_Length( + o, + ); } - late final _PyImport_GetModuleDictPtr = - _lookup Function()>>( - 'PyImport_GetModuleDict'); - late final _PyImport_GetModuleDict = - _PyImport_GetModuleDictPtr.asFunction Function()>(); + late final _PySequence_LengthPtr = + _lookup)>>( + 'PySequence_Length'); + late final _PySequence_Length = + _PySequence_LengthPtr.asFunction)>(); - ffi.Pointer PyImport_GetModule( - ffi.Pointer name, + ffi.Pointer PySequence_Concat( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return _PyImport_GetModule( - name, + return _PySequence_Concat( + o1, + o2, ); } - late final _PyImport_GetModulePtr = _lookup< + late final _PySequence_ConcatPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyImport_GetModule'); - late final _PyImport_GetModule = _PyImport_GetModulePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); - - ffi.Pointer PyImport_AddModuleObject( - ffi.Pointer name, + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PySequence_Concat'); + late final _PySequence_Concat = _PySequence_ConcatPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); + + ffi.Pointer PySequence_Repeat( + ffi.Pointer o, + int count, ) { - return _PyImport_AddModuleObject( - name, + return _PySequence_Repeat( + o, + count, ); } - late final _PyImport_AddModuleObjectPtr = _lookup< + late final _PySequence_RepeatPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyImport_AddModuleObject'); - late final _PyImport_AddModuleObject = _PyImport_AddModuleObjectPtr - .asFunction Function(ffi.Pointer)>(); + ffi.Pointer, Py_ssize_t)>>('PySequence_Repeat'); + late final _PySequence_Repeat = _PySequence_RepeatPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - ffi.Pointer PyImport_AddModule( - ffi.Pointer name, + ffi.Pointer PySequence_GetItem( + ffi.Pointer o, + int i, ) { - return _PyImport_AddModule( - name, + return _PySequence_GetItem( + o, + i, ); } - late final _PyImport_AddModulePtr = _lookup< + late final _PySequence_GetItemPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyImport_AddModule'); - late final _PyImport_AddModule = _PyImport_AddModulePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer, Py_ssize_t)>>('PySequence_GetItem'); + late final _PySequence_GetItem = _PySequence_GetItemPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int)>(); - ffi.Pointer PyImport_ImportModule( - ffi.Pointer name, + ffi.Pointer PySequence_GetSlice( + ffi.Pointer o, + int i1, + int i2, ) { - return _PyImport_ImportModule( - name, + return _PySequence_GetSlice( + o, + i1, + i2, ); } - late final _PyImport_ImportModulePtr = _lookup< + late final _PySequence_GetSlicePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyImport_ImportModule'); - late final _PyImport_ImportModule = _PyImport_ImportModulePtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Pointer Function(ffi.Pointer, Py_ssize_t, + Py_ssize_t)>>('PySequence_GetSlice'); + late final _PySequence_GetSlice = _PySequence_GetSlicePtr.asFunction< + ffi.Pointer Function(ffi.Pointer, int, int)>(); - ffi.Pointer PyImport_ImportModuleNoBlock( - ffi.Pointer name, + int PySequence_SetItem( + ffi.Pointer o, + int i, + ffi.Pointer v, ) { - return _PyImport_ImportModuleNoBlock( - name, + return _PySequence_SetItem( + o, + i, + v, ); } - late final _PyImport_ImportModuleNoBlockPtr = _lookup< + late final _PySequence_SetItemPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyImport_ImportModuleNoBlock'); - late final _PyImport_ImportModuleNoBlock = _PyImport_ImportModuleNoBlockPtr - .asFunction Function(ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, Py_ssize_t, + ffi.Pointer)>>('PySequence_SetItem'); + late final _PySequence_SetItem = _PySequence_SetItemPtr.asFunction< + int Function(ffi.Pointer, int, ffi.Pointer)>(); - ffi.Pointer PyImport_ImportModuleLevel( - ffi.Pointer name, - ffi.Pointer globals, - ffi.Pointer locals, - ffi.Pointer fromlist, - int level, + int PySequence_DelItem( + ffi.Pointer o, + int i, ) { - return _PyImport_ImportModuleLevel( - name, - globals, - locals, - fromlist, - level, + return _PySequence_DelItem( + o, + i, ); } - late final _PyImport_ImportModuleLevelPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Int)>>('PyImport_ImportModuleLevel'); - late final _PyImport_ImportModuleLevel = - _PyImport_ImportModuleLevelPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - int)>(); + late final _PySequence_DelItemPtr = _lookup< + ffi + .NativeFunction, Py_ssize_t)>>( + 'PySequence_DelItem'); + late final _PySequence_DelItem = _PySequence_DelItemPtr.asFunction< + int Function(ffi.Pointer, int)>(); - ffi.Pointer PyImport_ImportModuleLevelObject( - ffi.Pointer name, - ffi.Pointer globals, - ffi.Pointer locals, - ffi.Pointer fromlist, - int level, + int PySequence_SetSlice( + ffi.Pointer o, + int i1, + int i2, + ffi.Pointer v, ) { - return _PyImport_ImportModuleLevelObject( - name, - globals, - locals, - fromlist, - level, + return _PySequence_SetSlice( + o, + i1, + i2, + v, ); } - late final _PyImport_ImportModuleLevelObjectPtr = _lookup< + late final _PySequence_SetSlicePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Int)>>('PyImport_ImportModuleLevelObject'); - late final _PyImport_ImportModuleLevelObject = - _PyImport_ImportModuleLevelObjectPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - int)>(); + ffi.Int Function(ffi.Pointer, Py_ssize_t, Py_ssize_t, + ffi.Pointer)>>('PySequence_SetSlice'); + late final _PySequence_SetSlice = _PySequence_SetSlicePtr.asFunction< + int Function(ffi.Pointer, int, int, ffi.Pointer)>(); - ffi.Pointer PyImport_GetImporter( - ffi.Pointer path, + int PySequence_DelSlice( + ffi.Pointer o, + int i1, + int i2, ) { - return _PyImport_GetImporter( - path, + return _PySequence_DelSlice( + o, + i1, + i2, ); } - late final _PyImport_GetImporterPtr = _lookup< + late final _PySequence_DelSlicePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer)>>('PyImport_GetImporter'); - late final _PyImport_GetImporter = _PyImport_GetImporterPtr.asFunction< - ffi.Pointer Function(ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, Py_ssize_t, + Py_ssize_t)>>('PySequence_DelSlice'); + late final _PySequence_DelSlice = _PySequence_DelSlicePtr.asFunction< + int Function(ffi.Pointer, int, int)>(); - ffi.Pointer PyImport_Import( - ffi.Pointer name, + ffi.Pointer PySequence_Tuple( + ffi.Pointer o, ) { - return _PyImport_Import( - name, + return _PySequence_Tuple( + o, ); } - late final _PyImport_ImportPtr = _lookup< + late final _PySequence_TuplePtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyImport_Import'); - late final _PyImport_Import = _PyImport_ImportPtr.asFunction< + ffi.Pointer)>>('PySequence_Tuple'); + late final _PySequence_Tuple = _PySequence_TuplePtr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer PyImport_ReloadModule( - ffi.Pointer m, + ffi.Pointer PySequence_List( + ffi.Pointer o, ) { - return _PyImport_ReloadModule( - m, + return _PySequence_List( + o, ); } - late final _PyImport_ReloadModulePtr = _lookup< + late final _PySequence_ListPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer)>>('PyImport_ReloadModule'); - late final _PyImport_ReloadModule = _PyImport_ReloadModulePtr.asFunction< + ffi.Pointer)>>('PySequence_List'); + late final _PySequence_List = _PySequence_ListPtr.asFunction< ffi.Pointer Function(ffi.Pointer)>(); - int PyImport_ImportFrozenModuleObject( - ffi.Pointer name, + ffi.Pointer PySequence_Fast( + ffi.Pointer o, + ffi.Pointer m, ) { - return _PyImport_ImportFrozenModuleObject( - name, + return _PySequence_Fast( + o, + m, ); } - late final _PyImport_ImportFrozenModuleObjectPtr = - _lookup)>>( - 'PyImport_ImportFrozenModuleObject'); - late final _PyImport_ImportFrozenModuleObject = - _PyImport_ImportFrozenModuleObjectPtr.asFunction< - int Function(ffi.Pointer)>(); + late final _PySequence_FastPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PySequence_Fast'); + late final _PySequence_Fast = _PySequence_FastPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyImport_ImportFrozenModule( - ffi.Pointer name, + int PySequence_Count( + ffi.Pointer o, + ffi.Pointer value, ) { - return _PyImport_ImportFrozenModule( - name, + return _PySequence_Count( + o, + value, ); } - late final _PyImport_ImportFrozenModulePtr = - _lookup)>>( - 'PyImport_ImportFrozenModule'); - late final _PyImport_ImportFrozenModule = _PyImport_ImportFrozenModulePtr - .asFunction)>(); - - int PyImport_AppendInittab( - ffi.Pointer name, - ffi.Pointer Function()>> initfunc, + late final _PySequence_CountPtr = _lookup< + ffi.NativeFunction< + Py_ssize_t Function(ffi.Pointer, + ffi.Pointer)>>('PySequence_Count'); + late final _PySequence_Count = _PySequence_CountPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); + + int PySequence_Contains( + ffi.Pointer seq, + ffi.Pointer ob, ) { - return _PyImport_AppendInittab( - name, - initfunc, + return _PySequence_Contains( + seq, + ob, ); } - late final _PyImport_AppendInittabPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer< - ffi.NativeFunction Function()>>)>>( - 'PyImport_AppendInittab'); - late final _PyImport_AppendInittab = _PyImport_AppendInittabPtr.asFunction< - int Function(ffi.Pointer, - ffi.Pointer Function()>>)>(); + late final _PySequence_ContainsPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PySequence_Contains'); + late final _PySequence_Contains = _PySequence_ContainsPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer PyInit__imp() { - return _PyInit__imp(); + int PySequence_In( + ffi.Pointer o, + ffi.Pointer value, + ) { + return _PySequence_In( + o, + value, + ); } - late final _PyInit__impPtr = - _lookup Function()>>( - 'PyInit__imp'); - late final _PyInit__imp = - _PyInit__impPtr.asFunction Function()>(); + late final _PySequence_InPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function( + ffi.Pointer, ffi.Pointer)>>('PySequence_In'); + late final _PySequence_In = _PySequence_InPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int _PyImport_IsInitialized( - ffi.Pointer arg0, + int PySequence_Index( + ffi.Pointer o, + ffi.Pointer value, ) { - return __PyImport_IsInitialized( - arg0, + return _PySequence_Index( + o, + value, ); } - late final __PyImport_IsInitializedPtr = _lookup< + late final _PySequence_IndexPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer)>>('_PyImport_IsInitialized'); - late final __PyImport_IsInitialized = __PyImport_IsInitializedPtr - .asFunction)>(); + Py_ssize_t Function(ffi.Pointer, + ffi.Pointer)>>('PySequence_Index'); + late final _PySequence_Index = _PySequence_IndexPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyImport_GetModuleId( - ffi.Pointer<_Py_Identifier> name, + ffi.Pointer PySequence_InPlaceConcat( + ffi.Pointer o1, + ffi.Pointer o2, ) { - return __PyImport_GetModuleId( - name, + return _PySequence_InPlaceConcat( + o1, + o2, ); } - late final __PyImport_GetModuleIdPtr = _lookup< + late final _PySequence_InPlaceConcatPtr = _lookup< ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PySequence_InPlaceConcat'); + late final _PySequence_InPlaceConcat = + _PySequence_InPlaceConcatPtr.asFunction< ffi.Pointer Function( - ffi.Pointer<_Py_Identifier>)>>('_PyImport_GetModuleId'); - late final __PyImport_GetModuleId = __PyImport_GetModuleIdPtr.asFunction< - ffi.Pointer Function(ffi.Pointer<_Py_Identifier>)>(); + ffi.Pointer, ffi.Pointer)>(); - int _PyImport_SetModule( - ffi.Pointer name, - ffi.Pointer module, + ffi.Pointer PySequence_InPlaceRepeat( + ffi.Pointer o, + int count, ) { - return __PyImport_SetModule( - name, - module, + return _PySequence_InPlaceRepeat( + o, + count, ); } - late final __PyImport_SetModulePtr = _lookup< + late final _PySequence_InPlaceRepeatPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyImport_SetModule'); - late final __PyImport_SetModule = __PyImport_SetModulePtr - .asFunction, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, Py_ssize_t)>>('PySequence_InPlaceRepeat'); + late final _PySequence_InPlaceRepeat = _PySequence_InPlaceRepeatPtr + .asFunction Function(ffi.Pointer, int)>(); - int _PyImport_SetModuleString( - ffi.Pointer name, - ffi.Pointer module, + int PyMapping_Check( + ffi.Pointer o, ) { - return __PyImport_SetModuleString( - name, - module, + return _PyMapping_Check( + o, ); } - late final __PyImport_SetModuleStringPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer)>>('_PyImport_SetModuleString'); - late final __PyImport_SetModuleString = __PyImport_SetModuleStringPtr - .asFunction, ffi.Pointer)>(); + late final _PyMapping_CheckPtr = + _lookup)>>( + 'PyMapping_Check'); + late final _PyMapping_Check = + _PyMapping_CheckPtr.asFunction)>(); - void _PyImport_AcquireLock() { - return __PyImport_AcquireLock(); + int PyMapping_Size( + ffi.Pointer o, + ) { + return _PyMapping_Size( + o, + ); } - late final __PyImport_AcquireLockPtr = - _lookup>('_PyImport_AcquireLock'); - late final __PyImport_AcquireLock = - __PyImport_AcquireLockPtr.asFunction(); + late final _PyMapping_SizePtr = + _lookup)>>( + 'PyMapping_Size'); + late final _PyMapping_Size = + _PyMapping_SizePtr.asFunction)>(); - int _PyImport_ReleaseLock() { - return __PyImport_ReleaseLock(); + int PyMapping_Length( + ffi.Pointer o, + ) { + return _PyMapping_Length( + o, + ); } - late final __PyImport_ReleaseLockPtr = - _lookup>('_PyImport_ReleaseLock'); - late final __PyImport_ReleaseLock = - __PyImport_ReleaseLockPtr.asFunction(); + late final _PyMapping_LengthPtr = + _lookup)>>( + 'PyMapping_Length'); + late final _PyMapping_Length = + _PyMapping_LengthPtr.asFunction)>(); - ffi.Pointer _PyImport_FindExtensionObject( - ffi.Pointer arg0, - ffi.Pointer arg1, + int PyMapping_HasKeyString( + ffi.Pointer o, + ffi.Pointer key, ) { - return __PyImport_FindExtensionObject( - arg0, - arg1, + return _PyMapping_HasKeyString( + o, + key, ); } - late final __PyImport_FindExtensionObjectPtr = _lookup< + late final _PyMapping_HasKeyStringPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyImport_FindExtensionObject'); - late final __PyImport_FindExtensionObject = - __PyImport_FindExtensionObjectPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyMapping_HasKeyString'); + late final _PyMapping_HasKeyString = _PyMapping_HasKeyStringPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int _PyImport_FixupBuiltin( - ffi.Pointer mod, - ffi.Pointer name, - ffi.Pointer modules, + int PyMapping_HasKey( + ffi.Pointer o, + ffi.Pointer key, ) { - return __PyImport_FixupBuiltin( - mod, - name, - modules, + return _PyMapping_HasKey( + o, + key, ); } - late final __PyImport_FixupBuiltinPtr = _lookup< + late final _PyMapping_HasKeyPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('_PyImport_FixupBuiltin'); - late final __PyImport_FixupBuiltin = __PyImport_FixupBuiltinPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyMapping_HasKey'); + late final _PyMapping_HasKey = _PyMapping_HasKeyPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int _PyImport_FixupExtensionObject( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, - ffi.Pointer arg3, + ffi.Pointer PyMapping_Keys( + ffi.Pointer o, ) { - return __PyImport_FixupExtensionObject( - arg0, - arg1, - arg2, - arg3, + return _PyMapping_Keys( + o, ); } - late final __PyImport_FixupExtensionObjectPtr = _lookup< + late final _PyMapping_KeysPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer)>>('_PyImport_FixupExtensionObject'); - late final __PyImport_FixupExtensionObject = - __PyImport_FixupExtensionObjectPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); - - late final ffi.Pointer> _PyImport_Inittab = - _lookup>('PyImport_Inittab'); + ffi.Pointer Function( + ffi.Pointer)>>('PyMapping_Keys'); + late final _PyMapping_Keys = _PyMapping_KeysPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer<_inittab> get PyImport_Inittab => _PyImport_Inittab.value; + ffi.Pointer PyMapping_Values( + ffi.Pointer o, + ) { + return _PyMapping_Values( + o, + ); + } - set PyImport_Inittab(ffi.Pointer<_inittab> value) => - _PyImport_Inittab.value = value; + late final _PyMapping_ValuesPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyMapping_Values'); + late final _PyMapping_Values = _PyMapping_ValuesPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - int PyImport_ExtendInittab( - ffi.Pointer<_inittab> newtab, + ffi.Pointer PyMapping_Items( + ffi.Pointer o, ) { - return _PyImport_ExtendInittab( - newtab, + return _PyMapping_Items( + o, ); } - late final _PyImport_ExtendInittabPtr = - _lookup)>>( - 'PyImport_ExtendInittab'); - late final _PyImport_ExtendInittab = _PyImport_ExtendInittabPtr.asFunction< - int Function(ffi.Pointer<_inittab>)>(); - - late final ffi.Pointer> _PyImport_FrozenModules = - _lookup>('PyImport_FrozenModules'); - - ffi.Pointer<_frozen> get PyImport_FrozenModules => - _PyImport_FrozenModules.value; - - set PyImport_FrozenModules(ffi.Pointer<_frozen> value) => - _PyImport_FrozenModules.value = value; + late final _PyMapping_ItemsPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer)>>('PyMapping_Items'); + late final _PyMapping_Items = _PyMapping_ItemsPtr.asFunction< + ffi.Pointer Function(ffi.Pointer)>(); - ffi.Pointer _PyImport_GetModuleAttr( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyMapping_GetItemString( + ffi.Pointer o, + ffi.Pointer key, ) { - return __PyImport_GetModuleAttr( - arg0, - arg1, + return _PyMapping_GetItemString( + o, + key, ); } - late final __PyImport_GetModuleAttrPtr = _lookup< + late final _PyMapping_GetItemStringPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyImport_GetModuleAttr'); - late final __PyImport_GetModuleAttr = __PyImport_GetModuleAttrPtr.asFunction< + ffi.Pointer)>>('PyMapping_GetItemString'); + late final _PyMapping_GetItemString = _PyMapping_GetItemStringPtr.asFunction< ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyImport_GetModuleAttrString( - ffi.Pointer arg0, - ffi.Pointer arg1, + int PyMapping_SetItemString( + ffi.Pointer o, + ffi.Pointer key, + ffi.Pointer value, ) { - return __PyImport_GetModuleAttrString( - arg0, - arg1, + return _PyMapping_SetItemString( + o, + key, + value, ); } - late final __PyImport_GetModuleAttrStringPtr = _lookup< + late final _PyMapping_SetItemStringPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyImport_GetModuleAttrString'); - late final __PyImport_GetModuleAttrString = - __PyImport_GetModuleAttrStringPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>('PyMapping_SetItemString'); + late final _PyMapping_SetItemString = _PyMapping_SetItemStringPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>(); - late final ffi.Pointer _PyFilter_Type = - _lookup('PyFilter_Type'); + int PyObject_IsInstance( + ffi.Pointer object, + ffi.Pointer typeorclass, + ) { + return _PyObject_IsInstance( + object, + typeorclass, + ); + } - PyTypeObject get PyFilter_Type => _PyFilter_Type.ref; + late final _PyObject_IsInstancePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_IsInstance'); + late final _PyObject_IsInstance = _PyObject_IsInstancePtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer _PyMap_Type = - _lookup('PyMap_Type'); + int PyObject_IsSubclass( + ffi.Pointer object, + ffi.Pointer typeorclass, + ) { + return _PyObject_IsSubclass( + object, + typeorclass, + ); + } - PyTypeObject get PyMap_Type => _PyMap_Type.ref; + late final _PyObject_IsSubclassPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_IsSubclass'); + late final _PyObject_IsSubclass = _PyObject_IsSubclassPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - late final ffi.Pointer _PyZip_Type = - _lookup('PyZip_Type'); + ffi.Pointer _PyStack_AsDict( + ffi.Pointer> values, + ffi.Pointer kwnames, + ) { + return __PyStack_AsDict( + values, + kwnames, + ); + } - PyTypeObject get PyZip_Type => _PyZip_Type.ref; + late final __PyStack_AsDictPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer>, + ffi.Pointer)>>('_PyStack_AsDict'); + late final __PyStack_AsDict = __PyStack_AsDictPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer>, ffi.Pointer)>(); - ffi.Pointer PyEval_EvalCode( - ffi.Pointer arg0, - ffi.Pointer arg1, - ffi.Pointer arg2, + ffi.Pointer _Py_CheckFunctionResult( + ffi.Pointer tstate, + ffi.Pointer callable, + ffi.Pointer result, + ffi.Pointer where, ) { - return _PyEval_EvalCode( - arg0, - arg1, - arg2, + return __Py_CheckFunctionResult( + tstate, + callable, + result, + where, ); } - late final _PyEval_EvalCodePtr = _lookup< + late final __Py_CheckFunctionResultPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>('PyEval_EvalCode'); - late final _PyEval_EvalCode = _PyEval_EvalCodePtr.asFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer)>>('_Py_CheckFunctionResult'); + late final __Py_CheckFunctionResult = __Py_CheckFunctionResultPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>(); - ffi.Pointer PyEval_EvalCodeEx( - ffi.Pointer co, - ffi.Pointer globals, - ffi.Pointer locals, + ffi.Pointer _PyObject_MakeTpCall( + ffi.Pointer tstate, + ffi.Pointer callable, ffi.Pointer> args, - int argc, - ffi.Pointer> kwds, - int kwdc, - ffi.Pointer> defs, - int defc, - ffi.Pointer kwdefs, - ffi.Pointer closure, + int nargs, + ffi.Pointer keywords, ) { - return _PyEval_EvalCodeEx( - co, - globals, - locals, + return __PyObject_MakeTpCall( + tstate, + callable, args, - argc, - kwds, - kwdc, - defs, - defc, - kwdefs, - closure, + nargs, + keywords, ); } - late final _PyEval_EvalCodeExPtr = _lookup< + late final __PyObject_MakeTpCallPtr = _lookup< ffi.NativeFunction< ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>, - ffi.Int, - ffi.Pointer>, - ffi.Int, ffi.Pointer>, - ffi.Int, - ffi.Pointer, - ffi.Pointer)>>('PyEval_EvalCodeEx'); - late final _PyEval_EvalCodeEx = _PyEval_EvalCodeExPtr.asFunction< + Py_ssize_t, + ffi.Pointer)>>('_PyObject_MakeTpCall'); + late final __PyObject_MakeTpCall = __PyObject_MakeTpCallPtr.asFunction< ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer>, - int, - ffi.Pointer>, - int, ffi.Pointer>, int, - ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _PyEval_CallTracing( - ffi.Pointer func, - ffi.Pointer args, + vectorcallfunc PyVectorcall_Function( + ffi.Pointer callable, ) { - return __PyEval_CallTracing( - func, - args, + return _PyVectorcall_Function( + callable, ); } - late final __PyEval_CallTracingPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_PyEval_CallTracing'); - late final __PyEval_CallTracing = __PyEval_CallTracingPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); - - late final ffi.Pointer> __Py_ctype_table = - _lookup>('_Py_ctype_table'); - - ffi.Pointer get _Py_ctype_table => __Py_ctype_table.value; - - set _Py_ctype_table(ffi.Pointer value) => - __Py_ctype_table.value = value; - - late final ffi.Pointer> __Py_ctype_tolower = - _lookup>('_Py_ctype_tolower'); - - ffi.Pointer get _Py_ctype_tolower => - __Py_ctype_tolower.value; - - set _Py_ctype_tolower(ffi.Pointer value) => - __Py_ctype_tolower.value = value; - - late final ffi.Pointer> __Py_ctype_toupper = - _lookup>('_Py_ctype_toupper'); - - ffi.Pointer get _Py_ctype_toupper => - __Py_ctype_toupper.value; - - set _Py_ctype_toupper(ffi.Pointer value) => - __Py_ctype_toupper.value = value; + late final _PyVectorcall_FunctionPtr = _lookup< + ffi.NativeFunction)>>( + 'PyVectorcall_Function'); + late final _PyVectorcall_Function = _PyVectorcall_FunctionPtr.asFunction< + vectorcallfunc Function(ffi.Pointer)>(); - double PyOS_string_to_double( - ffi.Pointer str, - ffi.Pointer> endptr, - ffi.Pointer overflow_exception, + ffi.Pointer PyObject_Vectorcall( + ffi.Pointer callable, + ffi.Pointer> args, + int nargsf, + ffi.Pointer kwnames, ) { - return _PyOS_string_to_double( - str, - endptr, - overflow_exception, + return _PyObject_Vectorcall( + callable, + args, + nargsf, + kwnames, ); } - late final _PyOS_string_to_doublePtr = _lookup< + late final _PyObject_VectorcallPtr = _lookup< ffi.NativeFunction< - ffi.Double Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer)>>('PyOS_string_to_double'); - late final _PyOS_string_to_double = _PyOS_string_to_doublePtr.asFunction< - double Function(ffi.Pointer, ffi.Pointer>, - ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Size, + ffi.Pointer)>>('PyObject_Vectorcall'); + late final _PyObject_Vectorcall = _PyObject_VectorcallPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer>, int, ffi.Pointer)>(); - ffi.Pointer PyOS_double_to_string( - double val, - int format_code, - int precision, - int flags, - ffi.Pointer type, + ffi.Pointer PyObject_VectorcallDict( + ffi.Pointer callable, + ffi.Pointer> args, + int nargsf, + ffi.Pointer kwargs, ) { - return _PyOS_double_to_string( - val, - format_code, - precision, - flags, - type, + return _PyObject_VectorcallDict( + callable, + args, + nargsf, + kwargs, ); } - late final _PyOS_double_to_stringPtr = _lookup< + late final _PyObject_VectorcallDictPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Double, ffi.Char, ffi.Int, ffi.Int, - ffi.Pointer)>>('PyOS_double_to_string'); - late final _PyOS_double_to_string = _PyOS_double_to_stringPtr.asFunction< - ffi.Pointer Function( - double, int, int, int, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Size, + ffi.Pointer)>>('PyObject_VectorcallDict'); + late final _PyObject_VectorcallDict = _PyObject_VectorcallDictPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer>, int, ffi.Pointer)>(); - ffi.Pointer _Py_string_to_number_with_underscores( - ffi.Pointer str, - int len, - ffi.Pointer what, - ffi.Pointer obj, - ffi.Pointer arg, - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, Py_ssize_t, ffi.Pointer)>> - innerfunc, + ffi.Pointer PyVectorcall_Call( + ffi.Pointer callable, + ffi.Pointer tuple, + ffi.Pointer dict, ) { - return __Py_string_to_number_with_underscores( - str, - len, - what, - obj, - arg, - innerfunc, + return _PyVectorcall_Call( + callable, + tuple, + dict, ); } - late final __Py_string_to_number_with_underscoresPtr = _lookup< - ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, - Py_ssize_t, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer, - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - Py_ssize_t, ffi.Pointer)>>)>>( - '_Py_string_to_number_with_underscores'); - late final __Py_string_to_number_with_underscores = - __Py_string_to_number_with_underscoresPtr.asFunction< + late final _PyVectorcall_CallPtr = _lookup< + ffi.NativeFunction< ffi.Pointer Function( - ffi.Pointer, - int, - ffi.Pointer, ffi.Pointer, - ffi.Pointer, - ffi.Pointer< - ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - Py_ssize_t, ffi.Pointer)>>)>(); + ffi.Pointer, + ffi.Pointer)>>('PyVectorcall_Call'); + late final _PyVectorcall_Call = _PyVectorcall_CallPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - double _Py_parse_inf_or_nan( - ffi.Pointer p, - ffi.Pointer> endptr, + ffi.Pointer _PyObject_FastCall( + ffi.Pointer func, + ffi.Pointer> args, + int nargs, ) { - return __Py_parse_inf_or_nan( - p, - endptr, + return __PyObject_FastCall( + func, + args, + nargs, ); } - late final __Py_parse_inf_or_nanPtr = _lookup< + late final __PyObject_FastCallPtr = _lookup< ffi.NativeFunction< - ffi.Double Function(ffi.Pointer, - ffi.Pointer>)>>('_Py_parse_inf_or_nan'); - late final __Py_parse_inf_or_nan = __Py_parse_inf_or_nanPtr.asFunction< - double Function( - ffi.Pointer, ffi.Pointer>)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer>, + Py_ssize_t)>>('_PyObject_FastCall'); + late final __PyObject_FastCall = __PyObject_FastCallPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer>, int)>(); - int PyOS_mystrnicmp( - ffi.Pointer arg0, - ffi.Pointer arg1, - int arg2, + ffi.Pointer PyObject_CallOneArg( + ffi.Pointer func, + ffi.Pointer arg, ) { - return _PyOS_mystrnicmp( - arg0, - arg1, - arg2, + return _PyObject_CallOneArg( + func, + arg, ); } - late final _PyOS_mystrnicmpPtr = _lookup< + late final _PyObject_CallOneArgPtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - Py_ssize_t)>>('PyOS_mystrnicmp'); - late final _PyOS_mystrnicmp = _PyOS_mystrnicmpPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('PyObject_CallOneArg'); + late final _PyObject_CallOneArg = _PyObject_CallOneArgPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int PyOS_mystricmp( - ffi.Pointer arg0, - ffi.Pointer arg1, + ffi.Pointer PyObject_VectorcallMethod( + ffi.Pointer name, + ffi.Pointer> args, + int nargsf, + ffi.Pointer kwnames, ) { - return _PyOS_mystricmp( - arg0, - arg1, + return _PyObject_VectorcallMethod( + name, + args, + nargsf, + kwnames, ); } - late final _PyOS_mystricmpPtr = _lookup< + late final _PyObject_VectorcallMethodPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('PyOS_mystricmp'); - late final _PyOS_mystricmp = _PyOS_mystricmpPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Size, + ffi.Pointer)>>('PyObject_VectorcallMethod'); + late final _PyObject_VectorcallMethod = + _PyObject_VectorcallMethodPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer>, + int, + ffi.Pointer)>(); - ffi.Pointer Py_DecodeLocale( - ffi.Pointer arg, - ffi.Pointer size, + ffi.Pointer _PyObject_CallMethod( + ffi.Pointer obj, + ffi.Pointer name, + ffi.Pointer format, ) { - return _Py_DecodeLocale( - arg, - size, + return __PyObject_CallMethod( + obj, + name, + format, ); } - late final _Py_DecodeLocalePtr = _lookup< + late final __PyObject_CallMethodPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('Py_DecodeLocale'); - late final _Py_DecodeLocale = _Py_DecodeLocalePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer, + ffi.Pointer)>>('_PyObject_CallMethod'); + late final __PyObject_CallMethod = __PyObject_CallMethodPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer Py_EncodeLocale( - ffi.Pointer text, - ffi.Pointer error_pos, + ffi.Pointer _PyObject_CallMethodId( + ffi.Pointer obj, + ffi.Pointer<_Py_Identifier> name, + ffi.Pointer format, ) { - return _Py_EncodeLocale( - text, - error_pos, + return __PyObject_CallMethodId( + obj, + name, + format, ); } - late final _Py_EncodeLocalePtr = _lookup< + late final __PyObject_CallMethodIdPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('Py_EncodeLocale'); - late final _Py_EncodeLocale = _Py_EncodeLocalePtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer<_Py_Identifier>, + ffi.Pointer)>>('_PyObject_CallMethodId'); + late final __PyObject_CallMethodId = __PyObject_CallMethodIdPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer<_Py_Identifier>, ffi.Pointer)>(); - int _Py_GetErrorHandler( - ffi.Pointer errors, + ffi.Pointer _PyObject_CallMethodId_SizeT( + ffi.Pointer obj, + ffi.Pointer<_Py_Identifier> name, + ffi.Pointer format, ) { - return __Py_GetErrorHandler( - errors, + return __PyObject_CallMethodId_SizeT( + obj, + name, + format, ); } - late final __Py_GetErrorHandlerPtr = - _lookup)>>( - '_Py_GetErrorHandler'); - late final __Py_GetErrorHandler = - __Py_GetErrorHandlerPtr.asFunction)>(); + late final __PyObject_CallMethodId_SizeTPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + ffi.Pointer<_Py_Identifier>, + ffi.Pointer)>>('_PyObject_CallMethodId_SizeT'); + late final __PyObject_CallMethodId_SizeT = + __PyObject_CallMethodId_SizeTPtr.asFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer<_Py_Identifier>, ffi.Pointer)>(); - int _Py_DecodeLocaleEx( - ffi.Pointer arg, - ffi.Pointer> wstr, - ffi.Pointer wlen, - ffi.Pointer> reason, - int current_locale, - int errors, + ffi.Pointer _PyObject_CallMethodIdObjArgs( + ffi.Pointer obj, + ffi.Pointer<_Py_Identifier> name, ) { - return __Py_DecodeLocaleEx( - arg, - wstr, - wlen, - reason, - current_locale, - errors, + return __PyObject_CallMethodIdObjArgs( + obj, + name, ); } - late final __Py_DecodeLocaleExPtr = _lookup< + late final __PyObject_CallMethodIdObjArgsPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer, - ffi.Pointer>, - ffi.Int, - ffi.Int32)>>('_Py_DecodeLocaleEx'); - late final __Py_DecodeLocaleEx = __Py_DecodeLocaleExPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer, - ffi.Pointer>, - int, - int)>(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer<_Py_Identifier>)>>('_PyObject_CallMethodIdObjArgs'); + late final __PyObject_CallMethodIdObjArgs = + __PyObject_CallMethodIdObjArgsPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer<_Py_Identifier>)>(); - int _Py_EncodeLocaleEx( - ffi.Pointer text, - ffi.Pointer> str, - ffi.Pointer error_pos, - ffi.Pointer> reason, - int current_locale, - int errors, + int _PyObject_HasLen( + ffi.Pointer o, ) { - return __Py_EncodeLocaleEx( - text, - str, - error_pos, - reason, - current_locale, - errors, + return __PyObject_HasLen( + o, ); } - late final __Py_EncodeLocaleExPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer, - ffi.Pointer>, - ffi.Int, - ffi.Int32)>>('_Py_EncodeLocaleEx'); - late final __Py_EncodeLocaleEx = __Py_EncodeLocaleExPtr.asFunction< - int Function( - ffi.Pointer, - ffi.Pointer>, - ffi.Pointer, - ffi.Pointer>, - int, - int)>(); + late final __PyObject_HasLenPtr = + _lookup)>>( + '_PyObject_HasLen'); + late final __PyObject_HasLen = + __PyObject_HasLenPtr.asFunction)>(); - ffi.Pointer _Py_EncodeLocaleRaw( - ffi.Pointer text, - ffi.Pointer error_pos, + int PyObject_LengthHint( + ffi.Pointer o, + int arg1, ) { - return __Py_EncodeLocaleRaw( - text, - error_pos, + return _PyObject_LengthHint( + o, + arg1, ); } - late final __Py_EncodeLocaleRawPtr = _lookup< + late final _PyObject_LengthHintPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer)>>('_Py_EncodeLocaleRaw'); - late final __Py_EncodeLocaleRaw = __Py_EncodeLocaleRawPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + Py_ssize_t Function( + ffi.Pointer, Py_ssize_t)>>('PyObject_LengthHint'); + late final _PyObject_LengthHint = _PyObject_LengthHintPtr.asFunction< + int Function(ffi.Pointer, int)>(); - ffi.Pointer _Py_device_encoding( - int arg0, + int _PySequence_IterSearch( + ffi.Pointer seq, + ffi.Pointer obj, + int operation, ) { - return __Py_device_encoding( - arg0, + return __PySequence_IterSearch( + seq, + obj, + operation, ); } - late final __Py_device_encodingPtr = - _lookup Function(ffi.Int)>>( - '_Py_device_encoding'); - late final __Py_device_encoding = - __Py_device_encodingPtr.asFunction Function(int)>(); + late final __PySequence_IterSearchPtr = _lookup< + ffi.NativeFunction< + Py_ssize_t Function(ffi.Pointer, ffi.Pointer, + ffi.Int)>>('_PySequence_IterSearch'); + late final __PySequence_IterSearch = __PySequence_IterSearchPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - int _Py_fstat( - int fd, - ffi.Pointer status, + int _PyObject_RealIsInstance( + ffi.Pointer inst, + ffi.Pointer cls, ) { - return __Py_fstat( - fd, - status, + return __PyObject_RealIsInstance( + inst, + cls, ); } - late final __Py_fstatPtr = - _lookup)>>( - '_Py_fstat'); - late final __Py_fstat = - __Py_fstatPtr.asFunction)>(); + late final __PyObject_RealIsInstancePtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyObject_RealIsInstance'); + late final __PyObject_RealIsInstance = __PyObject_RealIsInstancePtr + .asFunction, ffi.Pointer)>(); - int _Py_fstat_noraise( - int fd, - ffi.Pointer status, + int _PyObject_RealIsSubclass( + ffi.Pointer derived, + ffi.Pointer cls, ) { - return __Py_fstat_noraise( - fd, - status, + return __PyObject_RealIsSubclass( + derived, + cls, ); } - late final __Py_fstat_noraisePtr = - _lookup)>>( - '_Py_fstat_noraise'); - late final __Py_fstat_noraise = - __Py_fstat_noraisePtr.asFunction)>(); + late final __PyObject_RealIsSubclassPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_PyObject_RealIsSubclass'); + late final __PyObject_RealIsSubclass = __PyObject_RealIsSubclassPtr + .asFunction, ffi.Pointer)>(); - int _Py_stat( - ffi.Pointer path, - ffi.Pointer status, + ffi.Pointer> _PySequence_BytesToCharpArray( + ffi.Pointer self, ) { - return __Py_stat( - path, - status, + return __PySequence_BytesToCharpArray( + self, ); } - late final __Py_statPtr = _lookup< + late final __PySequence_BytesToCharpArrayPtr = _lookup< ffi.NativeFunction< - ffi.Int Function( - ffi.Pointer, ffi.Pointer)>>('_Py_stat'); - late final __Py_stat = __Py_statPtr - .asFunction, ffi.Pointer)>(); + ffi.Pointer> Function( + ffi.Pointer)>>('_PySequence_BytesToCharpArray'); + late final __PySequence_BytesToCharpArray = + __PySequence_BytesToCharpArrayPtr.asFunction< + ffi.Pointer> Function(ffi.Pointer)>(); - int _Py_open( - ffi.Pointer pathname, - int flags, + void _Py_FreeCharPArray( + ffi.Pointer> array, ) { - return __Py_open( - pathname, - flags, + return __Py_FreeCharPArray( + array, ); } - late final __Py_openPtr = _lookup< - ffi.NativeFunction, ffi.Int)>>( - '_Py_open'); - late final __Py_open = - __Py_openPtr.asFunction, int)>(); + late final __Py_FreeCharPArrayPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function( + ffi.Pointer>)>>('_Py_FreeCharPArray'); + late final __Py_FreeCharPArray = __Py_FreeCharPArrayPtr + .asFunction>)>(); - int _Py_open_noraise( - ffi.Pointer pathname, - int flags, + void _Py_add_one_to_index_F( + int nd, + ffi.Pointer index, + ffi.Pointer shape, ) { - return __Py_open_noraise( - pathname, - flags, + return __Py_add_one_to_index_F( + nd, + index, + shape, ); } - late final __Py_open_noraisePtr = _lookup< - ffi.NativeFunction, ffi.Int)>>( - '_Py_open_noraise'); - late final __Py_open_noraise = __Py_open_noraisePtr - .asFunction, int)>(); + late final __Py_add_one_to_index_FPtr = _lookup< + ffi.NativeFunction< + ffi.Void Function(ffi.Int, ffi.Pointer, + ffi.Pointer)>>('_Py_add_one_to_index_F'); + late final __Py_add_one_to_index_F = __Py_add_one_to_index_FPtr.asFunction< + void Function(int, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _Py_wfopen( - ffi.Pointer path, - ffi.Pointer mode, + void _Py_add_one_to_index_C( + int nd, + ffi.Pointer index, + ffi.Pointer shape, ) { - return __Py_wfopen( - path, - mode, + return __Py_add_one_to_index_C( + nd, + index, + shape, ); } - late final __Py_wfopenPtr = _lookup< + late final __Py_add_one_to_index_CPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('_Py_wfopen'); - late final __Py_wfopen = __Py_wfopenPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Void Function(ffi.Int, ffi.Pointer, + ffi.Pointer)>>('_Py_add_one_to_index_C'); + late final __Py_add_one_to_index_C = __Py_add_one_to_index_CPtr.asFunction< + void Function(int, ffi.Pointer, ffi.Pointer)>(); - ffi.Pointer _Py_fopen_obj( - ffi.Pointer path, - ffi.Pointer mode, + int _Py_convert_optional_to_ssize_t( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __Py_fopen_obj( - path, - mode, + return __Py_convert_optional_to_ssize_t( + arg0, + arg1, ); } - late final __Py_fopen_objPtr = _lookup< + late final __Py_convert_optional_to_ssize_tPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>('_Py_fopen_obj'); - late final __Py_fopen_obj = __Py_fopen_objPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>(); + ffi.Int Function(ffi.Pointer, + ffi.Pointer)>>('_Py_convert_optional_to_ssize_t'); + late final __Py_convert_optional_to_ssize_t = + __Py_convert_optional_to_ssize_tPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int _Py_read( - int fd, - ffi.Pointer buf, - int count, + ffi.Pointer _PyNumber_Index( + ffi.Pointer o, ) { - return __Py_read( - fd, - buf, - count, + return __PyNumber_Index( + o, ); } - late final __Py_readPtr = _lookup< + late final __PyNumber_IndexPtr = _lookup< ffi.NativeFunction< - Py_ssize_t Function( - ffi.Int, ffi.Pointer, ffi.Size)>>('_Py_read'); - late final __Py_read = - __Py_readPtr.asFunction, int)>(); + ffi.Pointer Function( + ffi.Pointer)>>('_PyNumber_Index'); + late final __PyNumber_Index = __PyNumber_IndexPtr + .asFunction Function(ffi.Pointer)>(); - int _Py_write( - int fd, - ffi.Pointer buf, - int count, - ) { - return __Py_write( - fd, - buf, - count, - ); - } + late final ffi.Pointer _PyFilter_Type = + _lookup('PyFilter_Type'); + + PyTypeObject get PyFilter_Type => _PyFilter_Type.ref; + + late final ffi.Pointer _PyMap_Type = + _lookup('PyMap_Type'); + + PyTypeObject get PyMap_Type => _PyMap_Type.ref; + + late final ffi.Pointer _PyZip_Type = + _lookup('PyZip_Type'); + + PyTypeObject get PyZip_Type => _PyZip_Type.ref; + + late final ffi.Pointer> __Py_ctype_table = + _lookup>('_Py_ctype_table'); + + ffi.Pointer get _Py_ctype_table => __Py_ctype_table.value; + + set _Py_ctype_table(ffi.Pointer value) => + __Py_ctype_table.value = value; - late final __Py_writePtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function( - ffi.Int, ffi.Pointer, ffi.Size)>>('_Py_write'); - late final __Py_write = - __Py_writePtr.asFunction, int)>(); + late final ffi.Pointer> __Py_ctype_tolower = + _lookup>('_Py_ctype_tolower'); - int _Py_write_noraise( - int fd, - ffi.Pointer buf, - int count, - ) { - return __Py_write_noraise( - fd, - buf, - count, - ); - } + ffi.Pointer get _Py_ctype_tolower => + __Py_ctype_tolower.value; - late final __Py_write_noraisePtr = _lookup< - ffi.NativeFunction< - Py_ssize_t Function( - ffi.Int, ffi.Pointer, ffi.Size)>>('_Py_write_noraise'); - late final __Py_write_noraise = __Py_write_noraisePtr - .asFunction, int)>(); + set _Py_ctype_tolower(ffi.Pointer value) => + __Py_ctype_tolower.value = value; - int _Py_wreadlink( - ffi.Pointer path, - ffi.Pointer buf, - int buflen, - ) { - return __Py_wreadlink( - path, - buf, - buflen, - ); - } + late final ffi.Pointer> __Py_ctype_toupper = + _lookup>('_Py_ctype_toupper'); - late final __Py_wreadlinkPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Size)>>('_Py_wreadlink'); - late final __Py_wreadlink = __Py_wreadlinkPtr.asFunction< - int Function(ffi.Pointer, ffi.Pointer, int)>(); + ffi.Pointer get _Py_ctype_toupper => + __Py_ctype_toupper.value; - ffi.Pointer _Py_wrealpath( - ffi.Pointer path, - ffi.Pointer resolved_path, - int resolved_path_len, + set _Py_ctype_toupper(ffi.Pointer value) => + __Py_ctype_toupper.value = value; + + double PyOS_string_to_double( + ffi.Pointer str, + ffi.Pointer> endptr, + ffi.Pointer overflow_exception, ) { - return __Py_wrealpath( - path, - resolved_path, - resolved_path_len, + return _PyOS_string_to_double( + str, + endptr, + overflow_exception, ); } - late final __Py_wrealpathPtr = _lookup< + late final _PyOS_string_to_doublePtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Size)>>('_Py_wrealpath'); - late final __Py_wrealpath = __Py_wrealpathPtr.asFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, int)>(); + ffi.Double Function( + ffi.Pointer, + ffi.Pointer>, + ffi.Pointer)>>('PyOS_string_to_double'); + late final _PyOS_string_to_double = _PyOS_string_to_doublePtr.asFunction< + double Function(ffi.Pointer, ffi.Pointer>, + ffi.Pointer)>(); - int _Py_isabs( - ffi.Pointer path, + ffi.Pointer PyOS_double_to_string( + double val, + int format_code, + int precision, + int flags, + ffi.Pointer type, ) { - return __Py_isabs( - path, + return _PyOS_double_to_string( + val, + format_code, + precision, + flags, + type, ); } - late final __Py_isabsPtr = - _lookup)>>( - '_Py_isabs'); - late final __Py_isabs = - __Py_isabsPtr.asFunction)>(); + late final _PyOS_double_to_stringPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Double, ffi.Char, ffi.Int, ffi.Int, + ffi.Pointer)>>('PyOS_double_to_string'); + late final _PyOS_double_to_string = _PyOS_double_to_stringPtr.asFunction< + ffi.Pointer Function( + double, int, int, int, ffi.Pointer)>(); - int _Py_abspath( - ffi.Pointer path, - ffi.Pointer> abspath_p, + ffi.Pointer _Py_string_to_number_with_underscores( + ffi.Pointer str, + int len, + ffi.Pointer what, + ffi.Pointer obj, + ffi.Pointer arg, + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, Py_ssize_t, ffi.Pointer)>> + innerfunc, ) { - return __Py_abspath( - path, - abspath_p, + return __Py_string_to_number_with_underscores( + str, + len, + what, + obj, + arg, + innerfunc, ); } - late final __Py_abspathPtr = _lookup< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, - ffi.Pointer>)>>('_Py_abspath'); - late final __Py_abspath = __Py_abspathPtr.asFunction< - int Function( - ffi.Pointer, ffi.Pointer>)>(); + late final __Py_string_to_number_with_underscoresPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, + Py_ssize_t, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + Py_ssize_t, ffi.Pointer)>>)>>( + '_Py_string_to_number_with_underscores'); + late final __Py_string_to_number_with_underscores = + __Py_string_to_number_with_underscoresPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, + int, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer, + ffi.Pointer< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + Py_ssize_t, ffi.Pointer)>>)>(); - ffi.Pointer _Py_wgetcwd( - ffi.Pointer buf, - int buflen, + double _Py_parse_inf_or_nan( + ffi.Pointer p, + ffi.Pointer> endptr, ) { - return __Py_wgetcwd( - buf, - buflen, + return __Py_parse_inf_or_nan( + p, + endptr, ); } - late final __Py_wgetcwdPtr = _lookup< + late final __Py_parse_inf_or_nanPtr = _lookup< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Size)>>('_Py_wgetcwd'); - late final __Py_wgetcwd = __Py_wgetcwdPtr.asFunction< - ffi.Pointer Function(ffi.Pointer, int)>(); + ffi.Double Function(ffi.Pointer, + ffi.Pointer>)>>('_Py_parse_inf_or_nan'); + late final __Py_parse_inf_or_nan = __Py_parse_inf_or_nanPtr.asFunction< + double Function( + ffi.Pointer, ffi.Pointer>)>(); - int _Py_get_inheritable( - int fd, + int PyOS_mystrnicmp( + ffi.Pointer arg0, + ffi.Pointer arg1, + int arg2, ) { - return __Py_get_inheritable( - fd, + return _PyOS_mystrnicmp( + arg0, + arg1, + arg2, ); } - late final __Py_get_inheritablePtr = - _lookup>( - '_Py_get_inheritable'); - late final __Py_get_inheritable = - __Py_get_inheritablePtr.asFunction(); + late final _PyOS_mystrnicmpPtr = _lookup< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + Py_ssize_t)>>('PyOS_mystrnicmp'); + late final _PyOS_mystrnicmp = _PyOS_mystrnicmpPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer, int)>(); - int _Py_set_inheritable( - int fd, - int inheritable, - ffi.Pointer atomic_flag_works, + int PyOS_mystricmp( + ffi.Pointer arg0, + ffi.Pointer arg1, ) { - return __Py_set_inheritable( - fd, - inheritable, - atomic_flag_works, + return _PyOS_mystricmp( + arg0, + arg1, ); } - late final __Py_set_inheritablePtr = _lookup< + late final _PyOS_mystricmpPtr = _lookup< ffi.NativeFunction< ffi.Int Function( - ffi.Int, ffi.Int, ffi.Pointer)>>('_Py_set_inheritable'); - late final __Py_set_inheritable = __Py_set_inheritablePtr - .asFunction)>(); + ffi.Pointer, ffi.Pointer)>>('PyOS_mystricmp'); + late final _PyOS_mystricmp = _PyOS_mystricmpPtr.asFunction< + int Function(ffi.Pointer, ffi.Pointer)>(); - int _Py_set_inheritable_async_safe( - int fd, - int inheritable, - ffi.Pointer atomic_flag_works, + ffi.Pointer Py_DecodeLocale( + ffi.Pointer arg, + ffi.Pointer size, ) { - return __Py_set_inheritable_async_safe( - fd, - inheritable, - atomic_flag_works, + return _Py_DecodeLocale( + arg, + size, ); } - late final __Py_set_inheritable_async_safePtr = _lookup< + late final _Py_DecodeLocalePtr = _lookup< ffi.NativeFunction< - ffi.Int Function(ffi.Int, ffi.Int, - ffi.Pointer)>>('_Py_set_inheritable_async_safe'); - late final __Py_set_inheritable_async_safe = - __Py_set_inheritable_async_safePtr - .asFunction)>(); - - int _Py_dup( - int fd, - ) { - return __Py_dup( - fd, - ); - } - - late final __Py_dupPtr = - _lookup>('_Py_dup'); - late final __Py_dup = __Py_dupPtr.asFunction(); + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('Py_DecodeLocale'); + late final _Py_DecodeLocale = _Py_DecodeLocalePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _Py_get_blocking( - int fd, + ffi.Pointer Py_EncodeLocale( + ffi.Pointer text, + ffi.Pointer error_pos, ) { - return __Py_get_blocking( - fd, + return _Py_EncodeLocale( + text, + error_pos, ); } - late final __Py_get_blockingPtr = - _lookup>( - '_Py_get_blocking'); - late final __Py_get_blocking = - __Py_get_blockingPtr.asFunction(); + late final _Py_EncodeLocalePtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer)>>('Py_EncodeLocale'); + late final _Py_EncodeLocale = _Py_EncodeLocalePtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); - int _Py_set_blocking( - int fd, - int blocking, + ffi.Pointer _Py_fopen_obj( + ffi.Pointer path, + ffi.Pointer mode, ) { - return __Py_set_blocking( - fd, - blocking, + return __Py_fopen_obj( + path, + mode, ); } - late final __Py_set_blockingPtr = - _lookup>( - '_Py_set_blocking'); - late final __Py_set_blocking = - __Py_set_blockingPtr.asFunction(); + late final __Py_fopen_objPtr = _lookup< + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>('_Py_fopen_obj'); + late final __Py_fopen_obj = __Py_fopen_objPtr.asFunction< + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>(); int PyTraceMalloc_Track( int domain, @@ -23240,12 +22463,59 @@ final class PyMemAllocatorEx extends ffi.Struct { ffi.Pointer Function(ffi.Pointer ctx, ffi.Pointer ptr, ffi.Size new_size)>> realloc; - external ffi.Pointer< - ffi.NativeFunction< - ffi.Void Function( - ffi.Pointer ctx, ffi.Pointer ptr)>> free; + external ffi.Pointer< + ffi.NativeFunction< + ffi.Void Function( + ffi.Pointer ctx, ffi.Pointer ptr)>> free; +} + +final class PyModuleDef extends ffi.Struct { + external PyModuleDef_Base m_base; + + external ffi.Pointer m_name; + + external ffi.Pointer m_doc; + + @Py_ssize_t() + external int m_size; + + external ffi.Pointer m_methods; + + external ffi.Pointer m_slots; + + external traverseproc m_traverse; + + external inquiry m_clear; + + external freefunc m_free; +} + +final class PyModuleDef_Base extends ffi.Struct { + external PyObject ob_base; + + external ffi.Pointer Function()>> + m_init; + + @Py_ssize_t() + external int m_index; + + external ffi.Pointer m_copy; +} + +typedef PyObject = _object; + +final class _object extends ffi.Struct { + @Py_ssize_t() + external int ob_refcnt; + + external ffi.Pointer ob_type; } +typedef Py_ssize_t = ssize_t; +typedef ssize_t = __darwin_ssize_t; +typedef __darwin_ssize_t = ffi.Long; +typedef PyTypeObject = _typeobject; + final class _typeobject extends ffi.Struct { external PyVarObject ob_base; @@ -23312,9 +22582,9 @@ final class _typeobject extends ffi.Struct { external ffi.Pointer tp_getset; - external ffi.Pointer<_typeobject> tp_base; + external ffi.Pointer tp_base; - external ffi.Pointer tp_dict; + external ffi.Pointer tp_dict; external descrgetfunc tp_descr_get; @@ -23333,15 +22603,15 @@ final class _typeobject extends ffi.Struct { external inquiry tp_is_gc; - external ffi.Pointer tp_bases; + external ffi.Pointer tp_bases; - external ffi.Pointer tp_mro; + external ffi.Pointer tp_mro; - external ffi.Pointer tp_cache; + external ffi.Pointer tp_cache; - external ffi.Pointer tp_subclasses; + external ffi.Pointer tp_subclasses; - external ffi.Pointer tp_weaklist; + external ffi.Pointer tp_weaklist; external destructor tp_del; @@ -23354,35 +22624,23 @@ final class _typeobject extends ffi.Struct { } final class PyVarObject extends ffi.Struct { - external PyObject ob_base; + external PyObject1 ob_base; @Py_ssize_t() external int ob_size; } -typedef PyObject = _object; - -final class _object extends ffi.Struct { - @Py_ssize_t() - external int ob_refcnt; - - external ffi.Pointer ob_type; -} - -typedef Py_ssize_t = ssize_t; -typedef ssize_t = __darwin_ssize_t; -typedef __darwin_ssize_t = ffi.Long; -typedef PyTypeObject = _typeobject; -typedef destructor - = ffi.Pointer)>>; +typedef PyObject1 = _object; +typedef destructor = ffi + .Pointer)>>; typedef getattrfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>; typedef setattrfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>; final class PyAsyncMethods extends ffi.Struct { external unaryfunc am_await; @@ -23395,13 +22653,14 @@ final class PyAsyncMethods extends ffi.Struct { } typedef unaryfunc = ffi.Pointer< - ffi.NativeFunction Function(ffi.Pointer)>>; + ffi + .NativeFunction Function(ffi.Pointer)>>; typedef sendfunc = ffi.Pointer< ffi.NativeFunction< ffi.Int32 Function( - ffi.Pointer iter, - ffi.Pointer value, - ffi.Pointer> result)>>; + ffi.Pointer iter, + ffi.Pointer value, + ffi.Pointer> result)>>; abstract class PySendResult { static const int PYGEN_RETURN = 0; @@ -23410,7 +22669,8 @@ abstract class PySendResult { } typedef reprfunc = ffi.Pointer< - ffi.NativeFunction Function(ffi.Pointer)>>; + ffi + .NativeFunction Function(ffi.Pointer)>>; final class PyNumberMethods extends ffi.Struct { external binaryfunc nb_add; @@ -23488,14 +22748,14 @@ final class PyNumberMethods extends ffi.Struct { typedef binaryfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>; typedef ternaryfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>; typedef inquiry - = ffi.Pointer)>>; + = ffi.Pointer)>>; final class PySequenceMethods extends ffi.Struct { external lenfunc sq_length; @@ -23520,17 +22780,17 @@ final class PySequenceMethods extends ffi.Struct { } typedef lenfunc = ffi - .Pointer)>>; + .Pointer)>>; typedef ssizeargfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t)>>; + ffi.Pointer Function(ffi.Pointer, Py_ssize_t)>>; typedef ssizeobjargproc = ffi.Pointer< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer, Py_ssize_t, ffi.Pointer)>>; + ffi.Pointer, Py_ssize_t, ffi.Pointer)>>; typedef objobjproc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer)>>; final class PyMappingMethods extends ffi.Struct { external lenfunc mp_length; @@ -23542,19 +22802,19 @@ final class PyMappingMethods extends ffi.Struct { typedef objobjargproc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>; typedef hashfunc = ffi - .Pointer)>>; + .Pointer)>>; typedef Py_hash_t = Py_ssize_t; typedef getattrofunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>; typedef setattrofunc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>; final class PyBufferProcs extends ffi.Struct { external getbufferproc bf_getbuffer; @@ -23565,13 +22825,12 @@ final class PyBufferProcs extends ffi.Struct { typedef getbufferproc = ffi.Pointer< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer, ffi.Pointer, ffi.Int)>>; -typedef Py_buffer = bufferinfo; + ffi.Pointer, ffi.Pointer, ffi.Int)>>; -final class bufferinfo extends ffi.Struct { +final class Py_buffer extends ffi.Struct { external ffi.Pointer buf; - external ffi.Pointer obj; + external ffi.Pointer obj; @Py_ssize_t() external int len; @@ -23598,22 +22857,24 @@ final class bufferinfo extends ffi.Struct { typedef releasebufferproc = ffi.Pointer< ffi.NativeFunction< - ffi.Void Function(ffi.Pointer, ffi.Pointer)>>; + ffi.Void Function(ffi.Pointer, ffi.Pointer)>>; typedef traverseproc = ffi.Pointer< ffi.NativeFunction< ffi.Int Function( - ffi.Pointer, visitproc, ffi.Pointer)>>; + ffi.Pointer, visitproc, ffi.Pointer)>>; typedef visitproc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer)>>; typedef richcmpfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, ffi.Int)>>; + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer, ffi.Int)>>; typedef getiterfunc = ffi.Pointer< - ffi.NativeFunction Function(ffi.Pointer)>>; + ffi + .NativeFunction Function(ffi.Pointer)>>; typedef iternextfunc = ffi.Pointer< - ffi.NativeFunction Function(ffi.Pointer)>>; + ffi + .NativeFunction Function(ffi.Pointer)>>; final class PyMethodDef extends ffi.Struct { external ffi.Pointer ml_name; @@ -23628,8 +22889,8 @@ final class PyMethodDef extends ffi.Struct { typedef PyCFunction = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>; final class PyMemberDef extends ffi.Opaque {} @@ -23647,40 +22908,307 @@ final class PyGetSetDef extends ffi.Struct { typedef getter = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function( + ffi.Pointer, ffi.Pointer)>>; typedef setter = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Int Function(ffi.Pointer, ffi.Pointer, ffi.Pointer)>>; +typedef PyTypeObject1 = _typeobject; typedef descrgetfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>; typedef descrsetfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>; typedef initproc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Pointer)>>; + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Pointer)>>; typedef allocfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, Py_ssize_t)>>; + ffi.Pointer Function( + ffi.Pointer, Py_ssize_t)>>; typedef newfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function(ffi.Pointer, - ffi.Pointer, ffi.Pointer)>>; + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer, ffi.Pointer)>>; typedef freefunc = ffi.Pointer)>>; typedef vectorcallfunc = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer callable, - ffi.Pointer> args, + ffi.Pointer Function( + ffi.Pointer callable, + ffi.Pointer> args, ffi.Size nargsf, - ffi.Pointer kwnames)>>; + ffi.Pointer kwnames)>>; + +final class PyModuleDef_Slot extends ffi.Struct { + @ffi.Int() + external int slot; + + external ffi.Pointer value; +} + +final class _longobject extends ffi.Struct { + external PyVarObject ob_base; + + @ffi.Array.multi([1]) + external ffi.Array ob_digit; +} + +typedef digit = ffi.Uint32; + +final class PyCodeObject extends ffi.Struct { + external PyVarObject ob_base; + + external ffi.Pointer co_consts; + + external ffi.Pointer co_names; + + external ffi.Pointer co_exceptiontable; + + @ffi.Int() + external int co_flags; + + @ffi.Short() + external int co_warmup; + + @ffi.Short() + external int _co_linearray_entry_size; + + @ffi.Int() + external int co_argcount; + + @ffi.Int() + external int co_posonlyargcount; + + @ffi.Int() + external int co_kwonlyargcount; + + @ffi.Int() + external int co_stacksize; + + @ffi.Int() + external int co_firstlineno; + + @ffi.Int() + external int co_nlocalsplus; + + @ffi.Int() + external int co_nlocals; + + @ffi.Int() + external int co_nplaincellvars; + + @ffi.Int() + external int co_ncellvars; + + @ffi.Int() + external int co_nfreevars; + + external ffi.Pointer co_localsplusnames; + + external ffi.Pointer co_localspluskinds; + + external ffi.Pointer co_filename; + + external ffi.Pointer co_name; + + external ffi.Pointer co_qualname; + + external ffi.Pointer co_linetable; + + external ffi.Pointer co_weakreflist; + + external ffi.Pointer _co_code; + + external ffi.Pointer _co_linearray; + + @ffi.Int() + external int _co_firsttraceable; + + external ffi.Pointer co_extra; + + @ffi.Array.multi([1]) + external ffi.Array co_code_adaptive; +} + +final class _frame extends ffi.Opaque {} + +final class _ts extends ffi.Struct { + external ffi.Pointer prev; + + external ffi.Pointer next; + + external ffi.Pointer interp; + + @ffi.Int() + external int _initialized; + + @ffi.Int() + external int _static; + + @ffi.Int() + external int recursion_remaining; + + @ffi.Int() + external int recursion_limit; + + @ffi.Int() + external int recursion_headroom; + + @ffi.Int() + external int tracing; + + @ffi.Int() + external int tracing_what; + + external ffi.Pointer<_PyCFrame> cframe; + + external Py_tracefunc c_profilefunc; + + external Py_tracefunc c_tracefunc; + + external ffi.Pointer c_profileobj; + + external ffi.Pointer c_traceobj; + + external ffi.Pointer curexc_type; + + external ffi.Pointer curexc_value; + + external ffi.Pointer curexc_traceback; + + external ffi.Pointer<_PyErr_StackItem> exc_info; + + external ffi.Pointer dict; + + @ffi.Int() + external int gilstate_counter; + + external ffi.Pointer async_exc; + + @ffi.UnsignedLong() + external int thread_id; + + @ffi.UnsignedLong() + external int native_thread_id; + + @ffi.Int() + external int trash_delete_nesting; + + external ffi.Pointer trash_delete_later; + + external ffi + .Pointer)>> + on_delete; + + external ffi.Pointer on_delete_data; + + @ffi.Int() + external int coroutine_origin_tracking_depth; + + external ffi.Pointer async_gen_firstiter; + + external ffi.Pointer async_gen_finalizer; + + external ffi.Pointer context; + + @ffi.Uint64() + external int context_ver; + + @ffi.Uint64() + external int id; + + external PyTraceInfo trace_info; + + external ffi.Pointer<_PyStackChunk> datastack_chunk; + + external ffi.Pointer> datastack_top; + + external ffi.Pointer> datastack_limit; + + external _PyErr_StackItem exc_state; + + external _PyCFrame root_cframe; +} + +typedef PyThreadState = _ts; +typedef PyInterpreterState = _is; + +final class _is extends ffi.Opaque {} + +final class _PyCFrame extends ffi.Struct { + @ffi.Uint8() + external int use_tracing; + + external ffi.Pointer<_PyInterpreterFrame> current_frame; + + external ffi.Pointer<_PyCFrame> previous; +} + +final class _PyInterpreterFrame extends ffi.Opaque {} + +typedef Py_tracefunc = ffi.Pointer< + ffi.NativeFunction< + ffi.Int Function(ffi.Pointer, ffi.Pointer, + ffi.Int, ffi.Pointer)>>; +typedef PyFrameObject = _frame; +typedef _PyErr_StackItem = _err_stackitem; + +final class _err_stackitem extends ffi.Struct { + external ffi.Pointer exc_value; + + external ffi.Pointer<_err_stackitem> previous_item; +} + +final class PyTraceInfo extends ffi.Struct { + external ffi.Pointer code; + + external PyCodeAddressRange bounds; +} + +typedef PyCodeAddressRange = _line_offsets; + +final class _line_offsets extends ffi.Struct { + @ffi.Int() + external int ar_start; + + @ffi.Int() + external int ar_end; + + @ffi.Int() + external int ar_line; + + external _opaque opaque; +} + +final class _opaque extends ffi.Struct { + @ffi.Int() + external int computed_line; + + external ffi.Pointer lo_next; + + external ffi.Pointer limit; +} + +typedef _PyStackChunk = _stack_chunk; + +final class _stack_chunk extends ffi.Struct { + external ffi.Pointer<_stack_chunk> previous; + + @ffi.Size() + external int size; + + @ffi.Size() + external int top; + + @ffi.Array.multi([1]) + external ffi.Array> data; +} final class PyType_Slot extends ffi.Struct { @ffi.Int() @@ -23711,6 +23239,10 @@ final class _Py_Identifier extends ffi.Struct { external int index; } +final class _specialization_cache extends ffi.Struct { + external ffi.Pointer getitem; +} + final class _heaptypeobject extends ffi.Struct { external PyTypeObject ht_type; @@ -23733,49 +23265,13 @@ final class _heaptypeobject extends ffi.Struct { external ffi.Pointer<_dictkeysobject> ht_cached_keys; external ffi.Pointer ht_module; -} - -final class _dictkeysobject extends ffi.Opaque {} - -final class PyModuleDef extends ffi.Struct { - external PyModuleDef_Base m_base; - - external ffi.Pointer m_name; - - external ffi.Pointer m_doc; - - @Py_ssize_t() - external int m_size; - - external ffi.Pointer m_methods; - - external ffi.Pointer m_slots; - - external traverseproc m_traverse; - - external inquiry m_clear; - - external freefunc m_free; -} - -final class PyModuleDef_Base extends ffi.Struct { - external PyObject ob_base; - external ffi.Pointer Function()>> - m_init; - - @Py_ssize_t() - external int m_index; + external ffi.Pointer _ht_tpname; - external ffi.Pointer m_copy; + external _specialization_cache _spec_cache; } -final class PyModuleDef_Slot extends ffi.Struct { - @ffi.Int() - external int slot; - - external ffi.Pointer value; -} +final class _dictkeysobject extends ffi.Opaque {} typedef FILE = __sFILE; @@ -23802,7 +23298,7 @@ final class __sFILE extends ffi.Struct { external ffi.Pointer _cookie; external ffi - .Pointer)>> + .Pointer)>> _close; external ffi.Pointer< @@ -23854,119 +23350,6 @@ typedef __int64_t = ffi.LongLong; final class __sFILEX extends ffi.Opaque {} -final class _ts extends ffi.Struct { - external ffi.Pointer<_ts> prev; - - external ffi.Pointer<_ts> next; - - external ffi.Pointer interp; - - external ffi.Pointer frame; - - @ffi.Int() - external int recursion_depth; - - @ffi.Int() - external int recursion_headroom; - - @ffi.Int() - external int stackcheck_counter; - - @ffi.Int() - external int tracing; - - external ffi.Pointer cframe; - - external Py_tracefunc c_profilefunc; - - external Py_tracefunc c_tracefunc; - - external ffi.Pointer c_profileobj; - - external ffi.Pointer c_traceobj; - - external ffi.Pointer curexc_type; - - external ffi.Pointer curexc_value; - - external ffi.Pointer curexc_traceback; - - external _PyErr_StackItem exc_state; - - external ffi.Pointer<_PyErr_StackItem> exc_info; - - external ffi.Pointer dict; - - @ffi.Int() - external int gilstate_counter; - - external ffi.Pointer async_exc; - - @ffi.UnsignedLong() - external int thread_id; - - @ffi.Int() - external int trash_delete_nesting; - - external ffi.Pointer trash_delete_later; - - external ffi - .Pointer)>> - on_delete; - - external ffi.Pointer on_delete_data; - - @ffi.Int() - external int coroutine_origin_tracking_depth; - - external ffi.Pointer async_gen_firstiter; - - external ffi.Pointer async_gen_finalizer; - - external ffi.Pointer context; - - @ffi.Uint64() - external int context_ver; - - @ffi.Uint64() - external int id; - - external CFrame root_cframe; -} - -typedef PyInterpreterState = _is; - -final class _is extends ffi.Opaque {} - -typedef PyFrameObject = _frame; - -final class _frame extends ffi.Opaque {} - -typedef CFrame = _cframe; - -final class _cframe extends ffi.Struct { - @ffi.Int() - external int use_tracing; - - external ffi.Pointer<_cframe> previous; -} - -typedef Py_tracefunc = ffi.Pointer< - ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer, - ffi.Int, ffi.Pointer)>>; -typedef _PyErr_StackItem = _err_stackitem; - -final class _err_stackitem extends ffi.Struct { - external ffi.Pointer exc_type; - - external ffi.Pointer exc_value; - - external ffi.Pointer exc_traceback; - - external ffi.Pointer<_err_stackitem> previous_item; -} - final class PyObjectArenaAllocator extends ffi.Struct { external ffi.Pointer ctx; @@ -24136,14 +23519,6 @@ final class _PyUnicodeWriter extends ffi.Struct { external int readonly; } -final class _longobject extends ffi.Struct { - external PyVarObject ob_base; - - @ffi.Array.multi([1]) - external ffi.Array ob_digit; -} - -typedef digit = ffi.Uint32; typedef PyLongObject = _longobject; final class PyFloatObject extends ffi.Struct { @@ -24217,6 +23592,8 @@ final class PyListObject extends ffi.Struct { external int allocated; } +final class _dictvalues extends ffi.Opaque {} + final class PyDictObject extends ffi.Struct { external PyObject ob_base; @@ -24228,10 +23605,11 @@ final class PyDictObject extends ffi.Struct { external ffi.Pointer ma_keys; - external ffi.Pointer> ma_values; + external ffi.Pointer ma_values; } typedef PyDictKeysObject = _dictkeysobject; +typedef PyDictValues = _dictvalues; final class _PyDictViewObject extends ffi.Struct { external PyObject ob_base; @@ -24342,6 +23720,9 @@ final class PyFunctionObject extends ffi.Struct { external ffi.Pointer func_annotations; external vectorcallfunc vectorcall; + + @ffi.Uint32() + external int func_version; } final class PyMethodObject extends ffi.Struct { @@ -24369,97 +23750,20 @@ typedef Py_OpenCodeHookFunction = ffi.Pointer< typedef PyCapsule_Destructor = ffi.Pointer)>>; -final class PyCodeObject extends ffi.Struct { - external PyObject ob_base; - - @ffi.Int() - external int co_argcount; - - @ffi.Int() - external int co_posonlyargcount; - - @ffi.Int() - external int co_kwonlyargcount; - - @ffi.Int() - external int co_nlocals; - - @ffi.Int() - external int co_stacksize; - - @ffi.Int() - external int co_flags; - - @ffi.Int() - external int co_firstlineno; - - external ffi.Pointer co_code; - - external ffi.Pointer co_consts; - - external ffi.Pointer co_names; - - external ffi.Pointer co_varnames; - - external ffi.Pointer co_freevars; - - external ffi.Pointer co_cellvars; - - external ffi.Pointer co_cell2arg; - - external ffi.Pointer co_filename; - - external ffi.Pointer co_name; - - external ffi.Pointer co_linetable; - - external ffi.Pointer co_zombieframe; - - external ffi.Pointer co_weakreflist; - - external ffi.Pointer co_extra; - - external ffi.Pointer co_opcache_map; - - external ffi.Pointer<_PyOpcache> co_opcache; - - @ffi.Int() - external int co_opcache_flag; - - @ffi.UnsignedChar() - external int co_opcache_size; -} - -final class _PyOpcache extends ffi.Opaque {} - -final class _opaque extends ffi.Struct { - @ffi.Int() - external int computed_line; - - external ffi.Pointer lo_next; - - external ffi.Pointer limit; -} - -final class _line_offsets extends ffi.Struct { - @ffi.Int() - external int ar_start; - - @ffi.Int() - external int ar_end; - - @ffi.Int() - external int ar_line; - - external _opaque opaque; +abstract class _PyCodeLocationInfoKind { + static const int PY_CODE_LOCATION_INFO_SHORT0 = 0; + static const int PY_CODE_LOCATION_INFO_ONE_LINE0 = 10; + static const int PY_CODE_LOCATION_INFO_ONE_LINE1 = 11; + static const int PY_CODE_LOCATION_INFO_ONE_LINE2 = 12; + static const int PY_CODE_LOCATION_INFO_NO_COLUMNS = 13; + static const int PY_CODE_LOCATION_INFO_LONG = 14; + static const int PY_CODE_LOCATION_INFO_NONE = 15; } -typedef PyCodeAddressRange = _line_offsets; - final class _traceback extends ffi.Struct { external PyObject ob_base; - external ffi.Pointer<_traceback> tb_next; + external ffi.Pointer tb_next; external ffi.Pointer tb_frame; @@ -24470,6 +23774,8 @@ final class _traceback extends ffi.Struct { external int tb_lineno; } +typedef PyTracebackObject = _traceback; + final class PySliceObject extends ffi.Struct { external PyObject ob_base; @@ -24568,12 +23874,17 @@ final class PyConfig extends ffi.Struct { @ffi.Int() external int import_time; + @ffi.Int() + external int code_debug_ranges; + @ffi.Int() external int show_ref_count; @ffi.Int() external int dump_refs; + external ffi.Pointer dump_refs_file; + @ffi.Int() external int malloc_stats; @@ -24639,6 +23950,12 @@ final class PyConfig extends ffi.Struct { external ffi.Pointer check_hash_pycs_mode; + @ffi.Int() + external int use_frozen_modules; + + @ffi.Int() + external int safe_path; + @ffi.Int() external int pathconfig_warnings; @@ -24655,6 +23972,8 @@ final class PyConfig extends ffi.Struct { external PyWideStringList module_search_paths; + external ffi.Pointer stdlib_dir; + external ffi.Pointer executable; external ffi.Pointer base_executable; @@ -24684,9 +24003,10 @@ final class PyConfig extends ffi.Struct { @ffi.Int() external int _isolated_interpreter; -} -typedef PyThreadState = _ts; + @ffi.Int() + external int _is_python_build; +} abstract class PyGILState_STATE { static const int PyGILState_LOCKED = 0; @@ -24695,8 +24015,8 @@ abstract class PyGILState_STATE { typedef _PyFrameEvalFunction = ffi.Pointer< ffi.NativeFunction< - ffi.Pointer Function( - ffi.Pointer, ffi.Pointer, ffi.Int)>>; + ffi.Pointer Function(ffi.Pointer, + ffi.Pointer<_PyInterpreterFrame>, ffi.Int)>>; final class _xid extends ffi.Struct { external ffi.Pointer data; @@ -24707,41 +24027,56 @@ final class _xid extends ffi.Struct { external int interp; external ffi.Pointer< - ffi.NativeFunction Function(ffi.Pointer<_xid>)>> - new_object; + ffi.NativeFunction< + ffi.Pointer Function( + ffi.Pointer<_PyCrossInterpreterData>)>> new_object; external ffi - .Pointer)>> + .Pointer)>> free; } typedef _PyCrossInterpreterData = _xid; typedef crossinterpdatafunc = ffi.Pointer< ffi.NativeFunction< - ffi.Int Function(ffi.Pointer, ffi.Pointer<_xid>)>>; + ffi.Int Function( + ffi.Pointer, ffi.Pointer<_PyCrossInterpreterData>)>>; final class PyGenObject extends ffi.Struct { external PyObject ob_base; - external ffi.Pointer gi_frame; - - external ffi.Pointer gi_code; + external ffi.Pointer gi_code; external ffi.Pointer gi_weakreflist; external ffi.Pointer gi_name; - external ffi.Pointer gi_qualname; + external ffi.Pointer gi_qualname; + + external _PyErr_StackItem gi_exc_state; + + external ffi.Pointer gi_origin_or_finalizer; + + @ffi.Char() + external int gi_hooks_inited; + + @ffi.Char() + external int gi_closed; + + @ffi.Char() + external int gi_running_async; + + @ffi.Int8() + external int gi_frame_state; - external _PyErr_StackItem gi_exc_state; + @ffi.Array.multi([1]) + external ffi.Array> gi_iframe; } final class PyCoroObject extends ffi.Struct { external PyObject ob_base; - external ffi.Pointer cr_frame; - - external ffi.Pointer cr_code; + external ffi.Pointer cr_code; external ffi.Pointer cr_weakreflist; @@ -24751,15 +24086,28 @@ final class PyCoroObject extends ffi.Struct { external _PyErr_StackItem cr_exc_state; - external ffi.Pointer cr_origin; + external ffi.Pointer cr_origin_or_finalizer; + + @ffi.Char() + external int cr_hooks_inited; + + @ffi.Char() + external int cr_closed; + + @ffi.Char() + external int cr_running_async; + + @ffi.Int8() + external int cr_frame_state; + + @ffi.Array.multi([1]) + external ffi.Array> cr_iframe; } final class PyAsyncGenObject extends ffi.Struct { external PyObject ob_base; - external ffi.Pointer ag_frame; - - external ffi.Pointer ag_code; + external ffi.Pointer ag_code; external ffi.Pointer ag_weakreflist; @@ -24769,16 +24117,22 @@ final class PyAsyncGenObject extends ffi.Struct { external _PyErr_StackItem ag_exc_state; - external ffi.Pointer ag_finalizer; + external ffi.Pointer ag_origin_or_finalizer; - @ffi.Int() + @ffi.Char() external int ag_hooks_inited; - @ffi.Int() + @ffi.Char() external int ag_closed; - @ffi.Int() + @ffi.Char() external int ag_running_async; + + @ffi.Int8() + external int ag_frame_state; + + @ffi.Array.multi([1]) + external ffi.Array> ag_iframe; } final class wrapperbase extends ffi.Struct { @@ -24855,6 +24209,8 @@ final class _PyWeakReference extends ffi.Struct { external ffi.Pointer wr_prev; external ffi.Pointer wr_next; + + external vectorcallfunc vectorcall; } typedef PyWeakReference = _PyWeakReference; @@ -24961,6 +24317,27 @@ final class PyBaseExceptionObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + + external ffi.Pointer traceback; + + external ffi.Pointer context; + + external ffi.Pointer cause; + + @ffi.Char() + external int suppress_context; +} + +final class PyBaseExceptionGroupObject extends ffi.Struct { + external PyObject ob_base; + + external ffi.Pointer dict; + + external ffi.Pointer args; + + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -24969,6 +24346,10 @@ final class PyBaseExceptionObject extends ffi.Struct { @ffi.Char() external int suppress_context; + + external ffi.Pointer msg; + + external ffi.Pointer excs; } final class PySyntaxErrorObject extends ffi.Struct { @@ -24978,6 +24359,8 @@ final class PySyntaxErrorObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25011,6 +24394,8 @@ final class PyImportErrorObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25034,6 +24419,8 @@ final class PyUnicodeErrorObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25063,6 +24450,8 @@ final class PySystemExitObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25082,6 +24471,8 @@ final class PyOSErrorObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25110,6 +24501,8 @@ final class PyStopIterationObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25129,6 +24522,8 @@ final class PyNameErrorObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25148,6 +24543,8 @@ final class PyAttributeErrorObject extends ffi.Struct { external ffi.Pointer args; + external ffi.Pointer notes; + external ffi.Pointer traceback; external ffi.Pointer context; @@ -25248,91 +24645,14 @@ final class _frozen extends ffi.Struct { @ffi.Int() external int size; -} - -abstract class _Py_error_handler { - static const int _Py_ERROR_UNKNOWN = 0; - static const int _Py_ERROR_STRICT = 1; - static const int _Py_ERROR_SURROGATEESCAPE = 2; - static const int _Py_ERROR_REPLACE = 3; - static const int _Py_ERROR_IGNORE = 4; - static const int _Py_ERROR_BACKSLASHREPLACE = 5; - static const int _Py_ERROR_SURROGATEPASS = 6; - static const int _Py_ERROR_XMLCHARREFREPLACE = 7; - static const int _Py_ERROR_OTHER = 8; -} - -final class stat extends ffi.Struct { - @dev_t() - external int st_dev; - - @mode_t() - external int st_mode; - - @nlink_t() - external int st_nlink; - - @__darwin_ino64_t() - external int st_ino; - - @uid_t() - external int st_uid; - - @gid_t() - external int st_gid; - - @dev_t() - external int st_rdev; - external timespec st_atimespec; - - external timespec st_mtimespec; - - external timespec st_ctimespec; - - external timespec st_birthtimespec; - - @off_t() - external int st_size; - - @blkcnt_t() - external int st_blocks; - - @blksize_t() - external int st_blksize; - - @__uint32_t() - external int st_flags; - - @__uint32_t() - external int st_gen; - - @__int32_t() - external int st_lspare; + @ffi.Int() + external int is_package; - @ffi.Array.multi([2]) - external ffi.Array<__int64_t> st_qspare; + external ffi.Pointer Function()>> + get_code; } -typedef dev_t = __darwin_dev_t; -typedef __darwin_dev_t = __int32_t; -typedef mode_t = __darwin_mode_t; -typedef __darwin_mode_t = __uint16_t; -typedef __uint16_t = ffi.UnsignedShort; -typedef nlink_t = __uint16_t; -typedef __darwin_ino64_t = __uint64_t; -typedef __uint64_t = ffi.UnsignedLongLong; -typedef uid_t = __darwin_uid_t; -typedef __darwin_uid_t = __uint32_t; -typedef __uint32_t = ffi.UnsignedInt; -typedef gid_t = __darwin_gid_t; -typedef __darwin_gid_t = __uint32_t; -typedef off_t = __darwin_off_t; -typedef blkcnt_t = __darwin_blkcnt_t; -typedef __darwin_blkcnt_t = __int64_t; -typedef blksize_t = __darwin_blksize_t; -typedef __darwin_blksize_t = __int32_t; - const int _PyStatus_TYPE_OK = 0; const int _PyStatus_TYPE_ERROR = 1; @@ -25349,17 +24669,17 @@ const int PY_RELEASE_LEVEL_FINAL = 15; const int PY_MAJOR_VERSION = 3; -const int PY_MINOR_VERSION = 10; +const int PY_MINOR_VERSION = 11; -const int PY_MICRO_VERSION = 10; +const int PY_MICRO_VERSION = 6; const int PY_RELEASE_LEVEL = 15; const int PY_RELEASE_SERIAL = 0; -const String PY_VERSION = '3.10.10'; +const String PY_VERSION = '3.11.6'; -const int PY_VERSION_HEX = 50989808; +const int PY_VERSION_HEX = 51054320; const int ALIGNOF_LONG = 8; @@ -25367,6 +24687,8 @@ const int ALIGNOF_SIZE_T = 8; const int ENABLE_IPV6 = 1; +const int HAVE_ACCEPT = 1; + const int HAVE_ACOSH = 1; const int HAVE_ADDRINFO = 1; @@ -25379,14 +24701,18 @@ const int HAVE_ASINH = 1; const int HAVE_ATANH = 1; -const int HAVE_BIND_TEXTDOMAIN_CODESET = 1; +const int HAVE_BIND = 1; const int HAVE_BROKEN_SEM_GETVALUE = 1; const int HAVE_BUILTIN_ATOMIC = 1; +const int HAVE_BZLIB_H = 1; + const int HAVE_CHFLAGS = 1; +const int HAVE_CHMOD = 1; + const int HAVE_CHOWN = 1; const int HAVE_CHROOT = 1; @@ -25403,7 +24729,7 @@ const int HAVE_COMPUTED_GOTOS = 1; const int HAVE_CONFSTR = 1; -const int HAVE_COPYSIGN = 1; +const int HAVE_CONNECT = 1; const int HAVE_CTERMID = 1; @@ -25431,11 +24757,7 @@ const int HAVE_CURSES_USE_ENV = 1; const int HAVE_CURSES_WCHGAT = 1; -const int HAVE_DECL_ISFINITE = 1; - -const int HAVE_DECL_ISINF = 1; - -const int HAVE_DECL_ISNAN = 1; +const int HAVE_DB_H = 1; const int HAVE_DECL_RTLD_DEEPBIND = 0; @@ -25467,6 +24789,8 @@ const int HAVE_DLFCN_H = 1; const int HAVE_DLOPEN = 1; +const int HAVE_DUP = 1; + const int HAVE_DUP2 = 1; const int HAVE_DYLD_SHARED_CACHE_CONTAINS_PATH = 1; @@ -25533,8 +24857,16 @@ const int HAVE_GETADDRINFO = 1; const int HAVE_GETC_UNLOCKED = 1; +const int HAVE_GETEGID = 1; + const int HAVE_GETENTROPY = 1; +const int HAVE_GETEUID = 1; + +const int HAVE_GETGID = 1; + +const int HAVE_GETGRGID = 1; + const int HAVE_GETGRGID_R = 1; const int HAVE_GETGRNAM_R = 1; @@ -25543,8 +24875,12 @@ const int HAVE_GETGROUPLIST = 1; const int HAVE_GETGROUPS = 1; +const int HAVE_GETHOSTBYADDR = 1; + const int HAVE_GETHOSTBYNAME = 1; +const int HAVE_GETHOSTNAME = 1; + const int HAVE_GETITIMER = 1; const int HAVE_GETLOADAVG = 1; @@ -25563,28 +24899,44 @@ const int HAVE_GETPGRP = 1; const int HAVE_GETPID = 1; +const int HAVE_GETPPID = 1; + const int HAVE_GETPRIORITY = 1; +const int HAVE_GETPROTOBYNAME = 1; + const int HAVE_GETPWENT = 1; const int HAVE_GETPWNAM_R = 1; +const int HAVE_GETPWUID = 1; + const int HAVE_GETPWUID_R = 1; +const int HAVE_GETRUSAGE = 1; + +const int HAVE_GETSERVBYNAME = 1; + +const int HAVE_GETSERVBYPORT = 1; + const int HAVE_GETSID = 1; +const int HAVE_GETSOCKNAME = 1; + +const int HAVE_GETUID = 1; + const int HAVE_GETWD = 1; const int HAVE_GRP_H = 1; const int HAVE_HSTRERROR = 1; -const int HAVE_HYPOT = 1; - const int HAVE_IF_NAMEINDEX = 1; const int HAVE_INET_ATON = 1; +const int HAVE_INET_NTOA = 1; + const int HAVE_INET_PTON = 1; const int HAVE_INITGROUPS = 1; @@ -25605,38 +24957,40 @@ const int HAVE_LCHMOD = 1; const int HAVE_LCHOWN = 1; -const int HAVE_LGAMMA = 1; - const int HAVE_LIBDL = 1; -const int HAVE_LIBINTL_H = 1; - const int HAVE_LIBREADLINE = 1; +const int HAVE_LIBSQLITE3 = 1; + const int HAVE_LINK = 1; const int HAVE_LINKAT = 1; +const int HAVE_LISTEN = 1; + const int HAVE_LOCKF = 1; const int HAVE_LOG1P = 1; const int HAVE_LOG2 = 1; +const int HAVE_LOGIN_TTY = 1; + const int HAVE_LONG_DOUBLE = 1; const int HAVE_LSTAT = 1; const int HAVE_LUTIMES = 1; +const int HAVE_LZMA_H = 1; + const int HAVE_MADVISE = 1; const int HAVE_MAKEDEV = 1; const int HAVE_MBRTOWC = 1; -const int HAVE_MEMORY_H = 1; - const int HAVE_MKDIRAT = 1; const int HAVE_MKFIFO = 1; @@ -25651,20 +25005,32 @@ const int HAVE_MKTIME = 1; const int HAVE_MMAP = 1; +const int HAVE_NANOSLEEP = 1; + const int HAVE_NCURSES_H = 1; +const int HAVE_NDBM_H = 1; + +const int HAVE_NETDB_H = 1; + +const int HAVE_NETINET_IN_H = 1; + const int HAVE_NET_IF_H = 1; const int HAVE_NICE = 1; const int HAVE_OPENAT = 1; +const int HAVE_OPENDIR = 1; + const int HAVE_OPENPTY = 1; const int HAVE_PATHCONF = 1; const int HAVE_PAUSE = 1; +const int HAVE_PIPE = 1; + const int HAVE_POLL = 1; const int HAVE_POLL_H = 1; @@ -25697,11 +25063,9 @@ const int HAVE_READV = 1; const int HAVE_REALPATH = 1; -const int HAVE_RENAMEAT = 1; - -const int HAVE_RL_APPEND_HISTORY = 1; +const int HAVE_RECVFROM = 1; -const int HAVE_RL_CATCH_SIGNAL = 1; +const int HAVE_RENAMEAT = 1; const int HAVE_RL_COMPLETION_APPEND_CHARACTER = 1; @@ -25709,13 +25073,9 @@ const int HAVE_RL_COMPLETION_DISPLAY_MATCHES_HOOK = 1; const int HAVE_RL_COMPLETION_MATCHES = 1; -const int HAVE_RL_COMPLETION_SUPPRESS_APPEND = 1; - const int HAVE_RL_PRE_INPUT_HOOK = 1; -const int HAVE_RL_RESIZE_TERMINAL = 1; - -const int HAVE_ROUND = 1; +const int HAVE_RPC_RPC_H = 1; const int HAVE_SCHED_GET_PRIORITY_MAX = 1; @@ -25729,6 +25089,8 @@ const int HAVE_SEM_UNLINK = 1; const int HAVE_SENDFILE = 1; +const int HAVE_SENDTO = 1; + const int HAVE_SETEGID = 1; const int HAVE_SETEUID = 1; @@ -25741,6 +25103,8 @@ const int HAVE_SETHOSTNAME = 1; const int HAVE_SETITIMER = 1; +const int HAVE_SETJMP_H = 1; + const int HAVE_SETLOCALE = 1; const int HAVE_SETPGID = 1; @@ -25755,6 +25119,8 @@ const int HAVE_SETREUID = 1; const int HAVE_SETSID = 1; +const int HAVE_SETSOCKOPT = 1; + const int HAVE_SETUID = 1; const int HAVE_SETVBUF = 1; @@ -25763,6 +25129,8 @@ const int HAVE_SHM_OPEN = 1; const int HAVE_SHM_UNLINK = 1; +const int HAVE_SHUTDOWN = 1; + const int HAVE_SIGACTION = 1; const int HAVE_SIGALTSTACK = 1; @@ -25787,6 +25155,8 @@ const int HAVE_SOCKADDR_SA_LEN = 1; const int HAVE_SOCKADDR_STORAGE = 1; +const int HAVE_SOCKET = 1; + const int HAVE_SOCKETPAIR = 1; const int HAVE_SPAWN_H = 1; @@ -25843,6 +25213,10 @@ const int HAVE_SYSCONF = 1; const int HAVE_SYSEXITS_H = 1; +const int HAVE_SYSLOG_H = 1; + +const int HAVE_SYSTEM = 1; + const int HAVE_SYS_EVENT_H = 1; const int HAVE_SYS_FILE_H = 1; @@ -25901,8 +25275,6 @@ const int HAVE_TERMIOS_H = 1; const int HAVE_TERM_H = 1; -const int HAVE_TGAMMA = 1; - const int HAVE_TIMEGM = 1; const int HAVE_TIMES = 1; @@ -25915,6 +25287,10 @@ const int HAVE_TM_ZONE = 1; const int HAVE_TRUNCATE = 1; +const int HAVE_TTYNAME = 1; + +const int HAVE_UMASK = 1; + const int HAVE_UNAME = 1; const int HAVE_UNISTD_H = 1; @@ -25929,10 +25305,18 @@ const int HAVE_UTIMES = 1; const int HAVE_UTIME_H = 1; +const int HAVE_UTMP_H = 1; + +const int HAVE_UUID_GENERATE_TIME_SAFE = 1; + +const int HAVE_UUID_H = 1; + const int HAVE_UUID_UUID_H = 1; const int HAVE_VFORK = 1; +const int HAVE_WAIT = 1; + const int HAVE_WAIT3 = 1; const int HAVE_WAIT4 = 1; @@ -25957,6 +25341,8 @@ const int HAVE_WRITEV = 1; const int HAVE_ZLIB_COPY = 1; +const int HAVE_ZLIB_H = 1; + const int MVWDELCH_IS_EXPRESSION = 1; const int PTHREAD_SYSTEM_SCHED_SUPPORTED = 1; @@ -25967,8 +25353,12 @@ const int PY_COERCE_C_LOCALE = 1; const String PY_FORMAT_SIZE_T = 'z'; +const int PY_SQLITE_HAVE_SERIALIZE = 1; + const int PY_SSL_DEFAULT_CIPHERS = 1; +const int PY_SUPPORT_TIER = 2; + const int Py_ENABLE_SHARED = 1; const int SIZEOF_DOUBLE = 8; @@ -26033,7 +25423,7 @@ const int WITH_DOC_STRINGS = 1; const int WITH_DYLD = 1; -const int WITH_LIBINTL = 1; +const int WITH_FREELISTS = 1; const int WITH_PYMALLOC = 1; @@ -26061,16 +25451,16 @@ const int PY_ULLONG_MAX = -1; const int PYLONG_BITS_IN_DIGIT = 30; +const int PY_SSIZE_T_MAX = 9223372036854775807; + +const int PY_SSIZE_T_MIN = -9223372036854775808; + const int SIZEOF_PY_HASH_T = 8; const int SIZEOF_PY_UHASH_T = 8; const int PY_SIZE_MAX = -1; -const int PY_SSIZE_T_MAX = 9223372036854775807; - -const int PY_SSIZE_T_MIN = -9223372036854775808; - const int PY_BIG_ENDIAN = 0; const int PY_LITTLE_ENDIAN = 1; @@ -26091,10 +25481,54 @@ const double Py_HUGE_VAL = double.infinity; const double Py_NAN = double.nan; +const int PyBUF_MAX_NDIM = 64; + +const int PyBUF_SIMPLE = 0; + +const int PyBUF_WRITABLE = 1; + +const int PyBUF_WRITEABLE = 1; + +const int PyBUF_FORMAT = 4; + +const int PyBUF_ND = 8; + +const int PyBUF_STRIDES = 24; + +const int PyBUF_C_CONTIGUOUS = 56; + +const int PyBUF_F_CONTIGUOUS = 88; + +const int PyBUF_ANY_CONTIGUOUS = 152; + +const int PyBUF_INDIRECT = 280; + +const int PyBUF_CONTIG = 9; + +const int PyBUF_CONTIG_RO = 8; + +const int PyBUF_STRIDED = 25; + +const int PyBUF_STRIDED_RO = 24; + +const int PyBUF_RECORDS = 29; + +const int PyBUF_RECORDS_RO = 28; + +const int PyBUF_FULL = 285; + +const int PyBUF_FULL_RO = 284; + +const int PyBUF_READ = 256; + +const int PyBUF_WRITE = 512; + const int Py_INVALID_SIZE = -1; const int Py_PRINT_RAW = 1; +const int Py_TPFLAGS_MANAGED_DICT = 16; + const int Py_TPFLAGS_SEQUENCE = 32; const int Py_TPFLAGS_MAPPING = 64; @@ -26161,50 +25595,6 @@ const int Py_GT = 4; const int Py_GE = 5; -const int PyBUF_MAX_NDIM = 64; - -const int PyBUF_SIMPLE = 0; - -const int PyBUF_WRITABLE = 1; - -const int PyBUF_WRITEABLE = 1; - -const int PyBUF_FORMAT = 4; - -const int PyBUF_ND = 8; - -const int PyBUF_STRIDES = 24; - -const int PyBUF_C_CONTIGUOUS = 56; - -const int PyBUF_F_CONTIGUOUS = 88; - -const int PyBUF_ANY_CONTIGUOUS = 152; - -const int PyBUF_INDIRECT = 280; - -const int PyBUF_CONTIG = 9; - -const int PyBUF_CONTIG_RO = 8; - -const int PyBUF_STRIDED = 25; - -const int PyBUF_STRIDED_RO = 24; - -const int PyBUF_RECORDS = 29; - -const int PyBUF_RECORDS_RO = 28; - -const int PyBUF_FULL = 285; - -const int PyBUF_FULL_RO = 284; - -const int PyBUF_READ = 256; - -const int PyBUF_WRITE = 512; - -const int PyTrash_UNWIND_LEVEL = 50; - const int Py_bf_getbuffer = 1; const int Py_bf_releasebuffer = 2; @@ -26385,7 +25775,9 @@ const int Py_HASH_SIPHASH24 = 1; const int Py_HASH_FNV = 2; -const int Py_HASH_ALGORITHM = 1; +const int Py_HASH_SIPHASH13 = 3; + +const int Py_HASH_ALGORITHM = 3; const int Py_UNICODE_SIZE = 4; @@ -26471,8 +25863,6 @@ const int CO_NESTED = 16; const int CO_GENERATOR = 32; -const int CO_NOFREE = 64; - const int CO_COROUTINE = 128; const int CO_ITERABLE_COROUTINE = 256; @@ -26495,8 +25885,6 @@ const int CO_FUTURE_GENERATOR_STOP = 8388608; const int CO_FUTURE_ANNOTATIONS = 16777216; -const int CO_CELL_NOT_AN_ARG = -1; - const int CO_MAXBLOCKS = 20; const int MAX_CO_EXTRA_USERS = 255; @@ -26517,23 +25905,13 @@ const int PyTrace_C_RETURN = 6; const int PyTrace_OPCODE = 7; -const int _PY_FASTCALL_SMALL_STACK = 5; - -const int PY_VECTORCALL_ARGUMENTS_OFFSET = -9223372036854775808; - -const int PY_ITERSEARCH_COUNT = 1; - -const int PY_ITERSEARCH_INDEX = 2; - -const int PY_ITERSEARCH_CONTAINS = 3; - const int PyWrapperFlag_KEYWORDS = 1; const int _PyTime_MIN = -9223372036854775808; const int _PyTime_MAX = 9223372036854775807; -const int PYTHREAD_INVALID_THREAD_ID = -1; +const int _SIZEOF_PYTIME_T = 8; const int WAIT_LOCK = 1; @@ -26541,6 +25919,8 @@ const int NOWAIT_LOCK = 0; const int PY_TIMEOUT_MAX = 9223372036854775; +const int PYTHREAD_INVALID_THREAD_ID = -1; + const int Py_CLEANUP_SUPPORTED = 131072; const int PYTHON_API_VERSION = 1013; @@ -26619,6 +25999,16 @@ const int FVS_MASK = 4; const int FVS_HAVE_SPEC = 4; +const int _PY_FASTCALL_SMALL_STACK = 5; + +const int PY_VECTORCALL_ARGUMENTS_OFFSET = -9223372036854775808; + +const int PY_ITERSEARCH_COUNT = 1; + +const int PY_ITERSEARCH_INDEX = 2; + +const int PY_ITERSEARCH_CONTAINS = 3; + const int PY_CTF_LOWER = 1; const int PY_CTF_UPPER = 2; @@ -26639,12 +26029,10 @@ const int Py_DTSF_ADD_DOT_0 = 2; const int Py_DTSF_ALT = 4; +const int Py_DTSF_NO_NEG_0 = 8; + const int Py_DTST_FINITE = 0; const int Py_DTST_INFINITE = 1; const int Py_DTST_NAN = 2; - -const int _PY_READ_MAX = 2147483647; - -const int _PY_WRITE_MAX = 2147483647; diff --git a/src/serious_python_platform_interface/lib/src/utils.dart b/src/serious_python_platform_interface/lib/src/utils.dart index 51c4d7d7..4e758a2e 100644 --- a/src/serious_python_platform_interface/lib/src/utils.dart +++ b/src/serious_python_platform_interface/lib/src/utils.dart @@ -82,14 +82,15 @@ Future extractAsset(String assetPath) async { : await getTemporaryDirectory(); // (re-)create destination directory - await Directory(p.join( - documentsOrTempDir.path, - "${packageInfo.appName}-${packageInfo.version}-${packageInfo.buildNumber}", - p.dirname(assetPath))) - .create(recursive: true); + var destDir = Directory(p.join( + documentsOrTempDir.path, + "${packageInfo.appName}-${packageInfo.version}-${packageInfo.buildNumber}", + p.dirname(assetPath))); + + await destDir.create(recursive: true); // extract file from assets - var destPath = p.join(documentsOrTempDir.path, assetPath); + var destPath = p.join(destDir.path, p.basename(assetPath)); if (kDebugMode && await File(destPath).exists()) { await File(destPath).delete(); } diff --git a/src/serious_python_platform_interface/pubspec.yaml b/src/serious_python_platform_interface/pubspec.yaml index 07ab1b22..2cc696ed 100644 --- a/src/serious_python_platform_interface/pubspec.yaml +++ b/src/serious_python_platform_interface/pubspec.yaml @@ -2,7 +2,7 @@ name: serious_python_platform_interface description: A common platform interface for the serious_python plugin. homepage: https://flet.dev repository: https://github.com/flet-dev/serious-python -version: 0.4.1 +version: 0.5.0 environment: sdk: ">=3.0.0 <4.0.0" diff --git a/src/serious_python_platform_interface/python_ffigen.yaml b/src/serious_python_platform_interface/python_ffigen.yaml index 1ff95bbb..5bbde3b0 100644 --- a/src/serious_python_platform_interface/python_ffigen.yaml +++ b/src/serious_python_platform_interface/python_ffigen.yaml @@ -1,6 +1,6 @@ # Run with `dart run ffigen --config python_ffigen.yaml`. -output: "lib/src/android/gen.dart" +output: "lib/src/gen.dart" # enums: # rename: # "_(.*)": "$1" @@ -14,11 +14,11 @@ globals: "^class (\\w+) extends ffi.Union": "final class $1 extends ffi.Union" headers: entry-points: - - "/Users/feodor/.pyenv/versions/3.10.10/include/python3.10/Python.h" + - "/Users/feodor/Downloads/python/include/python3.11/Python.h" include-directives: - - "/Users/feodor/.pyenv/versions/3.10.10/include/python3.10/*" - - "/Users/feodor/.pyenv/versions/3.10.10/include/python3.10/internal/*" - - "/Users/feodor/.pyenv/versions/3.10.10/include/python3.10/cpython/*" + - "/Users/feodor/Downloads/python/include/python3.11/*" + - "/Users/feodor/Downloads/python/include/python3.11/internal/*" + - "/Users/feodor/Downloads/python/include/python3.11/cpython/*" name: "CPython" llvm-path: - /opt/homebrew/opt/llvm diff --git a/src/serious_python_windows/CHANGELOG.md b/src/serious_python_windows/CHANGELOG.md index ca914f77..99fe31d2 100644 --- a/src/serious_python_windows/CHANGELOG.md +++ b/src/serious_python_windows/CHANGELOG.md @@ -1,3 +1,7 @@ +## 0.5.0 + +* Python 3.11.6. + ## 0.4.1 * Bumping version after fixing pubspec.yaml. diff --git a/src/serious_python_windows/pubspec.yaml b/src/serious_python_windows/pubspec.yaml index f76a1b59..6a762524 100644 --- a/src/serious_python_windows/pubspec.yaml +++ b/src/serious_python_windows/pubspec.yaml @@ -2,7 +2,7 @@ name: serious_python_windows description: Windows implementations of the serious_python plugin homepage: https://flet.dev repository: https://github.com/flet-dev/serious-python -version: 0.4.1 +version: 0.5.0 environment: sdk: '>=3.1.3 <4.0.0' diff --git a/src/serious_python_windows/windows/CMakeLists.txt b/src/serious_python_windows/windows/CMakeLists.txt index ddc362de..5ae06a0c 100644 --- a/src/serious_python_windows/windows/CMakeLists.txt +++ b/src/serious_python_windows/windows/CMakeLists.txt @@ -17,8 +17,8 @@ cmake_policy(VERSION 3.14...3.25) set(PLUGIN_NAME "serious_python_windows_plugin") set(PYTHON_PACKAGE ${CMAKE_BINARY_DIR}/python) -set(PYTHON_URL https://github.com/flet-dev/serious-python/releases/download/v0.1.0/Python310.zip) -set(PYTHON_FILE ${CMAKE_BINARY_DIR}/Python310.zip) +set(PYTHON_URL https://github.com/flet-dev/serious-python/releases/download/v0.1.0/python3116.zip) +set(PYTHON_FILE ${CMAKE_BINARY_DIR}/python3116.zip) if (NOT EXISTS ${PYTHON_FILE}) file(DOWNLOAD ${PYTHON_URL} ${PYTHON_FILE}) file(ARCHIVE_EXTRACT INPUT ${PYTHON_FILE} DESTINATION ${PYTHON_PACKAGE}) @@ -62,14 +62,14 @@ include_directories( target_link_libraries(${PLUGIN_NAME} PRIVATE flutter flutter_wrapper_plugin) target_link_libraries(${PLUGIN_NAME} PRIVATE - "${PYTHON_PACKAGE}/libs/python310$<$:_d>.lib" + "${PYTHON_PACKAGE}/libs/python311$<$:_d>.lib" ) # List of absolute paths to libraries that should be bundled with the plugin. # This list could contain prebuilt libraries, or libraries created by an # external build triggered from this build file. set(serious_python_windows_bundled_libraries - "${PYTHON_PACKAGE}/python310$<$:_d>.dll" + "${PYTHON_PACKAGE}/python311$<$:_d>.dll" "${PYTHON_PACKAGE}/python3$<$:_d>.dll" "$ENV{WINDIR}/system32/msvcp140.dll" "$ENV{WINDIR}/system32/vcruntime140.dll"