Results of 1 - 10 of about 50 for Interpreter (0.004 sec.)
- インタープリタの初期化と終了処理 12934
- インタープリタの初期化と終了処理 初期化前にインタープリタを設定する方法の詳細は、 Python の初期化設定 を参照してください。 Python の初期化前 Python を組み込むアプリケーションでは、一部の関数と グローバルな設定変数 を除き、ほかの Python/C AP
...に、最後に Py_Initialize() を呼び出してから作成され、まだ破棄されていないサブインタープリタをすべて破棄します (以下の Py_NewInterpreter() を参照)。 再び Py_Initialize() を呼び出さずにもう一度呼び出しても、何も行いません。 Py_Initialize() の逆の処理なので、同...s. Dynamically loaded extension modules loaded by Python are not unloaded. Small amounts of memory allocated by the Python interpreter may not be freed (if you find a leak, please report it). Memory tied up in circular references between objects is not free...not be called recursively from within itself. Therefore, it must not be called by any code that may be run as part of the interpreter shutdown process, such as atexit handlers, object finalizers, or any code that may be run while flushing the stdout and st... - https://man.mtool.work/python/3.14/c-api/interp-lifecycle.html
- zipapp --- 実行可能な Python zip アーカイブを管理する 12934
- zipapp --- 実行可能な Python zip アーカイブを管理する Added in version 3.5. ソースコード: Lib/zipapp.py このモジュールは Python コードを含む zip ファイルの作成を行うツールを提供します。 zip ファイルは Python インタープリタで直接実行すること
...名を必ず指定しなければなりません。 ( source がアーカイブである場合は output を必ず source とは別の名前にしてください。) -p <interpreter> , --python =<interpreter> 実行コマンドとしての interpreter を指定する #! 行を書庫に追加します。 また、POSIX では書庫を実行...て終了します。 Python API このモジュールは 2 つの簡便関数を定義しています: zipapp. create_archive ( source , target = None , interpreter = None , main = None , filter = None , compressed = False ) source からアプリケーション書庫を作成します。 ソースは以下のい...ーカイブを作成します。 既存のアプリケーションアーカイブのファイル名、またはそのファイルを指す path-like object 。 この場合、 interpreter 引数の値を反映するよう変更して、ファイルを出力先へコピーします。 必要に応じて、ファイル名には .pyz 拡張子を含めてください。... - https://man.mtool.work/python/3.14/library/zipapp.html
- concurrent.interpreters --- 同じプロセス内の複数のインタープリタ 10633
- concurrent.interpreters --- 同じプロセス内の複数のインタープリタ Added in version 3.14. ソースコード: Lib/concurrent/interpreters concurrent.interpreters モジュールは、低水準の _interpreters モジュールの上に、より高水準のインターフェースを構
...り、それだけでは役に立ちません。 実際の並行処理は、別途 スレッド によって利用できます。 後述の説明 を参照してください。 参考 InterpreterPoolExecutor 使い慣れたインターフェースで、スレッドとインタープリタを組み合わせます。 拡張モジュールを分離する 複数のインタ...リタの状態に加え、現在の例外やバイトコードの評価ループに関する実行時の状態があります)。 The concept and functionality of the interpreter have been a part of Python since version 2.2, but the feature was only available through the C-API and not well known, and...ープリタに切り替えてから、関数を呼び出します。 ランタイムは、現在のインタープリタの状態を使って関数を実行します。 concurrent.interpreters モジュールは、インタープリタを作成・管理する基本的な API と、この切り替えと呼び出しの操作を提供します。 この操作で、他のス... - https://man.mtool.work/python/3.14/library/concurrent.interpreters.html
- スレッド状態とグローバルインタープリタロック 10106
- スレッド状態とグローバルインタープリタロック CPython の フリースレッドビルド を除き、Python インタープリタは一般にスレッドセーフではありません。 マルチスレッドの Python プログラムをサポートするため、 グローバルインタープリタロック 、または
...PyThreadState_New() followed by PyThreadState_Swap() . 注釈 PyThreadState_New requires an argument pointing to the desired interpreter; such a pointer can be acquired via a call to PyInterpreterState_Get() from the code where the thread was created. 例えば:.../* The return value of PyInterpreterState_Get() from the function that created this thread. */ PyInterpreterState * interp = thread_data -> interp ; /* Create...a new thread state for the interpreter. It does not start out attached. */ PyThreadState * tstate = PyThreadState_New ( interp ); /* Attach the thread state, whi... - https://man.mtool.work/python/3.14/c-api/threads.html
- Python インタプリタの拡張と埋め込み 9745
- Python インタプリタの拡張と埋め込み This document describes how to write modules in C or C++ to extend the Python interpreter with new modules. Those modules can not only define new functions but also new object types and their methods. The
...document also describes how to embed the Python interpreter in another application, for use as an extension language. Finally, it shows how to compile and link extension modules so t...hat they can be loaded dynamically (at run time) into the interpreter, if the underlying operating system supports this feature. このドキュメントは、C と Python の基礎知識を前提としています。... - https://man.mtool.work/python/3.14/extending/
- 1. Extending Python with C or C++ 9399
- 1. Extending Python with C or C++ It is quite easy to add new built-in modules to Python, if you know how to program in C. Such extension modules can do two things that can't be done directly in Python: they can implement new built-in objec
...mediately (as we saw in the example). 1.2. Intermezzo: Errors and Exceptions An important convention throughout the Python interpreter is the following: when a function fails, it should set an exception condition and return an error value (usually -1 or a N...ULL pointer). Exception information is stored in three members of the interpreter's thread state. These are NULL if there is no exception. Otherwise they are the C equivalents of the members of the Python...nd." }, ... { NULL , NULL , 0 , NULL } /* Sentinel */ }; Note the third entry ( METH_VARARGS ). This is a flag telling the interpreter the calling convention to be used for the C function. It should normally always be METH_VARARGS or METH_VARARGS | METH_KEY... - https://man.mtool.work/python/3.14/extending/extending.html
- 5. macOS で Python を使う 9038
- 5. macOS で Python を使う このドキュメントでは、Mac コンピュータで Python を使い始める際に知っておくべき、macOS 固有の挙動を概説します。 macOS を実行する Mac 上の Python は、ほかの Unix 派生プラットフォーム上の Python と非常によく似ています
...lly install an additional build of Python 3.14 that supports PEP 703 , the free-threading feature (running with the global interpreter lock disabled). Check the release page on python.org for possible updated information. The free-threaded mode is working a...line tools package, which is selected by default, will install links in /usr/local/bin for python3.14t , the free-threaded interpreter, and python3.14t-config , a configuration utility which may be useful for package builders. Since /usr/local/bin is typica...an example, the following shell snippet shows one way to do it, using the 3.14.0b2 release and selecting the free-threaded interpreter option: RELEASE="python-3.14.0b2-macos11.pkg" # download installer pkg curl -O https://www.python.org/ftp/python/3.14.0/${... - https://man.mtool.work/python/3.14/using/mac.html
- cmd --- 行指向のコマンドインタープリターのサポート 8858
- cmd --- 行指向のコマンドインタープリターのサポート ソースコード: Lib/cmd.py Cmd クラスでは、行指向のコマンドインタープリタを書くための簡単なフレームワークを提供します。テストハーネスや管理ツール、そして、後により洗練されたインターフェイスで
...ラップするプロトタイプとして、こうしたインタープリタはよく役に立ちます。 A command interpreter built with Cmd typically presents the user with an interactive prompt, reads input one line at a time, and dispatches each...name. For example, the help command is handled by the do_help() method. Apart from the built-in help command, most of the interpreter's behavior is defined by the do_* methods you add in your own subclass. class cmd. Cmd ( completekey = 'tab' , stdin = Non...tcmd() methods for useful execution hooks. The return value is a flag indicating whether interpretation of commands by the interpreter should stop. If there is a do_*() method for the command line , the return value of that method is returned, otherwise the... - https://man.mtool.work/python/3.14/library/cmd.html
- リモートデバッグのアタッチプロトコル 8331
- リモートデバッグのアタッチプロトコル このプロトコルを使うと、外部ツールから実行中の CPython プロセスにアタッチし、Python コードをリモートで実行できます。 別の Python プロセスへのアタッチには、プラットフォームによって追加の権限や設定が必要な
...ンタープリタと対応するスレッド状態の構造体をメモリ内で探さなければなりません。 関連する内部構造体の定義は次のとおりです。 PyInterpreterState は、隔離された Python インタープリタのインスタンスを表します。 各インタープリタは、インポート済みモジュール、組み込み...、デバッガーが使う制御用フィールドを含みます。 スレッドの位置を特定するには、次の手順を実行します。 オフセット runtime_state.interpreters_head を使い、 PyRuntime 構造体から最初のインタープリタのアドレスを取得します。 ここが、動作中のインタープリタの連結リスト...の先頭です。 オフセット interpreter_state.threads_main を使い、選んだインタープリタに対応するメインスレッドの状態にアクセスします。 通常、最も確実に対象にでき... - https://man.mtool.work/python/3.14/howto/remote_debugging.html
- atexit --- 終了ハンドラー 8331
- atexit --- 終了ハンドラー atexit モジュールは、 終了ハンドラー を登録・解除する関数を定義します。 終了ハンドラーは、プログラムの正常終了時 (例えば sys.exit() が呼び出されたときや、メインモジュールの実行が完了したとき)、より一般的には interpreter
...は、各インタープリタが終了ハンドラーのスタックを持ちます。 ハンドラーは、そのインタープリタが終了するとき (例えば concurrent.interpreters.Interpreter.close() や C API の Py_EndInterpreter() による終了時) に実行されます。 このモジュールの登録用関数が影響するの... - https://man.mtool.work/python/3.14/library/atexit.html