From b683422c57c2ce43e26796b38df2f4fd8419931a Mon Sep 17 00:00:00 2001 From: github-actions Date: Fri, 11 Oct 2024 23:49:17 +0000 Subject: [PATCH] Update translations from Transifex --- c-api/code.po | 115 +-- c-api/exceptions.po | 6 +- c-api/import.po | 37 +- c-api/init.po | 1145 +++++++++++++--------- c-api/init_config.po | 205 ++-- c-api/module.po | 291 +++--- c-api/tuple.po | 44 +- c-api/veryhigh.po | 134 +-- glossary.po | 735 +++++++------- library/_thread.po | 45 +- library/argparse.po | 1539 +++++++++-------------------- library/ast.po | 4 +- library/asyncio-eventloop.po | 16 +- library/asyncio-extending.po | 2 +- library/asyncio-policy.po | 6 +- library/asyncio-stream.po | 6 +- library/asyncio.po | 6 +- library/codecs.po | 6 +- library/compileall.po | 6 +- library/concurrent.futures.po | 6 +- library/configparser.po | 408 ++++---- library/ctypes.po | 44 +- library/curses.po | 4 +- library/datetime.po | 854 ++++++++-------- library/dbm.po | 12 +- library/dis.po | 471 ++++----- library/ensurepip.po | 4 +- library/errno.po | 6 +- library/fcntl.po | 6 +- library/ftplib.po | 6 +- library/functions.po | 644 ++++++------ library/getpass.po | 6 +- library/grp.po | 5 +- library/http.client.po | 6 +- library/http.server.po | 6 +- library/imaplib.po | 6 +- library/importlib.metadata.po | 445 +++++---- library/importlib.po | 612 ++++++------ library/itertools.po | 344 ++++--- library/locale.po | 69 +- library/logging.config.po | 94 +- library/mimetypes.po | 6 +- library/mmap.po | 6 +- library/multiprocessing.po | 4 +- library/os.path.po | 8 +- library/os.po | 284 ++---- library/pkgutil.po | 98 +- library/poplib.po | 6 +- library/posix.po | 6 +- library/pty.po | 8 +- library/pwd.po | 6 +- library/readline.po | 4 +- library/resource.po | 41 +- library/select.po | 12 +- library/selectors.po | 6 +- library/shutil.po | 12 +- library/signal.po | 36 +- library/smtplib.po | 6 +- library/socket.po | 145 +-- library/socketserver.po | 6 +- library/ssl.po | 11 +- library/stat.po | 6 +- library/subprocess.po | 18 +- library/symtable.po | 72 +- library/sys.po | 420 ++++---- library/syslog.po | 6 +- library/termios.po | 6 +- library/threading.po | 27 +- library/time.po | 64 +- library/traceback.po | 371 ++++--- library/tty.po | 8 +- library/types.po | 176 ++-- library/unittest.mock.po | 189 ++-- library/urllib.request.po | 6 +- library/venv.po | 14 +- library/webbrowser.po | 4 +- library/xmlrpc.client.po | 6 +- library/xmlrpc.server.po | 6 +- library/zoneinfo.po | 6 +- reference/datamodel.po | 1739 +++++++++++++++++++-------------- reference/executionmodel.po | 51 +- reference/expressions.po | 212 ++-- reference/import.po | 448 +++------ tutorial/introduction.po | 195 ++-- tutorial/modules.po | 23 +- using/cmdline.po | 13 +- whatsnew/2.6.po | 32 +- whatsnew/3.0.po | 16 +- whatsnew/3.2.po | 8 +- whatsnew/3.4.po | 102 +- whatsnew/3.5.po | 4 +- 91 files changed, 6306 insertions(+), 7059 deletions(-) diff --git a/c-api/code.po b/c-api/code.po index 441072223..80a35e5e1 100644 --- a/c-api/code.po +++ b/c-api/code.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:48+0000\n" "Last-Translator: Taichi Haradaguchi, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -59,123 +59,127 @@ msgid "" msgstr "" #: ../../c-api/code.rst:35 -msgid "Return the number of free variables in a code object." +msgid "" +"Return the number of :term:`free (closure) variables ` in " +"a code object." msgstr "" -#: ../../c-api/code.rst:39 -msgid "Return the position of the first free variable in a code object." +#: ../../c-api/code.rst:40 +msgid "" +"Return the position of the first :term:`free (closure) variable ` in a code object." msgstr "" -#: ../../c-api/code.rst:43 +#: ../../c-api/code.rst:45 msgid "" "Renamed from ``PyCode_GetFirstFree`` as part of :ref:`unstable-c-api`. The " "old name is deprecated, but will remain available until the signature " "changes again." msgstr "" -#: ../../c-api/code.rst:49 +#: ../../c-api/code.rst:51 msgid "" "Return a new code object. If you need a dummy code object to create a " "frame, use :c:func:`PyCode_NewEmpty` instead." msgstr "" -#: ../../c-api/code.rst:52 +#: ../../c-api/code.rst:54 msgid "" "Since the definition of the bytecode changes often, calling :c:func:" "`PyUnstable_Code_New` directly can bind you to a precise Python version." msgstr "" -#: ../../c-api/code.rst:55 +#: ../../c-api/code.rst:57 msgid "" "The many arguments of this function are inter-dependent in complex ways, " "meaning that subtle changes to values are likely to result in incorrect " "execution or VM crashes. Use this function only with extreme care." msgstr "" -#: ../../c-api/code.rst:59 +#: ../../c-api/code.rst:61 msgid "Added ``qualname`` and ``exceptiontable`` parameters." msgstr "" -#: ../../c-api/code.rst:66 +#: ../../c-api/code.rst:68 msgid "" "Renamed from ``PyCode_New`` as part of :ref:`unstable-c-api`. The old name " "is deprecated, but will remain available until the signature changes again." msgstr "" -#: ../../c-api/code.rst:72 +#: ../../c-api/code.rst:74 msgid "" "Similar to :c:func:`PyUnstable_Code_New`, but with an extra " "\"posonlyargcount\" for positional-only arguments. The same caveats that " "apply to ``PyUnstable_Code_New`` also apply to this function." msgstr "" -#: ../../c-api/code.rst:77 +#: ../../c-api/code.rst:79 msgid "as ``PyCode_NewWithPosOnlyArgs``" msgstr "" -#: ../../c-api/code.rst:79 +#: ../../c-api/code.rst:81 msgid "Added ``qualname`` and ``exceptiontable`` parameters." msgstr "" -#: ../../c-api/code.rst:84 +#: ../../c-api/code.rst:86 msgid "" "Renamed to ``PyUnstable_Code_NewWithPosOnlyArgs``. The old name is " "deprecated, but will remain available until the signature changes again." msgstr "" -#: ../../c-api/code.rst:90 +#: ../../c-api/code.rst:92 msgid "" "Return a new empty code object with the specified filename, function name, " "and first line number. The resulting code object will raise an ``Exception`` " "if executed." msgstr "" -#: ../../c-api/code.rst:96 +#: ../../c-api/code.rst:98 msgid "" "Return the line number of the instruction that occurs on or before " "``byte_offset`` and ends after it. If you just need the line number of a " "frame, use :c:func:`PyFrame_GetLineNumber` instead." msgstr "" -#: ../../c-api/code.rst:99 +#: ../../c-api/code.rst:101 msgid "" "For efficiently iterating over the line numbers in a code object, use :pep:" "`the API described in PEP 626 <0626#out-of-process-debuggers-and-profilers>`." msgstr "" -#: ../../c-api/code.rst:104 +#: ../../c-api/code.rst:106 msgid "" "Sets the passed ``int`` pointers to the source code line and column numbers " "for the instruction at ``byte_offset``. Sets the value to ``0`` when " "information is not available for any particular element." msgstr "" -#: ../../c-api/code.rst:108 +#: ../../c-api/code.rst:110 msgid "Returns ``1`` if the function succeeds and 0 otherwise." msgstr "" -#: ../../c-api/code.rst:114 +#: ../../c-api/code.rst:116 msgid "" "Equivalent to the Python code ``getattr(co, 'co_code')``. Returns a strong " "reference to a :c:type:`PyBytesObject` representing the bytecode in a code " "object. On error, ``NULL`` is returned and an exception is raised." msgstr "" -#: ../../c-api/code.rst:119 +#: ../../c-api/code.rst:121 msgid "" "This ``PyBytesObject`` may be created on-demand by the interpreter and does " "not necessarily represent the bytecode actually executed by CPython. The " "primary use case for this function is debuggers and profilers." msgstr "" -#: ../../c-api/code.rst:127 +#: ../../c-api/code.rst:129 msgid "" "Equivalent to the Python code ``getattr(co, 'co_varnames')``. Returns a new " "reference to a :c:type:`PyTupleObject` containing the names of the local " "variables. On error, ``NULL`` is returned and an exception is raised." msgstr "" -#: ../../c-api/code.rst:136 +#: ../../c-api/code.rst:138 msgid "" "Equivalent to the Python code ``getattr(co, 'co_cellvars')``. Returns a new " "reference to a :c:type:`PyTupleObject` containing the names of the local " @@ -183,14 +187,15 @@ msgid "" "returned and an exception is raised." msgstr "" -#: ../../c-api/code.rst:145 +#: ../../c-api/code.rst:147 msgid "" "Equivalent to the Python code ``getattr(co, 'co_freevars')``. Returns a new " -"reference to a :c:type:`PyTupleObject` containing the names of the free " -"variables. On error, ``NULL`` is returned and an exception is raised." +"reference to a :c:type:`PyTupleObject` containing the names of the :term:" +"`free (closure) variables `. On error, ``NULL`` is " +"returned and an exception is raised." msgstr "" -#: ../../c-api/code.rst:153 +#: ../../c-api/code.rst:156 msgid "" "Register *callback* as a code object watcher for the current interpreter. " "Return an ID which may be passed to :c:func:`PyCode_ClearWatcher`. In case " @@ -198,7 +203,7 @@ msgid "" "exception." msgstr "" -#: ../../c-api/code.rst:162 +#: ../../c-api/code.rst:165 msgid "" "Clear watcher identified by *watcher_id* previously returned from :c:func:" "`PyCode_AddWatcher` for the current interpreter. Return ``0`` on success, or " @@ -206,17 +211,17 @@ msgid "" "never registered.)" msgstr "" -#: ../../c-api/code.rst:171 +#: ../../c-api/code.rst:174 msgid "" "Enumeration of possible code object watcher events: - " "``PY_CODE_EVENT_CREATE`` - ``PY_CODE_EVENT_DESTROY``" msgstr "" -#: ../../c-api/code.rst:179 +#: ../../c-api/code.rst:182 msgid "Type of a code object watcher callback function." msgstr "" -#: ../../c-api/code.rst:181 +#: ../../c-api/code.rst:184 msgid "" "If *event* is ``PY_CODE_EVENT_CREATE``, then the callback is invoked after " "`co` has been fully initialized. Otherwise, the callback is invoked before " @@ -224,7 +229,7 @@ msgid "" "inspected." msgstr "" -#: ../../c-api/code.rst:186 +#: ../../c-api/code.rst:189 msgid "" "If *event* is ``PY_CODE_EVENT_DESTROY``, taking a reference in the callback " "to the about-to-be-destroyed code object will resurrect it and prevent it " @@ -232,7 +237,7 @@ msgid "" "later, any watcher callbacks active at that time will be called again." msgstr "" -#: ../../c-api/code.rst:191 +#: ../../c-api/code.rst:194 msgid "" "Users of this API should not rely on internal runtime implementation " "details. Such details may include, but are not limited to, the exact order " @@ -242,14 +247,14 @@ msgid "" "the Python code being executed." msgstr "" -#: ../../c-api/code.rst:198 +#: ../../c-api/code.rst:201 msgid "" "If the callback sets an exception, it must return ``-1``; this exception " "will be printed as an unraisable exception using :c:func:" "`PyErr_WriteUnraisable`. Otherwise it should return ``0``." msgstr "" -#: ../../c-api/code.rst:202 +#: ../../c-api/code.rst:205 msgid "" "There may already be a pending exception set on entry to the callback. In " "this case, the callback should return ``0`` with the same exception still " @@ -258,85 +263,85 @@ msgid "" "it before returning." msgstr "" -#: ../../c-api/code.rst:212 +#: ../../c-api/code.rst:215 msgid "Extra information" msgstr "" -#: ../../c-api/code.rst:214 +#: ../../c-api/code.rst:217 msgid "" "To support low-level extensions to frame evaluation, such as external just-" "in-time compilers, it is possible to attach arbitrary extra data to code " "objects." msgstr "" -#: ../../c-api/code.rst:218 +#: ../../c-api/code.rst:221 msgid "" "These functions are part of the unstable C API tier: this functionality is a " "CPython implementation detail, and the API may change without deprecation " "warnings." msgstr "" -#: ../../c-api/code.rst:224 +#: ../../c-api/code.rst:227 msgid "Return a new an opaque index value used to adding data to code objects." msgstr "" -#: ../../c-api/code.rst:226 +#: ../../c-api/code.rst:229 msgid "" "You generally call this function once (per interpreter) and use the result " "with ``PyCode_GetExtra`` and ``PyCode_SetExtra`` to manipulate data on " "individual code objects." msgstr "" -#: ../../c-api/code.rst:230 +#: ../../c-api/code.rst:233 msgid "" "If *free* is not ``NULL``: when a code object is deallocated, *free* will be " "called on non-``NULL`` data stored under the new index. Use :c:func:" "`Py_DecRef` when storing :c:type:`PyObject`." msgstr "" -#: ../../c-api/code.rst:236 +#: ../../c-api/code.rst:239 msgid "as ``_PyEval_RequestCodeExtraIndex``" msgstr "" -#: ../../c-api/code.rst:240 +#: ../../c-api/code.rst:243 msgid "" "Renamed to ``PyUnstable_Eval_RequestCodeExtraIndex``. The old private name " "is deprecated, but will be available until the API changes." msgstr "" -#: ../../c-api/code.rst:246 +#: ../../c-api/code.rst:249 msgid "" "Set *extra* to the extra data stored under the given index. Return 0 on " "success. Set an exception and return -1 on failure." msgstr "" -#: ../../c-api/code.rst:249 +#: ../../c-api/code.rst:252 msgid "" "If no data was set under the index, set *extra* to ``NULL`` and return 0 " "without setting an exception." msgstr "" -#: ../../c-api/code.rst:254 +#: ../../c-api/code.rst:257 msgid "as ``_PyCode_GetExtra``" msgstr "" -#: ../../c-api/code.rst:258 +#: ../../c-api/code.rst:261 msgid "" "Renamed to ``PyUnstable_Code_GetExtra``. The old private name is deprecated, " "but will be available until the API changes." msgstr "" -#: ../../c-api/code.rst:264 +#: ../../c-api/code.rst:267 msgid "" "Set the extra data stored under the given index to *extra*. Return 0 on " "success. Set an exception and return -1 on failure." msgstr "" -#: ../../c-api/code.rst:269 +#: ../../c-api/code.rst:272 msgid "as ``_PyCode_SetExtra``" msgstr "" -#: ../../c-api/code.rst:273 +#: ../../c-api/code.rst:276 msgid "" "Renamed to ``PyUnstable_Code_SetExtra``. The old private name is deprecated, " "but will be available until the API changes." @@ -354,22 +359,22 @@ msgstr "コード" msgid "code object" msgstr "コードオブジェクト" -#: ../../c-api/code.rst:62 +#: ../../c-api/code.rst:64 msgid "PyCode_New (C function)" msgstr "PyCode_New (C 関数)" -#: ../../c-api/code.rst:75 +#: ../../c-api/code.rst:77 msgid "PyCode_NewWithPosOnlyArgs (C function)" msgstr "PyCode_NewWithPosOnlyArgs (C 関数)" -#: ../../c-api/code.rst:234 +#: ../../c-api/code.rst:237 msgid "_PyEval_RequestCodeExtraIndex (C function)" msgstr "_PyEval_RequestCodeExtraIndex (C 関数)" -#: ../../c-api/code.rst:252 +#: ../../c-api/code.rst:255 msgid "_PyCode_GetExtra (C function)" msgstr "_PyCode_GetExtra (C 関数)" -#: ../../c-api/code.rst:267 +#: ../../c-api/code.rst:270 msgid "_PyCode_SetExtra (C function)" msgstr "_PyCode_SetExtra (C 関数)" diff --git a/c-api/exceptions.po b/c-api/exceptions.po index 60fff64e5..496f79a29 100644 --- a/c-api/exceptions.po +++ b/c-api/exceptions.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:48+0000\n" "Last-Translator: Taichi Haradaguchi, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -332,8 +332,8 @@ msgstr "" #: ../../c-api/exceptions.rst:234 ../../c-api/exceptions.rst:242 #: ../../c-api/exceptions.rst:253 ../../c-api/exceptions.rst:263 #: ../../c-api/exceptions.rst:271 ../../c-api/exceptions.rst:281 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +msgid "Availability" +msgstr "" #: ../../c-api/exceptions.rst:239 msgid "" diff --git a/c-api/import.po b/c-api/import.po index ec0ef8702..7ee4f226b 100644 --- a/c-api/import.po +++ b/c-api/import.po @@ -18,7 +18,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:48+0000\n" "Last-Translator: Masato HASHIMOTO , 2023\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -197,17 +197,17 @@ msgstr "" #: ../../c-api/import.rst:139 msgid "" -"The module's :attr:`__spec__` and :attr:`__loader__` will be set, if not set " -"already, with the appropriate values. The spec's loader will be set to the " -"module's ``__loader__`` (if set) and to an instance of :class:`~importlib." -"machinery.SourceFileLoader` otherwise." +"The module's :attr:`~module.__spec__` and :attr:`~module.__loader__` will be " +"set, if not set already, with the appropriate values. The spec's loader " +"will be set to the module's :attr:`!__loader__` (if set) and to an instance " +"of :class:`~importlib.machinery.SourceFileLoader` otherwise." msgstr "" #: ../../c-api/import.rst:144 msgid "" -"The module's :attr:`__file__` attribute will be set to the code object's :" -"attr:`~codeobject.co_filename`. If applicable, :attr:`__cached__` will also " -"be set." +"The module's :attr:`~module.__file__` attribute will be set to the code " +"object's :attr:`~codeobject.co_filename`. If applicable, :attr:`~module." +"__cached__` will also be set." msgstr "" #: ../../c-api/import.rst:148 @@ -237,18 +237,15 @@ msgstr "" #: ../../c-api/import.rst:157 msgid "" -"The setting of :attr:`__cached__` and :attr:`__loader__` is deprecated. See :" -"class:`~importlib.machinery.ModuleSpec` for alternatives." +"The setting of :attr:`~module.__cached__` and :attr:`~module.__loader__` is " +"deprecated. See :class:`~importlib.machinery.ModuleSpec` for alternatives." msgstr "" #: ../../c-api/import.rst:165 msgid "" -"Like :c:func:`PyImport_ExecCodeModule`, but the :attr:`__file__` attribute " -"of the module object is set to *pathname* if it is non-``NULL``." +"Like :c:func:`PyImport_ExecCodeModule`, but the :attr:`~module.__file__` " +"attribute of the module object is set to *pathname* if it is non-``NULL``." msgstr "" -":c:func:`PyImport_ExecCodeModule` と似ていますが、*pathname* が ``NULL`` でな" -"い場合にモジュールオブジェクトの :attr:`__file__` 属性に *pathname* が設定さ" -"れる点が異なります。" #: ../../c-api/import.rst:168 msgid "See also :c:func:`PyImport_ExecCodeModuleWithPathnames`." @@ -256,19 +253,15 @@ msgstr ":c:func:`PyImport_ExecCodeModuleWithPathnames` も参照してくださ #: ../../c-api/import.rst:173 msgid "" -"Like :c:func:`PyImport_ExecCodeModuleEx`, but the :attr:`__cached__` " +"Like :c:func:`PyImport_ExecCodeModuleEx`, but the :attr:`~module.__cached__` " "attribute of the module object is set to *cpathname* if it is non-``NULL``. " "Of the three functions, this is the preferred one to use." msgstr "" -":c:func:`PyImport_ExecCodeModuleEx` と似ていますが、*cpathname* が ``NULL`` " -"でない場合にモジュールオブジェクトの :attr:`__cached__` 属性に *cpathname* が" -"設定される点が異なります。これらの 3 つの関数のうち、この関数の使用が望ましい" -"です。" #: ../../c-api/import.rst:179 msgid "" -"Setting :attr:`__cached__` is deprecated. See :class:`~importlib.machinery." -"ModuleSpec` for alternatives." +"Setting :attr:`~module.__cached__` is deprecated. See :class:`~importlib." +"machinery.ModuleSpec` for alternatives." msgstr "" #: ../../c-api/import.rst:186 diff --git a/c-api/init.po b/c-api/init.po index 0749bc794..d4d5bc86e 100644 --- a/c-api/init.po +++ b/c-api/init.po @@ -12,15 +12,17 @@ # Takeshi Nakazato, 2024 # tomo, 2024 # Arihiro TAKASE, 2024 +# Tetsuo Koyama , 2024 +# Takanori Suzuki , 2024 # #, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:49+0000\n" -"Last-Translator: Arihiro TAKASE, 2024\n" +"Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" "ja/)\n" "MIME-Version: 1.0\n" @@ -34,14 +36,16 @@ msgid "Initialization, Finalization, and Threads" msgstr "初期化 (initialization)、終了処理 (finalization)、スレッド" #: ../../c-api/init.rst:10 -msgid "See also :ref:`Python Initialization Configuration `." -msgstr ":ref:`Python 初期化設定 ` も参照してください。" +msgid "" +"See :ref:`Python Initialization Configuration ` for details on " +"how to configure the interpreter prior to initialization." +msgstr "" -#: ../../c-api/init.rst:15 +#: ../../c-api/init.rst:16 msgid "Before Python Initialization" msgstr "Python 初期化以前" -#: ../../c-api/init.rst:17 +#: ../../c-api/init.rst:18 msgid "" "In an application embedding Python, the :c:func:`Py_Initialize` function " "must be called before using any other Python/C API functions; with the " @@ -52,146 +56,179 @@ msgstr "" "に :c:func:`Py_Initialize` 関数を呼ばなければなりません。これには例外として、" "いくつかの関数と :ref:`グローバルな設定変数 ` があります。" -#: ../../c-api/init.rst:22 +#: ../../c-api/init.rst:23 msgid "" "The following functions can be safely called before Python is initialized:" msgstr "次の関数は Python の初期化の前でも安全に呼び出せます:" -#: ../../c-api/init.rst:24 +#: ../../c-api/init.rst:25 +msgid "Functions that initialize the interpreter:" +msgstr "" + +#: ../../c-api/init.rst:27 +msgid ":c:func:`Py_Initialize`" +msgstr "" + +#: ../../c-api/init.rst:28 +msgid ":c:func:`Py_InitializeEx`" +msgstr "" + +#: ../../c-api/init.rst:29 +msgid ":c:func:`Py_InitializeFromConfig`" +msgstr ":c:func:`Py_InitializeFromConfig`" + +#: ../../c-api/init.rst:30 +msgid ":c:func:`Py_BytesMain`" +msgstr ":c:func:`Py_BytesMain`" + +#: ../../c-api/init.rst:31 +msgid ":c:func:`Py_Main`" +msgstr "" + +#: ../../c-api/init.rst:32 +msgid "the runtime pre-initialization functions covered in :ref:`init-config`" +msgstr "" + +#: ../../c-api/init.rst:34 msgid "Configuration functions:" msgstr "設定関数:" -#: ../../c-api/init.rst:26 +#: ../../c-api/init.rst:36 msgid ":c:func:`PyImport_AppendInittab`" msgstr ":c:func:`PyImport_AppendInittab`" -#: ../../c-api/init.rst:27 +#: ../../c-api/init.rst:37 msgid ":c:func:`PyImport_ExtendInittab`" msgstr ":c:func:`PyImport_ExtendInittab`" -#: ../../c-api/init.rst:28 +#: ../../c-api/init.rst:38 msgid ":c:func:`!PyInitFrozenExtensions`" msgstr "" -#: ../../c-api/init.rst:29 +#: ../../c-api/init.rst:39 msgid ":c:func:`PyMem_SetAllocator`" msgstr ":c:func:`PyMem_SetAllocator`" -#: ../../c-api/init.rst:30 +#: ../../c-api/init.rst:40 msgid ":c:func:`PyMem_SetupDebugHooks`" msgstr ":c:func:`PyMem_SetupDebugHooks`" -#: ../../c-api/init.rst:31 +#: ../../c-api/init.rst:41 msgid ":c:func:`PyObject_SetArenaAllocator`" msgstr ":c:func:`PyObject_SetArenaAllocator`" -#: ../../c-api/init.rst:32 +#: ../../c-api/init.rst:42 msgid ":c:func:`Py_SetProgramName`" msgstr ":c:func:`Py_SetProgramName`" -#: ../../c-api/init.rst:33 +#: ../../c-api/init.rst:43 msgid ":c:func:`Py_SetPythonHome`" msgstr ":c:func:`Py_SetPythonHome`" -#: ../../c-api/init.rst:34 +#: ../../c-api/init.rst:44 msgid ":c:func:`PySys_ResetWarnOptions`" msgstr ":c:func:`PySys_ResetWarnOptions`" -#: ../../c-api/init.rst:36 +#: ../../c-api/init.rst:45 +msgid "the configuration functions covered in :ref:`init-config`" +msgstr "" + +#: ../../c-api/init.rst:47 msgid "Informative functions:" msgstr "情報取得の関数:" -#: ../../c-api/init.rst:38 +#: ../../c-api/init.rst:49 ../../c-api/init.rst:57 msgid ":c:func:`Py_IsInitialized`" msgstr ":c:func:`Py_IsInitialized`" -#: ../../c-api/init.rst:39 +#: ../../c-api/init.rst:50 msgid ":c:func:`PyMem_GetAllocator`" msgstr ":c:func:`PyMem_GetAllocator`" -#: ../../c-api/init.rst:40 +#: ../../c-api/init.rst:51 msgid ":c:func:`PyObject_GetArenaAllocator`" msgstr ":c:func:`PyObject_GetArenaAllocator`" -#: ../../c-api/init.rst:41 +#: ../../c-api/init.rst:52 msgid ":c:func:`Py_GetBuildInfo`" msgstr ":c:func:`Py_GetBuildInfo`" -#: ../../c-api/init.rst:42 +#: ../../c-api/init.rst:53 msgid ":c:func:`Py_GetCompiler`" msgstr ":c:func:`Py_GetCompiler`" -#: ../../c-api/init.rst:43 +#: ../../c-api/init.rst:54 msgid ":c:func:`Py_GetCopyright`" msgstr ":c:func:`Py_GetCopyright`" -#: ../../c-api/init.rst:44 +#: ../../c-api/init.rst:55 msgid ":c:func:`Py_GetPlatform`" msgstr ":c:func:`Py_GetPlatform`" -#: ../../c-api/init.rst:45 +#: ../../c-api/init.rst:56 msgid ":c:func:`Py_GetVersion`" msgstr ":c:func:`Py_GetVersion`" -#: ../../c-api/init.rst:47 +#: ../../c-api/init.rst:59 msgid "Utilities:" msgstr "ユーティリティ:" -#: ../../c-api/init.rst:49 +#: ../../c-api/init.rst:61 msgid ":c:func:`Py_DecodeLocale`" msgstr ":c:func:`Py_DecodeLocale`" -#: ../../c-api/init.rst:51 +#: ../../c-api/init.rst:62 +msgid "" +"the status reporting and utility functions covered in :ref:`init-config`" +msgstr "" + +#: ../../c-api/init.rst:64 msgid "Memory allocators:" msgstr "メモリアロケータ:" -#: ../../c-api/init.rst:53 +#: ../../c-api/init.rst:66 msgid ":c:func:`PyMem_RawMalloc`" msgstr ":c:func:`PyMem_RawMalloc`" -#: ../../c-api/init.rst:54 +#: ../../c-api/init.rst:67 msgid ":c:func:`PyMem_RawRealloc`" msgstr ":c:func:`PyMem_RawRealloc`" -#: ../../c-api/init.rst:55 +#: ../../c-api/init.rst:68 msgid ":c:func:`PyMem_RawCalloc`" msgstr ":c:func:`PyMem_RawCalloc`" -#: ../../c-api/init.rst:56 +#: ../../c-api/init.rst:69 msgid ":c:func:`PyMem_RawFree`" msgstr ":c:func:`PyMem_RawFree`" -#: ../../c-api/init.rst:58 +#: ../../c-api/init.rst:71 msgid "Synchronization:" msgstr "" -#: ../../c-api/init.rst:60 +#: ../../c-api/init.rst:73 msgid ":c:func:`PyMutex_Lock`" msgstr "" -#: ../../c-api/init.rst:61 +#: ../../c-api/init.rst:74 msgid ":c:func:`PyMutex_Unlock`" msgstr "" -#: ../../c-api/init.rst:65 +#: ../../c-api/init.rst:78 msgid "" -"The following functions **should not be called** before :c:func:" -"`Py_Initialize`: :c:func:`Py_EncodeLocale`, :c:func:`Py_GetPath`, :c:func:" +"Despite their apparent similarity to some of the functions listed above, the " +"following functions **should not be called** before the interpreter has been " +"initialized: :c:func:`Py_EncodeLocale`, :c:func:`Py_GetPath`, :c:func:" "`Py_GetPrefix`, :c:func:`Py_GetExecPrefix`, :c:func:" "`Py_GetProgramFullPath`, :c:func:`Py_GetPythonHome`, :c:func:" -"`Py_GetProgramName` and :c:func:`PyEval_InitThreads`." +"`Py_GetProgramName`, :c:func:`PyEval_InitThreads`, and :c:func:`Py_RunMain`." msgstr "" -"次の関数は :c:func:`Py_Initialize` より前に **呼び出すべき ではありません" -"** : :c:func:`Py_EncodeLocale`, :c:func:`Py_GetPath`, :c:func:" -"`Py_GetPrefix`, :c:func:`Py_GetExecPrefix`, :c:func:" -"`Py_GetProgramFullPath`, :c:func:`Py_GetPythonHome`, :c:func:" -"`Py_GetProgramName`, :c:func:`PyEval_InitThreads` 。" -#: ../../c-api/init.rst:75 +#: ../../c-api/init.rst:90 msgid "Global configuration variables" msgstr "グローバルな設定変数" -#: ../../c-api/init.rst:77 +#: ../../c-api/init.rst:92 msgid "" "Python has variables for the global configuration to control different " "features and options. By default, these flags are controlled by :ref:" @@ -202,7 +239,7 @@ msgstr "" "デフォルトでは、これらのフラグは :ref:`コマンドラインオプション ` で制御されます。" -#: ../../c-api/init.rst:81 +#: ../../c-api/init.rst:96 msgid "" "When a flag is set by an option, the value of the flag is the number of " "times that the option was set. For example, ``-b`` sets :c:data:" @@ -214,14 +251,14 @@ msgstr "" "例えば、 ``-b`` では :c:data:`Py_BytesWarningFlag` が 1 に設定され、 ``-bb`` " "では :c:data:`Py_BytesWarningFlag` が 2 に設定されます。" -#: ../../c-api/init.rst:87 +#: ../../c-api/init.rst:102 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "bytes_warning` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:91 +#: ../../c-api/init.rst:106 msgid "" "Issue a warning when comparing :class:`bytes` or :class:`bytearray` with :" "class:`str` or :class:`bytes` with :class:`int`. Issue an error if greater " @@ -231,18 +268,18 @@ msgstr "" "は、 :class:`bytes` を :class:`int` と比較した場合に警告を発生させます。\n" "``2`` 以上の値を設定している場合は、エラーを発生させます。" -#: ../../c-api/init.rst:95 +#: ../../c-api/init.rst:110 msgid "Set by the :option:`-b` option." msgstr ":option:`-b` オプションで設定します。" -#: ../../c-api/init.rst:101 +#: ../../c-api/init.rst:116 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "parser_debug` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:105 +#: ../../c-api/init.rst:120 msgid "" "Turn on parser debugging output (for expert only, depending on compilation " "options)." @@ -250,20 +287,20 @@ msgstr "" "パーサーのデバッグ出力を有効にします。(専門家専用です。コンパイルオプションに" "依存します)。" -#: ../../c-api/init.rst:108 +#: ../../c-api/init.rst:123 msgid "" "Set by the :option:`-d` option and the :envvar:`PYTHONDEBUG` environment " "variable." msgstr ":option:`-d` オプションと :envvar:`PYTHONDEBUG` 環境変数で設定します。" -#: ../../c-api/init.rst:115 +#: ../../c-api/init.rst:130 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "write_bytecode` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:119 +#: ../../c-api/init.rst:134 msgid "" "If set to non-zero, Python won't try to write ``.pyc`` files on the import " "of source modules." @@ -271,7 +308,7 @@ msgstr "" "非ゼロに設定した場合、Python はソースモジュールのインポート時に ``.pyc`` ファ" "イルの作成を試みません。" -#: ../../c-api/init.rst:122 +#: ../../c-api/init.rst:137 msgid "" "Set by the :option:`-B` option and the :envvar:`PYTHONDONTWRITEBYTECODE` " "environment variable." @@ -279,14 +316,14 @@ msgstr "" ":option:`-B` オプションと :envvar:`PYTHONDONTWRITEBYTECODE` 環境変数で設定し" "ます。" -#: ../../c-api/init.rst:129 +#: ../../c-api/init.rst:144 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "pathconfig_warnings` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:133 +#: ../../c-api/init.rst:148 msgid "" "Suppress error messages when calculating the module search path in :c:func:" "`Py_GetPath`." @@ -294,20 +331,20 @@ msgstr "" ":c:func:`Py_GetPath` の中でモジュール検索パスを割り出しているときのエラーメッ" "セージを抑制します。" -#: ../../c-api/init.rst:136 +#: ../../c-api/init.rst:151 msgid "Private flag used by ``_freeze_module`` and ``frozenmain`` programs." msgstr "" "``_freeze_module`` プログラムと ``frozenmain`` プログラムが使用する非公開フラ" "グです。" -#: ../../c-api/init.rst:142 +#: ../../c-api/init.rst:157 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "hash_seed` and :c:member:`PyConfig.use_hash_seed` should be used instead, " "see :ref:`Python Initialization Configuration `." msgstr "" -#: ../../c-api/init.rst:147 +#: ../../c-api/init.rst:162 msgid "" "Set to ``1`` if the :envvar:`PYTHONHASHSEED` environment variable is set to " "a non-empty string." @@ -315,7 +352,7 @@ msgstr "" ":envvar:`PYTHONHASHSEED` 環境変数が空でない文字列に設定された場合に、 ``1`` " "が設定されます。" -#: ../../c-api/init.rst:150 +#: ../../c-api/init.rst:165 msgid "" "If the flag is non-zero, read the :envvar:`PYTHONHASHSEED` environment " "variable to initialize the secret hash seed." @@ -323,31 +360,31 @@ msgstr "" "フラグがゼロでない場合、 :envvar:`PYTHONHASHSEED` 環境変数を読みシークレット" "ハッシュシードを初期化します。" -#: ../../c-api/init.rst:157 +#: ../../c-api/init.rst:172 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "use_environment` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:161 +#: ../../c-api/init.rst:176 msgid "" "Ignore all :envvar:`!PYTHON*` environment variables, e.g. :envvar:" "`PYTHONPATH` and :envvar:`PYTHONHOME`, that might be set." msgstr "" -#: ../../c-api/init.rst:164 +#: ../../c-api/init.rst:179 msgid "Set by the :option:`-E` and :option:`-I` options." msgstr ":option:`-E` オプションと :option:`-I` オプションで設定します。" -#: ../../c-api/init.rst:170 +#: ../../c-api/init.rst:185 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "inspect` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:174 +#: ../../c-api/init.rst:189 msgid "" "When a script is passed as first argument or the :option:`-c` option is " "used, enter interactive mode after executing the script or the command, even " @@ -357,32 +394,32 @@ msgstr "" "際に、 :data:`sys.stdin` がターミナルに出力されないときであっても、スクリプト" "かコマンドを実行した後にインタラクティブモードに入ります。" -#: ../../c-api/init.rst:178 +#: ../../c-api/init.rst:193 msgid "" "Set by the :option:`-i` option and the :envvar:`PYTHONINSPECT` environment " "variable." msgstr "" ":option:`-i` オプションと :envvar:`PYTHONINSPECT` 環境変数で設定します。" -#: ../../c-api/init.rst:185 +#: ../../c-api/init.rst:200 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "interactive` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:189 +#: ../../c-api/init.rst:204 msgid "Set by the :option:`-i` option." msgstr ":option:`-i` オプションで設定します。" -#: ../../c-api/init.rst:195 +#: ../../c-api/init.rst:210 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "isolated` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:199 +#: ../../c-api/init.rst:214 msgid "" "Run Python in isolated mode. In isolated mode :data:`sys.path` contains " "neither the script's directory nor the user's site-packages directory." @@ -391,25 +428,25 @@ msgstr "" "隔離モードでは :data:`sys.path` はスクリプトのディレクトリやユーザのサイト" "パッケージのディレクトリを含みません。" -#: ../../c-api/init.rst:202 +#: ../../c-api/init.rst:217 msgid "Set by the :option:`-I` option." msgstr ":option:`-I` オプションで設定します。" -#: ../../c-api/init.rst:210 +#: ../../c-api/init.rst:225 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyPreConfig." "legacy_windows_fs_encoding` should be used instead, see :ref:`Python " "Initialization Configuration `." msgstr "" -#: ../../c-api/init.rst:214 +#: ../../c-api/init.rst:229 msgid "" "If the flag is non-zero, use the ``mbcs`` encoding with ``replace`` error " "handler, instead of the UTF-8 encoding with ``surrogatepass`` error handler, " "for the :term:`filesystem encoding and error handler`." msgstr "" -#: ../../c-api/init.rst:218 +#: ../../c-api/init.rst:233 msgid "" "Set to ``1`` if the :envvar:`PYTHONLEGACYWINDOWSFSENCODING` environment " "variable is set to a non-empty string." @@ -417,28 +454,28 @@ msgstr "" ":envvar:`PYTHONLEGACYWINDOWSFSENCODING` 環境変数が空でない文字列に設定された" "場合に、 ``1`` に設定されます。" -#: ../../c-api/init.rst:221 +#: ../../c-api/init.rst:236 msgid "See :pep:`529` for more details." msgstr "より詳しくは :pep:`529` を参照してください。" -#: ../../c-api/init.rst:223 ../../c-api/init.rst:241 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +#: ../../c-api/init.rst:238 ../../c-api/init.rst:256 +msgid "Availability" +msgstr "" -#: ../../c-api/init.rst:229 +#: ../../c-api/init.rst:244 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "legacy_windows_stdio` should be used instead, see :ref:`Python " "Initialization Configuration `." msgstr "" -#: ../../c-api/init.rst:233 +#: ../../c-api/init.rst:248 msgid "" "If the flag is non-zero, use :class:`io.FileIO` instead of :class:`!io." "_WindowsConsoleIO` for :mod:`sys` standard streams." msgstr "" -#: ../../c-api/init.rst:236 +#: ../../c-api/init.rst:251 msgid "" "Set to ``1`` if the :envvar:`PYTHONLEGACYWINDOWSSTDIO` environment variable " "is set to a non-empty string." @@ -446,18 +483,18 @@ msgstr "" ":envvar:`PYTHONLEGACYWINDOWSSTDIO` 環境変数が空でない文字列に設定された場合" "に、 ``1`` に設定されます。" -#: ../../c-api/init.rst:239 +#: ../../c-api/init.rst:254 msgid "See :pep:`528` for more details." msgstr "より詳しくは :pep:`528` を参照してください。" -#: ../../c-api/init.rst:247 +#: ../../c-api/init.rst:262 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "site_import` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:251 +#: ../../c-api/init.rst:266 msgid "" "Disable the import of the module :mod:`site` and the site-dependent " "manipulations of :data:`sys.path` that it entails. Also disable these " @@ -469,18 +506,18 @@ msgstr "" "import しても、これらの操作は実行されません (実行したい場合は、 :func:`site." "main` を呼び出してください)。" -#: ../../c-api/init.rst:256 +#: ../../c-api/init.rst:271 msgid "Set by the :option:`-S` option." msgstr ":option:`-S` オプションで設定します。" -#: ../../c-api/init.rst:262 +#: ../../c-api/init.rst:277 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "user_site_directory` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:266 +#: ../../c-api/init.rst:281 msgid "" "Don't add the :data:`user site-packages directory ` to :data:" "`sys.path`." @@ -488,7 +525,7 @@ msgstr "" ":data:`ユーザのサイトパッケージのディレクトリ ` を :data:" "`sys.path` に追加しません。" -#: ../../c-api/init.rst:269 +#: ../../c-api/init.rst:284 msgid "" "Set by the :option:`-s` and :option:`-I` options, and the :envvar:" "`PYTHONNOUSERSITE` environment variable." @@ -496,63 +533,63 @@ msgstr "" ":option:`-s` オプション、 :option:`-I` 、 :envvar:`PYTHONNOUSERSITE` 環境変数" "で設定します。" -#: ../../c-api/init.rst:276 +#: ../../c-api/init.rst:291 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "optimization_level` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:280 +#: ../../c-api/init.rst:295 msgid "" "Set by the :option:`-O` option and the :envvar:`PYTHONOPTIMIZE` environment " "variable." msgstr "" ":option:`-O` オプションと :envvar:`PYTHONOPTIMIZE` 環境変数で設定します。" -#: ../../c-api/init.rst:287 +#: ../../c-api/init.rst:302 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "quiet` should be used instead, see :ref:`Python Initialization Configuration " "`." msgstr "" -#: ../../c-api/init.rst:291 +#: ../../c-api/init.rst:306 msgid "" "Don't display the copyright and version messages even in interactive mode." msgstr "" "インタラクティブモードでも copyright とバージョンのメッセージを表示しません。" -#: ../../c-api/init.rst:293 +#: ../../c-api/init.rst:308 msgid "Set by the :option:`-q` option." msgstr ":option:`-q` オプションで設定します。" -#: ../../c-api/init.rst:301 +#: ../../c-api/init.rst:316 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "buffered_stdio` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:305 +#: ../../c-api/init.rst:320 msgid "Force the stdout and stderr streams to be unbuffered." msgstr "標準出力と標準エラーをバッファリングしないように強制します。" -#: ../../c-api/init.rst:307 +#: ../../c-api/init.rst:322 msgid "" "Set by the :option:`-u` option and the :envvar:`PYTHONUNBUFFERED` " "environment variable." msgstr "" ":option:`-u` オプションと :envvar:`PYTHONUNBUFFERED` 環境変数で設定します。" -#: ../../c-api/init.rst:314 +#: ../../c-api/init.rst:329 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "verbose` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:318 +#: ../../c-api/init.rst:333 msgid "" "Print a message each time a module is initialized, showing the place " "(filename or built-in module) from which it is loaded. If greater or equal " @@ -565,18 +602,18 @@ msgstr "" "セージを出力します。また、終了時のモジュールクリーンアップに関する情報も提供" "します。" -#: ../../c-api/init.rst:323 +#: ../../c-api/init.rst:338 msgid "" "Set by the :option:`-v` option and the :envvar:`PYTHONVERBOSE` environment " "variable." msgstr "" ":option:`-v` オプションと :envvar:`PYTHONVERBOSE` 環境変数で設定します。" -#: ../../c-api/init.rst:330 +#: ../../c-api/init.rst:345 msgid "Initializing and finalizing the interpreter" msgstr "インタープリタの初期化と終了処理" -#: ../../c-api/init.rst:345 +#: ../../c-api/init.rst:360 msgid "" "Initialize the Python interpreter. In an application embedding Python, " "this should be called before using any other Python/C API functions; see :" @@ -587,24 +624,24 @@ msgstr "" "するよりも前にこの関数を呼び出さなければなりません。いくつかの例外について" "は :ref:`Python 初期化以前 ` を参照してください。" -#: ../../c-api/init.rst:349 +#: ../../c-api/init.rst:364 msgid "" "This initializes the table of loaded modules (``sys.modules``), and creates " -"the fundamental modules :mod:`builtins`, :mod:`__main__` and :mod:`sys`. It " +"the fundamental modules :mod:`builtins`, :mod:`__main__` and :mod:`sys`. It " "also initializes the module search path (``sys.path``). It does not set " -"``sys.argv``; use the new :c:type:`PyConfig` API of the :ref:`Python " -"Initialization Configuration ` for that. This is a no-op when " -"called for a second time (without calling :c:func:`Py_FinalizeEx` first). " -"There is no return value; it is a fatal error if the initialization fails." +"``sys.argv``; use the :ref:`Python Initialization Configuration ` API for that. This is a no-op when called for a second time " +"(without calling :c:func:`Py_FinalizeEx` first). There is no return value; " +"it is a fatal error if the initialization fails." msgstr "" -#: ../../c-api/init.rst:359 ../../c-api/init.rst:373 +#: ../../c-api/init.rst:372 ../../c-api/init.rst:386 msgid "" -"Use the :c:func:`Py_InitializeFromConfig` function to customize the :ref:" -"`Python Initialization Configuration `." +"Use :c:func:`Py_InitializeFromConfig` to customize the :ref:`Python " +"Initialization Configuration `." msgstr "" -#: ../../c-api/init.rst:363 +#: ../../c-api/init.rst:376 msgid "" "On Windows, changes the console mode from ``O_TEXT`` to ``O_BINARY``, which " "will also affect non-Python uses of the console using the C Runtime." @@ -613,18 +650,28 @@ msgstr "" "が、これはその C ランタイムを使っているコンソールでの Python 以外の使い勝手に" "も影響を及ぼします。" -#: ../../c-api/init.rst:369 +#: ../../c-api/init.rst:382 msgid "" "This function works like :c:func:`Py_Initialize` if *initsigs* is ``1``. If " "*initsigs* is ``0``, it skips initialization registration of signal " -"handlers, which might be useful when Python is embedded." +"handlers, which may be useful when CPython is embedded as part of a larger " +"application." +msgstr "" + +#: ../../c-api/init.rst:392 +msgid "" +"Initialize Python from *config* configuration, as described in :ref:`init-" +"from-config`." +msgstr "" + +#: ../../c-api/init.rst:395 +msgid "" +"See the :ref:`init-config` section for details on pre-initializing the " +"interpreter, populating the runtime configuration structure, and querying " +"the returned status structure." msgstr "" -"*initsigs* に ``1`` を指定した場合、この関数は :c:func:`Py_Initialize` と同じ" -"ように動作します。\n" -"*initsigs* に ``0`` を指定した場合、初期化時のシグナルハンドラの登録をスキッ" -"プすることができ、これは Python の埋め込みで便利でしょう。" -#: ../../c-api/init.rst:379 +#: ../../c-api/init.rst:402 msgid "" "Return true (nonzero) when the Python interpreter has been initialized, " "false (zero) if not. After :c:func:`Py_FinalizeEx` is called, this returns " @@ -634,13 +681,13 @@ msgstr "" "します。:c:func:`Py_FinalizeEx` を呼び出した後は、:c:func:`Py_Initialize` を" "再び呼び出すまで、この関数は偽を返します。" -#: ../../c-api/init.rst:386 +#: ../../c-api/init.rst:409 msgid "" "Return true (non-zero) if the main Python interpreter is :term:`shutting " "down `. Return false (zero) otherwise." msgstr "" -#: ../../c-api/init.rst:394 +#: ../../c-api/init.rst:417 msgid "" "Undo all initializations made by :c:func:`Py_Initialize` and subsequent use " "of Python/C API functions, and destroy all sub-interpreters (see :c:func:" @@ -650,7 +697,7 @@ msgid "" "second time (without calling :c:func:`Py_Initialize` again first)." msgstr "" -#: ../../c-api/init.rst:401 +#: ../../c-api/init.rst:424 msgid "" "Since this is the reverse of :c:func:`Py_Initialize`, it should be called in " "the same thread with the same interpreter active. That means the main " @@ -658,13 +705,13 @@ msgid "" "`Py_RunMain` is running." msgstr "" -#: ../../c-api/init.rst:406 +#: ../../c-api/init.rst:429 msgid "" "Normally the return value is ``0``. If there were errors during finalization " "(flushing buffered data), ``-1`` is returned." msgstr "" -#: ../../c-api/init.rst:410 +#: ../../c-api/init.rst:433 msgid "" "This function is provided for a number of reasons. An embedding application " "might want to restart Python without having to restart the application " @@ -682,7 +729,7 @@ msgstr "" "ン内で起きているメモリリークを追跡する際に、開発者は Python が確保したメモリ" "をアプリケーションの終了前に解放させたいと思う場合もあります。" -#: ../../c-api/init.rst:418 +#: ../../c-api/init.rst:441 msgid "" "**Bugs and caveats:** The destruction of modules and objects in modules is " "done in random order; this may cause destructors (:meth:`~object.__del__` " @@ -697,7 +744,7 @@ msgid "" "more than once." msgstr "" -#: ../../c-api/init.rst:429 +#: ../../c-api/init.rst:452 msgid "" "Raises an :ref:`auditing event ` ``cpython." "_PySys_ClearAuditHooks`` with no arguments." @@ -705,7 +752,7 @@ msgstr "" "引数無しで :ref:`監査イベント ` ``cpython._PySys_ClearAuditHooks`` " "を送出します。 " -#: ../../c-api/init.rst:435 +#: ../../c-api/init.rst:459 msgid "" "This is a backwards-compatible version of :c:func:`Py_FinalizeEx` that " "disregards the return value." @@ -713,18 +760,148 @@ msgstr "" "この関数は :c:func:`Py_FinalizeEx` の後方互換性バージョンで、戻り値がありませ" "ん。" -#: ../../c-api/init.rst:440 +#: ../../c-api/init.rst:465 +msgid "" +"Similar to :c:func:`Py_Main` but *argv* is an array of bytes strings, " +"allowing the calling application to delegate the text decoding step to the " +"CPython runtime." +msgstr "" + +#: ../../c-api/init.rst:474 +msgid "" +"The main program for the standard interpreter, encapsulating a full " +"initialization/finalization cycle, as well as additional behaviour to " +"implement reading configurations settings from the environment and command " +"line, and then executing ``__main__`` in accordance with :ref:`using-on-" +"cmdline`." +msgstr "" + +#: ../../c-api/init.rst:480 +msgid "" +"This is made available for programs which wish to support the full CPython " +"command line interface, rather than just embedding a Python runtime in a " +"larger application." +msgstr "" + +#: ../../c-api/init.rst:484 +msgid "" +"The *argc* and *argv* parameters are similar to those which are passed to a " +"C program's :c:func:`main` function, except that the *argv* entries are " +"first converted to ``wchar_t`` using :c:func:`Py_DecodeLocale`. It is also " +"important to note that the argument list entries may be modified to point to " +"strings other than those passed in (however, the contents of the strings " +"pointed to by the argument list are not modified)." +msgstr "" + +#: ../../c-api/init.rst:491 +msgid "" +"The return value will be ``0`` if the interpreter exits normally (i.e., " +"without an exception), ``1`` if the interpreter exits due to an exception, " +"or ``2`` if the argument list does not represent a valid Python command line." +msgstr "" + +#: ../../c-api/init.rst:496 +msgid "" +"Note that if an otherwise unhandled :exc:`SystemExit` is raised, this " +"function will not return ``1``, but exit the process, as long as " +"``Py_InspectFlag`` is not set. If ``Py_InspectFlag`` is set, execution will " +"drop into the interactive Python prompt, at which point a second otherwise " +"unhandled :exc:`SystemExit` will still exit the process, while any other " +"means of exiting will set the return value as described above." +msgstr "" + +#: ../../c-api/init.rst:503 +msgid "" +"In terms of the CPython runtime configuration APIs documented in the :ref:" +"`runtime configuration ` section (and without accounting for " +"error handling), ``Py_Main`` is approximately equivalent to::" +msgstr "" + +#: ../../c-api/init.rst:507 +msgid "" +"PyConfig config;\n" +"PyConfig_InitPythonConfig(&config);\n" +"PyConfig_SetArgv(&config, argc, argv);\n" +"Py_InitializeFromConfig(&config);\n" +"PyConfig_Clear(&config);\n" +"\n" +"Py_RunMain();" +msgstr "" + +#: ../../c-api/init.rst:515 +msgid "" +"In normal usage, an embedding application will call this function *instead* " +"of calling :c:func:`Py_Initialize`, :c:func:`Py_InitializeEx` or :c:func:" +"`Py_InitializeFromConfig` directly, and all settings will be applied as " +"described elsewhere in this documentation. If this function is instead " +"called *after* a preceding runtime initialization API call, then exactly " +"which environmental and command line configuration settings will be updated " +"is version dependent (as it depends on which settings correctly support " +"being modified after they have already been set once when the runtime was " +"first initialized)." +msgstr "" + +#: ../../c-api/init.rst:528 +msgid "Executes the main module in a fully configured CPython runtime." +msgstr "" + +#: ../../c-api/init.rst:530 +msgid "" +"Executes the command (:c:member:`PyConfig.run_command`), the script (:c:" +"member:`PyConfig.run_filename`) or the module (:c:member:`PyConfig." +"run_module`) specified on the command line or in the configuration. If none " +"of these values are set, runs the interactive Python prompt (REPL) using the " +"``__main__`` module's global namespace." +msgstr "" + +#: ../../c-api/init.rst:536 +msgid "" +"If :c:member:`PyConfig.inspect` is not set (the default), the return value " +"will be ``0`` if the interpreter exits normally (that is, without raising an " +"exception), or ``1`` if the interpreter exits due to an exception. If an " +"otherwise unhandled :exc:`SystemExit` is raised, the function will " +"immediately exit the process instead of returning ``1``." +msgstr "" + +#: ../../c-api/init.rst:542 +msgid "" +"If :c:member:`PyConfig.inspect` is set (such as when the :option:`-i` option " +"is used), rather than returning when the interpreter exits, execution will " +"instead resume in an interactive Python prompt (REPL) using the ``__main__`` " +"module's global namespace. If the interpreter exited with an exception, it " +"is immediately raised in the REPL session. The function return value is then " +"determined by the way the *REPL session* terminates: returning ``0`` if the " +"session terminates without raising an unhandled exception, exiting " +"immediately for an unhandled :exc:`SystemExit`, and returning ``1`` for any " +"other unhandled exception." +msgstr "" + +#: ../../c-api/init.rst:552 +msgid "" +"This function always finalizes the Python interpreter regardless of whether " +"it returns a value or immediately exits the process due to an unhandled :exc:" +"`SystemExit` exception." +msgstr "" + +#: ../../c-api/init.rst:556 +msgid "" +"See :ref:`Python Configuration ` for an example of a " +"customized Python that always runs in isolated mode using :c:func:" +"`Py_RunMain`." +msgstr "" + +#: ../../c-api/init.rst:562 msgid "Process-wide parameters" msgstr "プロセスワイドのパラメータ" -#: ../../c-api/init.rst:450 +#: ../../c-api/init.rst:572 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "program_name` should be used instead, see :ref:`Python Initialization " "Configuration `." msgstr "" -#: ../../c-api/init.rst:454 +#: ../../c-api/init.rst:576 msgid "" "This function should be called before :c:func:`Py_Initialize` is called for " "the first time, if it is called at all. It tells the interpreter the value " @@ -747,8 +924,8 @@ msgstr "" "はプログラムの実行中に変更してはなりません。 Python インタプリタ内のコード" "で、この記憶領域の内容を変更するものは一切ありません。" -#: ../../c-api/init.rst:465 ../../c-api/init.rst:704 ../../c-api/init.rst:740 -#: ../../c-api/init.rst:766 +#: ../../c-api/init.rst:587 ../../c-api/init.rst:826 ../../c-api/init.rst:862 +#: ../../c-api/init.rst:888 msgid "" "Use :c:func:`Py_DecodeLocale` to decode a bytes string to get a :c:expr:" "`wchar_*` string." @@ -756,30 +933,30 @@ msgstr "" "バイト文字列を :c:expr:`wchar_*` 文字列にデコードするには :c:func:" "`Py_DecodeLocale` を使ってください。" -#: ../../c-api/init.rst:473 +#: ../../c-api/init.rst:595 msgid "" "Return the program name set with :c:member:`PyConfig.program_name`, or the " "default. The returned string points into static storage; the caller should " "not modify its value." msgstr "" -#: ../../c-api/init.rst:477 ../../c-api/init.rst:499 ../../c-api/init.rst:543 -#: ../../c-api/init.rst:564 ../../c-api/init.rst:590 ../../c-api/init.rst:778 +#: ../../c-api/init.rst:599 ../../c-api/init.rst:621 ../../c-api/init.rst:665 +#: ../../c-api/init.rst:686 ../../c-api/init.rst:712 ../../c-api/init.rst:900 msgid "" "This function should not be called before :c:func:`Py_Initialize`, otherwise " "it returns ``NULL``." msgstr "" -#: ../../c-api/init.rst:480 ../../c-api/init.rst:502 ../../c-api/init.rst:546 -#: ../../c-api/init.rst:567 ../../c-api/init.rst:595 ../../c-api/init.rst:781 +#: ../../c-api/init.rst:602 ../../c-api/init.rst:624 ../../c-api/init.rst:668 +#: ../../c-api/init.rst:689 ../../c-api/init.rst:717 ../../c-api/init.rst:903 msgid "It now returns ``NULL`` if called before :c:func:`Py_Initialize`." msgstr "" -#: ../../c-api/init.rst:483 ../../c-api/init.rst:570 +#: ../../c-api/init.rst:605 ../../c-api/init.rst:692 msgid "Get :data:`sys.executable` instead." msgstr "" -#: ../../c-api/init.rst:489 +#: ../../c-api/init.rst:611 msgid "" "Return the *prefix* for installed platform-independent files. This is " "derived through a number of complicated rules from the program name set " @@ -793,11 +970,11 @@ msgid "" "also the next function." msgstr "" -#: ../../c-api/init.rst:505 +#: ../../c-api/init.rst:627 msgid "Get :data:`sys.prefix` instead." msgstr "" -#: ../../c-api/init.rst:511 +#: ../../c-api/init.rst:633 msgid "" "Return the *exec-prefix* for installed platform-*dependent* files. This is " "derived through a number of complicated rules from the program name set " @@ -811,7 +988,7 @@ msgid "" "on Unix." msgstr "" -#: ../../c-api/init.rst:521 +#: ../../c-api/init.rst:643 msgid "" "Background: The exec-prefix differs from the prefix when platform dependent " "files (such as executables and shared libraries) are installed in a " @@ -825,7 +1002,7 @@ msgstr "" "usr/local` に収められる一方、プラットフォーム依存のファイルは :file:`/usr/" "local/plat` サブツリーに収められます。" -#: ../../c-api/init.rst:527 +#: ../../c-api/init.rst:649 msgid "" "Generally speaking, a platform is a combination of hardware and software " "families, e.g. Sparc machines running the Solaris 2.x operating system are " @@ -850,7 +1027,7 @@ msgstr "" "ムに依存しないので注意してください (ただし、どのバージョンの Python でコンパ" "イルされたかには依存します!)。" -#: ../../c-api/init.rst:538 +#: ../../c-api/init.rst:660 msgid "" "System administrators will know how to configure the :program:`mount` or :" "program:`automount` programs to share :file:`/usr/local` between platforms " @@ -862,11 +1039,11 @@ msgstr "" "に置き、プラットフォーム間で :file:`/usr/local` を共有するための設定方法を" "知っているでしょう。" -#: ../../c-api/init.rst:549 +#: ../../c-api/init.rst:671 msgid "Get :data:`sys.exec_prefix` instead." msgstr "" -#: ../../c-api/init.rst:558 +#: ../../c-api/init.rst:680 msgid "" "Return the full program name of the Python executable; this is computed as " "a side-effect of deriving the default module search path from the program " @@ -875,7 +1052,7 @@ msgid "" "available to Python code as ``sys.executable``." msgstr "" -#: ../../c-api/init.rst:580 +#: ../../c-api/init.rst:702 msgid "" "Return the default module search path; this is computed from the program " "name (set by :c:member:`PyConfig.program_name`) and some environment " @@ -888,11 +1065,11 @@ msgid "" "for loading modules." msgstr "" -#: ../../c-api/init.rst:598 +#: ../../c-api/init.rst:720 msgid "Get :data:`sys.path` instead." msgstr "" -#: ../../c-api/init.rst:604 +#: ../../c-api/init.rst:726 msgid "" "Return the version of this Python interpreter. This is a string that looks " "something like ::" @@ -900,11 +1077,11 @@ msgstr "" "Python インタプリタのバージョンを返します。バージョンは、次のような形式の文字" "列です ::" -#: ../../c-api/init.rst:607 +#: ../../c-api/init.rst:729 msgid "\"3.0a5+ (py3k:63103M, May 12 2008, 00:53:55) \\n[GCC 4.2.3]\"" msgstr "" -#: ../../c-api/init.rst:611 +#: ../../c-api/init.rst:733 msgid "" "The first word (up to the first space character) is the current Python " "version; the first characters are the major and minor version separated by a " @@ -918,11 +1095,11 @@ msgstr "" "変更できません。この値は Python コードからは :data:`sys.version` として利用で" "きます。" -#: ../../c-api/init.rst:616 +#: ../../c-api/init.rst:738 msgid "See also the :c:var:`Py_Version` constant." msgstr "" -#: ../../c-api/init.rst:623 +#: ../../c-api/init.rst:745 msgid "" "Return the platform identifier for the current platform. On Unix, this is " "formed from the \"official\" name of the operating system, converted to " @@ -940,18 +1117,18 @@ msgstr "" "す; 関数の呼び出し側はこの値を変更できません。この値は Python コードからは " "``sys.platform`` として利用できます。" -#: ../../c-api/init.rst:634 +#: ../../c-api/init.rst:756 msgid "" "Return the official copyright string for the current Python version, for " "example" msgstr "" "現在の Python バージョンに対する公式の著作権表示文字列を返します。例えば" -#: ../../c-api/init.rst:636 +#: ../../c-api/init.rst:758 msgid "``'Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam'``" msgstr "``'Copyright 1991-1995 Stichting Mathematisch Centrum, Amsterdam'``" -#: ../../c-api/init.rst:640 +#: ../../c-api/init.rst:762 msgid "" "The returned string points into static storage; the caller should not modify " "its value. The value is available to Python code as ``sys.copyright``." @@ -960,7 +1137,7 @@ msgstr "" "を変更できません。この値は Python コードからは ``sys.copyright`` として利用で" "きます。" -#: ../../c-api/init.rst:646 +#: ../../c-api/init.rst:768 msgid "" "Return an indication of the compiler used to build the current Python " "version, in square brackets, for example::" @@ -968,11 +1145,11 @@ msgstr "" "現在使っているバージョンの Python をビルドする際に用いたコンパイラを示す文字" "列を、角括弧で囲った文字列を返します。例えば::" -#: ../../c-api/init.rst:649 +#: ../../c-api/init.rst:771 msgid "\"[GCC 2.7.2.2]\"" msgstr "" -#: ../../c-api/init.rst:653 ../../c-api/init.rst:667 +#: ../../c-api/init.rst:775 ../../c-api/init.rst:789 msgid "" "The returned string points into static storage; the caller should not modify " "its value. The value is available to Python code as part of the variable " @@ -982,7 +1159,7 @@ msgstr "" "を変更できません。この値は Python コードからは ``sys.version`` の一部として取" "り出せます。" -#: ../../c-api/init.rst:660 +#: ../../c-api/init.rst:782 msgid "" "Return information about the sequence number and build date and time of the " "current Python interpreter instance, for example ::" @@ -990,11 +1167,11 @@ msgstr "" "現在使っている Python インタプリタインスタンスの、シーケンス番号とビルド日時" "に関する情報を返します。例えば ::" -#: ../../c-api/init.rst:663 +#: ../../c-api/init.rst:785 msgid "\"#67, Aug 1 1997, 22:34:28\"" msgstr "" -#: ../../c-api/init.rst:679 +#: ../../c-api/init.rst:801 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "argv`, :c:member:`PyConfig.parse_argv` and :c:member:`PyConfig.safe_path` " @@ -1002,7 +1179,7 @@ msgid "" "config>`." msgstr "" -#: ../../c-api/init.rst:684 +#: ../../c-api/init.rst:806 msgid "" "Set :data:`sys.argv` based on *argc* and *argv*. These parameters are " "similar to those passed to the program's :c:func:`main` function with the " @@ -1019,7 +1196,7 @@ msgstr "" "の最初の要素は空文字列にしてもかまいません。この関数が :data:`sys.argv` の初" "期化に失敗した場合、致命的エラーを :c:func:`Py_FatalError` で知らせます。" -#: ../../c-api/init.rst:692 +#: ../../c-api/init.rst:814 msgid "" "If *updatepath* is zero, this is all the function does. If *updatepath* is " "non-zero, the function also modifies :data:`sys.path` according to the " @@ -1029,7 +1206,7 @@ msgstr "" "*updatepath* が 0 でない場合、この関数は :data:`sys.path` を以下のアルゴリズ" "ムに基づいて修正します:" -#: ../../c-api/init.rst:696 +#: ../../c-api/init.rst:818 msgid "" "If the name of an existing script is passed in ``argv[0]``, the absolute " "path of the directory where the script is located is prepended to :data:`sys." @@ -1038,7 +1215,7 @@ msgstr "" "存在するスクリプトの名前が ``argv[0]`` に渡された場合、そのスクリプトがある場" "所の絶対パスを :data:`sys.path` の先頭に追加します。" -#: ../../c-api/init.rst:699 +#: ../../c-api/init.rst:821 msgid "" "Otherwise (that is, if *argc* is ``0`` or ``argv[0]`` doesn't point to an " "existing file name), an empty string is prepended to :data:`sys.path`, which " @@ -1048,20 +1225,20 @@ msgstr "" "指していない場合)、 :data:`sys.path` の先頭に空の文字列を追加します。\n" "これは現在の作業ディレクトリ (``\".\"``) を先頭に追加するのと同じです。" -#: ../../c-api/init.rst:707 ../../c-api/init.rst:743 +#: ../../c-api/init.rst:829 ../../c-api/init.rst:865 msgid "" "See also :c:member:`PyConfig.orig_argv` and :c:member:`PyConfig.argv` " "members of the :ref:`Python Initialization Configuration `." msgstr "" -#: ../../c-api/init.rst:711 +#: ../../c-api/init.rst:833 msgid "" "It is recommended that applications embedding the Python interpreter for " "purposes other than executing a single script pass ``0`` as *updatepath*, " "and update :data:`sys.path` themselves if desired. See :cve:`2008-5983`." msgstr "" -#: ../../c-api/init.rst:716 +#: ../../c-api/init.rst:838 msgid "" "On versions before 3.1.3, you can achieve the same effect by manually " "popping the first :data:`sys.path` element after having called :c:func:" @@ -1071,18 +1248,18 @@ msgstr "" "に :data:`sys.path` の先頭の要素を取り出すことで、同じ効果が得られます。例え" "ばこのように使います::" -#: ../../c-api/init.rst:720 +#: ../../c-api/init.rst:842 msgid "PyRun_SimpleString(\"import sys; sys.path.pop(0)\\n\");" msgstr "" -#: ../../c-api/init.rst:732 +#: ../../c-api/init.rst:854 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "argv` and :c:member:`PyConfig.parse_argv` should be used instead, see :ref:" "`Python Initialization Configuration `." msgstr "" -#: ../../c-api/init.rst:736 +#: ../../c-api/init.rst:858 msgid "" "This function works like :c:func:`PySys_SetArgvEx` with *updatepath* set to " "``1`` unless the :program:`python` interpreter was started with the :option:" @@ -1092,18 +1269,18 @@ msgstr "" "行されている場合を除き :c:func:`PySys_SetArgvEx` の *updatepath* に ``1`` を" "設定したのと同じように動作します。" -#: ../../c-api/init.rst:746 +#: ../../c-api/init.rst:868 msgid "The *updatepath* value depends on :option:`-I`." msgstr "*updatepath* の値は :option:`-I` オプションに依存します。" -#: ../../c-api/init.rst:753 +#: ../../c-api/init.rst:875 msgid "" "This API is kept for backward compatibility: setting :c:member:`PyConfig." "home` should be used instead, see :ref:`Python Initialization Configuration " "`." msgstr "" -#: ../../c-api/init.rst:757 +#: ../../c-api/init.rst:879 msgid "" "Set the default \"home\" directory, that is, the location of the standard " "Python libraries. See :envvar:`PYTHONHOME` for the meaning of the argument " @@ -1112,7 +1289,7 @@ msgstr "" "Python の標準ライブラリがある、デフォルトの \"home\" ディレクトリを設定しま" "す。引数の文字列の意味については :envvar:`PYTHONHOME` を参照してください。" -#: ../../c-api/init.rst:761 +#: ../../c-api/init.rst:883 msgid "" "The argument should point to a zero-terminated character string in static " "storage whose contents will not change for the duration of the program's " @@ -1123,26 +1300,26 @@ msgstr "" "終端の文字列であるべきです。Python インタプリタはこのストレージの内容を変更し" "ません。" -#: ../../c-api/init.rst:774 +#: ../../c-api/init.rst:896 msgid "" "Return the default \"home\", that is, the value set by :c:member:`PyConfig." "home`, or the value of the :envvar:`PYTHONHOME` environment variable if it " "is set." msgstr "" -#: ../../c-api/init.rst:784 +#: ../../c-api/init.rst:906 msgid "" "Get :c:member:`PyConfig.home` or :envvar:`PYTHONHOME` environment variable " "instead." msgstr "" -#: ../../c-api/init.rst:792 +#: ../../c-api/init.rst:914 msgid "Thread State and the Global Interpreter Lock" msgstr "" "スレッド状態 (thread state) とグローバルインタプリタロック (global " "interpreter lock)" -#: ../../c-api/init.rst:799 +#: ../../c-api/init.rst:921 msgid "" "The Python interpreter is not fully thread-safe. In order to support multi-" "threaded Python programs, there's a global lock, called the :term:`global " @@ -1163,7 +1340,7 @@ msgstr "" "メントすると、結果的に参照カウントは二回でなく一回だけしかインクリメントされ" "ないかもしれません。" -#: ../../c-api/init.rst:809 +#: ../../c-api/init.rst:931 msgid "" "Therefore, the rule exists that only the thread that has acquired the :term:" "`GIL` may operate on Python objects or call Python/C API functions. In order " @@ -1179,7 +1356,7 @@ msgstr "" "る I/O 操作の付近でも解放・獲得され、 I/O を要求するスレッドが I/O 操作の完了" "を待つ間、他のスレッドが動作できるようにしています。" -#: ../../c-api/init.rst:819 +#: ../../c-api/init.rst:941 msgid "" "The Python interpreter keeps some thread-specific bookkeeping information " "inside a data structure called :c:type:`PyThreadState`. There's also one " @@ -1191,18 +1368,18 @@ msgstr "" "`PyThreadState` を指すポインタを1つ持ちます。このグローバル変数は :c:func:" "`PyThreadState_Get` を使って取得できます。" -#: ../../c-api/init.rst:825 +#: ../../c-api/init.rst:947 msgid "Releasing the GIL from extension code" msgstr "拡張コード内で GIL を解放する" -#: ../../c-api/init.rst:827 +#: ../../c-api/init.rst:949 msgid "" "Most extension code manipulating the :term:`GIL` has the following simple " "structure::" msgstr "" ":term:`GIL` を操作するほとんどのコードは、次のような単純な構造になります::" -#: ../../c-api/init.rst:830 +#: ../../c-api/init.rst:952 msgid "" "Save the thread state in a local variable.\n" "Release the global interpreter lock.\n" @@ -1211,20 +1388,20 @@ msgid "" "Restore the thread state from the local variable." msgstr "" -#: ../../c-api/init.rst:836 +#: ../../c-api/init.rst:958 msgid "This is so common that a pair of macros exists to simplify it::" msgstr "" "この構造は非常に一般的なので、作業を単純にするために2つのマクロが用意されてい" "ます::" -#: ../../c-api/init.rst:838 +#: ../../c-api/init.rst:960 msgid "" "Py_BEGIN_ALLOW_THREADS\n" "... Do some blocking I/O operation ...\n" "Py_END_ALLOW_THREADS" msgstr "" -#: ../../c-api/init.rst:846 +#: ../../c-api/init.rst:968 msgid "" "The :c:macro:`Py_BEGIN_ALLOW_THREADS` macro opens a new block and declares a " "hidden local variable; the :c:macro:`Py_END_ALLOW_THREADS` macro closes the " @@ -1233,11 +1410,11 @@ msgstr "" ":c:macro:`Py_BEGIN_ALLOW_THREADS` マクロは新たなブロックを開始し、隠しローカ" "ル変数を宣言します; :c:macro:`Py_END_ALLOW_THREADS` はブロックを閉じます。" -#: ../../c-api/init.rst:850 +#: ../../c-api/init.rst:972 msgid "The block above expands to the following code::" msgstr "上のブロックは次のコードに展開されます::" -#: ../../c-api/init.rst:852 +#: ../../c-api/init.rst:974 msgid "" "PyThreadState *_save;\n" "\n" @@ -1246,7 +1423,7 @@ msgid "" "PyEval_RestoreThread(_save);" msgstr "" -#: ../../c-api/init.rst:862 +#: ../../c-api/init.rst:984 msgid "" "Here is how these functions work: the global interpreter lock is used to " "protect the pointer to the current thread state. When releasing the lock " @@ -1264,7 +1441,7 @@ msgstr "" "には、グローバル変数にスレッド状態ポインタを保存する前にロックを獲得しておか" "なければなりません。" -#: ../../c-api/init.rst:871 +#: ../../c-api/init.rst:993 msgid "" "Calling system I/O functions is the most common use case for releasing the " "GIL, but it can also be useful before calling long-running computations " @@ -1279,11 +1456,11 @@ msgstr "" "`zlib` や :mod:`hashlib` モジュールは圧縮やハッシュ計算の前に GIL を解放しま" "す。" -#: ../../c-api/init.rst:882 +#: ../../c-api/init.rst:1004 msgid "Non-Python created threads" msgstr "Python 以外で作られたスレッド" -#: ../../c-api/init.rst:884 +#: ../../c-api/init.rst:1006 msgid "" "When threads are created using the dedicated Python APIs (such as the :mod:" "`threading` module), a thread state is automatically associated to them and " @@ -1298,7 +1475,7 @@ msgstr "" "合、そのスレッドには GIL がなく、スレッド状態データ構造体もないことに注意する" "必要があります。" -#: ../../c-api/init.rst:891 +#: ../../c-api/init.rst:1013 msgid "" "If you need to call Python code from these threads (often this will be part " "of a callback API provided by the aforementioned third-party library), you " @@ -1315,7 +1492,7 @@ msgstr "" "終えたら、スレッド状態ポインタをリセットして、ロックを解放し、最後にスレッド" "状態データ構造体のメモリを解放しなければなりません。" -#: ../../c-api/init.rst:899 +#: ../../c-api/init.rst:1021 msgid "" "The :c:func:`PyGILState_Ensure` and :c:func:`PyGILState_Release` functions " "do all of the above automatically. The typical idiom for calling into " @@ -1325,7 +1502,7 @@ msgstr "" "的に行います。 Cのスレッドから Python を呼び出す典型的な方法は以下のとおりで" "す::" -#: ../../c-api/init.rst:903 +#: ../../c-api/init.rst:1025 msgid "" "PyGILState_STATE gstate;\n" "gstate = PyGILState_Ensure();\n" @@ -1338,7 +1515,7 @@ msgid "" "PyGILState_Release(gstate);" msgstr "" -#: ../../c-api/init.rst:913 +#: ../../c-api/init.rst:1035 msgid "" "Note that the ``PyGILState_*`` functions assume there is only one global " "interpreter (created automatically by :c:func:`Py_Initialize`). Python " @@ -1352,11 +1529,11 @@ msgstr "" "ることに変わりはありませんが、複数インタプリタと ``PyGILState_*`` API を混ぜ" "て使うことはサポートされていません。" -#: ../../c-api/init.rst:923 +#: ../../c-api/init.rst:1045 msgid "Cautions about fork()" msgstr "" -#: ../../c-api/init.rst:925 +#: ../../c-api/init.rst:1047 msgid "" "Another important thing to note about threads is their behaviour in the face " "of the C :c:func:`fork` call. On most systems with :c:func:`fork`, after a " @@ -1365,7 +1542,7 @@ msgid "" "CPython's runtime." msgstr "" -#: ../../c-api/init.rst:931 +#: ../../c-api/init.rst:1053 msgid "" "The fact that only the \"current\" thread remains means any locks held by " "other threads will never be released. Python solves this for :func:`os.fork` " @@ -1382,7 +1559,7 @@ msgid "" "locks, but is not always able to." msgstr "" -#: ../../c-api/init.rst:946 +#: ../../c-api/init.rst:1068 msgid "" "The fact that all other threads go away also means that CPython's runtime " "state there must be cleaned up properly, which :func:`os.fork` does. This " @@ -1395,11 +1572,11 @@ msgid "" "called immediately after." msgstr "" -#: ../../c-api/init.rst:959 +#: ../../c-api/init.rst:1081 msgid "High-level API" msgstr "高レベルAPI" -#: ../../c-api/init.rst:961 +#: ../../c-api/init.rst:1083 msgid "" "These are the most commonly used types and functions when writing C " "extension code, or when embedding the Python interpreter:" @@ -1407,7 +1584,7 @@ msgstr "" "C拡張を書いたりPythonインタプリタを埋め込むときに最も一般的に使われる型や関数" "は次のとおりです:" -#: ../../c-api/init.rst:966 +#: ../../c-api/init.rst:1088 msgid "" "This data structure represents the state shared by a number of cooperating " "threads. Threads belonging to the same interpreter share their module " @@ -1419,7 +1596,7 @@ msgstr "" "内部的な情報を共有しています。この構造体には公開 (public) のメンバはありませ" "ん。" -#: ../../c-api/init.rst:971 +#: ../../c-api/init.rst:1093 msgid "" "Threads belonging to different interpreters initially share nothing, except " "process state like available memory, open file descriptors and such. The " @@ -1431,30 +1608,30 @@ msgstr "" "いません。GILもまた、スレッドがどのインタプリタに属しているかに関わらずすべて" "のスレッドで共有されています。" -#: ../../c-api/init.rst:979 +#: ../../c-api/init.rst:1101 msgid "" "This data structure represents the state of a single thread. The only " "public data member is:" msgstr "" -#: ../../c-api/init.rst:984 +#: ../../c-api/init.rst:1106 msgid "This thread's interpreter state." msgstr "" -#: ../../c-api/init.rst:995 +#: ../../c-api/init.rst:1117 msgid "Deprecated function which does nothing." msgstr "" -#: ../../c-api/init.rst:997 +#: ../../c-api/init.rst:1119 msgid "" "In Python 3.6 and older, this function created the GIL if it didn't exist." msgstr "" -#: ../../c-api/init.rst:999 +#: ../../c-api/init.rst:1121 msgid "The function now does nothing." msgstr "" -#: ../../c-api/init.rst:1002 +#: ../../c-api/init.rst:1124 msgid "" "This function is now called by :c:func:`Py_Initialize()`, so you don't have " "to call it yourself anymore." @@ -1462,14 +1639,14 @@ msgstr "" "この関数は :c:func:`Py_Initialize()` から呼び出されるようになり、わざわざ呼び" "出す必要はもう無くなりました。" -#: ../../c-api/init.rst:1006 +#: ../../c-api/init.rst:1128 msgid "" "This function cannot be called before :c:func:`Py_Initialize()` anymore." msgstr "" "この関数は :c:func:`Py_Initialize()` より前に呼び出すことができなくなりまし" "た。" -#: ../../c-api/init.rst:1016 +#: ../../c-api/init.rst:1138 msgid "" "Release the global interpreter lock (if it has been created) and reset the " "thread state to ``NULL``, returning the previous thread state (which is not " @@ -1481,7 +1658,7 @@ msgstr "" "ロックがすでに生成されている場合、現在のスレッドがロックを獲得していなければ" "なりません。" -#: ../../c-api/init.rst:1024 +#: ../../c-api/init.rst:1146 msgid "" "Acquire the global interpreter lock (if it has been created) and set the " "thread state to *tstate*, which must not be ``NULL``. If the lock has been " @@ -1493,8 +1670,8 @@ msgstr "" "この関数を呼び出したスレッドがすでにロックを獲得している場合、デッドロックに" "陥ります。" -#: ../../c-api/init.rst:1030 ../../c-api/init.rst:1089 -#: ../../c-api/init.rst:1371 +#: ../../c-api/init.rst:1152 ../../c-api/init.rst:1211 +#: ../../c-api/init.rst:1493 msgid "" "Calling this function from a thread when the runtime is finalizing will " "terminate the thread, even if the thread was not created by Python. You can " @@ -1503,7 +1680,7 @@ msgid "" "avoid unwanted termination." msgstr "" -#: ../../c-api/init.rst:1038 +#: ../../c-api/init.rst:1160 msgid "" "Return the current thread state. The global interpreter lock must be held. " "When the current thread state is ``NULL``, this issues a fatal error (so " @@ -1513,24 +1690,24 @@ msgstr "" "レッド状態が ``NULL`` なら、(呼び出し側が ``NULL`` チェックをしなくてすむよう" "に) この関数は致命的エラーを起こすようになっています。" -#: ../../c-api/init.rst:1042 +#: ../../c-api/init.rst:1164 msgid "See also :c:func:`PyThreadState_GetUnchecked`." msgstr "" -#: ../../c-api/init.rst:1047 +#: ../../c-api/init.rst:1169 msgid "" "Similar to :c:func:`PyThreadState_Get`, but don't kill the process with a " "fatal error if it is NULL. The caller is responsible to check if the result " "is NULL." msgstr "" -#: ../../c-api/init.rst:1051 +#: ../../c-api/init.rst:1173 msgid "" "In Python 3.5 to 3.12, the function was private and known as " "``_PyThreadState_UncheckedGet()``." msgstr "" -#: ../../c-api/init.rst:1058 +#: ../../c-api/init.rst:1180 msgid "" "Swap the current thread state with the thread state given by the argument " "*tstate*, which may be ``NULL``. The global interpreter lock must be held " @@ -1539,7 +1716,7 @@ msgstr "" "現在のスレッド状態を *tstate* に指定したスレッド状態と入れ変えます。*tstate* " "は ``NULL`` の場合があります。GIL を保持していなければならず、解放しません。" -#: ../../c-api/init.rst:1063 +#: ../../c-api/init.rst:1185 msgid "" "The following functions use thread-local storage, and are not compatible " "with sub-interpreters:" @@ -1547,7 +1724,7 @@ msgstr "" "以下の関数はスレッドローカルストレージを利用していて、サブインタプリタとの互" "換性がありません:" -#: ../../c-api/init.rst:1068 +#: ../../c-api/init.rst:1190 msgid "" "Ensure that the current thread is ready to call the Python C API regardless " "of the current state of Python, or of the global interpreter lock. This may " @@ -1568,7 +1745,7 @@ msgstr "" "ば、通常の :c:macro:`Py_BEGIN_ALLOW_THREADS` マクロと :c:macro:" "`Py_END_ALLOW_THREADS` は使用することができます。" -#: ../../c-api/init.rst:1078 +#: ../../c-api/init.rst:1200 msgid "" "The return value is an opaque \"handle\" to the thread state when :c:func:" "`PyGILState_Ensure` was called, and must be passed to :c:func:" @@ -1583,7 +1760,7 @@ msgstr "" "* - それぞれの :c:func:`PyGILState_Ensure` 呼び出しでハンドルを保存し、対応す" "る :c:func:`PyGILState_Release` 呼び出しで渡してください。" -#: ../../c-api/init.rst:1085 +#: ../../c-api/init.rst:1207 msgid "" "When the function returns, the current thread will hold the GIL and be able " "to call arbitrary Python code. Failure is a fatal error." @@ -1591,7 +1768,7 @@ msgstr "" "関数から復帰したとき、実行中のスレッドはGILを所有していて、任意の Python コー" "ドを実行できます。処理の失敗は致命的なエラーです。" -#: ../../c-api/init.rst:1097 +#: ../../c-api/init.rst:1219 msgid "" "Release any resources previously acquired. After this call, Python's state " "will be the same as it was prior to the corresponding :c:func:" @@ -1603,7 +1780,7 @@ msgstr "" "態は呼び出し元でははわかりませんので、GILState APIを利用するようにしてくださ" "い)。" -#: ../../c-api/init.rst:1102 +#: ../../c-api/init.rst:1224 msgid "" "Every call to :c:func:`PyGILState_Ensure` must be matched by a call to :c:" "func:`PyGILState_Release` on the same thread." @@ -1611,7 +1788,7 @@ msgstr "" ":c:func:`PyGILState_Ensure` を呼び出す場合は、必ず同一スレッド内で対応する :" "c:func:`PyGILState_Release` を呼び出してください。" -#: ../../c-api/init.rst:1108 +#: ../../c-api/init.rst:1230 msgid "" "Get the current thread state for this thread. May return ``NULL`` if no " "GILState API has been used on the current thread. Note that the main thread " @@ -1624,7 +1801,7 @@ msgstr "" "スレッド状態の情報を持っていることに注意してください。こうなっている目的は主" "にヘルパ機能もしくは診断機能のためです。" -#: ../../c-api/init.rst:1116 +#: ../../c-api/init.rst:1238 msgid "" "Return ``1`` if the current thread is holding the GIL and ``0`` otherwise. " "This function can be called from any thread at any time. Only if it has had " @@ -1642,7 +1819,7 @@ msgstr "" "ロックされていると知っていれば、呼び出し元は sensitive な行動を実行することが" "でき、そうでなければ異なるやりかたで振る舞うことができるからです。" -#: ../../c-api/init.rst:1128 +#: ../../c-api/init.rst:1250 msgid "" "The following macros are normally used without a trailing semicolon; look " "for example usage in the Python source distribution." @@ -1650,7 +1827,7 @@ msgstr "" "以下のマクロは、通常末尾にセミコロンを付けずに使います; Python ソース配布物内" "の使用例を見てください。" -#: ../../c-api/init.rst:1134 +#: ../../c-api/init.rst:1256 msgid "" "This macro expands to ``{ PyThreadState *_save; _save = PyEval_SaveThread();" "``. Note that it contains an opening brace; it must be matched with a " @@ -1662,7 +1839,7 @@ msgstr "" "弧は後で :c:macro:`Py_END_ALLOW_THREADS` マクロと対応させなければなりません。" "マクロについての詳しい議論は上記を参照してください。" -#: ../../c-api/init.rst:1142 +#: ../../c-api/init.rst:1264 msgid "" "This macro expands to ``PyEval_RestoreThread(_save); }``. Note that it " "contains a closing brace; it must be matched with an earlier :c:macro:" @@ -1674,7 +1851,7 @@ msgstr "" "`Py_BEGIN_ALLOW_THREADS` マクロと対応していなければなりません。マクロについて" "の詳しい議論は上記を参照してください。" -#: ../../c-api/init.rst:1150 +#: ../../c-api/init.rst:1272 msgid "" "This macro expands to ``PyEval_RestoreThread(_save);``: it is equivalent to :" "c:macro:`Py_END_ALLOW_THREADS` without the closing brace." @@ -1682,7 +1859,7 @@ msgstr "" "このマクロを展開すると ``PyEval_RestoreThread(_save);`` になります: 閉じ波括" "弧のない :c:macro:`Py_END_ALLOW_THREADS` と同じです。" -#: ../../c-api/init.rst:1156 +#: ../../c-api/init.rst:1278 msgid "" "This macro expands to ``_save = PyEval_SaveThread();``: it is equivalent to :" "c:macro:`Py_BEGIN_ALLOW_THREADS` without the opening brace and variable " @@ -1691,22 +1868,22 @@ msgstr "" "このマクロを展開すると ``_save = PyEval_SaveThread();`` になります: 開き波括" "弧のない :c:macro:`Py_BEGIN_ALLOW_THREADS` と同じです。" -#: ../../c-api/init.rst:1162 +#: ../../c-api/init.rst:1284 msgid "Low-level API" msgstr "低レベルAPI" -#: ../../c-api/init.rst:1164 +#: ../../c-api/init.rst:1286 msgid "" "All of the following functions must be called after :c:func:`Py_Initialize`." msgstr "" "次の全ての関数は :c:func:`Py_Initialize` の後に呼び出さなければなりません。" -#: ../../c-api/init.rst:1166 +#: ../../c-api/init.rst:1288 msgid ":c:func:`Py_Initialize()` now initializes the :term:`GIL`." msgstr "" ":c:func:`Py_Initialize()` は :term:`GIL` を初期化するようになりました。" -#: ../../c-api/init.rst:1172 +#: ../../c-api/init.rst:1294 msgid "" "Create a new interpreter state object. The global interpreter lock need not " "be held, but may be held if it is necessary to serialize calls to this " @@ -1716,7 +1893,7 @@ msgstr "" "ませんが、この関数を次々に呼び出す必要がある場合には保持しておいたほうがよい" "でしょう。" -#: ../../c-api/init.rst:1176 +#: ../../c-api/init.rst:1298 msgid "" "Raises an :ref:`auditing event ` ``cpython." "PyInterpreterState_New`` with no arguments." @@ -1724,7 +1901,7 @@ msgstr "" "引数無しで :ref:`監査イベント ` ``cpython.PyInterpreterState_New`` " "を送出します。 " -#: ../../c-api/init.rst:1181 +#: ../../c-api/init.rst:1303 msgid "" "Reset all information in an interpreter state object. The global " "interpreter lock must be held." @@ -1732,7 +1909,7 @@ msgstr "" "インタプリタ状態オブジェクト内の全ての情報をリセットします。GIL を保持してい" "なければなりません。" -#: ../../c-api/init.rst:1184 +#: ../../c-api/init.rst:1306 msgid "" "Raises an :ref:`auditing event ` ``cpython." "PyInterpreterState_Clear`` with no arguments." @@ -1740,7 +1917,7 @@ msgstr "" "引数無しで :ref:`監査イベント ` ``cpython." "PyInterpreterState_Clear`` を送出します。 " -#: ../../c-api/init.rst:1189 +#: ../../c-api/init.rst:1311 msgid "" "Destroy an interpreter state object. The global interpreter lock need not " "be held. The interpreter state must have been reset with a previous call " @@ -1750,7 +1927,7 @@ msgstr "" "ん。インタプリタ状態は :c:func:`PyInterpreterState_Clear` であらかじめリセッ" "トしておかなければなりません。" -#: ../../c-api/init.rst:1196 +#: ../../c-api/init.rst:1318 msgid "" "Create a new thread state object belonging to the given interpreter object. " "The global interpreter lock need not be held, but may be held if it is " @@ -1760,7 +1937,7 @@ msgstr "" "します。GIL を保持しておく必要はありませんが、この関数を次々に呼び出す必要が" "ある場合には保持しておいたほうがよいでしょう。" -#: ../../c-api/init.rst:1203 +#: ../../c-api/init.rst:1325 msgid "" "Reset all information in a thread state object. The global interpreter lock " "must be held." @@ -1768,13 +1945,13 @@ msgstr "" "スレッド状態オブジェクト内の全ての情報をリセットします。GIL を保持していなけ" "ればなりません。" -#: ../../c-api/init.rst:1206 +#: ../../c-api/init.rst:1328 msgid "" "This function now calls the :c:member:`PyThreadState.on_delete` callback. " "Previously, that happened in :c:func:`PyThreadState_Delete`." msgstr "" -#: ../../c-api/init.rst:1213 +#: ../../c-api/init.rst:1335 msgid "" "Destroy a thread state object. The global interpreter lock need not be " "held. The thread state must have been reset with a previous call to :c:func:" @@ -1784,7 +1961,7 @@ msgstr "" "ド状態は :c:func:`PyThreadState_Clear` であらかじめリセットしておかなければな" "りません。" -#: ../../c-api/init.rst:1220 +#: ../../c-api/init.rst:1342 msgid "" "Destroy the current thread state and release the global interpreter lock. " "Like :c:func:`PyThreadState_Delete`, the global interpreter lock must be " @@ -1792,68 +1969,68 @@ msgid "" "`PyThreadState_Clear`." msgstr "" -#: ../../c-api/init.rst:1228 +#: ../../c-api/init.rst:1350 msgid "Get the current frame of the Python thread state *tstate*." msgstr "" -#: ../../c-api/init.rst:1230 +#: ../../c-api/init.rst:1352 msgid "" "Return a :term:`strong reference`. Return ``NULL`` if no frame is currently " "executing." msgstr "" -#: ../../c-api/init.rst:1233 +#: ../../c-api/init.rst:1355 msgid "See also :c:func:`PyEval_GetFrame`." msgstr "" -#: ../../c-api/init.rst:1235 ../../c-api/init.rst:1244 -#: ../../c-api/init.rst:1253 +#: ../../c-api/init.rst:1357 ../../c-api/init.rst:1366 +#: ../../c-api/init.rst:1375 msgid "*tstate* must not be ``NULL``." msgstr "" -#: ../../c-api/init.rst:1242 +#: ../../c-api/init.rst:1364 msgid "" "Get the unique thread state identifier of the Python thread state *tstate*." msgstr "" -#: ../../c-api/init.rst:1251 +#: ../../c-api/init.rst:1373 msgid "Get the interpreter of the Python thread state *tstate*." msgstr "" -#: ../../c-api/init.rst:1260 +#: ../../c-api/init.rst:1382 msgid "Suspend tracing and profiling in the Python thread state *tstate*." msgstr "" -#: ../../c-api/init.rst:1262 +#: ../../c-api/init.rst:1384 msgid "Resume them using the :c:func:`PyThreadState_LeaveTracing` function." msgstr "" -#: ../../c-api/init.rst:1269 +#: ../../c-api/init.rst:1391 msgid "" "Resume tracing and profiling in the Python thread state *tstate* suspended " "by the :c:func:`PyThreadState_EnterTracing` function." msgstr "" -#: ../../c-api/init.rst:1272 +#: ../../c-api/init.rst:1394 msgid "" "See also :c:func:`PyEval_SetTrace` and :c:func:`PyEval_SetProfile` functions." msgstr "" -#: ../../c-api/init.rst:1280 +#: ../../c-api/init.rst:1402 msgid "Get the current interpreter." msgstr "" -#: ../../c-api/init.rst:1282 +#: ../../c-api/init.rst:1404 msgid "" "Issue a fatal error if there no current Python thread state or no current " "interpreter. It cannot return NULL." msgstr "" -#: ../../c-api/init.rst:1285 ../../c-api/init.rst:1295 +#: ../../c-api/init.rst:1407 ../../c-api/init.rst:1417 msgid "The caller must hold the GIL." msgstr "呼び出し側はGILを獲得する必要があります" -#: ../../c-api/init.rst:1292 +#: ../../c-api/init.rst:1414 msgid "" "Return the interpreter's unique ID. If there was any error in doing so then " "``-1`` is returned and an error is set." @@ -1861,7 +2038,7 @@ msgstr "" "インタプリタの一意な ID を返します。\n" "処理中に何かエラーが起きたら、 ``-1`` が返され、エラーがセットされます。" -#: ../../c-api/init.rst:1302 +#: ../../c-api/init.rst:1424 msgid "" "Return a dictionary in which interpreter-specific data may be stored. If " "this function returns ``NULL`` then no exception has been raised and the " @@ -1871,7 +2048,7 @@ msgstr "" "この関数が ``NULL`` を返した場合は、ここまでで例外は送出されておらず、呼び出" "し側はインタプリタ固有の辞書は利用できないと考えなければなりません。" -#: ../../c-api/init.rst:1306 +#: ../../c-api/init.rst:1428 msgid "" "This is not a replacement for :c:func:`PyModule_GetState()`, which " "extensions should use to store interpreter-specific state information." @@ -1879,39 +2056,39 @@ msgstr "" "この関数は :c:func:`PyModule_GetState()` を置き換えるものではなく、拡張モ" "ジュールがインタプリタ固有の状態情報を格納するのに使うべきものです。" -#: ../../c-api/init.rst:1313 +#: ../../c-api/init.rst:1435 msgid "Type of a frame evaluation function." msgstr "" -#: ../../c-api/init.rst:1315 +#: ../../c-api/init.rst:1437 msgid "" "The *throwflag* parameter is used by the ``throw()`` method of generators: " "if non-zero, handle the current exception." msgstr "" -#: ../../c-api/init.rst:1318 +#: ../../c-api/init.rst:1440 msgid "The function now takes a *tstate* parameter." msgstr "" -#: ../../c-api/init.rst:1321 +#: ../../c-api/init.rst:1443 msgid "" "The *frame* parameter changed from ``PyFrameObject*`` to " "``_PyInterpreterFrame*``." msgstr "" -#: ../../c-api/init.rst:1326 +#: ../../c-api/init.rst:1448 msgid "Get the frame evaluation function." msgstr "" -#: ../../c-api/init.rst:1328 ../../c-api/init.rst:1336 +#: ../../c-api/init.rst:1450 ../../c-api/init.rst:1458 msgid "See the :pep:`523` \"Adding a frame evaluation API to CPython\"." msgstr "" -#: ../../c-api/init.rst:1334 +#: ../../c-api/init.rst:1456 msgid "Set the frame evaluation function." msgstr "" -#: ../../c-api/init.rst:1343 +#: ../../c-api/init.rst:1465 msgid "" "Return a dictionary in which extensions can store thread-specific state " "information. Each extension should use a unique key to use to store state " @@ -1925,7 +2102,7 @@ msgstr "" "の関数が ``NULL`` を返す場合、例外はまったく送出されず、呼び出し側は現在のス" "レッド状態が利用できないと考えなければなりません。" -#: ../../c-api/init.rst:1352 +#: ../../c-api/init.rst:1474 msgid "" "Asynchronously raise an exception in a thread. The *id* argument is the " "thread id of the target thread; *exc* is the exception object to be raised. " @@ -1937,7 +2114,7 @@ msgid "" "raises no exceptions." msgstr "" -#: ../../c-api/init.rst:1360 +#: ../../c-api/init.rst:1482 msgid "" "The type of the *id* parameter changed from :c:expr:`long` to :c:expr:" "`unsigned long`." @@ -1945,7 +2122,7 @@ msgstr "" "*id* 引数の型が :c:expr:`long` から :c:expr:`unsigned long` へ変更されまし" "た。" -#: ../../c-api/init.rst:1366 +#: ../../c-api/init.rst:1488 msgid "" "Acquire the global interpreter lock and set the current thread state to " "*tstate*, which must not be ``NULL``. The lock must have been created " @@ -1956,14 +2133,14 @@ msgstr "" "ん。この関数を呼び出したスレッドがすでにロックを獲得している場合、デッドロッ" "クに陥ります。" -#: ../../c-api/init.rst:1377 +#: ../../c-api/init.rst:1499 msgid "" "Updated to be consistent with :c:func:`PyEval_RestoreThread`, :c:func:" "`Py_END_ALLOW_THREADS`, and :c:func:`PyGILState_Ensure`, and terminate the " "current thread if called while the interpreter is finalizing." msgstr "" -#: ../../c-api/init.rst:1382 +#: ../../c-api/init.rst:1504 msgid "" ":c:func:`PyEval_RestoreThread` is a higher-level function which is always " "available (even when threads have not been initialized)." @@ -1971,7 +2148,7 @@ msgstr "" ":c:func:`PyEval_RestoreThread` はいつでも (スレッドが初期化されたいないときで" "も) 利用可能な高レベル関数です。" -#: ../../c-api/init.rst:1388 +#: ../../c-api/init.rst:1510 msgid "" "Reset the current thread state to ``NULL`` and release the global " "interpreter lock. The lock must have been created earlier and must be held " @@ -1985,7 +2162,7 @@ msgstr "" "状態を表現しているかどうかを調べるためにだけ使われます --- もしそうでなけれ" "ば、致命的エラーが報告されます。" -#: ../../c-api/init.rst:1394 +#: ../../c-api/init.rst:1516 msgid "" ":c:func:`PyEval_SaveThread` is a higher-level function which is always " "available (even when threads have not been initialized)." @@ -1993,11 +2170,11 @@ msgstr "" ":c:func:`PyEval_SaveThread` はより高レベルな関数で常に (スレッドが初期化され" "ていないときでも) 利用できます。" -#: ../../c-api/init.rst:1401 +#: ../../c-api/init.rst:1523 msgid "Sub-interpreter support" msgstr "サブインタプリタサポート" -#: ../../c-api/init.rst:1403 +#: ../../c-api/init.rst:1525 msgid "" "While in most uses, you will only embed a single Python interpreter, there " "are cases where you need to create several independent interpreters in the " @@ -2009,7 +2186,7 @@ msgstr "" "る必要があります。\n" "これを可能にするのがサブインタプリタです。" -#: ../../c-api/init.rst:1408 +#: ../../c-api/init.rst:1530 msgid "" "The \"main\" interpreter is the first one created when the runtime " "initializes. It is usually the only Python interpreter in a process. Unlike " @@ -2028,7 +2205,7 @@ msgstr "" ":c:func:`PyInterpreterState_Main` 関数は、メインインタプリタの状態へのポイン" "タを返します。" -#: ../../c-api/init.rst:1415 +#: ../../c-api/init.rst:1537 msgid "" "You can switch between sub-interpreters using the :c:func:" "`PyThreadState_Swap` function. You can create and destroy them using the " @@ -2037,24 +2214,24 @@ msgstr "" "サブインタプリタを切り替えが :c:func:`PyThreadState_Swap` 関数でできます。\n" "次の関数を使ってサブインタプリタの作成と削除が行えます:" -#: ../../c-api/init.rst:1421 +#: ../../c-api/init.rst:1543 msgid "" "Structure containing most parameters to configure a sub-interpreter. Its " "values are used only in :c:func:`Py_NewInterpreterFromConfig` and never " "modified by the runtime." msgstr "" -#: ../../c-api/init.rst:1427 +#: ../../c-api/init.rst:1549 msgid "Structure fields:" msgstr "構造体フィールド:" -#: ../../c-api/init.rst:1431 +#: ../../c-api/init.rst:1553 msgid "" "If this is ``0`` then the sub-interpreter will use its own \"object\" " "allocator state. Otherwise it will use (share) the main interpreter's." msgstr "" -#: ../../c-api/init.rst:1435 +#: ../../c-api/init.rst:1557 msgid "" "If this is ``0`` then :c:member:`~PyInterpreterConfig." "check_multi_interp_extensions` must be ``1`` (non-zero). If this is ``1`` " @@ -2062,44 +2239,44 @@ msgid "" "`PyInterpreterConfig_OWN_GIL`." msgstr "" -#: ../../c-api/init.rst:1443 +#: ../../c-api/init.rst:1565 msgid "" "If this is ``0`` then the runtime will not support forking the process in " "any thread where the sub-interpreter is currently active. Otherwise fork is " "unrestricted." msgstr "" -#: ../../c-api/init.rst:1447 +#: ../../c-api/init.rst:1569 msgid "" "Note that the :mod:`subprocess` module still works when fork is disallowed." msgstr "" -#: ../../c-api/init.rst:1452 +#: ../../c-api/init.rst:1574 msgid "" "If this is ``0`` then the runtime will not support replacing the current " "process via exec (e.g. :func:`os.execv`) in any thread where the sub-" "interpreter is currently active. Otherwise exec is unrestricted." msgstr "" -#: ../../c-api/init.rst:1457 +#: ../../c-api/init.rst:1579 msgid "" "Note that the :mod:`subprocess` module still works when exec is disallowed." msgstr "" -#: ../../c-api/init.rst:1462 +#: ../../c-api/init.rst:1584 msgid "" "If this is ``0`` then the sub-interpreter's :mod:`threading` module won't " "create threads. Otherwise threads are allowed." msgstr "" -#: ../../c-api/init.rst:1468 +#: ../../c-api/init.rst:1590 msgid "" "If this is ``0`` then the sub-interpreter's :mod:`threading` module won't " "create daemon threads. Otherwise daemon threads are allowed (as long as :c:" "member:`~PyInterpreterConfig.allow_threads` is non-zero)." msgstr "" -#: ../../c-api/init.rst:1475 +#: ../../c-api/init.rst:1597 msgid "" "If this is ``0`` then all extension modules may be imported, including " "legacy (single-phase init) modules, in any thread where the sub-interpreter " @@ -2108,37 +2285,37 @@ msgid "" "`Py_mod_multiple_interpreters`.)" msgstr "" -#: ../../c-api/init.rst:1482 +#: ../../c-api/init.rst:1604 msgid "" "This must be ``1`` (non-zero) if :c:member:`~PyInterpreterConfig." "use_main_obmalloc` is ``0``." msgstr "" -#: ../../c-api/init.rst:1487 +#: ../../c-api/init.rst:1609 msgid "" "This determines the operation of the GIL for the sub-interpreter. It may be " "one of the following:" msgstr "" -#: ../../c-api/init.rst:1494 +#: ../../c-api/init.rst:1616 msgid "Use the default selection (:c:macro:`PyInterpreterConfig_SHARED_GIL`)." msgstr "" -#: ../../c-api/init.rst:1498 +#: ../../c-api/init.rst:1620 msgid "Use (share) the main interpreter's GIL." msgstr "" -#: ../../c-api/init.rst:1502 +#: ../../c-api/init.rst:1624 msgid "Use the sub-interpreter's own GIL." msgstr "" -#: ../../c-api/init.rst:1504 +#: ../../c-api/init.rst:1626 msgid "" "If this is :c:macro:`PyInterpreterConfig_OWN_GIL` then :c:member:" "`PyInterpreterConfig.use_main_obmalloc` must be ``0``." msgstr "" -#: ../../c-api/init.rst:1518 +#: ../../c-api/init.rst:1640 msgid "" "Create a new sub-interpreter. This is an (almost) totally separate " "environment for the execution of Python code. In particular, the new " @@ -2161,13 +2338,13 @@ msgstr "" "stdout``, ``sys.stderr`` を持ちます (とはいえ、これらのストリームは根底にある" "同じファイル記述子を参照しています)。" -#: ../../c-api/init.rst:1528 +#: ../../c-api/init.rst:1650 msgid "" "The given *config* controls the options with which the interpreter is " "initialized." msgstr "" -#: ../../c-api/init.rst:1531 +#: ../../c-api/init.rst:1653 msgid "" "Upon success, *tstate_p* will be set to the first thread state created in " "the new sub-interpreter. This thread state is made in the current thread " @@ -2178,7 +2355,7 @@ msgid "" "state." msgstr "" -#: ../../c-api/init.rst:1540 +#: ../../c-api/init.rst:1662 msgid "" "Like all other Python/C API functions, the global interpreter lock must be " "held before calling this function and is still held when it returns. " @@ -2190,13 +2367,13 @@ msgid "" "released here." msgstr "" -#: ../../c-api/init.rst:1551 +#: ../../c-api/init.rst:1673 msgid "" "Sub-interpreters are most effective when isolated from each other, with " "certain functionality restricted::" msgstr "" -#: ../../c-api/init.rst:1554 +#: ../../c-api/init.rst:1676 msgid "" "PyInterpreterConfig config = {\n" " .use_main_obmalloc = 0,\n" @@ -2210,7 +2387,7 @@ msgid "" "PyThreadState *tstate = Py_NewInterpreterFromConfig(&config);" msgstr "" -#: ../../c-api/init.rst:1565 +#: ../../c-api/init.rst:1687 msgid "" "Note that the config is used only briefly and does not get modified. During " "initialization the config's values are converted into various :c:type:" @@ -2218,11 +2395,11 @@ msgid "" "internally on the :c:type:`PyInterpreterState`." msgstr "" -#: ../../c-api/init.rst:1574 +#: ../../c-api/init.rst:1696 msgid "Extension modules are shared between (sub-)interpreters as follows:" msgstr "" -#: ../../c-api/init.rst:1576 +#: ../../c-api/init.rst:1698 msgid "" "For modules using multi-phase initialization, e.g. :c:func:" "`PyModule_FromDefAndSpec`, a separate module object is created and " @@ -2230,7 +2407,7 @@ msgid "" "are shared between these module objects." msgstr "" -#: ../../c-api/init.rst:1582 +#: ../../c-api/init.rst:1704 msgid "" "For modules using single-phase initialization, e.g. :c:func:" "`PyModule_Create`, the first time a particular extension is imported, it is " @@ -2242,7 +2419,7 @@ msgid "" "might cause unwanted behavior (see `Bugs and caveats`_ below)." msgstr "" -#: ../../c-api/init.rst:1593 +#: ../../c-api/init.rst:1715 msgid "" "Note that this is different from what happens when an extension is imported " "after the interpreter has been completely re-initialized by calling :c:func:" @@ -2252,7 +2429,7 @@ msgid "" "shared between these modules." msgstr "" -#: ../../c-api/init.rst:1613 +#: ../../c-api/init.rst:1735 msgid "" "Create a new sub-interpreter. This is essentially just a wrapper around :c:" "func:`Py_NewInterpreterFromConfig` with a config that preserves the existing " @@ -2261,7 +2438,7 @@ msgid "" "single-phase init modules." msgstr "" -#: ../../c-api/init.rst:1625 +#: ../../c-api/init.rst:1747 msgid "" "Destroy the (sub-)interpreter represented by the given thread state. The " "given thread state must be the current thread state. See the discussion of " @@ -2271,17 +2448,17 @@ msgid "" "be held before calling this function. No GIL is held when it returns." msgstr "" -#: ../../c-api/init.rst:1633 +#: ../../c-api/init.rst:1755 msgid "" ":c:func:`Py_FinalizeEx` will destroy all sub-interpreters that haven't been " "explicitly destroyed at that point." msgstr "" -#: ../../c-api/init.rst:1638 +#: ../../c-api/init.rst:1760 msgid "A Per-Interpreter GIL" msgstr "" -#: ../../c-api/init.rst:1640 +#: ../../c-api/init.rst:1762 msgid "" "Using :c:func:`Py_NewInterpreterFromConfig` you can create a sub-interpreter " "that is completely isolated from other interpreters, including having its " @@ -2293,7 +2470,7 @@ msgid "" "just using threads. (See :pep:`554`.)" msgstr "" -#: ../../c-api/init.rst:1650 +#: ../../c-api/init.rst:1772 msgid "" "Using an isolated interpreter requires vigilance in preserving that " "isolation. That especially means not sharing any objects or mutable state " @@ -2307,7 +2484,7 @@ msgid "" "builtin objects." msgstr "" -#: ../../c-api/init.rst:1661 +#: ../../c-api/init.rst:1783 msgid "" "If you preserve isolation then you will have access to proper multi-core " "computing without the complications that come with free-threading. Failure " @@ -2315,7 +2492,7 @@ msgid "" "threading, including races and hard-to-debug crashes." msgstr "" -#: ../../c-api/init.rst:1666 +#: ../../c-api/init.rst:1788 msgid "" "Aside from that, one of the main challenges of using multiple isolated " "interpreters is how to communicate between them safely (not break isolation) " @@ -2325,11 +2502,11 @@ msgid "" "sharing) data between interpreters." msgstr "" -#: ../../c-api/init.rst:1677 +#: ../../c-api/init.rst:1799 msgid "Bugs and caveats" msgstr "バグと注意事項" -#: ../../c-api/init.rst:1679 +#: ../../c-api/init.rst:1801 msgid "" "Because sub-interpreters (and the main interpreter) are part of the same " "process, the insulation between them isn't perfect --- for example, using " @@ -2342,7 +2519,7 @@ msgid "" "should be avoided if possible." msgstr "" -#: ../../c-api/init.rst:1689 +#: ../../c-api/init.rst:1811 msgid "" "Special care should be taken to avoid sharing user-defined functions, " "methods, instances or classes between sub-interpreters, since import " @@ -2351,7 +2528,7 @@ msgid "" "objects from which the above are reachable." msgstr "" -#: ../../c-api/init.rst:1695 +#: ../../c-api/init.rst:1817 msgid "" "Also note that combining this functionality with ``PyGILState_*`` APIs is " "delicate, because these APIs assume a bijection between Python thread states " @@ -2371,11 +2548,11 @@ msgstr "" "たスレッドから Pythonコードを実行している拡張モジュールはサブインタプリタを使" "うと壊れる可能性があります。" -#: ../../c-api/init.rst:1706 +#: ../../c-api/init.rst:1828 msgid "Asynchronous Notifications" msgstr "非同期通知" -#: ../../c-api/init.rst:1708 +#: ../../c-api/init.rst:1830 msgid "" "A mechanism is provided to make asynchronous notifications to the main " "interpreter thread. These notifications take the form of a function pointer " @@ -2384,7 +2561,7 @@ msgstr "" "インタプリタのメインスレッドに非同期な通知を行うために提供されている仕組みで" "す。これらの通知は関数ポインタと void ポインタ引数という形態を取ります。" -#: ../../c-api/init.rst:1715 +#: ../../c-api/init.rst:1837 msgid "" "Schedule a function to be called from the main interpreter thread. On " "success, ``0`` is returned and *func* is queued for being called in the main " @@ -2394,7 +2571,7 @@ msgstr "" "``0`` が返り、*func* はメインスレッドの呼び出しキューに詰められます。失敗する" "と、例外をセットせずに ``-1`` が返ります。" -#: ../../c-api/init.rst:1719 +#: ../../c-api/init.rst:1841 msgid "" "When successfully queued, *func* will be *eventually* called from the main " "interpreter thread with the argument *arg*. It will be called " @@ -2406,11 +2583,11 @@ msgstr "" "Python コードに対して非同期に呼び出されますが、次の両方の条件に合致したときに" "呼び出されます:" -#: ../../c-api/init.rst:1724 +#: ../../c-api/init.rst:1846 msgid "on a :term:`bytecode` boundary;" msgstr ":term:`bytecode` 境界上にいるとき、" -#: ../../c-api/init.rst:1725 +#: ../../c-api/init.rst:1847 msgid "" "with the main thread holding the :term:`global interpreter lock` (*func* can " "therefore use the full C API)." @@ -2418,7 +2595,7 @@ msgstr "" "メインスレッドが :term:`global interpreter lock` を保持している (すなわち " "*func* が全ての C API を呼び出せる) とき。" -#: ../../c-api/init.rst:1728 +#: ../../c-api/init.rst:1850 msgid "" "*func* must return ``0`` on success, or ``-1`` on failure with an exception " "set. *func* won't be interrupted to perform another asynchronous " @@ -2430,7 +2607,7 @@ msgstr "" "込まれることはありませんが、グローバルインタプリタロックが解放された場合は、" "スレッドの切り替えによって割り込まれる可能性が残っています。" -#: ../../c-api/init.rst:1733 +#: ../../c-api/init.rst:1855 msgid "" "This function doesn't need a current thread state to run, and it doesn't " "need the global interpreter lock." @@ -2438,14 +2615,14 @@ msgstr "" "この関数は実行するのに現在のスレッド状態を必要とせず、グローバルインタプリタ" "ロックも必要としません。" -#: ../../c-api/init.rst:1736 +#: ../../c-api/init.rst:1858 msgid "" "To call this function in a subinterpreter, the caller must hold the GIL. " "Otherwise, the function *func* can be scheduled to be called from the wrong " "interpreter." msgstr "" -#: ../../c-api/init.rst:1741 +#: ../../c-api/init.rst:1863 msgid "" "This is a low-level function, only useful for very special cases. There is " "no guarantee that *func* will be called as quick as possible. If the main " @@ -2461,7 +2638,7 @@ msgstr "" "には **向きません** 。これの代わりに、 :ref:`PyGILState API` を使用" "してください。" -#: ../../c-api/init.rst:1750 +#: ../../c-api/init.rst:1872 msgid "" "If this function is called in a subinterpreter, the function *func* is now " "scheduled to be called from the subinterpreter, rather than being called " @@ -2469,11 +2646,11 @@ msgid "" "scheduled calls." msgstr "" -#: ../../c-api/init.rst:1759 +#: ../../c-api/init.rst:1881 msgid "Profiling and Tracing" msgstr "プロファイルとトレース (profiling and tracing)" -#: ../../c-api/init.rst:1764 +#: ../../c-api/init.rst:1886 msgid "" "The Python interpreter provides some low-level support for attaching " "profiling and execution tracing facilities. These are used for profiling, " @@ -2484,7 +2661,7 @@ msgstr "" "ポートは、プロファイルやデバッグ、適用範囲分析 (coverage analysis) ツールなど" "に使われます。" -#: ../../c-api/init.rst:1768 +#: ../../c-api/init.rst:1890 msgid "" "This C interface allows the profiling or tracing code to avoid the overhead " "of calling through Python-level callable objects, making a direct C function " @@ -2500,7 +2677,7 @@ msgstr "" "ルでき、トレース関数に報告される基本イベント (basic event) は以前のバージョン" "において Python レベルのトレース関数で報告されていたものと同じです。" -#: ../../c-api/init.rst:1778 +#: ../../c-api/init.rst:1900 msgid "" "The type of the trace function registered using :c:func:`PyEval_SetProfile` " "and :c:func:`PyEval_SetTrace`. The first parameter is the object passed to " @@ -2512,68 +2689,68 @@ msgid "" "value of *what*:" msgstr "" -#: ../../c-api/init.rst:1787 +#: ../../c-api/init.rst:1909 msgid "Value of *what*" msgstr "*what* の値" -#: ../../c-api/init.rst:1787 +#: ../../c-api/init.rst:1909 msgid "Meaning of *arg*" msgstr "*arg* の意味" -#: ../../c-api/init.rst:1789 +#: ../../c-api/init.rst:1911 msgid ":c:data:`PyTrace_CALL`" msgstr "" -#: ../../c-api/init.rst:1789 ../../c-api/init.rst:1794 -#: ../../c-api/init.rst:1805 +#: ../../c-api/init.rst:1911 ../../c-api/init.rst:1916 +#: ../../c-api/init.rst:1927 msgid "Always :c:data:`Py_None`." msgstr "常に :c:data:`Py_None` 。" -#: ../../c-api/init.rst:1791 +#: ../../c-api/init.rst:1913 msgid ":c:data:`PyTrace_EXCEPTION`" msgstr "" -#: ../../c-api/init.rst:1791 +#: ../../c-api/init.rst:1913 msgid "Exception information as returned by :func:`sys.exc_info`." msgstr ":func:`sys.exc_info` の返す例外情報です。" -#: ../../c-api/init.rst:1794 +#: ../../c-api/init.rst:1916 msgid ":c:data:`PyTrace_LINE`" msgstr "" -#: ../../c-api/init.rst:1796 +#: ../../c-api/init.rst:1918 msgid ":c:data:`PyTrace_RETURN`" msgstr "" -#: ../../c-api/init.rst:1796 +#: ../../c-api/init.rst:1918 msgid "" "Value being returned to the caller, or ``NULL`` if caused by an exception." msgstr "" "呼び出し側に返される予定の値か、例外によって関数を抜ける場合は ``NULL`` で" "す。" -#: ../../c-api/init.rst:1799 +#: ../../c-api/init.rst:1921 msgid ":c:data:`PyTrace_C_CALL`" msgstr "" -#: ../../c-api/init.rst:1799 ../../c-api/init.rst:1801 -#: ../../c-api/init.rst:1803 +#: ../../c-api/init.rst:1921 ../../c-api/init.rst:1923 +#: ../../c-api/init.rst:1925 msgid "Function object being called." msgstr "呼び出される関数オブジェクト。" -#: ../../c-api/init.rst:1801 +#: ../../c-api/init.rst:1923 msgid ":c:data:`PyTrace_C_EXCEPTION`" msgstr "" -#: ../../c-api/init.rst:1803 +#: ../../c-api/init.rst:1925 msgid ":c:data:`PyTrace_C_RETURN`" msgstr "" -#: ../../c-api/init.rst:1805 +#: ../../c-api/init.rst:1927 msgid ":c:data:`PyTrace_OPCODE`" msgstr "" -#: ../../c-api/init.rst:1810 +#: ../../c-api/init.rst:1932 msgid "" "The value of the *what* parameter to a :c:type:`Py_tracefunc` function when " "a new call to a function or method is being reported, or a new entry into a " @@ -2587,7 +2764,7 @@ msgstr "" "制御の委譲 (control transfer) が起こらないため報告されないので注意してくださ" "い。" -#: ../../c-api/init.rst:1819 +#: ../../c-api/init.rst:1941 msgid "" "The value of the *what* parameter to a :c:type:`Py_tracefunc` function when " "an exception has been raised. The callback function is called with this " @@ -2605,7 +2782,7 @@ msgstr "" "から処理が戻るごとにコールバック関数が呼び出されます。トレース関数だけがこれ" "らのイベントを受け取ります; プロファイラはこの種のイベントを必要としません。" -#: ../../c-api/init.rst:1830 +#: ../../c-api/init.rst:1952 msgid "" "The value passed as the *what* parameter to a :c:type:`Py_tracefunc` " "function (but not a profiling function) when a line-number event is being " @@ -2613,7 +2790,7 @@ msgid "" "f_trace_lines` to *0* on that frame." msgstr "" -#: ../../c-api/init.rst:1838 +#: ../../c-api/init.rst:1960 msgid "" "The value for the *what* parameter to :c:type:`Py_tracefunc` functions when " "a call is about to return." @@ -2621,7 +2798,7 @@ msgstr "" "呼び出しが返るときに :c:type:`Py_tracefunc` 関数に *what* 引数として渡す値で" "す。" -#: ../../c-api/init.rst:1844 +#: ../../c-api/init.rst:1966 msgid "" "The value for the *what* parameter to :c:type:`Py_tracefunc` functions when " "a C function is about to be called." @@ -2629,7 +2806,7 @@ msgstr "" "C関数を呼び出す直前に :c:type:`Py_tracefunc` 関数の *what* 引数として渡す値で" "す。" -#: ../../c-api/init.rst:1850 +#: ../../c-api/init.rst:1972 msgid "" "The value for the *what* parameter to :c:type:`Py_tracefunc` functions when " "a C function has raised an exception." @@ -2637,7 +2814,7 @@ msgstr "" "C関数が例外を送出したときに :c:type:`Py_tracefunc` 関数の *what* 引数として渡" "す値です。" -#: ../../c-api/init.rst:1856 +#: ../../c-api/init.rst:1978 msgid "" "The value for the *what* parameter to :c:type:`Py_tracefunc` functions when " "a C function has returned." @@ -2645,7 +2822,7 @@ msgstr "" "C関数から戻るときに :c:type:`Py_tracefunc` 関数の *what* 引数として渡す値で" "す。" -#: ../../c-api/init.rst:1862 +#: ../../c-api/init.rst:1984 msgid "" "The value for the *what* parameter to :c:type:`Py_tracefunc` functions (but " "not profiling functions) when a new opcode is about to be executed. This " @@ -2653,7 +2830,7 @@ msgid "" "attr:`~frame.f_trace_opcodes` to *1* on the frame." msgstr "" -#: ../../c-api/init.rst:1870 +#: ../../c-api/init.rst:1992 msgid "" "Set the profiler function to *func*. The *obj* parameter is passed to the " "function as its first parameter, and may be any Python object, or ``NULL``. " @@ -2663,29 +2840,29 @@ msgid "" "`PyTrace_LINE` :c:data:`PyTrace_OPCODE` and :c:data:`PyTrace_EXCEPTION`." msgstr "" -#: ../../c-api/init.rst:1877 +#: ../../c-api/init.rst:1999 msgid "See also the :func:`sys.setprofile` function." msgstr ":func:`sys.setprofile` 関数も参照してください。" -#: ../../c-api/init.rst:1879 ../../c-api/init.rst:1886 -#: ../../c-api/init.rst:1905 ../../c-api/init.rst:1912 +#: ../../c-api/init.rst:2001 ../../c-api/init.rst:2008 +#: ../../c-api/init.rst:2027 ../../c-api/init.rst:2034 msgid "The caller must hold the :term:`GIL`." msgstr "呼び出し側は :term:`GIL` を獲得しなければなりません。" -#: ../../c-api/init.rst:1883 +#: ../../c-api/init.rst:2005 msgid "" "Like :c:func:`PyEval_SetProfile` but sets the profile function in all " "running threads belonging to the current interpreter instead of the setting " "it only on the current thread." msgstr "" -#: ../../c-api/init.rst:1888 +#: ../../c-api/init.rst:2010 msgid "" "As :c:func:`PyEval_SetProfile`, this function ignores any exceptions raised " "while setting the profile functions in all threads." msgstr "" -#: ../../c-api/init.rst:1896 +#: ../../c-api/init.rst:2018 msgid "" "Set the tracing function to *func*. This is similar to :c:func:" "`PyEval_SetProfile`, except the tracing function does receive line-number " @@ -2696,28 +2873,28 @@ msgid "" "*what* parameter." msgstr "" -#: ../../c-api/init.rst:1903 +#: ../../c-api/init.rst:2025 msgid "See also the :func:`sys.settrace` function." msgstr ":func:`sys.settrace` 関数も参照してください。" -#: ../../c-api/init.rst:1909 +#: ../../c-api/init.rst:2031 msgid "" "Like :c:func:`PyEval_SetTrace` but sets the tracing function in all running " "threads belonging to the current interpreter instead of the setting it only " "on the current thread." msgstr "" -#: ../../c-api/init.rst:1914 +#: ../../c-api/init.rst:2036 msgid "" "As :c:func:`PyEval_SetTrace`, this function ignores any exceptions raised " "while setting the trace functions in all threads." msgstr "" -#: ../../c-api/init.rst:1920 +#: ../../c-api/init.rst:2042 msgid "Reference tracing" msgstr "" -#: ../../c-api/init.rst:1926 +#: ../../c-api/init.rst:2048 msgid "" "The type of the trace function registered using :c:func:" "`PyRefTracer_SetTracer`. The first parameter is a Python object that has " @@ -2727,19 +2904,19 @@ msgid "" "provided when :c:func:`PyRefTracer_SetTracer` was called." msgstr "" -#: ../../c-api/init.rst:1936 +#: ../../c-api/init.rst:2058 msgid "" "The value for the *event* parameter to :c:type:`PyRefTracer` functions when " "a Python object has been created." msgstr "" -#: ../../c-api/init.rst:1941 +#: ../../c-api/init.rst:2063 msgid "" "The value for the *event* parameter to :c:type:`PyRefTracer` functions when " "a Python object has been destroyed." msgstr "" -#: ../../c-api/init.rst:1946 +#: ../../c-api/init.rst:2068 msgid "" "Register a reference tracer function. The function will be called when a new " "Python has been created or when an object is going to be destroyed. If " @@ -2748,7 +2925,7 @@ msgid "" "return ``-1`` on error." msgstr "" -#: ../../c-api/init.rst:1952 +#: ../../c-api/init.rst:2074 msgid "" "Not that tracer functions **must not** create Python objects inside or " "otherwise the call will be re-entrant. The tracer also **must not** clear " @@ -2756,11 +2933,11 @@ msgid "" "the tracer function is called." msgstr "" -#: ../../c-api/init.rst:1957 ../../c-api/init.rst:1968 +#: ../../c-api/init.rst:2079 ../../c-api/init.rst:2090 msgid "The GIL must be held when calling this function." msgstr "" -#: ../../c-api/init.rst:1963 +#: ../../c-api/init.rst:2085 msgid "" "Get the registered reference tracer function and the value of the opaque " "data pointer that was registered when :c:func:`PyRefTracer_SetTracer` was " @@ -2768,27 +2945,27 @@ msgid "" "set the **data** pointer to NULL." msgstr "" -#: ../../c-api/init.rst:1975 +#: ../../c-api/init.rst:2097 msgid "Advanced Debugger Support" msgstr "高度なデバッガサポート (advanced debugger support)" -#: ../../c-api/init.rst:1980 +#: ../../c-api/init.rst:2102 msgid "" "These functions are only intended to be used by advanced debugging tools." msgstr "以下の関数は高度なデバッグツールでの使用のためだけのものです。" -#: ../../c-api/init.rst:1985 +#: ../../c-api/init.rst:2107 msgid "" "Return the interpreter state object at the head of the list of all such " "objects." msgstr "" "インタプリタ状態オブジェクトからなるリストのうち、先頭にあるものを返します。" -#: ../../c-api/init.rst:1990 +#: ../../c-api/init.rst:2112 msgid "Return the main interpreter state object." msgstr "メインインタプリタの状態オブジェクトを返します。" -#: ../../c-api/init.rst:1995 +#: ../../c-api/init.rst:2117 msgid "" "Return the next interpreter state object after *interp* from the list of all " "such objects." @@ -2796,7 +2973,7 @@ msgstr "" "インタプリタ状態オブジェクトからなるリストのうち、*interp* の次にあるものを返" "します。" -#: ../../c-api/init.rst:2001 +#: ../../c-api/init.rst:2123 msgid "" "Return the pointer to the first :c:type:`PyThreadState` object in the list " "of threads associated with the interpreter *interp*." @@ -2804,7 +2981,7 @@ msgstr "" "インタプリタ *interp* に関連付けられているスレッドからなるリストのうち、先頭" "にある :c:type:`PyThreadState` オブジェクトを返します。" -#: ../../c-api/init.rst:2007 +#: ../../c-api/init.rst:2129 msgid "" "Return the next thread state object after *tstate* from the list of all such " "objects belonging to the same :c:type:`PyInterpreterState` object." @@ -2812,11 +2989,11 @@ msgstr "" "*tstate* と同じ :c:type:`PyInterpreterState` オブジェクトに属しているスレッド" "状態オブジェクトのうち、 *tstate* の次にあるものを返します。" -#: ../../c-api/init.rst:2014 +#: ../../c-api/init.rst:2136 msgid "Thread Local Storage Support" msgstr "スレッドローカルストレージのサポート" -#: ../../c-api/init.rst:2018 +#: ../../c-api/init.rst:2140 msgid "" "The Python interpreter provides low-level support for thread-local storage " "(TLS) which wraps the underlying native TLS implementation to support the " @@ -2832,7 +3009,7 @@ msgstr "" "CPython の C レベル API は pthreads や Windows で与えられる TLS と同様です: " "スレッドキーとスレッドごとに :c:expr:`void*` 値を関係付ける関数を使います。" -#: ../../c-api/init.rst:2025 +#: ../../c-api/init.rst:2147 msgid "" "The GIL does *not* need to be held when calling these functions; they supply " "their own locking." @@ -2840,7 +3017,7 @@ msgstr "" "API で使われる関数を呼ぶときは、 GIL を取得する必要は *ありません* 。関数自身" "のロックがサポートされています。" -#: ../../c-api/init.rst:2028 +#: ../../c-api/init.rst:2150 msgid "" "Note that :file:`Python.h` does not include the declaration of the TLS APIs, " "you need to include :file:`pythread.h` to use thread-local storage." @@ -2849,7 +3026,7 @@ msgstr "" "を使うには :file:`pythread.h` を include する必要があることに注意してくださ" "い。" -#: ../../c-api/init.rst:2032 +#: ../../c-api/init.rst:2154 msgid "" "None of these API functions handle memory management on behalf of the :c:" "expr:`void*` values. You need to allocate and deallocate them yourself. If " @@ -2862,11 +3039,11 @@ msgstr "" ":c:expr:`void*` 値がたまたま :c:expr:`PyObject*` だった場合は、 API 関数はそ" "れぞれの値の参照カウントの操作は行いません。" -#: ../../c-api/init.rst:2040 +#: ../../c-api/init.rst:2162 msgid "Thread Specific Storage (TSS) API" msgstr "スレッド固有ストレージ (Thread Specific Storage, TSS) API" -#: ../../c-api/init.rst:2042 +#: ../../c-api/init.rst:2164 msgid "" "TSS API is introduced to supersede the use of the existing TLS API within " "the CPython interpreter. This API uses a new type :c:type:`Py_tss_t` " @@ -2877,12 +3054,12 @@ msgstr "" "この API は、スレッドキーの表現に :c:expr:`int` の代わりに新しい型 :c:type:" "`Py_tss_t` を使います。" -#: ../../c-api/init.rst:2048 +#: ../../c-api/init.rst:2170 msgid "\"A New C-API for Thread-Local Storage in CPython\" (:pep:`539`)" msgstr "" "\"CPython のスレッドローカルストレージのための新しい C API\" (:pep:`539`)" -#: ../../c-api/init.rst:2053 +#: ../../c-api/init.rst:2175 msgid "" "This data structure represents the state of a thread key, the definition of " "which may depend on the underlying TLS implementation, and it has an " @@ -2893,7 +3070,7 @@ msgstr "" "底の TLS 実装に依存し、キーの初期化状態を表現する内部フィールドを持ちます。\n" "この構造体には公開 (public) のメンバはありません。" -#: ../../c-api/init.rst:2058 +#: ../../c-api/init.rst:2180 msgid "" "When :ref:`Py_LIMITED_API ` is not defined, static allocation of " "this type by :c:macro:`Py_tss_NEEDS_INIT` is allowed." @@ -2901,7 +3078,7 @@ msgstr "" ":ref:`Py_LIMITED_API ` が定義されていないときは、この型の :c:macro:" "`Py_tss_NEEDS_INIT` による静的メモリ確保ができます。" -#: ../../c-api/init.rst:2064 +#: ../../c-api/init.rst:2186 msgid "" "This macro expands to the initializer for :c:type:`Py_tss_t` variables. Note " "that this macro won't be defined with :ref:`Py_LIMITED_API `." @@ -2909,11 +3086,11 @@ msgstr "" "このマクロは :c:type:`Py_tss_t` 変数の初期化子に展開されます。\n" "このマクロは :ref:`Py_LIMITED_API ` があるときは定義されません。" -#: ../../c-api/init.rst:2069 +#: ../../c-api/init.rst:2191 msgid "Dynamic Allocation" msgstr "動的メモリ確保" -#: ../../c-api/init.rst:2071 +#: ../../c-api/init.rst:2193 msgid "" "Dynamic allocation of the :c:type:`Py_tss_t`, required in extension modules " "built with :ref:`Py_LIMITED_API `, where static allocation of this " @@ -2923,29 +3100,29 @@ msgstr "" "ルドされた拡張モジュールで必要になりますが、その実装がビルド時に不透明なため" "に、この型の静的なメモリ確保は不可能です。" -#: ../../c-api/init.rst:2078 +#: ../../c-api/init.rst:2200 msgid "" "Return a value which is the same state as a value initialized with :c:macro:" "`Py_tss_NEEDS_INIT`, or ``NULL`` in the case of dynamic allocation failure." msgstr "" -#: ../../c-api/init.rst:2085 +#: ../../c-api/init.rst:2207 msgid "" "Free the given *key* allocated by :c:func:`PyThread_tss_alloc`, after first " "calling :c:func:`PyThread_tss_delete` to ensure any associated thread locals " "have been unassigned. This is a no-op if the *key* argument is ``NULL``." msgstr "" -#: ../../c-api/init.rst:2091 +#: ../../c-api/init.rst:2213 msgid "" "A freed key becomes a dangling pointer. You should reset the key to ``NULL``." msgstr "" -#: ../../c-api/init.rst:2096 +#: ../../c-api/init.rst:2218 msgid "Methods" msgstr "メソッド" -#: ../../c-api/init.rst:2098 +#: ../../c-api/init.rst:2220 msgid "" "The parameter *key* of these functions must not be ``NULL``. Moreover, the " "behaviors of :c:func:`PyThread_tss_set` and :c:func:`PyThread_tss_get` are " @@ -2953,13 +3130,13 @@ msgid "" "func:`PyThread_tss_create`." msgstr "" -#: ../../c-api/init.rst:2106 +#: ../../c-api/init.rst:2228 msgid "" "Return a non-zero value if the given :c:type:`Py_tss_t` has been initialized " "by :c:func:`PyThread_tss_create`." msgstr "" -#: ../../c-api/init.rst:2112 +#: ../../c-api/init.rst:2234 msgid "" "Return a zero value on successful initialization of a TSS key. The behavior " "is undefined if the value pointed to by the *key* argument is not " @@ -2968,7 +3145,7 @@ msgid "" "no-op and immediately returns success." msgstr "" -#: ../../c-api/init.rst:2121 +#: ../../c-api/init.rst:2243 msgid "" "Destroy a TSS key to forget the values associated with the key across all " "threads, and change the key's initialization state to uninitialized. A " @@ -2977,31 +3154,31 @@ msgid "" "key -- calling it on an already destroyed key is a no-op." msgstr "" -#: ../../c-api/init.rst:2130 +#: ../../c-api/init.rst:2252 msgid "" "Return a zero value to indicate successfully associating a :c:expr:`void*` " "value with a TSS key in the current thread. Each thread has a distinct " "mapping of the key to a :c:expr:`void*` value." msgstr "" -#: ../../c-api/init.rst:2137 +#: ../../c-api/init.rst:2259 msgid "" "Return the :c:expr:`void*` value associated with a TSS key in the current " "thread. This returns ``NULL`` if no value is associated with the key in the " "current thread." msgstr "" -#: ../../c-api/init.rst:2145 +#: ../../c-api/init.rst:2267 msgid "Thread Local Storage (TLS) API" msgstr "スレッドローカルストレージ (TLS) API" -#: ../../c-api/init.rst:2147 +#: ../../c-api/init.rst:2269 msgid "" "This API is superseded by :ref:`Thread Specific Storage (TSS) API `." msgstr "" -#: ../../c-api/init.rst:2152 +#: ../../c-api/init.rst:2274 msgid "" "This version of the API does not support platforms where the native TLS key " "is defined in a way that cannot be safely cast to ``int``. On such " @@ -3010,7 +3187,7 @@ msgid "" "platforms." msgstr "" -#: ../../c-api/init.rst:2157 +#: ../../c-api/init.rst:2279 msgid "" "Due to the compatibility problem noted above, this version of the API should " "not be used in new code." @@ -3018,56 +3195,56 @@ msgstr "" "前述の互換性の問題により、このバージョンのAPIは新規のコードで利用すべきではあ" "りません。" -#: ../../c-api/init.rst:2168 +#: ../../c-api/init.rst:2290 msgid "Synchronization Primitives" msgstr "同期プリミティブ" -#: ../../c-api/init.rst:2170 +#: ../../c-api/init.rst:2292 msgid "The C-API provides a basic mutual exclusion lock." msgstr "" -#: ../../c-api/init.rst:2174 +#: ../../c-api/init.rst:2296 msgid "" "A mutual exclusion lock. The :c:type:`!PyMutex` should be initialized to " "zero to represent the unlocked state. For example::" msgstr "" -#: ../../c-api/init.rst:2177 +#: ../../c-api/init.rst:2299 msgid "PyMutex mutex = {0};" msgstr "" -#: ../../c-api/init.rst:2179 +#: ../../c-api/init.rst:2301 msgid "" "Instances of :c:type:`!PyMutex` should not be copied or moved. Both the " "contents and address of a :c:type:`!PyMutex` are meaningful, and it must " "remain at a fixed, writable location in memory." msgstr "" -#: ../../c-api/init.rst:2185 +#: ../../c-api/init.rst:2307 msgid "" "A :c:type:`!PyMutex` currently occupies one byte, but the size should be " "considered unstable. The size may change in future Python releases without " "a deprecation period." msgstr "" -#: ../../c-api/init.rst:2193 +#: ../../c-api/init.rst:2315 msgid "" "Lock mutex *m*. If another thread has already locked it, the calling thread " "will block until the mutex is unlocked. While blocked, the thread will " "temporarily release the :term:`GIL` if it is held." msgstr "" -#: ../../c-api/init.rst:2201 +#: ../../c-api/init.rst:2323 msgid "" "Unlock mutex *m*. The mutex must be locked --- otherwise, the function will " "issue a fatal error." msgstr "" -#: ../../c-api/init.rst:2209 +#: ../../c-api/init.rst:2331 msgid "Python Critical Section API" msgstr "" -#: ../../c-api/init.rst:2211 +#: ../../c-api/init.rst:2333 msgid "" "The critical section API provides a deadlock avoidance layer on top of per-" "object locks for :term:`free-threaded ` CPython. They are " @@ -3075,7 +3252,7 @@ msgid "" "no-ops in versions of Python with the global interpreter lock." msgstr "" -#: ../../c-api/init.rst:2216 +#: ../../c-api/init.rst:2338 msgid "" "Critical sections avoid deadlocks by implicitly suspending active critical " "sections and releasing the locks during calls to :c:func:" @@ -3085,7 +3262,7 @@ msgid "" "-- they are useful because their behavior is similar to the :term:`GIL`." msgstr "" -#: ../../c-api/init.rst:2223 +#: ../../c-api/init.rst:2345 msgid "" "The functions and structs used by the macros are exposed for cases where C " "macros are not available. They should only be used as in the given macro " @@ -3093,7 +3270,7 @@ msgid "" "future Python versions." msgstr "" -#: ../../c-api/init.rst:2230 +#: ../../c-api/init.rst:2352 msgid "" "Operations that need to lock two objects at once must use :c:macro:" "`Py_BEGIN_CRITICAL_SECTION2`. You *cannot* use nested critical sections to " @@ -3102,11 +3279,11 @@ msgid "" "lock more than two objects at once." msgstr "" -#: ../../c-api/init.rst:2236 +#: ../../c-api/init.rst:2358 msgid "Example usage::" msgstr "使用例::" -#: ../../c-api/init.rst:2238 +#: ../../c-api/init.rst:2360 msgid "" "static PyObject *\n" "set_field(MyObject *self, PyObject *value)\n" @@ -3118,7 +3295,7 @@ msgid "" "}" msgstr "" -#: ../../c-api/init.rst:2247 +#: ../../c-api/init.rst:2369 msgid "" "In the above example, :c:macro:`Py_SETREF` calls :c:macro:`Py_DECREF`, which " "can call arbitrary code through an object's deallocation function. The " @@ -3128,215 +3305,215 @@ msgid "" "`PyEval_SaveThread`." msgstr "" -#: ../../c-api/init.rst:2255 +#: ../../c-api/init.rst:2377 msgid "" "Acquires the per-object lock for the object *op* and begins a critical " "section." msgstr "" -#: ../../c-api/init.rst:2258 ../../c-api/init.rst:2272 -#: ../../c-api/init.rst:2287 ../../c-api/init.rst:2301 +#: ../../c-api/init.rst:2380 ../../c-api/init.rst:2394 +#: ../../c-api/init.rst:2409 ../../c-api/init.rst:2423 msgid "In the free-threaded build, this macro expands to::" msgstr "" -#: ../../c-api/init.rst:2260 +#: ../../c-api/init.rst:2382 msgid "" "{\n" " PyCriticalSection _py_cs;\n" " PyCriticalSection_Begin(&_py_cs, (PyObject*)(op))" msgstr "" -#: ../../c-api/init.rst:2264 ../../c-api/init.rst:2293 +#: ../../c-api/init.rst:2386 ../../c-api/init.rst:2415 msgid "In the default build, this macro expands to ``{``." msgstr "" -#: ../../c-api/init.rst:2270 +#: ../../c-api/init.rst:2392 msgid "Ends the critical section and releases the per-object lock." msgstr "" -#: ../../c-api/init.rst:2274 +#: ../../c-api/init.rst:2396 msgid "" " PyCriticalSection_End(&_py_cs);\n" "}" msgstr "" -#: ../../c-api/init.rst:2277 ../../c-api/init.rst:2306 +#: ../../c-api/init.rst:2399 ../../c-api/init.rst:2428 msgid "In the default build, this macro expands to ``}``." msgstr "" -#: ../../c-api/init.rst:2283 +#: ../../c-api/init.rst:2405 msgid "" "Acquires the per-objects locks for the objects *a* and *b* and begins a " "critical section. The locks are acquired in a consistent order (lowest " "address first) to avoid lock ordering deadlocks." msgstr "" -#: ../../c-api/init.rst:2289 +#: ../../c-api/init.rst:2411 msgid "" "{\n" " PyCriticalSection2 _py_cs2;\n" " PyCriticalSection_Begin2(&_py_cs2, (PyObject*)(a), (PyObject*)(b))" msgstr "" -#: ../../c-api/init.rst:2299 +#: ../../c-api/init.rst:2421 msgid "Ends the critical section and releases the per-object locks." msgstr "" -#: ../../c-api/init.rst:2303 +#: ../../c-api/init.rst:2425 msgid "" " PyCriticalSection_End2(&_py_cs2);\n" "}" msgstr "" -#: ../../c-api/init.rst:335 +#: ../../c-api/init.rst:350 msgid "PyEval_InitThreads()" msgstr "PyEval_InitThreads()" -#: ../../c-api/init.rst:335 +#: ../../c-api/init.rst:350 msgid "modules (in module sys)" msgstr "modules (in module sys)" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:576 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:698 msgid "path (in module sys)" msgstr "path (sys モジュール)" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:576 ../../c-api/init.rst:1011 -#: ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:698 ../../c-api/init.rst:1133 +#: ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "module" msgstr "module" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "builtins" msgstr "builtins" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "__main__" msgstr "__main__" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "sys" msgstr "sys" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:576 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:698 msgid "search" msgstr "検索" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:576 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:698 msgid "path" msgstr "パス" -#: ../../c-api/init.rst:335 ../../c-api/init.rst:1570 ../../c-api/init.rst:1623 +#: ../../c-api/init.rst:350 ../../c-api/init.rst:1692 ../../c-api/init.rst:1745 msgid "Py_FinalizeEx (C function)" msgstr "" -#: ../../c-api/init.rst:445 +#: ../../c-api/init.rst:567 msgid "Py_Initialize()" msgstr "Py_Initialize()" -#: ../../c-api/init.rst:445 ../../c-api/init.rst:674 +#: ../../c-api/init.rst:567 ../../c-api/init.rst:796 msgid "main()" msgstr "main()" -#: ../../c-api/init.rst:445 +#: ../../c-api/init.rst:567 msgid "Py_GetPath()" msgstr "Py_GetPath()" -#: ../../c-api/init.rst:555 +#: ../../c-api/init.rst:677 msgid "executable (in module sys)" msgstr "executable (in module sys)" -#: ../../c-api/init.rst:609 ../../c-api/init.rst:651 ../../c-api/init.rst:665 +#: ../../c-api/init.rst:731 ../../c-api/init.rst:773 ../../c-api/init.rst:787 msgid "version (in module sys)" msgstr "version (in module sys)" -#: ../../c-api/init.rst:621 +#: ../../c-api/init.rst:743 msgid "platform (in module sys)" msgstr "platform (in module sys)" -#: ../../c-api/init.rst:638 +#: ../../c-api/init.rst:760 msgid "copyright (in module sys)" msgstr "copyright (in module sys)" -#: ../../c-api/init.rst:674 +#: ../../c-api/init.rst:796 msgid "Py_FatalError()" msgstr "Py_FatalError()" -#: ../../c-api/init.rst:674 +#: ../../c-api/init.rst:796 msgid "argv (in module sys)" msgstr "argv (in module sys)" -#: ../../c-api/init.rst:794 +#: ../../c-api/init.rst:916 msgid "global interpreter lock" msgstr "global interpreter lock" -#: ../../c-api/init.rst:794 +#: ../../c-api/init.rst:916 msgid "interpreter lock" msgstr "interpreter lock" -#: ../../c-api/init.rst:794 +#: ../../c-api/init.rst:916 msgid "lock, interpreter" msgstr "lock, interpreter" -#: ../../c-api/init.rst:807 +#: ../../c-api/init.rst:929 msgid "setswitchinterval (in module sys)" msgstr "" -#: ../../c-api/init.rst:816 +#: ../../c-api/init.rst:938 msgid "PyThreadState (C type)" msgstr "" -#: ../../c-api/init.rst:842 +#: ../../c-api/init.rst:964 msgid "Py_BEGIN_ALLOW_THREADS (C macro)" msgstr "" -#: ../../c-api/init.rst:842 +#: ../../c-api/init.rst:964 msgid "Py_END_ALLOW_THREADS (C macro)" msgstr "" -#: ../../c-api/init.rst:858 +#: ../../c-api/init.rst:980 msgid "PyEval_RestoreThread (C function)" msgstr "" -#: ../../c-api/init.rst:858 +#: ../../c-api/init.rst:980 msgid "PyEval_SaveThread (C function)" msgstr "" -#: ../../c-api/init.rst:989 +#: ../../c-api/init.rst:1111 msgid "PyEval_AcquireThread()" msgstr "PyEval_AcquireThread()" -#: ../../c-api/init.rst:989 +#: ../../c-api/init.rst:1111 msgid "PyEval_ReleaseThread()" msgstr "PyEval_ReleaseThread()" -#: ../../c-api/init.rst:989 +#: ../../c-api/init.rst:1111 msgid "PyEval_SaveThread()" msgstr "PyEval_SaveThread()" -#: ../../c-api/init.rst:989 +#: ../../c-api/init.rst:1111 msgid "PyEval_RestoreThread()" msgstr "PyEval_RestoreThread()" -#: ../../c-api/init.rst:1011 +#: ../../c-api/init.rst:1133 msgid "_thread" msgstr "_thread" -#: ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "stdout (in module sys)" msgstr "stdout (sys モジュール)" -#: ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "stderr (in module sys)" msgstr "stderr (sys モジュール)" -#: ../../c-api/init.rst:1510 ../../c-api/init.rst:1605 +#: ../../c-api/init.rst:1632 ../../c-api/init.rst:1727 msgid "stdin (in module sys)" msgstr "stdin (sys モジュール)" -#: ../../c-api/init.rst:1570 +#: ../../c-api/init.rst:1692 msgid "Py_Initialize (C function)" msgstr "" -#: ../../c-api/init.rst:1600 +#: ../../c-api/init.rst:1722 msgid "close (in module os)" msgstr "" diff --git a/c-api/init_config.po b/c-api/init_config.po index 2a0232c67..42eec3324 100644 --- a/c-api/init_config.po +++ b/c-api/init_config.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:49+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -573,7 +573,7 @@ msgid "" "`~PyPreConfig.parse_argv` of *preconfig* is non-zero." msgstr "" -#: ../../c-api/init_config.rst:401 ../../c-api/init_config.rst:1360 +#: ../../c-api/init_config.rst:401 ../../c-api/init_config.rst:1359 msgid "" "The caller is responsible to handle exceptions (error or exit) using :c:func:" "`PyStatus_Exception` and :c:func:`Py_ExitStatusException`." @@ -1839,19 +1839,17 @@ msgstr "" msgid "The ``show_alloc_count`` field has been removed." msgstr "" -#: ../../c-api/init_config.rst:1352 -msgid "Initialization with PyConfig" -msgstr "" - #: ../../c-api/init_config.rst:1354 -msgid "Function to initialize Python:" +msgid "Initialization with PyConfig" msgstr "" -#: ../../c-api/init_config.rst:1358 -msgid "Initialize Python from *config* configuration." +#: ../../c-api/init_config.rst:1356 +msgid "" +"Initializing the interpreter from a populated configuration struct is " +"handled by calling :c:func:`Py_InitializeFromConfig`." msgstr "" -#: ../../c-api/init_config.rst:1363 +#: ../../c-api/init_config.rst:1362 msgid "" "If :c:func:`PyImport_FrozenModules`, :c:func:`PyImport_AppendInittab` or :c:" "func:`PyImport_ExtendInittab` are used, they must be set or called after " @@ -1860,17 +1858,17 @@ msgid "" "`PyImport_ExtendInittab` must be called before each Python initialization." msgstr "" -#: ../../c-api/init_config.rst:1370 +#: ../../c-api/init_config.rst:1369 msgid "" "The current configuration (``PyConfig`` type) is stored in " "``PyInterpreterState.config``." msgstr "" -#: ../../c-api/init_config.rst:1373 +#: ../../c-api/init_config.rst:1372 msgid "Example setting the program name::" msgstr "" -#: ../../c-api/init_config.rst:1375 +#: ../../c-api/init_config.rst:1374 msgid "" "void init_python(void)\n" "{\n" @@ -1899,7 +1897,7 @@ msgid "" "}" msgstr "" -#: ../../c-api/init_config.rst:1401 +#: ../../c-api/init_config.rst:1400 msgid "" "More complete example modifying the default configuration, read the " "configuration, and then override some parameters. Note that since 3.11, many " @@ -1908,7 +1906,7 @@ msgid "" "called will be left unchanged by initialization::" msgstr "" -#: ../../c-api/init_config.rst:1408 +#: ../../c-api/init_config.rst:1407 msgid "" "PyStatus init_python(const char *program_name)\n" "{\n" @@ -1963,18 +1961,18 @@ msgid "" "}" msgstr "" -#: ../../c-api/init_config.rst:1464 +#: ../../c-api/init_config.rst:1463 msgid "Isolated Configuration" msgstr "" -#: ../../c-api/init_config.rst:1466 +#: ../../c-api/init_config.rst:1465 msgid "" ":c:func:`PyPreConfig_InitIsolatedConfig` and :c:func:" "`PyConfig_InitIsolatedConfig` functions create a configuration to isolate " "Python from the system. For example, to embed Python into an application." msgstr "" -#: ../../c-api/init_config.rst:1471 +#: ../../c-api/init_config.rst:1470 msgid "" "This configuration ignores global configuration variables, environment " "variables, command line arguments (:c:member:`PyConfig.argv` is not parsed) " @@ -1982,115 +1980,115 @@ msgid "" "LC_CTYPE locale are left unchanged. Signal handlers are not installed." msgstr "" -#: ../../c-api/init_config.rst:1476 +#: ../../c-api/init_config.rst:1475 msgid "" "Configuration files are still used with this configuration to determine " "paths that are unspecified. Ensure :c:member:`PyConfig.home` is specified to " "avoid computing the default path configuration." msgstr "" -#: ../../c-api/init_config.rst:1484 +#: ../../c-api/init_config.rst:1483 msgid "Python Configuration" msgstr "" -#: ../../c-api/init_config.rst:1486 +#: ../../c-api/init_config.rst:1485 msgid "" ":c:func:`PyPreConfig_InitPythonConfig` and :c:func:" "`PyConfig_InitPythonConfig` functions create a configuration to build a " "customized Python which behaves as the regular Python." msgstr "" -#: ../../c-api/init_config.rst:1490 +#: ../../c-api/init_config.rst:1489 msgid "" "Environments variables and command line arguments are used to configure " "Python, whereas global configuration variables are ignored." msgstr "" -#: ../../c-api/init_config.rst:1493 +#: ../../c-api/init_config.rst:1492 msgid "" "This function enables C locale coercion (:pep:`538`) and :ref:`Python UTF-8 " "Mode ` (:pep:`540`) depending on the LC_CTYPE locale, :envvar:" "`PYTHONUTF8` and :envvar:`PYTHONCOERCECLOCALE` environment variables." msgstr "" -#: ../../c-api/init_config.rst:1502 +#: ../../c-api/init_config.rst:1501 msgid "Python Path Configuration" msgstr "" -#: ../../c-api/init_config.rst:1504 +#: ../../c-api/init_config.rst:1503 msgid ":c:type:`PyConfig` contains multiple fields for the path configuration:" msgstr "" -#: ../../c-api/init_config.rst:1506 +#: ../../c-api/init_config.rst:1505 msgid "Path configuration inputs:" msgstr "" -#: ../../c-api/init_config.rst:1508 +#: ../../c-api/init_config.rst:1507 msgid ":c:member:`PyConfig.home`" msgstr "" -#: ../../c-api/init_config.rst:1509 +#: ../../c-api/init_config.rst:1508 msgid ":c:member:`PyConfig.platlibdir`" msgstr "" -#: ../../c-api/init_config.rst:1510 +#: ../../c-api/init_config.rst:1509 msgid ":c:member:`PyConfig.pathconfig_warnings`" msgstr "" -#: ../../c-api/init_config.rst:1511 +#: ../../c-api/init_config.rst:1510 msgid ":c:member:`PyConfig.program_name`" msgstr "" -#: ../../c-api/init_config.rst:1512 +#: ../../c-api/init_config.rst:1511 msgid ":c:member:`PyConfig.pythonpath_env`" msgstr "" -#: ../../c-api/init_config.rst:1513 +#: ../../c-api/init_config.rst:1512 msgid "current working directory: to get absolute paths" msgstr "" -#: ../../c-api/init_config.rst:1514 +#: ../../c-api/init_config.rst:1513 msgid "" "``PATH`` environment variable to get the program full path (from :c:member:" "`PyConfig.program_name`)" msgstr "" -#: ../../c-api/init_config.rst:1516 +#: ../../c-api/init_config.rst:1515 msgid "``__PYVENV_LAUNCHER__`` environment variable" msgstr "" -#: ../../c-api/init_config.rst:1517 +#: ../../c-api/init_config.rst:1516 msgid "" "(Windows only) Application paths in the registry under " "\"Software\\Python\\PythonCore\\X.Y\\PythonPath\" of HKEY_CURRENT_USER and " "HKEY_LOCAL_MACHINE (where X.Y is the Python version)." msgstr "" -#: ../../c-api/init_config.rst:1521 +#: ../../c-api/init_config.rst:1520 msgid "Path configuration output fields:" msgstr "" -#: ../../c-api/init_config.rst:1523 +#: ../../c-api/init_config.rst:1522 msgid ":c:member:`PyConfig.base_exec_prefix`" msgstr ":c:member:`PyConfig.base_exec_prefix`" -#: ../../c-api/init_config.rst:1524 +#: ../../c-api/init_config.rst:1523 msgid ":c:member:`PyConfig.base_executable`" msgstr ":c:member:`PyConfig.base_executable`" -#: ../../c-api/init_config.rst:1525 +#: ../../c-api/init_config.rst:1524 msgid ":c:member:`PyConfig.base_prefix`" msgstr ":c:member:`PyConfig.base_prefix`" -#: ../../c-api/init_config.rst:1526 +#: ../../c-api/init_config.rst:1525 msgid ":c:member:`PyConfig.exec_prefix`" msgstr ":c:member:`PyConfig.exec_prefix`" -#: ../../c-api/init_config.rst:1527 +#: ../../c-api/init_config.rst:1526 msgid ":c:member:`PyConfig.executable`" msgstr ":c:member:`PyConfig.executable`" -#: ../../c-api/init_config.rst:1528 +#: ../../c-api/init_config.rst:1527 msgid "" ":c:member:`PyConfig.module_search_paths_set`, :c:member:`PyConfig." "module_search_paths`" @@ -2098,11 +2096,11 @@ msgstr "" ":c:member:`PyConfig.module_search_paths_set`, :c:member:`PyConfig." "module_search_paths`" -#: ../../c-api/init_config.rst:1530 +#: ../../c-api/init_config.rst:1529 msgid ":c:member:`PyConfig.prefix`" msgstr ":c:member:`PyConfig.prefix`" -#: ../../c-api/init_config.rst:1532 +#: ../../c-api/init_config.rst:1531 msgid "" "If at least one \"output field\" is not set, Python calculates the path " "configuration to fill unset fields. If :c:member:`~PyConfig." @@ -2111,7 +2109,7 @@ msgid "" "module_search_paths_set` is set to ``1``." msgstr "" -#: ../../c-api/init_config.rst:1538 +#: ../../c-api/init_config.rst:1537 msgid "" "It is possible to completely ignore the function calculating the default " "path configuration by setting explicitly all path configuration output " @@ -2121,52 +2119,52 @@ msgid "" "modification." msgstr "" -#: ../../c-api/init_config.rst:1545 +#: ../../c-api/init_config.rst:1544 msgid "" "Set :c:member:`~PyConfig.pathconfig_warnings` to ``0`` to suppress warnings " "when calculating the path configuration (Unix only, Windows does not log any " "warning)." msgstr "" -#: ../../c-api/init_config.rst:1548 +#: ../../c-api/init_config.rst:1547 msgid "" "If :c:member:`~PyConfig.base_prefix` or :c:member:`~PyConfig." "base_exec_prefix` fields are not set, they inherit their value from :c:" "member:`~PyConfig.prefix` and :c:member:`~PyConfig.exec_prefix` respectively." msgstr "" -#: ../../c-api/init_config.rst:1552 +#: ../../c-api/init_config.rst:1551 msgid ":c:func:`Py_RunMain` and :c:func:`Py_Main` modify :data:`sys.path`:" msgstr "" -#: ../../c-api/init_config.rst:1554 +#: ../../c-api/init_config.rst:1553 msgid "" "If :c:member:`~PyConfig.run_filename` is set and is a directory which " "contains a ``__main__.py`` script, prepend :c:member:`~PyConfig." "run_filename` to :data:`sys.path`." msgstr "" -#: ../../c-api/init_config.rst:1557 +#: ../../c-api/init_config.rst:1556 msgid "If :c:member:`~PyConfig.isolated` is zero:" msgstr "" -#: ../../c-api/init_config.rst:1559 +#: ../../c-api/init_config.rst:1558 msgid "" "If :c:member:`~PyConfig.run_module` is set, prepend the current directory " "to :data:`sys.path`. Do nothing if the current directory cannot be read." msgstr "" -#: ../../c-api/init_config.rst:1561 +#: ../../c-api/init_config.rst:1560 msgid "" "If :c:member:`~PyConfig.run_filename` is set, prepend the directory of the " "filename to :data:`sys.path`." msgstr "" -#: ../../c-api/init_config.rst:1563 +#: ../../c-api/init_config.rst:1562 msgid "Otherwise, prepend an empty string to :data:`sys.path`." msgstr "" -#: ../../c-api/init_config.rst:1565 +#: ../../c-api/init_config.rst:1564 msgid "" "If :c:member:`~PyConfig.site_import` is non-zero, :data:`sys.path` can be " "modified by the :mod:`site` module. If :c:member:`~PyConfig." @@ -2175,170 +2173,143 @@ msgid "" "data:`sys.path`." msgstr "" -#: ../../c-api/init_config.rst:1571 +#: ../../c-api/init_config.rst:1570 msgid "The following configuration files are used by the path configuration:" msgstr "" -#: ../../c-api/init_config.rst:1573 +#: ../../c-api/init_config.rst:1572 msgid "``pyvenv.cfg``" msgstr "``pyvenv.cfg``" -#: ../../c-api/init_config.rst:1574 +#: ../../c-api/init_config.rst:1573 msgid "``._pth`` file (ex: ``python._pth``)" msgstr "" -#: ../../c-api/init_config.rst:1575 +#: ../../c-api/init_config.rst:1574 msgid "``pybuilddir.txt`` (Unix only)" msgstr "" -#: ../../c-api/init_config.rst:1577 +#: ../../c-api/init_config.rst:1576 msgid "If a ``._pth`` file is present:" msgstr "" -#: ../../c-api/init_config.rst:1579 +#: ../../c-api/init_config.rst:1578 msgid "Set :c:member:`~PyConfig.isolated` to ``1``." msgstr "" -#: ../../c-api/init_config.rst:1580 +#: ../../c-api/init_config.rst:1579 msgid "Set :c:member:`~PyConfig.use_environment` to ``0``." msgstr "" -#: ../../c-api/init_config.rst:1581 +#: ../../c-api/init_config.rst:1580 msgid "Set :c:member:`~PyConfig.site_import` to ``0``." msgstr "" -#: ../../c-api/init_config.rst:1582 +#: ../../c-api/init_config.rst:1581 msgid "Set :c:member:`~PyConfig.safe_path` to ``1``." msgstr "" -#: ../../c-api/init_config.rst:1584 +#: ../../c-api/init_config.rst:1583 msgid "" "The ``__PYVENV_LAUNCHER__`` environment variable is used to set :c:member:" "`PyConfig.base_executable`." msgstr "" -#: ../../c-api/init_config.rst:1589 -msgid "Py_RunMain()" -msgstr "Py_RunMain()" - -#: ../../c-api/init_config.rst:1593 -msgid "" -"Execute the command (:c:member:`PyConfig.run_command`), the script (:c:" -"member:`PyConfig.run_filename`) or the module (:c:member:`PyConfig." -"run_module`) specified on the command line or in the configuration." -msgstr "" - -#: ../../c-api/init_config.rst:1598 -msgid "By default and when if :option:`-i` option is used, run the REPL." -msgstr "" - -#: ../../c-api/init_config.rst:1600 -msgid "" -"Finally, finalizes Python and returns an exit status that can be passed to " -"the ``exit()`` function." -msgstr "" - -#: ../../c-api/init_config.rst:1603 -msgid "" -"See :ref:`Python Configuration ` for an example of " -"customized Python always running in isolated mode using :c:func:`Py_RunMain`." -msgstr "" - -#: ../../c-api/init_config.rst:1609 +#: ../../c-api/init_config.rst:1588 msgid "Py_GetArgcArgv()" msgstr "Py_GetArgcArgv()" -#: ../../c-api/init_config.rst:1613 +#: ../../c-api/init_config.rst:1592 msgid "Get the original command line arguments, before Python modified them." msgstr "" -#: ../../c-api/init_config.rst:1615 +#: ../../c-api/init_config.rst:1594 msgid "See also :c:member:`PyConfig.orig_argv` member." msgstr "" -#: ../../c-api/init_config.rst:1619 +#: ../../c-api/init_config.rst:1598 msgid "Multi-Phase Initialization Private Provisional API" msgstr "" -#: ../../c-api/init_config.rst:1621 +#: ../../c-api/init_config.rst:1600 msgid "" "This section is a private provisional API introducing multi-phase " "initialization, the core feature of :pep:`432`:" msgstr "" -#: ../../c-api/init_config.rst:1624 +#: ../../c-api/init_config.rst:1603 msgid "\"Core\" initialization phase, \"bare minimum Python\":" msgstr "" -#: ../../c-api/init_config.rst:1626 +#: ../../c-api/init_config.rst:1605 msgid "Builtin types;" msgstr "" -#: ../../c-api/init_config.rst:1627 +#: ../../c-api/init_config.rst:1606 msgid "Builtin exceptions;" msgstr "" -#: ../../c-api/init_config.rst:1628 +#: ../../c-api/init_config.rst:1607 msgid "Builtin and frozen modules;" msgstr "" -#: ../../c-api/init_config.rst:1629 +#: ../../c-api/init_config.rst:1608 msgid "" "The :mod:`sys` module is only partially initialized (ex: :data:`sys.path` " "doesn't exist yet)." msgstr "" -#: ../../c-api/init_config.rst:1632 +#: ../../c-api/init_config.rst:1611 msgid "\"Main\" initialization phase, Python is fully initialized:" msgstr "" -#: ../../c-api/init_config.rst:1634 +#: ../../c-api/init_config.rst:1613 msgid "Install and configure :mod:`importlib`;" msgstr "" -#: ../../c-api/init_config.rst:1635 +#: ../../c-api/init_config.rst:1614 msgid "Apply the :ref:`Path Configuration `;" msgstr "" -#: ../../c-api/init_config.rst:1636 +#: ../../c-api/init_config.rst:1615 msgid "Install signal handlers;" msgstr "" -#: ../../c-api/init_config.rst:1637 +#: ../../c-api/init_config.rst:1616 msgid "" "Finish :mod:`sys` module initialization (ex: create :data:`sys.stdout` and :" "data:`sys.path`);" msgstr "" -#: ../../c-api/init_config.rst:1639 +#: ../../c-api/init_config.rst:1618 msgid "" "Enable optional features like :mod:`faulthandler` and :mod:`tracemalloc`;" msgstr "" -#: ../../c-api/init_config.rst:1640 +#: ../../c-api/init_config.rst:1619 msgid "Import the :mod:`site` module;" msgstr "" -#: ../../c-api/init_config.rst:1641 +#: ../../c-api/init_config.rst:1620 msgid "etc." msgstr "" -#: ../../c-api/init_config.rst:1643 +#: ../../c-api/init_config.rst:1622 msgid "Private provisional API:" msgstr "" -#: ../../c-api/init_config.rst:1645 +#: ../../c-api/init_config.rst:1624 msgid "" ":c:member:`PyConfig._init_main`: if set to ``0``, :c:func:" "`Py_InitializeFromConfig` stops at the \"Core\" initialization phase." msgstr "" -#: ../../c-api/init_config.rst:1650 +#: ../../c-api/init_config.rst:1629 msgid "" "Move to the \"Main\" initialization phase, finish the Python initialization." msgstr "" -#: ../../c-api/init_config.rst:1652 +#: ../../c-api/init_config.rst:1631 msgid "" "No module is imported during the \"Core\" phase and the ``importlib`` module " "is not configured: the :ref:`Path Configuration ` is only " @@ -2347,14 +2318,14 @@ msgid "" "maybe install a custom :data:`sys.meta_path` importer or an import hook, etc." msgstr "" -#: ../../c-api/init_config.rst:1658 +#: ../../c-api/init_config.rst:1637 msgid "" "It may become possible to calculate the :ref:`Path Configuration ` in Python, after the Core phase and before the Main phase, which is " "one of the :pep:`432` motivation." msgstr "" -#: ../../c-api/init_config.rst:1662 +#: ../../c-api/init_config.rst:1641 msgid "" "The \"Core\" phase is not properly defined: what should be and what should " "not be available at this phase is not specified yet. The API is marked as " @@ -2362,13 +2333,13 @@ msgid "" "until a proper public API is designed." msgstr "" -#: ../../c-api/init_config.rst:1667 +#: ../../c-api/init_config.rst:1646 msgid "" "Example running Python code between \"Core\" and \"Main\" initialization " "phases::" msgstr "" -#: ../../c-api/init_config.rst:1670 +#: ../../c-api/init_config.rst:1649 msgid "" "void init_python(void)\n" "{\n" diff --git a/c-api/module.po b/c-api/module.po index adbf10585..9ed4cbaa4 100644 --- a/c-api/module.po +++ b/c-api/module.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:49+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -57,29 +57,25 @@ msgstr "" #: ../../c-api/module.rst:40 msgid "" -"Return a new module object with the :attr:`__name__` attribute set to " -"*name*. The module's :attr:`__name__`, :attr:`__doc__`, :attr:`__package__`, " -"and :attr:`__loader__` attributes are filled in (all but :attr:`__name__` " -"are set to ``None``); the caller is responsible for providing a :attr:" -"`__file__` attribute." +"Return a new module object with :attr:`module.__name__` set to *name*. The " +"module's :attr:`!__name__`, :attr:`~module.__doc__`, :attr:`~module." +"__package__` and :attr:`~module.__loader__` attributes are filled in (all " +"but :attr:`!__name__` are set to ``None``). The caller is responsible for " +"setting a :attr:`~module.__file__` attribute." msgstr "" -":attr:`__name__` 属性に *name* が設定された新しいモジュールオブジェクトを返し" -"ます。\n" -"モジュールの :attr:`__name__`, :attr:`__doc__`, :attr:`__package__`, :attr:" -"`__loader__` 属性に値が入っています (:attr:`__name__` 以外は全て ``None`` で" -"す);\n" -":attr:`__file__` 属性に値を入れるのは呼び出し側の責任です。" -#: ../../c-api/module.rst:46 ../../c-api/module.rst:270 -#: ../../c-api/module.rst:472 +#: ../../c-api/module.rst:46 ../../c-api/module.rst:272 +#: ../../c-api/module.rst:474 msgid "Return ``NULL`` with an exception set on error." msgstr "" #: ../../c-api/module.rst:50 -msgid ":attr:`__package__` and :attr:`__loader__` are set to ``None``." -msgstr ":attr:`__package__` と :attr:`__loader__` は ``None`` に設定されます。" +msgid "" +":attr:`~module.__package__` and :attr:`~module.__loader__` are now set to " +"``None``." +msgstr "" -#: ../../c-api/module.rst:56 +#: ../../c-api/module.rst:57 msgid "" "Similar to :c:func:`PyModule_NewObject`, but the name is a UTF-8 encoded " "string instead of a Unicode object." @@ -87,7 +83,7 @@ msgstr "" ":c:func:`PyModule_NewObject` に似ていますが、 name は Unicode オブジェクトで" "はなく UTF-8 でエンコードされた文字列です。" -#: ../../c-api/module.rst:64 +#: ../../c-api/module.rst:65 msgid "" "Return the dictionary object that implements *module*'s namespace; this " "object is the same as the :attr:`~object.__dict__` attribute of the module " @@ -100,7 +96,7 @@ msgstr "" "*module* がモジュールオブジェクト (もしくはモジュールオブジェクトのサブタイ" "プ) でない場合は、 :exc:`SystemError` が送出され ``NULL`` が返されます。" -#: ../../c-api/module.rst:69 +#: ../../c-api/module.rst:70 msgid "" "It is recommended extensions use other ``PyModule_*`` and ``PyObject_*`` " "functions rather than directly manipulate a module's :attr:`~object." @@ -109,17 +105,14 @@ msgstr "" "拡張モジュールでは、モジュールの :attr:`~object.__dict__` を直接操作するより" "も、 ``PyModule_*`` および ``PyObject_*`` 関数を使う方が推奨されます。" -#: ../../c-api/module.rst:80 +#: ../../c-api/module.rst:81 msgid "" -"Return *module*'s :attr:`__name__` value. If the module does not provide " -"one, or if it is not a string, :exc:`SystemError` is raised and ``NULL`` is " -"returned." +"Return *module*'s :attr:`~module.__name__` value. If the module does not " +"provide one, or if it is not a string, :exc:`SystemError` is raised and " +"``NULL`` is returned." msgstr "" -"*module* の :attr:`__name__` の値を返します。モジュールがこの属性を提供してい" -"ない場合や文字列型でない場合、 :exc:`SystemError` を送出して ``NULL`` を返し" -"ます。" -#: ../../c-api/module.rst:88 +#: ../../c-api/module.rst:90 msgid "" "Similar to :c:func:`PyModule_GetNameObject` but return the name encoded to " "``'utf-8'``." @@ -127,7 +120,7 @@ msgstr "" ":c:func:`PyModule_GetNameObject` に似ていますが、 ``'utf-8'`` でエンコードさ" "れた name を返します。" -#: ../../c-api/module.rst:93 +#: ../../c-api/module.rst:95 msgid "" "Return the \"state\" of the module, that is, a pointer to the block of " "memory allocated at module creation time, or ``NULL``. See :c:member:" @@ -137,7 +130,7 @@ msgstr "" "クへのポインター) か、なければ ``NULL`` を返します。 :c:member:`PyModuleDef." "m_size` を参照してください。" -#: ../../c-api/module.rst:100 +#: ../../c-api/module.rst:102 msgid "" "Return a pointer to the :c:type:`PyModuleDef` struct from which the module " "was created, or ``NULL`` if the module wasn't created from a definition." @@ -146,19 +139,15 @@ msgstr "" "ます。\n" "モジュールが定義によって作られていなかった場合は ``NULL`` を返します。" -#: ../../c-api/module.rst:110 +#: ../../c-api/module.rst:112 msgid "" "Return the name of the file from which *module* was loaded using *module*'s :" -"attr:`__file__` attribute. If this is not defined, or if it is not a " -"unicode string, raise :exc:`SystemError` and return ``NULL``; otherwise " -"return a reference to a Unicode object." +"attr:`~module.__file__` attribute. If this is not defined, or if it is not " +"a string, raise :exc:`SystemError` and return ``NULL``; otherwise return a " +"reference to a Unicode object." msgstr "" -"*module* の :attr:`__file__` 属性をもとに *module* がロードされたもとのファイ" -"ル名を返します。もしファイル名が定義されていない場合や、 Unicode 文字列ではな" -"い場合、 :exc:`SystemError` を発生させて ``NULL`` を返します。それ以外の場合" -"は Unicode オブジェクトへの参照を返します。" -#: ../../c-api/module.rst:120 +#: ../../c-api/module.rst:122 msgid "" "Similar to :c:func:`PyModule_GetFilenameObject` but return the filename " "encoded to 'utf-8'." @@ -166,7 +155,7 @@ msgstr "" ":c:func:`PyModule_GetFilenameObject` と似ていますが、 'utf-8' でエンコードさ" "れたファイル名を返します。" -#: ../../c-api/module.rst:123 +#: ../../c-api/module.rst:125 msgid "" ":c:func:`PyModule_GetFilename` raises :exc:`UnicodeEncodeError` on " "unencodable filenames, use :c:func:`PyModule_GetFilenameObject` instead." @@ -175,11 +164,11 @@ msgstr "" "`UnicodeEncodeError` を送出します。これの代わりに :c:func:" "`PyModule_GetFilenameObject` を使用してください。" -#: ../../c-api/module.rst:131 +#: ../../c-api/module.rst:133 msgid "Initializing C modules" msgstr "Cモジュールの初期化" -#: ../../c-api/module.rst:133 +#: ../../c-api/module.rst:135 msgid "" "Modules objects are usually created from extension modules (shared libraries " "which export an initialization function), or compiled-in modules (where the " @@ -193,7 +182,7 @@ msgstr "" "詳細については :ref:`building` または :ref:`extending-with-embedding` を見て" "ください。" -#: ../../c-api/module.rst:138 +#: ../../c-api/module.rst:140 msgid "" "The initialization function can either pass a module definition instance to :" "c:func:`PyModule_Create`, and return the resulting module object, or request " @@ -203,7 +192,7 @@ msgstr "" "て出来上がったモジュールオブジェクトを返してもよいですし、もしくは定義構造体" "そのものを返し\"多段階初期化\"を要求しても構いません。" -#: ../../c-api/module.rst:144 +#: ../../c-api/module.rst:146 msgid "" "The module definition struct, which holds all information needed to create a " "module object. There is usually only one statically initialized variable of " @@ -214,16 +203,16 @@ msgstr "" "通常は、それぞれのモジュールごとに静的に初期化されたこの型の変数が1つだけ存在" "します。" -#: ../../c-api/module.rst:150 +#: ../../c-api/module.rst:152 msgid "Always initialize this member to :c:macro:`PyModuleDef_HEAD_INIT`." msgstr "" "このメンバーは常に :c:macro:`PyModuleDef_HEAD_INIT` で初期化してください。" -#: ../../c-api/module.rst:154 +#: ../../c-api/module.rst:156 msgid "Name for the new module." msgstr "新しいモジュールの名前。" -#: ../../c-api/module.rst:158 +#: ../../c-api/module.rst:160 msgid "" "Docstring for the module; usually a docstring variable created with :c:macro:" "`PyDoc_STRVAR` is used." @@ -231,7 +220,7 @@ msgstr "" "モジュールの docstring。たいてい docstring は :c:macro:`PyDoc_STRVAR` を利用" "して生成されます。" -#: ../../c-api/module.rst:163 +#: ../../c-api/module.rst:165 msgid "" "Module state may be kept in a per-module memory area that can be retrieved " "with :c:func:`PyModule_GetState`, rather than in static globals. This makes " @@ -242,7 +231,7 @@ msgstr "" "とがあります。\n" "これによってモジュールは複数のサブ・インタプリターで安全に使えます。" -#: ../../c-api/module.rst:167 +#: ../../c-api/module.rst:169 msgid "" "This memory area is allocated based on *m_size* on module creation, and " "freed when the module object is deallocated, after the :c:member:" @@ -252,7 +241,7 @@ msgstr "" "ブジェクトが破棄されるときに、 :c:member:`~PyModuleDef.m_free` 関数があればそ" "れが呼ばれた後で解放されます。" -#: ../../c-api/module.rst:171 +#: ../../c-api/module.rst:173 msgid "" "Setting ``m_size`` to ``-1`` means that the module does not support sub-" "interpreters, because it has global state." @@ -260,7 +249,7 @@ msgstr "" "``m_size`` に ``-1`` を設定すると、そのモジュールはグローバルな状態を持つため" "にサブ・インタープリターをサポートしていないということになります。" -#: ../../c-api/module.rst:174 +#: ../../c-api/module.rst:176 msgid "" "Setting it to a non-negative value means that the module can be re-" "initialized and specifies the additional amount of memory it requires for " @@ -271,11 +260,11 @@ msgstr "" "必要となる追加のメモリ量を指定できるということになります。\n" "非負の ``m_size`` は多段階初期化で必要になります。" -#: ../../c-api/module.rst:179 +#: ../../c-api/module.rst:181 msgid "See :PEP:`3121` for more details." msgstr "詳細は :PEP:`3121` を参照。" -#: ../../c-api/module.rst:183 +#: ../../c-api/module.rst:185 msgid "" "A pointer to a table of module-level functions, described by :c:type:" "`PyMethodDef` values. Can be ``NULL`` if no functions are present." @@ -283,7 +272,7 @@ msgstr "" ":c:type:`PyMethodDef` で定義される、モジュールレベル関数のテーブルへのポイン" "ター。関数が存在しない場合は ``NULL`` を設定することが可能。" -#: ../../c-api/module.rst:188 +#: ../../c-api/module.rst:190 msgid "" "An array of slot definitions for multi-phase initialization, terminated by a " "``{0, NULL}`` entry. When using single-phase initialization, *m_slots* must " @@ -293,7 +282,7 @@ msgstr "" "す。\n" "一段階初期化を使うときは、 *m_slots* は ``NULL`` でなければなりません。" -#: ../../c-api/module.rst:194 +#: ../../c-api/module.rst:196 msgid "" "Prior to version 3.5, this member was always set to ``NULL``, and was " "defined as:" @@ -301,7 +290,7 @@ msgstr "" "バージョン 3.5 より前は、このメンバは常に ``NULL`` に設定されていて、次のもの" "として定義されていました:" -#: ../../c-api/module.rst:201 +#: ../../c-api/module.rst:203 msgid "" "A traversal function to call during GC traversal of the module object, or " "``NULL`` if not needed." @@ -309,8 +298,8 @@ msgstr "" "GC走査がモジュールオブジェクトを走査する際に呼び出される走査関数。必要ない場" "合は ``NULL``." -#: ../../c-api/module.rst:204 ../../c-api/module.rst:219 -#: ../../c-api/module.rst:240 +#: ../../c-api/module.rst:206 ../../c-api/module.rst:221 +#: ../../c-api/module.rst:242 msgid "" "This function is not called if the module state was requested but is not " "allocated yet. This is the case immediately after the module is created and " @@ -320,12 +309,12 @@ msgid "" "`PyModule_GetState`) is ``NULL``." msgstr "" -#: ../../c-api/module.rst:211 ../../c-api/module.rst:232 -#: ../../c-api/module.rst:247 +#: ../../c-api/module.rst:213 ../../c-api/module.rst:234 +#: ../../c-api/module.rst:249 msgid "No longer called before the module state is allocated." msgstr "" -#: ../../c-api/module.rst:216 +#: ../../c-api/module.rst:218 msgid "" "A clear function to call during GC clearing of the module object, or " "``NULL`` if not needed." @@ -333,7 +322,7 @@ msgstr "" "GCがこのモジュールオブジェクトをクリアーする時に呼び出されるクリアー関数。必" "要ない場合は、``NULL``." -#: ../../c-api/module.rst:226 +#: ../../c-api/module.rst:228 msgid "" "Like :c:member:`PyTypeObject.tp_clear`, this function is not *always* called " "before a module is deallocated. For example, when reference counting is " @@ -342,7 +331,7 @@ msgid "" "directly." msgstr "" -#: ../../c-api/module.rst:237 +#: ../../c-api/module.rst:239 msgid "" "A function to call during deallocation of the module object, or ``NULL`` if " "not needed." @@ -350,11 +339,11 @@ msgstr "" "GCがこのモジュールオブジェクトを解放するときに呼び出される関数。必要ない場合" "は ``NULL``." -#: ../../c-api/module.rst:251 +#: ../../c-api/module.rst:253 msgid "Single-phase initialization" msgstr "一段階初期化" -#: ../../c-api/module.rst:253 +#: ../../c-api/module.rst:255 msgid "" "The module initialization function may create and return the module object " "directly. This is referred to as \"single-phase initialization\", and uses " @@ -365,14 +354,14 @@ msgstr "" "これは\"一段階初期化\"と呼ばれ、次の2つのモジュール生成関数のどちらか1つを使" "います:" -#: ../../c-api/module.rst:259 +#: ../../c-api/module.rst:261 msgid "" "Create a new module object, given the definition in *def*. This behaves " "like :c:func:`PyModule_Create2` with *module_api_version* set to :c:macro:" "`PYTHON_API_VERSION`." msgstr "" -#: ../../c-api/module.rst:266 +#: ../../c-api/module.rst:268 msgid "" "Create a new module object, given the definition in *def*, assuming the API " "version *module_api_version*. If that version does not match the version of " @@ -383,7 +372,7 @@ msgstr "" "もし指定されたバージョンが実行しているインタープリターのバージョンと異なる場" "合は、 :exc:`RuntimeWarning` を発生させます。" -#: ../../c-api/module.rst:274 +#: ../../c-api/module.rst:276 msgid "" "Most uses of this function should be using :c:func:`PyModule_Create` " "instead; only use this if you are sure you need it." @@ -391,7 +380,7 @@ msgstr "" "ほとんどの場合、この関数ではなく :c:func:`PyModule_Create` を利用するべきで" "す。この関数は、この関数の必要性を理解しているときにだけ利用してください。" -#: ../../c-api/module.rst:277 +#: ../../c-api/module.rst:279 msgid "" "Before it is returned from in the initialization function, the resulting " "module object is typically populated using functions like :c:func:" @@ -401,11 +390,11 @@ msgstr "" "`PyModule_AddObjectRef` などの関数を使ってモジュールオブジェクトにメンバを所" "属させます。" -#: ../../c-api/module.rst:283 +#: ../../c-api/module.rst:285 msgid "Multi-phase initialization" msgstr "多段階初期化" -#: ../../c-api/module.rst:285 +#: ../../c-api/module.rst:287 msgid "" "An alternate way to specify extensions is to request \"multi-phase " "initialization\". Extension modules created this way behave more like Python " @@ -415,7 +404,7 @@ msgid "" "__init__` methods of classes." msgstr "" -#: ../../c-api/module.rst:292 +#: ../../c-api/module.rst:294 msgid "" "Unlike modules created using single-phase initialization, these modules are " "not singletons: if the *sys.modules* entry is removed and the module is re-" @@ -428,7 +417,7 @@ msgid "" "__dict__` or individual classes created with :c:func:`PyType_FromSpec`)." msgstr "" -#: ../../c-api/module.rst:302 +#: ../../c-api/module.rst:304 msgid "" "All modules created using multi-phase initialization are expected to " "support :ref:`sub-interpreters `. Making sure " @@ -439,7 +428,7 @@ msgstr "" "複数のモジュールが独立していることを保証するのには、たいていはこのサポートを" "するだけで十分です。" -#: ../../c-api/module.rst:306 +#: ../../c-api/module.rst:308 msgid "" "To request multi-phase initialization, the initialization function " "(PyInit_modulename) returns a :c:type:`PyModuleDef` instance with non-empty :" @@ -451,7 +440,7 @@ msgstr "" "これを返す前に、 ``PyModuleDef`` インスタンスは次の関数で初期化されなくてはい" "けません:" -#: ../../c-api/module.rst:313 +#: ../../c-api/module.rst:315 msgid "" "Ensures a module definition is a properly initialized Python object that " "correctly reports its type and reference count." @@ -459,13 +448,13 @@ msgstr "" "モジュール定義が型と参照カウントを正しく報告する、適切に初期化された Python " "オブジェクトであること保証します。" -#: ../../c-api/module.rst:316 +#: ../../c-api/module.rst:318 msgid "Returns *def* cast to ``PyObject*``, or ``NULL`` if an error occurred." msgstr "" "``PyObject*`` にキャストされた *def* を返します。エラーが発生した場合 " "``NULL`` を返します。" -#: ../../c-api/module.rst:320 +#: ../../c-api/module.rst:322 msgid "" "The *m_slots* member of the module definition must point to an array of " "``PyModuleDef_Slot`` structures:" @@ -473,23 +462,23 @@ msgstr "" "モジュール定義の *m_slots* メンバは ``PyModuleDef_Slot`` 構造体の配列を指さな" "ければなりません:" -#: ../../c-api/module.rst:327 +#: ../../c-api/module.rst:329 msgid "A slot ID, chosen from the available values explained below." msgstr "スロット ID で、以下で説明されている利用可能な値から選ばれます。" -#: ../../c-api/module.rst:331 +#: ../../c-api/module.rst:333 msgid "Value of the slot, whose meaning depends on the slot ID." msgstr "スロットの値で、意味はスロット ID に依存します。" -#: ../../c-api/module.rst:335 +#: ../../c-api/module.rst:337 msgid "The *m_slots* array must be terminated by a slot with id 0." msgstr "*m_slots* 配列はID 0 のスロットで終端されていなければなりません。" -#: ../../c-api/module.rst:337 +#: ../../c-api/module.rst:339 msgid "The available slot types are:" msgstr "利用可能なスロットの型は以下です:" -#: ../../c-api/module.rst:341 +#: ../../c-api/module.rst:343 msgid "" "Specifies a function that is called to create the module object itself. The " "*value* pointer of this slot must point to a function of the signature:" @@ -498,7 +487,7 @@ msgstr "" "このスロットの *value* ポインタは次のシグネチャを持つ関数を指していなくてはい" "けません:" -#: ../../c-api/module.rst:348 +#: ../../c-api/module.rst:350 msgid "" "The function receives a :py:class:`~importlib.machinery.ModuleSpec` " "instance, as defined in :PEP:`451`, and the module definition. It should " @@ -509,7 +498,7 @@ msgstr "" "これは新しいモジュールオブジェクトを返すか、エラーを設定して ``NULL`` を返す" "べきです。" -#: ../../c-api/module.rst:353 +#: ../../c-api/module.rst:355 msgid "" "This function should be kept minimal. In particular, it should not call " "arbitrary Python code, as trying to import the same module again may result " @@ -519,7 +508,7 @@ msgstr "" "特に任意のPythonコードを呼び出すべきではなく、同じモジュールをインポートしよ" "うとすると無限ループに陥るでしょう。" -#: ../../c-api/module.rst:357 +#: ../../c-api/module.rst:359 msgid "" "Multiple ``Py_mod_create`` slots may not be specified in one module " "definition." @@ -527,7 +516,7 @@ msgstr "" "複数の ``Py_mod_create`` スロットを1つのモジュール定義に設定しない方がよいで" "す。" -#: ../../c-api/module.rst:360 +#: ../../c-api/module.rst:362 msgid "" "If ``Py_mod_create`` is not specified, the import machinery will create a " "normal module object using :c:func:`PyModule_New`. The name is taken from " @@ -541,7 +530,7 @@ msgstr "" "ルが動的にモジュール階層における位置を調整できたり、シンボリックリンクを通し" "て同一のモジュール定義を共有しつつ別の名前でインポートできたりします。" -#: ../../c-api/module.rst:366 +#: ../../c-api/module.rst:368 msgid "" "There is no requirement for the returned object to be an instance of :c:type:" "`PyModule_Type`. Any type can be used, as long as it supports setting and " @@ -558,7 +547,7 @@ msgstr "" "のスロットを持つ場合は、 ``PyModule_Type`` インスタンスのみが返されるでしょ" "う。" -#: ../../c-api/module.rst:375 +#: ../../c-api/module.rst:377 msgid "" "Specifies a function that is called to *execute* the module. This is " "equivalent to executing the code of a Python module: typically, this " @@ -570,7 +559,7 @@ msgstr "" "この関数はたいていはクラスと定数をモジュールにします。\n" "この関数のシグネチャは以下です:" -#: ../../c-api/module.rst:384 +#: ../../c-api/module.rst:386 msgid "" "If multiple ``Py_mod_exec`` slots are specified, they are processed in the " "order they appear in the *m_slots* array." @@ -578,55 +567,55 @@ msgstr "" "複数の ``Py_mod_exec`` スロットが設定されていた場合は、 *m_slots* 配列に現れ" "た順に処理されていきます。" -#: ../../c-api/module.rst:389 ../../c-api/module.rst:422 +#: ../../c-api/module.rst:391 ../../c-api/module.rst:424 msgid "Specifies one of the following values:" msgstr "" -#: ../../c-api/module.rst:395 +#: ../../c-api/module.rst:397 msgid "The module does not support being imported in subinterpreters." msgstr "" -#: ../../c-api/module.rst:399 +#: ../../c-api/module.rst:401 msgid "" "The module supports being imported in subinterpreters, but only when they " "share the main interpreter's GIL. (See :ref:`isolating-extensions-howto`.)" msgstr "" -#: ../../c-api/module.rst:405 +#: ../../c-api/module.rst:407 msgid "" "The module supports being imported in subinterpreters, even when they have " "their own GIL. (See :ref:`isolating-extensions-howto`.)" msgstr "" -#: ../../c-api/module.rst:409 +#: ../../c-api/module.rst:411 msgid "" "This slot determines whether or not importing this module in a " "subinterpreter will fail." msgstr "" -#: ../../c-api/module.rst:412 +#: ../../c-api/module.rst:414 msgid "" "Multiple ``Py_mod_multiple_interpreters`` slots may not be specified in one " "module definition." msgstr "" -#: ../../c-api/module.rst:415 +#: ../../c-api/module.rst:417 msgid "" "If ``Py_mod_multiple_interpreters`` is not specified, the import machinery " "defaults to ``Py_MOD_MULTIPLE_INTERPRETERS_NOT_SUPPORTED``." msgstr "" -#: ../../c-api/module.rst:428 +#: ../../c-api/module.rst:430 msgid "" "The module depends on the presence of the global interpreter lock (GIL), and " "may access global state without synchronization." msgstr "" -#: ../../c-api/module.rst:433 +#: ../../c-api/module.rst:435 msgid "The module is safe to run without an active GIL." msgstr "" -#: ../../c-api/module.rst:435 +#: ../../c-api/module.rst:437 msgid "" "This slot is ignored by Python builds not configured with :option:`--disable-" "gil`. Otherwise, it determines whether or not importing this module will " @@ -634,26 +623,26 @@ msgid "" "threaded-cpython` for more detail." msgstr "" -#: ../../c-api/module.rst:440 +#: ../../c-api/module.rst:442 msgid "" "Multiple ``Py_mod_gil`` slots may not be specified in one module definition." msgstr "" -#: ../../c-api/module.rst:442 +#: ../../c-api/module.rst:444 msgid "" "If ``Py_mod_gil`` is not specified, the import machinery defaults to " "``Py_MOD_GIL_USED``." msgstr "" -#: ../../c-api/module.rst:447 +#: ../../c-api/module.rst:449 msgid "See :PEP:`489` for more details on multi-phase initialization." msgstr "多段階初期化についてより詳しくは :PEP:`489` を見てください。" -#: ../../c-api/module.rst:450 +#: ../../c-api/module.rst:452 msgid "Low-level module creation functions" msgstr "低水準モジュール作成関数" -#: ../../c-api/module.rst:452 +#: ../../c-api/module.rst:454 msgid "" "The following functions are called under the hood when using multi-phase " "initialization. They can be used directly, for example when creating module " @@ -666,14 +655,14 @@ msgstr "" "``PyModule_FromDefAndSpec`` および ``PyModule_ExecDef`` のどちらも、呼び出し" "た後にはモジュールが完全に初期化されていなければなりません。" -#: ../../c-api/module.rst:459 +#: ../../c-api/module.rst:461 msgid "" "Create a new module object, given the definition in *def* and the ModuleSpec " "*spec*. This behaves like :c:func:`PyModule_FromDefAndSpec2` with " "*module_api_version* set to :c:macro:`PYTHON_API_VERSION`." msgstr "" -#: ../../c-api/module.rst:467 +#: ../../c-api/module.rst:469 msgid "" "Create a new module object, given the definition in *def* and the ModuleSpec " "*spec*, assuming the API version *module_api_version*. If that version does " @@ -685,7 +674,7 @@ msgstr "" "もし指定されたバージョンが実行しているインタープリターのバージョンと異なる場" "合は、 :exc:`RuntimeWarning` を発生させます。" -#: ../../c-api/module.rst:476 +#: ../../c-api/module.rst:478 msgid "" "Most uses of this function should be using :c:func:`PyModule_FromDefAndSpec` " "instead; only use this if you are sure you need it." @@ -694,12 +683,12 @@ msgstr "" "べきです。\n" "この関数は、この関数の必要性を理解しているときにだけ利用してください。" -#: ../../c-api/module.rst:483 +#: ../../c-api/module.rst:485 msgid "Process any execution slots (:c:data:`Py_mod_exec`) given in *def*." msgstr "" "*def* で与えられた任意の実行スロット (:c:data:`Py_mod_exec`) を実行します。" -#: ../../c-api/module.rst:489 +#: ../../c-api/module.rst:491 msgid "" "Set the docstring for *module* to *docstring*. This function is called " "automatically when creating a module from ``PyModuleDef``, using either " @@ -710,7 +699,7 @@ msgstr "" "``PyModule_FromDefAndSpec`` を使ってモジュールを生成するときに自動的に呼び出" "されます。" -#: ../../c-api/module.rst:498 +#: ../../c-api/module.rst:500 msgid "" "Add the functions from the ``NULL`` terminated *functions* array to " "*module*. Refer to the :c:type:`PyMethodDef` documentation for details on " @@ -731,11 +720,11 @@ msgstr "" "``PyModule_FromDefAndSpec`` を使ってモジュールを生成するときに自動的に呼び出" "されます。" -#: ../../c-api/module.rst:510 +#: ../../c-api/module.rst:512 msgid "Support functions" msgstr "サポート関数" -#: ../../c-api/module.rst:512 +#: ../../c-api/module.rst:514 msgid "" "The module initialization function (if using single phase initialization) or " "a function called from a module execution slot (if using multi-phase " @@ -746,7 +735,7 @@ msgstr "" "ロットから呼び出される関数 (多段階初期化を使う場合) は次の関数を使うと、モ" "ジュールの state の初期化を簡単にできます:" -#: ../../c-api/module.rst:519 +#: ../../c-api/module.rst:521 msgid "" "Add an object to *module* as *name*. This is a convenience function which " "can be used from the module's initialization function." @@ -754,24 +743,24 @@ msgstr "" "*module* にオブジェクトを *name* として追加します。\n" "この関数はモジュールの初期化関数から利用される便利関数です。" -#: ../../c-api/module.rst:522 +#: ../../c-api/module.rst:524 msgid "" "On success, return ``0``. On error, raise an exception and return ``-1``." msgstr "" "成功すると ``0`` を返し、エラーになると例外を送出して ``-1`` を返します。" -#: ../../c-api/module.rst:524 +#: ../../c-api/module.rst:526 msgid "" "Return ``-1`` if *value* is ``NULL``. It must be called with an exception " "raised in this case." msgstr "" -#: ../../c-api/module.rst:527 ../../c-api/module.rst:574 -#: ../../c-api/module.rst:601 +#: ../../c-api/module.rst:529 ../../c-api/module.rst:576 +#: ../../c-api/module.rst:603 msgid "Example usage::" msgstr "使用例::" -#: ../../c-api/module.rst:529 +#: ../../c-api/module.rst:531 msgid "" "static int\n" "add_spam(PyObject *module, int value)\n" @@ -786,7 +775,7 @@ msgid "" " }" msgstr "" -#: ../../c-api/module.rst:541 +#: ../../c-api/module.rst:543 msgid "" "The example can also be written without checking explicitly if *obj* is " "``NULL``::" @@ -794,7 +783,7 @@ msgstr "" "この例は、明示的に *obj* が ``NULL`` であることを確認せずに書くこともできま" "す::" -#: ../../c-api/module.rst:544 +#: ../../c-api/module.rst:546 msgid "" "static int\n" "add_spam(PyObject *module, int value)\n" @@ -806,7 +795,7 @@ msgid "" " }" msgstr "" -#: ../../c-api/module.rst:553 +#: ../../c-api/module.rst:555 msgid "" "Note that ``Py_XDECREF()`` should be used instead of ``Py_DECREF()`` in this " "case, since *obj* can be ``NULL``." @@ -814,7 +803,7 @@ msgstr "" "この場合は、 *obj* が ``NULL`` でありうるため、 ``Py_DECREF()`` の代わりに " "``Py_XDECREF()`` を呼び出す必要があることに注意してください。" -#: ../../c-api/module.rst:556 +#: ../../c-api/module.rst:558 msgid "" "The number of different *name* strings passed to this function should be " "kept small, usually by only using statically allocated strings as *name*. " @@ -824,7 +813,7 @@ msgid "" "internally to create a key object." msgstr "" -#: ../../c-api/module.rst:569 +#: ../../c-api/module.rst:571 msgid "" "Similar to :c:func:`PyModule_AddObjectRef`, but \"steals\" a reference to " "*value*. It can be called with a result of function that returns a new " @@ -832,39 +821,39 @@ msgid "" "variable." msgstr "" -#: ../../c-api/module.rst:576 +#: ../../c-api/module.rst:578 msgid "" "if (PyModule_Add(module, \"spam\", PyBytes_FromString(value)) < 0) {\n" " goto error;\n" "}" msgstr "" -#: ../../c-api/module.rst:585 +#: ../../c-api/module.rst:587 msgid "" "Similar to :c:func:`PyModule_AddObjectRef`, but steals a reference to " "*value* on success (if it returns ``0``)." msgstr "" -#: ../../c-api/module.rst:588 +#: ../../c-api/module.rst:590 msgid "" "The new :c:func:`PyModule_Add` or :c:func:`PyModule_AddObjectRef` functions " "are recommended, since it is easy to introduce reference leaks by misusing " "the :c:func:`PyModule_AddObject` function." msgstr "" -#: ../../c-api/module.rst:595 +#: ../../c-api/module.rst:597 msgid "" "Unlike other functions that steal references, ``PyModule_AddObject()`` only " "releases the reference to *value* **on success**." msgstr "" -#: ../../c-api/module.rst:598 +#: ../../c-api/module.rst:600 msgid "" "This means that its return value must be checked, and calling code must :c:" "func:`Py_XDECREF` *value* manually on error." msgstr "" -#: ../../c-api/module.rst:603 +#: ../../c-api/module.rst:605 msgid "" "PyObject *obj = PyBytes_FromString(value);\n" "if (PyModule_AddObject(module, \"spam\", obj) < 0) {\n" @@ -878,24 +867,24 @@ msgid "" "// Py_XDECREF(obj) is not needed here." msgstr "" -#: ../../c-api/module.rst:616 +#: ../../c-api/module.rst:618 msgid ":c:func:`PyModule_AddObject` is :term:`soft deprecated`." msgstr "" -#: ../../c-api/module.rst:621 +#: ../../c-api/module.rst:623 msgid "" "Add an integer constant to *module* as *name*. This convenience function " "can be used from the module's initialization function. Return ``-1`` with an " "exception set on error, ``0`` on success." msgstr "" -#: ../../c-api/module.rst:625 +#: ../../c-api/module.rst:627 msgid "" "This is a convenience function that calls :c:func:`PyLong_FromLong` and :c:" "func:`PyModule_AddObjectRef`; see their documentation for details." msgstr "" -#: ../../c-api/module.rst:631 +#: ../../c-api/module.rst:633 msgid "" "Add a string constant to *module* as *name*. This convenience function can " "be used from the module's initialization function. The string *value* must " @@ -903,14 +892,14 @@ msgid "" "on success." msgstr "" -#: ../../c-api/module.rst:636 +#: ../../c-api/module.rst:638 msgid "" "This is a convenience function that calls :c:func:" "`PyUnicode_InternFromString` and :c:func:`PyModule_AddObjectRef`; see their " "documentation for details." msgstr "" -#: ../../c-api/module.rst:643 +#: ../../c-api/module.rst:645 msgid "" "Add an int constant to *module*. The name and the value are taken from " "*macro*. For example ``PyModule_AddIntMacro(module, AF_INET)`` adds the int " @@ -918,11 +907,11 @@ msgid "" "with an exception set on error, ``0`` on success." msgstr "" -#: ../../c-api/module.rst:651 +#: ../../c-api/module.rst:653 msgid "Add a string constant to *module*." msgstr "文字列定数を *module* に追加します。" -#: ../../c-api/module.rst:655 +#: ../../c-api/module.rst:657 msgid "" "Add a type object to *module*. The type object is finalized by calling " "internally :c:func:`PyType_Ready`. The name of the type object is taken from " @@ -930,7 +919,7 @@ msgid "" "``-1`` with an exception set on error, ``0`` on success." msgstr "" -#: ../../c-api/module.rst:665 +#: ../../c-api/module.rst:667 msgid "" "Indicate that *module* does or does not support running without the global " "interpreter lock (GIL), using one of the values from :c:macro:`Py_mod_gil`. " @@ -941,11 +930,11 @@ msgid "" "Return ``-1`` with an exception set on error, ``0`` on success." msgstr "" -#: ../../c-api/module.rst:678 +#: ../../c-api/module.rst:680 msgid "Module lookup" msgstr "モジュール検索" -#: ../../c-api/module.rst:680 +#: ../../c-api/module.rst:682 msgid "" "Single-phase initialization creates singleton modules that can be looked up " "in the context of the current interpreter. This allows the module object to " @@ -956,7 +945,7 @@ msgstr "" "これによって、後からモジュール定義への参照だけでモジュールオブジェクトが取得" "できます。" -#: ../../c-api/module.rst:684 +#: ../../c-api/module.rst:686 msgid "" "These functions will not work on modules created using multi-phase " "initialization, since multiple such modules can be created from a single " @@ -965,7 +954,7 @@ msgstr "" "多段階初期化を使うと単一の定義から複数のモジュールが作成できるので、これらの" "関数は多段階初期化を使って作成されたモジュールには使えません。" -#: ../../c-api/module.rst:689 +#: ../../c-api/module.rst:691 msgid "" "Returns the module object that was created from *def* for the current " "interpreter. This method requires that the module object has been attached " @@ -979,7 +968,7 @@ msgstr "" "ジュールオブジェクトが見付からない、もしくは事前にインタプリタの state に連結" "されていない場合は、 ``NULL`` を返します。" -#: ../../c-api/module.rst:696 +#: ../../c-api/module.rst:698 msgid "" "Attaches the module object passed to the function to the interpreter state. " "This allows the module object to be accessible via :c:func:" @@ -989,11 +978,11 @@ msgstr "" "の関数を使うことで :c:func:`PyState_FindModule` からモジュールオブジェクトに" "アクセスできるようになります。" -#: ../../c-api/module.rst:699 +#: ../../c-api/module.rst:701 msgid "Only effective on modules created using single-phase initialization." msgstr "一段階初期化を使って作成されたモジュールにのみ有効です。" -#: ../../c-api/module.rst:701 +#: ../../c-api/module.rst:703 msgid "" "Python calls ``PyState_AddModule`` automatically after importing a module, " "so it is unnecessary (but harmless) to call it from module initialization " @@ -1004,15 +993,15 @@ msgid "" "state updates)." msgstr "" -#: ../../c-api/module.rst:709 ../../c-api/module.rst:720 +#: ../../c-api/module.rst:711 ../../c-api/module.rst:722 msgid "The caller must hold the GIL." msgstr "呼び出し側はGILを獲得しなければなりません。" -#: ../../c-api/module.rst:711 +#: ../../c-api/module.rst:713 msgid "Return ``-1`` with an exception set on error, ``0`` on success." msgstr "" -#: ../../c-api/module.rst:717 +#: ../../c-api/module.rst:719 msgid "" "Removes the module object created from *def* from the interpreter state. " "Return ``-1`` with an exception set on error, ``0`` on success." @@ -1030,7 +1019,7 @@ msgstr "module" msgid "ModuleType (in module types)" msgstr "ModuleType (in module types)" -#: ../../c-api/module.rst:33 ../../c-api/module.rst:76 +#: ../../c-api/module.rst:33 ../../c-api/module.rst:77 msgid "__name__ (module attribute)" msgstr "__name__ (モジュール属性)" @@ -1038,7 +1027,7 @@ msgstr "__name__ (モジュール属性)" msgid "__doc__ (module attribute)" msgstr "__doc__ (モジュール属性)" -#: ../../c-api/module.rst:33 ../../c-api/module.rst:106 +#: ../../c-api/module.rst:33 ../../c-api/module.rst:108 msgid "__file__ (module attribute)" msgstr "__file__ (モジュール属性)" @@ -1050,10 +1039,10 @@ msgstr "" msgid "__loader__ (module attribute)" msgstr "" -#: ../../c-api/module.rst:62 +#: ../../c-api/module.rst:63 msgid "__dict__ (module attribute)" msgstr "__dict__ (モジュール属性)" -#: ../../c-api/module.rst:76 ../../c-api/module.rst:106 +#: ../../c-api/module.rst:77 ../../c-api/module.rst:108 msgid "SystemError (built-in exception)" msgstr "SystemError (組み込み例外)" diff --git a/c-api/tuple.po b/c-api/tuple.po index ba86c365c..494b97d10 100644 --- a/c-api/tuple.po +++ b/c-api/tuple.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:50+0000\n" "Last-Translator: tomo, 2023\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -144,8 +144,8 @@ msgstr "" ":c:func:`PyTuple_SetItem` に似ていますが、エラーチェックを行わず、新たなタプ" "ルに値を入れるとき *以外には使ってはなりません* 。" -#: ../../c-api/tuple.rst:102 ../../c-api/tuple.rst:217 -#: ../../c-api/tuple.rst:235 +#: ../../c-api/tuple.rst:102 ../../c-api/tuple.rst:218 +#: ../../c-api/tuple.rst:236 msgid "" "Bounds checking is performed as an assertion if Python is built in :ref:" "`debug mode ` or :option:`with assertions <--with-assertions>`." @@ -211,7 +211,7 @@ msgstr "" "後述の *desc* 中のデータから新しい struct sequence 型を生成します。返される型" "のインスタンスは :c:func:`PyStructSequence_New` で生成できます。" -#: ../../c-api/tuple.rst:142 ../../c-api/tuple.rst:210 +#: ../../c-api/tuple.rst:142 ../../c-api/tuple.rst:211 msgid "Return ``NULL`` with an exception set on failure." msgstr "" @@ -231,22 +231,24 @@ msgid "Contains the meta information of a struct sequence type to create." msgstr "生成するstruct sequence 型のメタデータを保持します。" #: ../../c-api/tuple.rst:164 -msgid "Name of the struct sequence type." +msgid "" +"Fully qualified name of the type; null-terminated UTF-8 encoded. The name " +"must contain the module name." msgstr "" -#: ../../c-api/tuple.rst:168 +#: ../../c-api/tuple.rst:169 msgid "Pointer to docstring for the type or ``NULL`` to omit." msgstr "" -#: ../../c-api/tuple.rst:172 +#: ../../c-api/tuple.rst:173 msgid "Pointer to ``NULL``-terminated array with field names of the new type." msgstr "" -#: ../../c-api/tuple.rst:176 +#: ../../c-api/tuple.rst:177 msgid "Number of fields visible to the Python side (if used as tuple)." msgstr "" -#: ../../c-api/tuple.rst:181 +#: ../../c-api/tuple.rst:182 msgid "" "Describes a field of a struct sequence. As a struct sequence is modeled as a " "tuple, all fields are typed as :c:expr:`PyObject*`. The index in the :c:" @@ -255,25 +257,25 @@ msgid "" "described." msgstr "" -#: ../../c-api/tuple.rst:189 +#: ../../c-api/tuple.rst:190 msgid "" "Name for the field or ``NULL`` to end the list of named fields, set to :c:" "data:`PyStructSequence_UnnamedField` to leave unnamed." msgstr "" -#: ../../c-api/tuple.rst:194 +#: ../../c-api/tuple.rst:195 msgid "Field docstring or ``NULL`` to omit." msgstr "" -#: ../../c-api/tuple.rst:199 +#: ../../c-api/tuple.rst:200 msgid "Special value for a field name to leave it unnamed." msgstr "フィールド名を名前がないままするための特殊な値。" -#: ../../c-api/tuple.rst:201 +#: ../../c-api/tuple.rst:202 msgid "The type was changed from ``char *``." msgstr "型が ``char *`` から変更されました。" -#: ../../c-api/tuple.rst:207 +#: ../../c-api/tuple.rst:208 msgid "" "Creates an instance of *type*, which must have been created with :c:func:" "`PyStructSequence_NewType`." @@ -281,20 +283,20 @@ msgstr "" "*type* のインスタンスを生成します。 *type* は :c:func:" "`PyStructSequence_NewType` によって事前に生成していなければなりません。" -#: ../../c-api/tuple.rst:215 +#: ../../c-api/tuple.rst:216 msgid "" "Return the object at position *pos* in the struct sequence pointed to by *p*." msgstr "" -#: ../../c-api/tuple.rst:223 +#: ../../c-api/tuple.rst:224 msgid "Alias to :c:func:`PyStructSequence_GetItem`." msgstr "" -#: ../../c-api/tuple.rst:225 +#: ../../c-api/tuple.rst:226 msgid "Now implemented as an alias to :c:func:`PyStructSequence_GetItem`." msgstr "" -#: ../../c-api/tuple.rst:231 +#: ../../c-api/tuple.rst:232 msgid "" "Sets the field at index *pos* of the struct sequence *p* to value *o*. " "Like :c:func:`PyTuple_SET_ITEM`, this should only be used to fill in brand " @@ -304,15 +306,15 @@ msgstr "" "func:`PyTuple_SET_ITEM` のように、生成したてのインスタンスに対してのみ使用す" "べきです。" -#: ../../c-api/tuple.rst:240 +#: ../../c-api/tuple.rst:241 msgid "This function \"steals\" a reference to *o*." msgstr "この関数は *o* への参照を \"盗み取り\" ます。" -#: ../../c-api/tuple.rst:245 +#: ../../c-api/tuple.rst:246 msgid "Alias to :c:func:`PyStructSequence_SetItem`." msgstr "" -#: ../../c-api/tuple.rst:247 +#: ../../c-api/tuple.rst:248 msgid "Now implemented as an alias to :c:func:`PyStructSequence_SetItem`." msgstr "" diff --git a/c-api/veryhigh.po b/c-api/veryhigh.po index 5de831f60..234f20efc 100644 --- a/c-api/veryhigh.po +++ b/c-api/veryhigh.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:50+0000\n" "Last-Translator: Arihiro TAKASE, 2023\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -60,45 +60,13 @@ msgstr "" #: ../../c-api/veryhigh.rst:30 msgid "" -"The main program for the standard interpreter. This is made available for " -"programs which embed Python. The *argc* and *argv* parameters should be " -"prepared exactly as those which are passed to a C program's :c:func:`main` " -"function (converted to wchar_t according to the user's locale). It is " -"important to note that the argument list may be modified (but the contents " -"of the strings pointed to by the argument list are not). The return value " -"will be ``0`` if the interpreter exits normally (i.e., without an " -"exception), ``1`` if the interpreter exits due to an exception, or ``2`` if " -"the parameter list does not represent a valid Python command line." -msgstr "" -"標準インタプリタのためのメインプログラム。Pythonを組み込むプログラムのために" -"これを利用できるようにしています。 *argc* と *argv* 引数をCプログラムの :c:" -"func:`main` 関数 (ユーザのロケールに従って wchar_t に変換されます) へ渡される" -"ものとまったく同じに作成すべきです。引数リストが変更される可能性があるという" -"点に注意することは重要です。 (しかし、引数リストが指している文字列の内容は変" -"更されません)。戻り値はインタプリタが(例外などではなく)普通に終了した時は " -"``0`` に、例外で終了したときには ``1`` に、引数リストが正しい Python コマンド" -"ラインが渡されなかったときは ``2`` になります。" - -#: ../../c-api/veryhigh.rst:40 -msgid "" -"Note that if an otherwise unhandled :exc:`SystemExit` is raised, this " -"function will not return ``1``, but exit the process, as long as :c:member:" -"`PyConfig.inspect` is zero." -msgstr "" - -#: ../../c-api/veryhigh.rst:47 -msgid "Similar to :c:func:`Py_Main` but *argv* is an array of bytes strings." -msgstr "" - -#: ../../c-api/veryhigh.rst:54 -msgid "" "This is a simplified interface to :c:func:`PyRun_AnyFileExFlags` below, " "leaving *closeit* set to ``0`` and *flags* set to ``NULL``." msgstr "" "下記の :c:func:`PyRun_AnyFileExFlags` の *closeit* を ``0`` に、 *flags* を " "``NULL`` にして単純化したインターフェースです。" -#: ../../c-api/veryhigh.rst:60 +#: ../../c-api/veryhigh.rst:36 msgid "" "This is a simplified interface to :c:func:`PyRun_AnyFileExFlags` below, " "leaving the *closeit* argument set to ``0``." @@ -106,7 +74,7 @@ msgstr "" "下記の :c:func:`PyRun_AnyFileExFlags` の *closeit* を ``0`` にして単純化した" "インターフェースです。" -#: ../../c-api/veryhigh.rst:66 +#: ../../c-api/veryhigh.rst:42 msgid "" "This is a simplified interface to :c:func:`PyRun_AnyFileExFlags` below, " "leaving the *flags* argument set to ``NULL``." @@ -114,7 +82,7 @@ msgstr "" "下記の :c:func:`PyRun_AnyFileExFlags` の *flags* を ``NULL`` にして単純化した" "インターフェースです。" -#: ../../c-api/veryhigh.rst:72 +#: ../../c-api/veryhigh.rst:48 msgid "" "If *fp* refers to a file associated with an interactive device (console or " "terminal input or Unix pseudo-terminal), return the value of :c:func:" @@ -132,7 +100,7 @@ msgstr "" "この関数はファイル名として ``\"???\"`` を使います。*closeit* が真なら、ファイ" "ルは ``PyRun_SimpleFileExFlags()`` が処理を戻す前に閉じられます。" -#: ../../c-api/veryhigh.rst:84 +#: ../../c-api/veryhigh.rst:60 msgid "" "This is a simplified interface to :c:func:`PyRun_SimpleStringFlags` below, " "leaving the :c:struct:`PyCompilerFlags`\\* argument set to ``NULL``." @@ -140,7 +108,7 @@ msgstr "" "下記の :c:func:`PyRun_SimpleStringFlags` の :c:struct:`PyCompilerFlags`\\* " "を ``NULL`` にして単純化したインタフェースです。" -#: ../../c-api/veryhigh.rst:90 +#: ../../c-api/veryhigh.rst:66 msgid "" "Executes the Python source code from *command* in the :mod:`__main__` module " "according to the *flags* argument. If :mod:`__main__` does not already " @@ -154,14 +122,14 @@ msgstr "" "します。エラーがあっても、例外情報を得る方法はありません。 *flags* の意味につ" "いては、後述します。" -#: ../../c-api/veryhigh.rst:96 +#: ../../c-api/veryhigh.rst:72 msgid "" "Note that if an otherwise unhandled :exc:`SystemExit` is raised, this " "function will not return ``-1``, but exit the process, as long as :c:member:" "`PyConfig.inspect` is zero." msgstr "" -#: ../../c-api/veryhigh.rst:103 +#: ../../c-api/veryhigh.rst:79 msgid "" "This is a simplified interface to :c:func:`PyRun_SimpleFileExFlags` below, " "leaving *closeit* set to ``0`` and *flags* set to ``NULL``." @@ -169,7 +137,7 @@ msgstr "" "下記の :c:func:`PyRun_SimpleFileExFlags` の *closeit* を ``0`` に、 *flags* " "を ``NULL`` にして単純化したインターフェースです。" -#: ../../c-api/veryhigh.rst:109 +#: ../../c-api/veryhigh.rst:85 msgid "" "This is a simplified interface to :c:func:`PyRun_SimpleFileExFlags` below, " "leaving *flags* set to ``NULL``." @@ -177,7 +145,7 @@ msgstr "" "下記の :c:func:`PyRun_SimpleFileExFlags` の *flags* を ``NULL`` にして単純化" "したインターフェースです。" -#: ../../c-api/veryhigh.rst:115 +#: ../../c-api/veryhigh.rst:91 msgid "" "Similar to :c:func:`PyRun_SimpleStringFlags`, but the Python source code is " "read from *fp* instead of an in-memory string. *filename* should be the name " @@ -192,7 +160,7 @@ msgstr "" "を指定した場合は、``PyRun_SimpleFileExFlags()`` が処理を戻す前にファイルを閉" "じます。" -#: ../../c-api/veryhigh.rst:122 +#: ../../c-api/veryhigh.rst:98 msgid "" "On Windows, *fp* should be opened as binary mode (e.g. ``fopen(filename, " "\"rb\")``). Otherwise, Python may not handle script file with LF line ending " @@ -202,7 +170,7 @@ msgstr "" "\"rb\")``)。\n" "そうしない場合は、 Python は行末が LF のスクリプトを正しく扱えないでしょう。" -#: ../../c-api/veryhigh.rst:128 +#: ../../c-api/veryhigh.rst:104 msgid "" "This is a simplified interface to :c:func:`PyRun_InteractiveOneFlags` below, " "leaving *flags* set to ``NULL``." @@ -210,7 +178,7 @@ msgstr "" "下記の :c:func:`PyRun_InteractiveOneFlags` の *flags* を ``NULL`` にして単純" "化したインターフェースです。" -#: ../../c-api/veryhigh.rst:134 +#: ../../c-api/veryhigh.rst:110 msgid "" "Read and execute a single statement from a file associated with an " "interactive device according to the *flags* argument. The user will be " @@ -222,7 +190,7 @@ msgstr "" "ます。 *filename* は :term:`ファイルシステムのエンコーディングとエラーハンド" "ラ ` でデコードされます。" -#: ../../c-api/veryhigh.rst:139 +#: ../../c-api/veryhigh.rst:115 msgid "" "Returns ``0`` when the input was executed successfully, ``-1`` if there was " "an exception, or an error code from the :file:`errcode.h` include file " @@ -236,7 +204,7 @@ msgstr "" "`Python.h` は :file:`errcode.h` をインクルードしません。従って、 必要な場合は" "その都度インクルードしなければならないことに注意してください。)" -#: ../../c-api/veryhigh.rst:148 +#: ../../c-api/veryhigh.rst:124 msgid "" "This is a simplified interface to :c:func:`PyRun_InteractiveLoopFlags` " "below, leaving *flags* set to ``NULL``." @@ -244,7 +212,7 @@ msgstr "" "下記の :c:func:`PyRun_InteractiveLoopFlags` の *flags* を ``NULL`` にして単純" "化したインターフェースです。" -#: ../../c-api/veryhigh.rst:154 +#: ../../c-api/veryhigh.rst:130 msgid "" "Read and execute statements from a file associated with an interactive " "device until EOF is reached. The user will be prompted using ``sys.ps1`` " @@ -258,7 +226,7 @@ msgstr "" "` でデコードされます。\n" "EOFに達すると ``0`` を返すか、失敗したら負の数を返します。" -#: ../../c-api/veryhigh.rst:162 +#: ../../c-api/veryhigh.rst:138 msgid "" "Can be set to point to a function with the prototype ``int func(void)``. " "The function will be called when Python's interpreter prompt is about to " @@ -275,13 +243,13 @@ msgstr "" "_tkinter.c` がやっているように、インタプリタのプロンプトと他のイベントループ" "を統合できます。" -#: ../../c-api/veryhigh.rst:170 ../../c-api/veryhigh.rst:194 +#: ../../c-api/veryhigh.rst:146 ../../c-api/veryhigh.rst:170 msgid "" "This function is only called from the :ref:`main interpreter `." msgstr "" -#: ../../c-api/veryhigh.rst:177 +#: ../../c-api/veryhigh.rst:153 msgid "" "Can be set to point to a function with the prototype ``char *func(FILE " "*stdin, FILE *stdout, char *prompt)``, overriding the default function used " @@ -300,7 +268,7 @@ msgstr "" "例えば、 :mod:`readline` モジュールはこのフックを設定して、行編集機能やタブ補" "完機能を提供しています。" -#: ../../c-api/veryhigh.rst:186 +#: ../../c-api/veryhigh.rst:162 msgid "" "The result must be a string allocated by :c:func:`PyMem_RawMalloc` or :c:" "func:`PyMem_RawRealloc`, or ``NULL`` if an error occurred." @@ -309,7 +277,7 @@ msgstr "" "確保した文字列、あるいはエラーが起きた場合には ``NULL`` でなければなりませ" "ん。" -#: ../../c-api/veryhigh.rst:189 +#: ../../c-api/veryhigh.rst:165 msgid "" "The result must be allocated by :c:func:`PyMem_RawMalloc` or :c:func:" "`PyMem_RawRealloc`, instead of being allocated by :c:func:`PyMem_Malloc` or :" @@ -319,7 +287,7 @@ msgstr "" "func:`PyMem_RawMalloc` または :c:func:`PyMem_RawRealloc` でメモリ確保したもの" "でなければなりません。" -#: ../../c-api/veryhigh.rst:200 +#: ../../c-api/veryhigh.rst:176 msgid "" "This is a simplified interface to :c:func:`PyRun_StringFlags` below, leaving " "*flags* set to ``NULL``." @@ -327,7 +295,7 @@ msgstr "" "下記の :c:func:`PyRun_StringFlags` の *flags* を ``NULL`` にして単純化したイ" "ンターフェースです。" -#: ../../c-api/veryhigh.rst:206 +#: ../../c-api/veryhigh.rst:182 msgid "" "Execute Python source code from *str* in the context specified by the " "objects *globals* and *locals* with the compiler flags specified by " @@ -343,7 +311,7 @@ msgstr "" "引数 *start* はソースコードをパースするために使われるべき開始トークンを指定し" "ます。" -#: ../../c-api/veryhigh.rst:212 +#: ../../c-api/veryhigh.rst:188 msgid "" "Returns the result of executing the code as a Python object, or ``NULL`` if " "an exception was raised." @@ -351,7 +319,7 @@ msgstr "" "コードを実行した結果をPythonオブジェクトとして返します。または、例外が発生し" "たならば ``NULL`` を返します。" -#: ../../c-api/veryhigh.rst:218 +#: ../../c-api/veryhigh.rst:194 msgid "" "This is a simplified interface to :c:func:`PyRun_FileExFlags` below, leaving " "*closeit* set to ``0`` and *flags* set to ``NULL``." @@ -359,7 +327,7 @@ msgstr "" "下記の :c:func:`PyRun_FileExFlags` の *closeit* を ``0`` にし、 *flags* を " "``NULL`` にして単純化したインターフェースです。" -#: ../../c-api/veryhigh.rst:224 +#: ../../c-api/veryhigh.rst:200 msgid "" "This is a simplified interface to :c:func:`PyRun_FileExFlags` below, leaving " "*flags* set to ``NULL``." @@ -367,7 +335,7 @@ msgstr "" "下記の :c:func:`PyRun_FileExFlags` の *flags* を ``NULL`` にして単純化したイ" "ンターフェースです。" -#: ../../c-api/veryhigh.rst:230 +#: ../../c-api/veryhigh.rst:206 msgid "" "This is a simplified interface to :c:func:`PyRun_FileExFlags` below, leaving " "*closeit* set to ``0``." @@ -375,7 +343,7 @@ msgstr "" "下記の :c:func:`PyRun_FileExFlags` の *closeit* を ``0`` にして単純化したイン" "ターフェースです。" -#: ../../c-api/veryhigh.rst:236 +#: ../../c-api/veryhigh.rst:212 msgid "" "Similar to :c:func:`PyRun_StringFlags`, but the Python source code is read " "from *fp* instead of an in-memory string. *filename* should be the name of " @@ -390,7 +358,7 @@ msgstr "" "を指定した場合は、:c:func:`PyRun_FileExFlags` が処理を戻す前にファイルを閉じ" "ます。" -#: ../../c-api/veryhigh.rst:245 +#: ../../c-api/veryhigh.rst:221 msgid "" "This is a simplified interface to :c:func:`Py_CompileStringFlags` below, " "leaving *flags* set to ``NULL``." @@ -398,7 +366,7 @@ msgstr "" "下記の :c:func:`Py_CompileStringFlags` の *flags* を ``NULL`` にして単純化し" "たインターフェースです。" -#: ../../c-api/veryhigh.rst:251 +#: ../../c-api/veryhigh.rst:227 msgid "" "This is a simplified interface to :c:func:`Py_CompileStringExFlags` below, " "with *optimize* set to ``-1``." @@ -406,7 +374,7 @@ msgstr "" "下記の :c:func:`Py_CompileStringExFlags` の *optimize* を ``-1`` にして単純化" "したインターフェースです。" -#: ../../c-api/veryhigh.rst:257 +#: ../../c-api/veryhigh.rst:233 msgid "" "Parse and compile the Python source code in *str*, returning the resulting " "code object. The start token is given by *start*; this can be used to " @@ -417,7 +385,7 @@ msgid "" "returns ``NULL`` if the code cannot be parsed or compiled." msgstr "" -#: ../../c-api/veryhigh.rst:265 +#: ../../c-api/veryhigh.rst:241 msgid "" "The integer *optimize* specifies the optimization level of the compiler; a " "value of ``-1`` selects the optimization level of the interpreter as given " @@ -430,7 +398,7 @@ msgstr "" "明示的なレベルは、 ``0`` (最適化なし、 ``__debug__`` は真)、 ``1`` (assert は" "取り除かれ、 ``__debug__`` は偽)、 ``2`` (docstring も取り除かれる) です。" -#: ../../c-api/veryhigh.rst:276 +#: ../../c-api/veryhigh.rst:252 msgid "" "Like :c:func:`Py_CompileStringObject`, but *filename* is a byte string " "decoded from the :term:`filesystem encoding and error handler`." @@ -439,7 +407,7 @@ msgstr "" "ルシステムのエンコーディングとエラーハンドラ ` でデコードされたバイト文字列です。" -#: ../../c-api/veryhigh.rst:283 +#: ../../c-api/veryhigh.rst:259 msgid "" "This is a simplified interface to :c:func:`PyEval_EvalCodeEx`, with just the " "code object, and global and local variables. The other arguments are set to " @@ -449,7 +417,7 @@ msgstr "" "トと、グローバル変数とローカル変数だけを受け取ります。\n" "他の引数には ``NULL`` が渡されます。" -#: ../../c-api/veryhigh.rst:290 +#: ../../c-api/veryhigh.rst:266 msgid "" "Evaluate a precompiled code object, given a particular environment for its " "evaluation. This environment consists of a dictionary of global variables, " @@ -462,7 +430,7 @@ msgstr "" "列、キーワードとデフォルト値、:ref:`キーワード専用 ` " "引数のデフォルト値の辞書と、セルのクロージャタプルで構成されます。" -#: ../../c-api/veryhigh.rst:299 +#: ../../c-api/veryhigh.rst:275 msgid "" "Evaluate an execution frame. This is a simplified interface to :c:func:" "`PyEval_EvalFrameEx`, for backward compatibility." @@ -470,7 +438,7 @@ msgstr "" "実行フレームを評価します。これは :c:func:`PyEval_EvalFrameEx` に対するシンプ" "ルなインターフェースで、後方互換性のためのものです。" -#: ../../c-api/veryhigh.rst:305 +#: ../../c-api/veryhigh.rst:281 msgid "" "This is the main, unvarnished function of Python interpretation. The code " "object associated with the execution frame *f* is executed, interpreting " @@ -485,7 +453,7 @@ msgstr "" "し true なら、 すぐに例外を発生させます。これはジェネレータオブジェクトの :" "meth:`~generator.throw` メソッドで利用されます。" -#: ../../c-api/veryhigh.rst:312 +#: ../../c-api/veryhigh.rst:288 msgid "" "This function now includes a debug assertion to help ensure that it does not " "silently discard an active exception." @@ -493,7 +461,7 @@ msgstr "" "アクティブな例外を黙って捨てないことを保証するのに便利なように、この関数はデ" "バッグアサーションを含むようになりました。" -#: ../../c-api/veryhigh.rst:319 +#: ../../c-api/veryhigh.rst:295 msgid "" "This function changes the flags of the current evaluation frame, and returns " "true on success, false on failure." @@ -501,7 +469,7 @@ msgstr "" "現在の評価フレームのフラグを変更します。成功したら true を、失敗したら false " "を返します。" -#: ../../c-api/veryhigh.rst:327 +#: ../../c-api/veryhigh.rst:303 msgid "" "The start symbol from the Python grammar for isolated expressions; for use " "with :c:func:`Py_CompileString`." @@ -509,7 +477,7 @@ msgstr "" "単独の式に対するPython文法の開始記号で、 :c:func:`Py_CompileString` と一緒に" "使います。" -#: ../../c-api/veryhigh.rst:335 +#: ../../c-api/veryhigh.rst:311 msgid "" "The start symbol from the Python grammar for sequences of statements as read " "from a file or other source; for use with :c:func:`Py_CompileString`. This " @@ -519,7 +487,7 @@ msgstr "" "号で、 :c:func:`Py_CompileString` と一緒に使います。これは任意の長さのPython" "ソースコードをコンパイルするときに使う記号です。" -#: ../../c-api/veryhigh.rst:344 +#: ../../c-api/veryhigh.rst:320 msgid "" "The start symbol from the Python grammar for a single statement; for use " "with :c:func:`Py_CompileString`. This is the symbol used for the interactive " @@ -528,7 +496,7 @@ msgstr "" "単一の文に対するPython文法の開始記号で、 :c:func:`Py_CompileString` と一緒に" "使います。これは対話式のインタプリタループのための記号です。" -#: ../../c-api/veryhigh.rst:351 +#: ../../c-api/veryhigh.rst:327 msgid "" "This is the structure used to hold compiler flags. In cases where code is " "only being compiled, it is passed as ``int flags``, and in cases where code " @@ -540,34 +508,34 @@ msgstr "" "``PyCompilerFlags *flags`` として渡されます。この場合、``from __future__ " "import`` は *flags* の内容を変更できます。" -#: ../../c-api/veryhigh.rst:356 +#: ../../c-api/veryhigh.rst:332 msgid "" "Whenever ``PyCompilerFlags *flags`` is ``NULL``, :c:member:`~PyCompilerFlags." "cf_flags` is treated as equal to ``0``, and any modification due to ``from " "__future__ import`` is discarded." msgstr "" -#: ../../c-api/veryhigh.rst:362 +#: ../../c-api/veryhigh.rst:338 msgid "Compiler flags." msgstr "コンパイラフラグ。" -#: ../../c-api/veryhigh.rst:366 +#: ../../c-api/veryhigh.rst:342 msgid "" "*cf_feature_version* is the minor Python version. It should be initialized " "to ``PY_MINOR_VERSION``." msgstr "" -#: ../../c-api/veryhigh.rst:369 +#: ../../c-api/veryhigh.rst:345 msgid "" "The field is ignored by default, it is used if and only if ``PyCF_ONLY_AST`` " "flag is set in :c:member:`~PyCompilerFlags.cf_flags`." msgstr "" -#: ../../c-api/veryhigh.rst:372 +#: ../../c-api/veryhigh.rst:348 msgid "Added *cf_feature_version* field." msgstr "" -#: ../../c-api/veryhigh.rst:378 +#: ../../c-api/veryhigh.rst:354 msgid "" "This bit can be set in *flags* to cause division operator ``/`` to be " "interpreted as \"true division\" according to :pep:`238`." @@ -575,7 +543,7 @@ msgstr "" "このビットを *flags* にセットすると、除算演算子 ``/`` は :pep:`238` による" "「真の除算 (true division)」として扱われます。" -#: ../../c-api/veryhigh.rst:325 ../../c-api/veryhigh.rst:333 -#: ../../c-api/veryhigh.rst:342 +#: ../../c-api/veryhigh.rst:301 ../../c-api/veryhigh.rst:309 +#: ../../c-api/veryhigh.rst:318 msgid "Py_CompileString (C function)" msgstr "" diff --git a/glossary.po b/glossary.po index 948acdf91..688c7b0cb 100644 --- a/glossary.po +++ b/glossary.po @@ -4,7 +4,6 @@ # FIRST AUTHOR , YEAR. # # Translators: -# tomo, 2021 # Osamu NAKAMURA, 2021 # Yusuke Miyazaki , 2021 # mollinaca, 2021 @@ -14,15 +13,16 @@ # Taichi Haradaguchi, 2024 # 石井明久, 2024 # Arihiro TAKASE, 2024 +# tomo, 2024 # #, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:47+0000\n" -"Last-Translator: Arihiro TAKASE, 2024\n" +"Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" "ja/)\n" "MIME-Version: 1.0\n" @@ -551,10 +551,50 @@ msgstr "" "上ではなしに) 変更されることを目的としている変数です。" #: ../../glossary.rst:228 +msgid "closure variable" +msgstr "" + +#: ../../glossary.rst:230 +msgid "" +"A :term:`free variable` referenced from a :term:`nested scope` that is " +"defined in an outer scope rather than being resolved at runtime from the " +"globals or builtin namespaces. May be explicitly defined with the :keyword:" +"`nonlocal` keyword to allow write access, or implicitly defined if the " +"variable is only being read." +msgstr "" + +#: ../../glossary.rst:235 +msgid "" +"For example, in the ``inner`` function in the following code, both ``x`` and " +"``print`` are :term:`free variables `, but only ``x`` is a " +"*closure variable*::" +msgstr "" + +#: ../../glossary.rst:238 +msgid "" +"def outer():\n" +" x = 0\n" +" def inner():\n" +" nonlocal x\n" +" x += 1\n" +" print(x)\n" +" return inner" +msgstr "" + +#: ../../glossary.rst:246 +msgid "" +"Due to the :attr:`codeobject.co_freevars` attribute (which, despite its " +"name, only includes the names of closure variables rather than listing all " +"referenced free variables), the more general :term:`free variable` term is " +"sometimes used even when the intended meaning is to refer specifically to " +"closure variables." +msgstr "" + +#: ../../glossary.rst:250 msgid "complex number" msgstr "complex number" -#: ../../glossary.rst:230 +#: ../../glossary.rst:252 msgid "" "An extension of the familiar real number system in which all numbers are " "expressed as a sum of a real part and an imaginary part. Imaginary numbers " @@ -574,22 +614,22 @@ msgstr "" "`cmath` を使います。複素数の使用はかなり高度な数学の機能です。必要性を感じな" "ければ、ほぼ間違いなく無視してしまってよいでしょう。" -#: ../../glossary.rst:240 +#: ../../glossary.rst:262 msgid "context manager" msgstr "context manager" -#: ../../glossary.rst:242 +#: ../../glossary.rst:264 msgid "" "An object which controls the environment seen in a :keyword:`with` statement " "by defining :meth:`~object.__enter__` and :meth:`~object.__exit__` methods. " "See :pep:`343`." msgstr "" -#: ../../glossary.rst:245 +#: ../../glossary.rst:267 msgid "context variable" msgstr "context variable" -#: ../../glossary.rst:247 +#: ../../glossary.rst:269 msgid "" "A variable which can have different values depending on its context. This is " "similar to Thread-Local Storage in which each execution thread may have a " @@ -605,11 +645,11 @@ msgstr "" "得、コンテキスト変数の主な用途は並列な非同期タスクの変数の追跡です。\n" ":mod:`contextvars` を参照してください。" -#: ../../glossary.rst:254 +#: ../../glossary.rst:276 msgid "contiguous" msgstr "contiguous" -#: ../../glossary.rst:258 +#: ../../glossary.rst:280 msgid "" "A buffer is considered contiguous exactly if it is either *C-contiguous* or " "*Fortran contiguous*. Zero-dimensional buffers are C and Fortran " @@ -627,11 +667,11 @@ msgstr "" "多次元の C-連続な配列では、メモリアドレス順に要素を巡る際には最後の添え字が最" "初に変わるのに対し、 Fortran 連続な配列では最初の添え字が最初に動きます。" -#: ../../glossary.rst:266 +#: ../../glossary.rst:288 msgid "coroutine" msgstr "コルーチン" -#: ../../glossary.rst:268 +#: ../../glossary.rst:290 msgid "" "Coroutines are a more generalized form of subroutines. Subroutines are " "entered at one point and exited at another point. Coroutines can be " @@ -644,11 +684,11 @@ msgstr "" "コルーチンは :keyword:`async def` 文で実装できます。\n" ":pep:`492` を参照してください。" -#: ../../glossary.rst:273 +#: ../../glossary.rst:295 msgid "coroutine function" msgstr "coroutine function" -#: ../../glossary.rst:275 +#: ../../glossary.rst:297 msgid "" "A function which returns a :term:`coroutine` object. A coroutine function " "may be defined with the :keyword:`async def` statement, and may contain :" @@ -662,11 +702,11 @@ msgstr "" "ます。\n" "これらは :pep:`492` で導入されました。" -#: ../../glossary.rst:280 +#: ../../glossary.rst:302 msgid "CPython" msgstr "CPython" -#: ../../glossary.rst:282 +#: ../../glossary.rst:304 msgid "" "The canonical implementation of the Python programming language, as " "distributed on `python.org `_. The term \"CPython\" " @@ -677,11 +717,11 @@ msgstr "" "グ言語の標準的な実装です。\"CPython\" という単語は、この実装を Jython や " "IronPython といった他の実装と区別する必要が有る場合に利用されます。" -#: ../../glossary.rst:286 +#: ../../glossary.rst:308 msgid "decorator" msgstr "decorator" -#: ../../glossary.rst:288 +#: ../../glossary.rst:310 msgid "" "A function returning another function, usually applied as a function " "transformation using the ``@wrapper`` syntax. Common examples for " @@ -691,7 +731,7 @@ msgstr "" "用されます。デコレータの一般的な利用例は、 :func:`classmethod` と :func:" "`staticmethod` です。" -#: ../../glossary.rst:292 +#: ../../glossary.rst:314 msgid "" "The decorator syntax is merely syntactic sugar, the following two function " "definitions are semantically equivalent::" @@ -699,7 +739,7 @@ msgstr "" "デコレータの文法はシンタックスシュガーです。次の2つの関数定義は意味的に同じも" "のです::" -#: ../../glossary.rst:295 +#: ../../glossary.rst:317 msgid "" "def f(arg):\n" " ...\n" @@ -710,7 +750,7 @@ msgid "" " ..." msgstr "" -#: ../../glossary.rst:303 +#: ../../glossary.rst:325 msgid "" "The same concept exists for classes, but is less commonly used there. See " "the documentation for :ref:`function definitions ` and :ref:`class " @@ -720,11 +760,11 @@ msgstr "" "くは、 :ref:`関数定義 ` および :ref:`クラス定義 ` のドキュメ" "ントを参照してください。" -#: ../../glossary.rst:306 +#: ../../glossary.rst:328 msgid "descriptor" msgstr "descriptor" -#: ../../glossary.rst:308 +#: ../../glossary.rst:330 msgid "" "Any object which defines the methods :meth:`~object.__get__`, :meth:`~object." "__set__`, or :meth:`~object.__delete__`. When a class attribute is a " @@ -737,7 +777,7 @@ msgid "" "methods, static methods, and reference to super classes." msgstr "" -#: ../../glossary.rst:319 +#: ../../glossary.rst:341 msgid "" "For more information about descriptors' methods, see :ref:`descriptors` or " "the :ref:`Descriptor How To Guide `." @@ -745,22 +785,22 @@ msgstr "" "デスクリプタのメソッドに関しての詳細は、 :ref:`descriptors` や :ref:" "`Descriptor How To Guide ` を参照してください。" -#: ../../glossary.rst:321 +#: ../../glossary.rst:343 msgid "dictionary" msgstr "dictionary" -#: ../../glossary.rst:323 +#: ../../glossary.rst:345 msgid "" "An associative array, where arbitrary keys are mapped to values. The keys " "can be any object with :meth:`~object.__hash__` and :meth:`~object.__eq__` " "methods. Called a hash in Perl." msgstr "" -#: ../../glossary.rst:327 +#: ../../glossary.rst:349 msgid "dictionary comprehension" msgstr "dictionary comprehension" -#: ../../glossary.rst:329 +#: ../../glossary.rst:351 msgid "" "A compact way to process all or part of the elements in an iterable and " "return a dictionary with the results. ``results = {n: n ** 2 for n in " @@ -772,11 +812,11 @@ msgstr "" "range(10)}`` とすると、キー ``n`` を値 ``n ** 2`` に対応付ける辞書を生成しま" "す。 :ref:`comprehensions` を参照してください。" -#: ../../glossary.rst:333 +#: ../../glossary.rst:355 msgid "dictionary view" msgstr "dictionary view" -#: ../../glossary.rst:335 +#: ../../glossary.rst:357 msgid "" "The objects returned from :meth:`dict.keys`, :meth:`dict.values`, and :meth:" "`dict.items` are called dictionary views. They provide a dynamic view on the " @@ -793,11 +833,11 @@ msgstr "" "さい。 \n" ":ref:`dict-views` を参照してください。" -#: ../../glossary.rst:341 +#: ../../glossary.rst:363 msgid "docstring" msgstr "docstring" -#: ../../glossary.rst:343 +#: ../../glossary.rst:365 msgid "" "A string literal which appears as the first expression in a class, function " "or module. While ignored when the suite is executed, it is recognized by " @@ -806,11 +846,11 @@ msgid "" "introspection, it is the canonical place for documentation of the object." msgstr "" -#: ../../glossary.rst:349 +#: ../../glossary.rst:371 msgid "duck-typing" msgstr "duck-typing" -#: ../../glossary.rst:351 +#: ../../glossary.rst:373 msgid "" "A programming style which does not look at an object's type to determine if " "it has the right interface; instead, the method or attribute is simply " @@ -832,11 +872,11 @@ msgstr "" "class>` で補完することもできます。) その代わり、典型的に :func:`hasattr` 判定" "や :term:`EAFP` プログラミングを利用します。" -#: ../../glossary.rst:360 +#: ../../glossary.rst:382 msgid "EAFP" msgstr "EAFP" -#: ../../glossary.rst:362 +#: ../../glossary.rst:384 msgid "" "Easier to ask for forgiveness than permission. This common Python coding " "style assumes the existence of valid keys or attributes and catches " @@ -853,11 +893,11 @@ msgstr "" "す。このテクニックは、C のような言語でよく使われている :term:`LBYL` スタイル" "と対照的なものです。" -#: ../../glossary.rst:368 +#: ../../glossary.rst:390 msgid "expression" msgstr "expression" -#: ../../glossary.rst:370 +#: ../../glossary.rst:392 msgid "" "A piece of syntax which can be evaluated to some value. In other words, an " "expression is an accumulation of expression elements like literals, names, " @@ -873,11 +913,11 @@ msgstr "" "素が式というわけではありません。 :keyword:`while` のように、式としては使えな" "い :term:`文 ` もあります。代入も式ではなく文です。" -#: ../../glossary.rst:377 +#: ../../glossary.rst:399 msgid "extension module" msgstr "extension module" -#: ../../glossary.rst:379 +#: ../../glossary.rst:401 msgid "" "A module written in C or C++, using Python's C API to interact with the core " "and with user code." @@ -885,11 +925,11 @@ msgstr "" "(拡張モジュール) C や C++ で書かれたモジュールで、Python の C API を利用して " "Python コアやユーザーコードとやりとりします。" -#: ../../glossary.rst:381 +#: ../../glossary.rst:403 msgid "f-string" msgstr "f-string" -#: ../../glossary.rst:383 +#: ../../glossary.rst:405 msgid "" "String literals prefixed with ``'f'`` or ``'F'`` are commonly called \"f-" "strings\" which is short for :ref:`formatted string literals `. " @@ -899,11 +939,11 @@ msgstr "" "は :ref:`フォーマット済み文字列リテラル ` の短縮形の名称です。\n" ":pep:`498` も参照してください。" -#: ../../glossary.rst:386 +#: ../../glossary.rst:408 msgid "file object" msgstr "file object" -#: ../../glossary.rst:388 +#: ../../glossary.rst:410 msgid "" "An object exposing a file-oriented API (with methods such as :meth:`!read` " "or :meth:`!write`) to an underlying resource. Depending on the way it was " @@ -913,7 +953,7 @@ msgid "" "called :dfn:`file-like objects` or :dfn:`streams`." msgstr "" -#: ../../glossary.rst:396 +#: ../../glossary.rst:418 msgid "" "There are actually three categories of file objects: raw :term:`binary files " "`, buffered :term:`binary files ` and :term:`text " @@ -927,25 +967,25 @@ msgstr "" "`io` モジュールで定義されています。ファイルオブジェクトを作る標準的な方法は :" "func:`open` 関数を使うことです。" -#: ../../glossary.rst:401 +#: ../../glossary.rst:423 msgid "file-like object" msgstr "file-like object" -#: ../../glossary.rst:403 +#: ../../glossary.rst:425 msgid "A synonym for :term:`file object`." msgstr ":term:`file object` と同義です。" -#: ../../glossary.rst:404 +#: ../../glossary.rst:426 msgid "filesystem encoding and error handler" msgstr "" -#: ../../glossary.rst:406 +#: ../../glossary.rst:428 msgid "" "Encoding and error handler used by Python to decode bytes from the operating " "system and encode Unicode to the operating system." msgstr "" -#: ../../glossary.rst:409 +#: ../../glossary.rst:431 msgid "" "The filesystem encoding must guarantee to successfully decode all bytes " "below 128. If the file system encoding fails to provide this guarantee, API " @@ -956,14 +996,14 @@ msgstr "" "でこれが保証されなかった場合は、API 関数が :exc:`UnicodeError` を送出すること" "があります。" -#: ../../glossary.rst:413 +#: ../../glossary.rst:435 msgid "" "The :func:`sys.getfilesystemencoding` and :func:`sys." "getfilesystemencodeerrors` functions can be used to get the filesystem " "encoding and error handler." msgstr "" -#: ../../glossary.rst:417 +#: ../../glossary.rst:439 msgid "" "The :term:`filesystem encoding and error handler` are configured at Python " "startup by the :c:func:`PyConfig_Read` function: see :c:member:`~PyConfig." @@ -971,15 +1011,15 @@ msgid "" "c:type:`PyConfig`." msgstr "" -#: ../../glossary.rst:422 +#: ../../glossary.rst:444 msgid "See also the :term:`locale encoding`." msgstr "" -#: ../../glossary.rst:423 +#: ../../glossary.rst:445 msgid "finder" msgstr "finder" -#: ../../glossary.rst:425 +#: ../../glossary.rst:447 msgid "" "An object that tries to find the :term:`loader` for a module that is being " "imported." @@ -988,22 +1028,23 @@ msgstr "" "インポートされているモジュールの :term:`loader` の発見を試行するオブジェクト" "です。" -#: ../../glossary.rst:428 +#: ../../glossary.rst:450 msgid "" "There are two types of finder: :term:`meta path finders ` " "for use with :data:`sys.meta_path`, and :term:`path entry finders ` for use with :data:`sys.path_hooks`." msgstr "" -#: ../../glossary.rst:432 -msgid "See :ref:`importsystem` and :mod:`importlib` for much more detail." +#: ../../glossary.rst:454 +msgid "" +"See :ref:`finders-and-loaders` and :mod:`importlib` for much more detail." msgstr "" -#: ../../glossary.rst:433 +#: ../../glossary.rst:455 msgid "floor division" msgstr "floor division" -#: ../../glossary.rst:435 +#: ../../glossary.rst:457 msgid "" "Mathematical division that rounds down to nearest integer. The floor " "division operator is ``//``. For example, the expression ``11 // 4`` " @@ -1019,11 +1060,11 @@ msgstr "" "を行う) ので ``-3`` になることに注意してください。\n" ":pep:`238` を参照してください。" -#: ../../glossary.rst:440 +#: ../../glossary.rst:462 msgid "free threading" msgstr "" -#: ../../glossary.rst:442 +#: ../../glossary.rst:464 msgid "" "A threading model where multiple threads can run Python bytecode " "simultaneously within the same interpreter. This is in contrast to the :" @@ -1031,11 +1072,25 @@ msgid "" "Python bytecode at a time. See :pep:`703`." msgstr "" -#: ../../glossary.rst:446 +#: ../../glossary.rst:468 +msgid "free variable" +msgstr "" + +#: ../../glossary.rst:470 +msgid "" +"Formally, as defined in the :ref:`language execution model `, a " +"free variable is any variable used in a namespace which is not a local " +"variable in that namespace. See :term:`closure variable` for an example. " +"Pragmatically, due to the name of the :attr:`codeobject.co_freevars` " +"attribute, the term is also sometimes used as a synonym for :term:`closure " +"variable`." +msgstr "" + +#: ../../glossary.rst:475 msgid "function" msgstr "関数" -#: ../../glossary.rst:448 +#: ../../glossary.rst:477 msgid "" "A series of statements which returns some value to a caller. It can also be " "passed zero or more :term:`arguments ` which may be used in the " @@ -1047,16 +1102,16 @@ msgstr "" "す。 :term:`仮引数 `、:term:`メソッド `、:ref:`function` " "を参照してください。" -#: ../../glossary.rst:452 +#: ../../glossary.rst:481 msgid "function annotation" msgstr "function annotation" -#: ../../glossary.rst:454 +#: ../../glossary.rst:483 msgid "An :term:`annotation` of a function parameter or return value." msgstr "" "(関数アノテーション) 関数のパラメータや返り値の :term:`annotation` です。" -#: ../../glossary.rst:456 +#: ../../glossary.rst:485 msgid "" "Function annotations are usually used for :term:`type hints `: " "for example, this function is expected to take two :class:`int` arguments " @@ -1066,17 +1121,17 @@ msgstr "" "す: 例えば、この関数は 2 つの :class:`int` 型の引数を取ると期待され、また :" "class:`int` 型の返り値を持つと期待されています。" -#: ../../glossary.rst:461 +#: ../../glossary.rst:490 msgid "" "def sum_two_numbers(a: int, b: int) -> int:\n" " return a + b" msgstr "" -#: ../../glossary.rst:464 +#: ../../glossary.rst:493 msgid "Function annotation syntax is explained in section :ref:`function`." msgstr "関数アノテーションの文法は :ref:`function` の節で解説されています。" -#: ../../glossary.rst:466 +#: ../../glossary.rst:495 msgid "" "See :term:`variable annotation` and :pep:`484`, which describe this " "functionality. Also see :ref:`annotations-howto` for best practices on " @@ -1086,11 +1141,11 @@ msgstr "" "また、アノテーションを利用するベストプラクティスとして :ref:`annotations-" "howto` も参照してください。" -#: ../../glossary.rst:470 +#: ../../glossary.rst:499 msgid "__future__" msgstr "__future__" -#: ../../glossary.rst:472 +#: ../../glossary.rst:501 msgid "" "A :ref:`future statement `, ``from __future__ import ``, " "directs the compiler to compile the current module using syntax or semantics " @@ -1107,18 +1162,18 @@ msgstr "" "し、その変数を評価することで、新機能が最初に言語に追加されたのはいつかや、い" "つデフォルトになるか (またはなったか) を見ることができます::" -#: ../../glossary.rst:480 +#: ../../glossary.rst:509 msgid "" ">>> import __future__\n" ">>> __future__.division\n" "_Feature((2, 2, 0, 'alpha', 2), (3, 0, 0, 'alpha', 0), 8192)" msgstr "" -#: ../../glossary.rst:483 +#: ../../glossary.rst:512 msgid "garbage collection" msgstr "garbage collection" -#: ../../glossary.rst:485 +#: ../../glossary.rst:514 msgid "" "The process of freeing memory when it is not used anymore. Python performs " "garbage collection via reference counting and a cyclic garbage collector " @@ -1130,11 +1185,11 @@ msgstr "" "てガベージコレクションを行います。\n" "ガベージコレクタは :mod:`gc` モジュールを使って操作できます。" -#: ../../glossary.rst:490 ../../glossary.rst:491 +#: ../../glossary.rst:519 ../../glossary.rst:520 msgid "generator" msgstr "ジェネレータ" -#: ../../glossary.rst:493 +#: ../../glossary.rst:522 msgid "" "A function which returns a :term:`generator iterator`. It looks like a " "normal function except that it contains :keyword:`yield` expressions for " @@ -1147,7 +1202,7 @@ msgstr "" ":keyword:`yield` 式は、 for ループで使用できたり、:func:`next` 関数で値を 1 " "つずつ取り出したりできる、値の並びを生成するのに使用されます。" -#: ../../glossary.rst:498 +#: ../../glossary.rst:527 msgid "" "Usually refers to a generator function, but may refer to a *generator " "iterator* in some contexts. In cases where the intended meaning isn't " @@ -1157,17 +1212,17 @@ msgstr "" "を指す場合があります。\n" "意図された意味が明らかでない場合、 明瞭化のために完全な単語を使用します。" -#: ../../glossary.rst:501 +#: ../../glossary.rst:530 msgid "generator iterator" msgstr "generator iterator" -#: ../../glossary.rst:503 +#: ../../glossary.rst:532 msgid "An object created by a :term:`generator` function." msgstr "" "(ジェネレータイテレータ)\n" ":term:`generator` 関数で生成されるオブジェクトです。" -#: ../../glossary.rst:505 +#: ../../glossary.rst:534 msgid "" "Each :keyword:`yield` temporarily suspends processing, remembering the " "location execution state (including local variables and pending try-" @@ -1179,11 +1234,11 @@ msgstr "" "*ジェネレータイテレータ* が再開されると、中断した位置を取得します (通常の関数" "が実行のたびに新しい状態から開始するのと対照的です)。" -#: ../../glossary.rst:511 ../../glossary.rst:512 +#: ../../glossary.rst:540 ../../glossary.rst:541 msgid "generator expression" msgstr "generator expression" -#: ../../glossary.rst:514 +#: ../../glossary.rst:543 msgid "" "An :term:`expression` that returns an :term:`iterator`. It looks like a " "normal expression followed by a :keyword:`!for` clause defining a loop " @@ -1191,17 +1246,17 @@ msgid "" "expression generates values for an enclosing function::" msgstr "" -#: ../../glossary.rst:519 +#: ../../glossary.rst:548 msgid "" ">>> sum(i*i for i in range(10)) # sum of squares 0, 1, 4, ... 81\n" "285" msgstr "" -#: ../../glossary.rst:521 +#: ../../glossary.rst:550 msgid "generic function" msgstr "generic function" -#: ../../glossary.rst:523 +#: ../../glossary.rst:552 msgid "" "A function composed of multiple functions implementing the same operation " "for different types. Which implementation should be used during a call is " @@ -1210,7 +1265,7 @@ msgstr "" "(ジェネリック関数) 異なる型に対し同じ操作をする関数群から構成される関数です。" "呼び出し時にどの実装を用いるかはディスパッチアルゴリズムにより決定されます。" -#: ../../glossary.rst:527 +#: ../../glossary.rst:556 msgid "" "See also the :term:`single dispatch` glossary entry, the :func:`functools." "singledispatch` decorator, and :pep:`443`." @@ -1218,36 +1273,36 @@ msgstr "" ":term:`single dispatch`、:func:`functools.singledispatch` デコレータ、:pep:" "`443` を参照してください。" -#: ../../glossary.rst:529 +#: ../../glossary.rst:558 msgid "generic type" msgstr "" -#: ../../glossary.rst:531 +#: ../../glossary.rst:560 msgid "" "A :term:`type` that can be parameterized; typically a :ref:`container " "class` such as :class:`list` or :class:`dict`. Used for :" "term:`type hints ` and :term:`annotations `." msgstr "" -#: ../../glossary.rst:536 +#: ../../glossary.rst:565 msgid "" "For more details, see :ref:`generic alias types`, :pep:" "`483`, :pep:`484`, :pep:`585`, and the :mod:`typing` module." msgstr "" -#: ../../glossary.rst:538 +#: ../../glossary.rst:567 msgid "GIL" msgstr "GIL" -#: ../../glossary.rst:540 +#: ../../glossary.rst:569 msgid "See :term:`global interpreter lock`." msgstr ":term:`global interpreter lock` を参照してください。" -#: ../../glossary.rst:541 +#: ../../glossary.rst:570 msgid "global interpreter lock" msgstr "global interpreter lock" -#: ../../glossary.rst:543 +#: ../../glossary.rst:572 msgid "" "The mechanism used by the :term:`CPython` interpreter to assure that only " "one thread executes Python :term:`bytecode` at a time. This simplifies the " @@ -1265,7 +1320,7 @@ msgstr "" "チプロセッサマシンが生じる並列化のコストと引き換えに、インタプリタを簡単にマ" "ルチスレッド化できるようになります。" -#: ../../glossary.rst:552 +#: ../../glossary.rst:581 msgid "" "However, some extension modules, either standard or third-party, are " "designed so as to release the GIL when doing computationally intensive tasks " @@ -1276,7 +1331,7 @@ msgstr "" "の計算の重い処理をするときに GIL を解除するように設計されています。また、I/O " "処理をする場合 GIL は常に解除されます。" -#: ../../glossary.rst:557 +#: ../../glossary.rst:586 msgid "" "As of Python 3.13, the GIL can be disabled using the :option:`--disable-gil` " "build configuration. After building Python with this option, code must be " @@ -1286,11 +1341,11 @@ msgid "" "core CPUs efficiently. For more details, see :pep:`703`." msgstr "" -#: ../../glossary.rst:563 +#: ../../glossary.rst:592 msgid "hash-based pyc" msgstr "hash-based pyc" -#: ../../glossary.rst:565 +#: ../../glossary.rst:594 msgid "" "A bytecode cache file that uses the hash rather than the last-modified time " "of the corresponding source file to determine its validity. See :ref:`pyc-" @@ -1300,11 +1355,11 @@ msgstr "" "の最終更新時刻ではなくハッシュ値を使用するバイトコードのキャッシュファイルで" "す。:ref:`pyc-invalidation` を参照してください。" -#: ../../glossary.rst:568 +#: ../../glossary.rst:597 msgid "hashable" msgstr "hashable" -#: ../../glossary.rst:570 +#: ../../glossary.rst:599 msgid "" "An object is *hashable* if it has a hash value which never changes during " "its lifetime (it needs a :meth:`~object.__hash__` method), and can be " @@ -1312,7 +1367,7 @@ msgid "" "Hashable objects which compare equal must have the same hash value." msgstr "" -#: ../../glossary.rst:576 +#: ../../glossary.rst:605 msgid "" "Hashability makes an object usable as a dictionary key and a set member, " "because these data structures use the hash value internally." @@ -1320,7 +1375,7 @@ msgstr "" "ハッシュ可能なオブジェクトは辞書のキーや集合のメンバーとして使えます。辞書や" "集合のデータ構造は内部でハッシュ値を使っているからです。" -#: ../../glossary.rst:579 +#: ../../glossary.rst:608 msgid "" "Most of Python's immutable built-in objects are hashable; mutable containers " "(such as lists or dictionaries) are not; immutable containers (such as " @@ -1338,11 +1393,11 @@ msgstr "" "それらは全て (自身を除いて) 比較結果は非等価であり、ハッシュ値は :func:`id` " "より得られます。" -#: ../../glossary.rst:586 +#: ../../glossary.rst:615 msgid "IDLE" msgstr "IDLE" -#: ../../glossary.rst:588 +#: ../../glossary.rst:617 msgid "" "An Integrated Development and Learning Environment for Python. :ref:`idle` " "is a basic editor and interpreter environment which ships with the standard " @@ -1352,28 +1407,28 @@ msgstr "" "(Learning Environment) です。:ref:`idle` は Python の標準的な配布に同梱されて" "いる基本的な機能のエディタとインタプリタ環境です。" -#: ../../glossary.rst:591 +#: ../../glossary.rst:620 msgid "immortal" msgstr "永続オブジェクト (immortal)" -#: ../../glossary.rst:593 +#: ../../glossary.rst:622 msgid "" "*Immortal objects* are a CPython implementation detail introduced in :pep:" "`683`." msgstr "" -#: ../../glossary.rst:596 +#: ../../glossary.rst:625 msgid "" "If an object is immortal, its :term:`reference count` is never modified, and " "therefore it is never deallocated while the interpreter is running. For " "example, :const:`True` and :const:`None` are immortal in CPython." msgstr "" -#: ../../glossary.rst:599 +#: ../../glossary.rst:628 msgid "immutable" msgstr "immutable" -#: ../../glossary.rst:601 +#: ../../glossary.rst:630 msgid "" "An object with a fixed value. Immutable objects include numbers, strings " "and tuples. Such an object cannot be altered. A new object has to be " @@ -1387,11 +1442,11 @@ msgstr "" "なりません。イミュータブルなオブジェクトは、固定のハッシュ値が必要となる状況" "で重要な役割を果たします。辞書のキーがその例です。" -#: ../../glossary.rst:606 +#: ../../glossary.rst:635 msgid "import path" msgstr "import path" -#: ../../glossary.rst:608 +#: ../../glossary.rst:637 msgid "" "A list of locations (or :term:`path entries `) that are searched " "by the :term:`path based finder` for modules to import. During import, this " @@ -1403,11 +1458,11 @@ msgstr "" "ら来ますが、サブパッケージの場合は親パッケージの ``__path__`` 属性からも来ま" "す。" -#: ../../glossary.rst:613 +#: ../../glossary.rst:642 msgid "importing" msgstr "importing" -#: ../../glossary.rst:615 +#: ../../glossary.rst:644 msgid "" "The process by which Python code in one module is made available to Python " "code in another module." @@ -1415,11 +1470,11 @@ msgstr "" "あるモジュールの Python コードが別のモジュールの Python コードで使えるように" "する処理です。" -#: ../../glossary.rst:617 +#: ../../glossary.rst:646 msgid "importer" msgstr "importer" -#: ../../glossary.rst:619 +#: ../../glossary.rst:648 msgid "" "An object that both finds and loads a module; both a :term:`finder` and :" "term:`loader` object." @@ -1427,11 +1482,11 @@ msgstr "" "モジュールを探してロードするオブジェクト。 :term:`finder` と :term:`loader` " "のどちらでもあるオブジェクト。" -#: ../../glossary.rst:621 +#: ../../glossary.rst:650 msgid "interactive" msgstr "interactive" -#: ../../glossary.rst:623 +#: ../../glossary.rst:652 msgid "" "Python has an interactive interpreter which means you can enter statements " "and expressions at the interpreter prompt, immediately execute them and see " @@ -1441,11 +1496,11 @@ msgid "" "For more on interactive mode, see :ref:`tut-interac`." msgstr "" -#: ../../glossary.rst:630 +#: ../../glossary.rst:659 msgid "interpreted" msgstr "interpreted" -#: ../../glossary.rst:632 +#: ../../glossary.rst:661 msgid "" "Python is an interpreted language, as opposed to a compiled one, though the " "distinction can be blurry because of the presence of the bytecode compiler. " @@ -1461,11 +1516,11 @@ msgstr "" "常、コンパイラ形式の言語よりも開発/デバッグのサイクルは短いものの、プログラ" "ムの実行は一般に遅いです。 :term:`対話的 ` も参照してください。" -#: ../../glossary.rst:639 +#: ../../glossary.rst:668 msgid "interpreter shutdown" msgstr "interpreter shutdown" -#: ../../glossary.rst:641 +#: ../../glossary.rst:670 msgid "" "When asked to shut down, the Python interpreter enters a special phase where " "it gradually releases all allocated resources, such as modules and various " @@ -1487,7 +1542,7 @@ msgstr "" "機能しない(よくある例はライブラリーモジュールや warning 機構です) ために様々" "な例外に直面します。" -#: ../../glossary.rst:650 +#: ../../glossary.rst:679 msgid "" "The main reason for interpreter shutdown is that the ``__main__`` module or " "the script being run has finished executing." @@ -1495,11 +1550,11 @@ msgstr "" "インタープリタがシャットダウンする主な理由は ``__main__`` モジュールや実行さ" "れていたスクリプトの実行が終了したことです。" -#: ../../glossary.rst:652 +#: ../../glossary.rst:681 msgid "iterable" msgstr "iterable" -#: ../../glossary.rst:654 +#: ../../glossary.rst:683 msgid "" "An object capable of returning its members one at a time. Examples of " "iterables include all sequence types (such as :class:`list`, :class:`str`, " @@ -1509,7 +1564,7 @@ msgid "" "method that implements :term:`sequence` semantics." msgstr "" -#: ../../glossary.rst:662 +#: ../../glossary.rst:691 msgid "" "Iterables can be used in a :keyword:`for` loop and in many other places " "where a sequence is needed (:func:`zip`, :func:`map`, ...). When an " @@ -1522,11 +1577,11 @@ msgid "" "loop. See also :term:`iterator`, :term:`sequence`, and :term:`generator`." msgstr "" -#: ../../glossary.rst:672 +#: ../../glossary.rst:701 msgid "iterator" msgstr "iterator" -#: ../../glossary.rst:674 +#: ../../glossary.rst:703 msgid "" "An object representing a stream of data. Repeated calls to the iterator's :" "meth:`~iterator.__next__` method (or passing it to the built-in function :" @@ -1557,22 +1612,22 @@ msgstr "" "前回のイテレーションで使用済みの同じイテレータオブジェクトを単純に返すため、" "空のコンテナのようになってしまします。" -#: ../../glossary.rst:689 +#: ../../glossary.rst:718 msgid "More information can be found in :ref:`typeiter`." msgstr "詳細な情報は :ref:`typeiter` にあります。" -#: ../../glossary.rst:693 +#: ../../glossary.rst:722 msgid "" "CPython does not consistently apply the requirement that an iterator define :" "meth:`~iterator.__iter__`. And also please note that the free-threading " "CPython does not guarantee the thread-safety of iterator operations." msgstr "" -#: ../../glossary.rst:698 +#: ../../glossary.rst:727 msgid "key function" msgstr "key function" -#: ../../glossary.rst:700 +#: ../../glossary.rst:729 msgid "" "A key function or collation function is a callable that returns a value used " "for sorting or ordering. For example, :func:`locale.strxfrm` is used to " @@ -1582,7 +1637,7 @@ msgstr "" "び出し可能オブジェクト(callable)です。例えば、 :func:`locale.strxfrm` をキー" "関数に使えば、ロケール依存のソートの慣習にのっとったソートキーを返します。" -#: ../../glossary.rst:705 +#: ../../glossary.rst:734 msgid "" "A number of tools in Python accept key functions to control how elements are " "ordered or grouped. They include :func:`min`, :func:`max`, :func:`sorted`, :" @@ -1595,7 +1650,7 @@ msgstr "" "merge`, :func:`heapq.nsmallest`, :func:`heapq.nlargest`, :func:`itertools." "groupby` 等があります。" -#: ../../glossary.rst:711 +#: ../../glossary.rst:740 msgid "" "There are several ways to create a key function. For example. the :meth:" "`str.lower` method can serve as a key function for case insensitive sorts. " @@ -1615,19 +1670,19 @@ msgstr "" "キー関数の作り方と使い方の例は :ref:`Sorting HOW TO ` を参照し" "てください。" -#: ../../glossary.rst:718 +#: ../../glossary.rst:747 msgid "keyword argument" msgstr "keyword argument" -#: ../../glossary.rst:720 ../../glossary.rst:1019 +#: ../../glossary.rst:749 ../../glossary.rst:1053 msgid "See :term:`argument`." msgstr ":term:`実引数 ` を参照してください。" -#: ../../glossary.rst:721 +#: ../../glossary.rst:750 msgid "lambda" msgstr "lambda" -#: ../../glossary.rst:723 +#: ../../glossary.rst:752 msgid "" "An anonymous inline function consisting of a single :term:`expression` which " "is evaluated when the function is called. The syntax to create a lambda " @@ -1637,11 +1692,11 @@ msgstr "" "term:`式 ` を含みます。ラムダ関数を作る構文は ``lambda " "[parameters]: expression`` です。" -#: ../../glossary.rst:726 +#: ../../glossary.rst:755 msgid "LBYL" msgstr "LBYL" -#: ../../glossary.rst:728 +#: ../../glossary.rst:757 msgid "" "Look before you leap. This coding style explicitly tests for pre-conditions " "before making calls or lookups. This style contrasts with the :term:`EAFP` " @@ -1653,7 +1708,7 @@ msgstr "" "す。 :term:`EAFP` アプローチと対照的で、 :keyword:`if` 文がたくさん使われるの" "が特徴的です。" -#: ../../glossary.rst:733 +#: ../../glossary.rst:762 msgid "" "In a multi-threaded environment, the LBYL approach can risk introducing a " "race condition between \"the looking\" and \"the leaping\". For example, " @@ -1667,22 +1722,22 @@ msgstr "" "*mapping* から *key* を取り除くと失敗します。この問題は、ロックするか EAFP ア" "プローチを使うことで解決できます。" -#: ../../glossary.rst:738 +#: ../../glossary.rst:767 msgid "list" msgstr "list" -#: ../../glossary.rst:740 +#: ../../glossary.rst:769 msgid "" "A built-in Python :term:`sequence`. Despite its name it is more akin to an " "array in other languages than to a linked list since access to elements is " "*O*\\ (1)." msgstr "" -#: ../../glossary.rst:743 +#: ../../glossary.rst:772 msgid "list comprehension" msgstr "list comprehension" -#: ../../glossary.rst:745 +#: ../../glossary.rst:774 msgid "" "A compact way to process all or part of the elements in a sequence and " "return a list with the results. ``result = ['{:#04x}'.format(x) for x in " @@ -1697,62 +1752,68 @@ msgstr "" "です。 :keyword:`if` 節がない場合、 ``range(256)`` の全ての要素が処理されま" "す。" -#: ../../glossary.rst:751 +#: ../../glossary.rst:780 msgid "loader" msgstr "loader" -#: ../../glossary.rst:753 +#: ../../glossary.rst:782 msgid "" "An object that loads a module. It must define a method named :meth:" -"`load_module`. A loader is typically returned by a :term:`finder`. See :pep:" -"`302` for details and :class:`importlib.abc.Loader` for an :term:`abstract " -"base class`." +"`load_module`. A loader is typically returned by a :term:`finder`. See also:" msgstr "" -"モジュールをロードするオブジェクト。 :meth:`load_module` という名前のメソッド" -"を定義していなければなりません。ローダーは一般的に :term:`finder` から返され" -"ます。詳細は :pep:`302` を、 :term:`abstract base class` については :class:" -"`importlib.abc.Loader` を参照してください。" -#: ../../glossary.rst:757 +#: ../../glossary.rst:786 +msgid ":ref:`finders-and-loaders`" +msgstr "" + +#: ../../glossary.rst:787 +msgid ":class:`importlib.abc.Loader`" +msgstr "" + +#: ../../glossary.rst:788 +msgid ":pep:`302`" +msgstr ":pep:`302`" + +#: ../../glossary.rst:789 msgid "locale encoding" msgstr "ロケールエンコーディング" -#: ../../glossary.rst:759 +#: ../../glossary.rst:791 msgid "" "On Unix, it is the encoding of the LC_CTYPE locale. It can be set with :func:" "`locale.setlocale(locale.LC_CTYPE, new_locale) `." msgstr "" -#: ../../glossary.rst:762 +#: ../../glossary.rst:794 msgid "On Windows, it is the ANSI code page (ex: ``\"cp1252\"``)." msgstr "" -#: ../../glossary.rst:764 +#: ../../glossary.rst:796 msgid "" "On Android and VxWorks, Python uses ``\"utf-8\"`` as the locale encoding." msgstr "" -#: ../../glossary.rst:766 +#: ../../glossary.rst:798 msgid ":func:`locale.getencoding` can be used to get the locale encoding." msgstr "" -#: ../../glossary.rst:768 +#: ../../glossary.rst:800 msgid "See also the :term:`filesystem encoding and error handler`." msgstr "" -#: ../../glossary.rst:769 +#: ../../glossary.rst:801 msgid "magic method" msgstr "magic method" -#: ../../glossary.rst:773 +#: ../../glossary.rst:805 msgid "An informal synonym for :term:`special method`." msgstr ":term:`special method` のくだけた同義語です。" -#: ../../glossary.rst:774 +#: ../../glossary.rst:806 msgid "mapping" msgstr "mapping" -#: ../../glossary.rst:776 +#: ../../glossary.rst:808 msgid "" "A container object that supports arbitrary key lookups and implements the " "methods specified in the :class:`collections.abc.Mapping` or :class:" @@ -1768,11 +1829,11 @@ msgstr "" "defaultdict`, :class:`collections.OrderedDict`, :class:`collections.Counter` " "などです。" -#: ../../glossary.rst:782 +#: ../../glossary.rst:814 msgid "meta path finder" msgstr "meta path finder" -#: ../../glossary.rst:784 +#: ../../glossary.rst:816 msgid "" "A :term:`finder` returned by a search of :data:`sys.meta_path`. Meta path " "finders are related to, but different from :term:`path entry finders ` と :term:`ネストされたスコープ ` も参照" "してください。" -#: ../../glossary.rst:809 +#: ../../glossary.rst:841 msgid "method resolution order" msgstr "method resolution order" -#: ../../glossary.rst:811 +#: ../../glossary.rst:843 msgid "" "Method Resolution Order is the order in which base classes are searched for " "a member during lookup. See :ref:`python_2.3_mro` for details of the " "algorithm used by the Python interpreter since the 2.3 release." msgstr "" -#: ../../glossary.rst:814 +#: ../../glossary.rst:846 msgid "module" msgstr "module" -#: ../../glossary.rst:816 +#: ../../glossary.rst:848 msgid "" "An object that serves as an organizational unit of Python code. Modules " "have a namespace containing arbitrary Python objects. Modules are loaded " @@ -1861,15 +1922,15 @@ msgstr "" "ルは任意の Python オブジェクトを含む名前空間を持ちます。モジュールは :term:" "`importing` の処理によって Python に読み込まれます。" -#: ../../glossary.rst:820 +#: ../../glossary.rst:852 msgid "See also :term:`package`." msgstr ":term:`パッケージ ` を参照してください。" -#: ../../glossary.rst:821 +#: ../../glossary.rst:853 msgid "module spec" msgstr "module spec" -#: ../../glossary.rst:823 +#: ../../glossary.rst:855 msgid "" "A namespace containing the import-related information used to load a module. " "An instance of :class:`importlib.machinery.ModuleSpec`." @@ -1877,19 +1938,23 @@ msgstr "" "モジュールをロードするのに使われるインポート関連の情報を含む名前空間です。\n" ":class:`importlib.machinery.ModuleSpec` のインスタンスです。" -#: ../../glossary.rst:825 +#: ../../glossary.rst:858 +msgid "See also :ref:`module-specs`." +msgstr "" + +#: ../../glossary.rst:859 msgid "MRO" msgstr "MRO" -#: ../../glossary.rst:827 +#: ../../glossary.rst:861 msgid "See :term:`method resolution order`." msgstr ":term:`method resolution order` を参照してください。" -#: ../../glossary.rst:828 +#: ../../glossary.rst:862 msgid "mutable" msgstr "mutable" -#: ../../glossary.rst:830 +#: ../../glossary.rst:864 msgid "" "Mutable objects can change their value but keep their :func:`id`. See also :" "term:`immutable`." @@ -1897,11 +1962,11 @@ msgstr "" "(ミュータブル) ミュータブルなオブジェクトは、 :func:`id` を変えることなく値を" "変更できます。 :term:`イミュータブル `) も参照してください。" -#: ../../glossary.rst:832 +#: ../../glossary.rst:866 msgid "named tuple" msgstr "named tuple" -#: ../../glossary.rst:834 +#: ../../glossary.rst:868 msgid "" "The term \"named tuple\" applies to any type or class that inherits from " "tuple and whose indexable elements are also accessible using named " @@ -1911,7 +1976,7 @@ msgstr "" "に対し属性を使ってのアクセスもできる任意の型やクラスに応用されています。\n" "その型やクラスは他の機能も持っていることもあります。" -#: ../../glossary.rst:838 +#: ../../glossary.rst:872 msgid "" "Several built-in types are named tuples, including the values returned by :" "func:`time.localtime` and :func:`os.stat`. Another example is :data:`sys." @@ -1921,7 +1986,7 @@ msgstr "" "は名前付きタプルです。\n" "他の例は :data:`sys.float_info` です::" -#: ../../glossary.rst:842 +#: ../../glossary.rst:876 msgid "" ">>> sys.float_info[1] # indexed access\n" "1024\n" @@ -1931,7 +1996,7 @@ msgid "" "True" msgstr "" -#: ../../glossary.rst:849 +#: ../../glossary.rst:883 msgid "" "Some named tuples are built-in types (such as the above examples). " "Alternatively, a named tuple can be created from a regular class definition " @@ -1942,11 +2007,11 @@ msgid "" "be found in hand-written or built-in named tuples." msgstr "" -#: ../../glossary.rst:857 +#: ../../glossary.rst:891 msgid "namespace" msgstr "namespace" -#: ../../glossary.rst:859 +#: ../../glossary.rst:893 msgid "" "The place where a variable is stored. Namespaces are implemented as " "dictionaries. There are the local, global and built-in namespaces as well " @@ -1968,11 +2033,11 @@ msgstr "" "れモジュール :mod:`random` や :mod:`itertools` で実装されていることが明らかで" "す。" -#: ../../glossary.rst:869 +#: ../../glossary.rst:903 msgid "namespace package" msgstr "namespace package" -#: ../../glossary.rst:871 +#: ../../glossary.rst:905 msgid "" "A :pep:`420` :term:`package` which serves only as a container for " "subpackages. Namespace packages may have no physical representation, and " @@ -1984,15 +2049,15 @@ msgstr "" "いことができ、 ``__init__.py`` ファイルを持たないため、 :term:`regular " "package` とは異なります。" -#: ../../glossary.rst:876 +#: ../../glossary.rst:910 msgid "See also :term:`module`." msgstr ":term:`module` を参照してください。" -#: ../../glossary.rst:877 +#: ../../glossary.rst:911 msgid "nested scope" msgstr "nested scope" -#: ../../glossary.rst:879 +#: ../../glossary.rst:913 msgid "" "The ability to refer to a variable in an enclosing definition. For " "instance, a function defined inside another function can refer to variables " @@ -2008,11 +2073,11 @@ msgstr "" "を読み書きします。同様に、グローバル変数を使うとグローバル名前空間の値を読み" "書きします。 :keyword:`nonlocal` で外側の変数に書き込めます。" -#: ../../glossary.rst:886 +#: ../../glossary.rst:920 msgid "new-style class" msgstr "new-style class" -#: ../../glossary.rst:888 +#: ../../glossary.rst:922 msgid "" "Old name for the flavor of classes now used for all class objects. In " "earlier Python versions, only new-style classes could use Python's newer, " @@ -2020,11 +2085,11 @@ msgid "" "meth:`~object.__getattribute__`, class methods, and static methods." msgstr "" -#: ../../glossary.rst:893 +#: ../../glossary.rst:927 msgid "object" msgstr "object" -#: ../../glossary.rst:895 +#: ../../glossary.rst:929 msgid "" "Any data with state (attributes or value) and defined behavior (methods). " "Also the ultimate base class of any :term:`new-style class`." @@ -2033,11 +2098,11 @@ msgstr "" "データ。もしくは、全ての :term:`新スタイルクラス ` の究極の" "基底クラスのこと。" -#: ../../glossary.rst:898 +#: ../../glossary.rst:932 msgid "optimized scope" msgstr "" -#: ../../glossary.rst:900 +#: ../../glossary.rst:934 msgid "" "A scope where target local variable names are reliably known to the compiler " "when the code is compiled, allowing optimization of read and write access to " @@ -2048,11 +2113,11 @@ msgid "" "to optimized scopes." msgstr "" -#: ../../glossary.rst:907 +#: ../../glossary.rst:941 msgid "package" msgstr "package" -#: ../../glossary.rst:909 +#: ../../glossary.rst:943 msgid "" "A Python :term:`module` which can contain submodules or recursively, " "subpackages. Technically, a package is a Python module with a ``__path__`` " @@ -2062,16 +2127,16 @@ msgstr "" "`module` のことです。専門的には、パッケージは ``__path__`` 属性を持つ Python " "オブジェクトです。" -#: ../../glossary.rst:913 +#: ../../glossary.rst:947 msgid "See also :term:`regular package` and :term:`namespace package`." msgstr "" ":term:`regular package` と :term:`namespace package` を参照してください。" -#: ../../glossary.rst:914 +#: ../../glossary.rst:948 msgid "parameter" msgstr "parameter" -#: ../../glossary.rst:916 +#: ../../glossary.rst:950 msgid "" "A named entity in a :term:`function` (or method) definition that specifies " "an :term:`argument` (or in some cases, arguments) that the function can " @@ -2081,7 +2146,7 @@ msgstr "" "` ) の定義において関数が受ける :term:`実引数 ` を指定しま" "す。仮引数には5種類あります:" -#: ../../glossary.rst:920 +#: ../../glossary.rst:954 msgid "" ":dfn:`positional-or-keyword`: specifies an argument that can be passed " "either :term:`positionally ` or as a :term:`keyword argument " @@ -2092,11 +2157,11 @@ msgstr "" "ワード引数 ` として渡すことができる引数を指定します。\n" "これはたとえば以下の *foo* や *bar* のように、デフォルトの仮引数の種類です::" -#: ../../glossary.rst:925 +#: ../../glossary.rst:959 msgid "def func(foo, bar=None): ..." msgstr "" -#: ../../glossary.rst:929 +#: ../../glossary.rst:963 msgid "" ":dfn:`positional-only`: specifies an argument that can be supplied only by " "position. Positional-only parameters can be defined by including a ``/`` " @@ -2107,11 +2172,11 @@ msgstr "" "義の引数のリストの中でそれらの後ろに ``/`` を含めることで定義できます。例えば" "下記の *posonly1* と *posonly2* は位置専用引数になります:: " -#: ../../glossary.rst:934 +#: ../../glossary.rst:968 msgid "def func(posonly1, posonly2, /, positional_or_keyword): ..." msgstr "" -#: ../../glossary.rst:938 +#: ../../glossary.rst:972 msgid "" ":dfn:`keyword-only`: specifies an argument that can be supplied only by " "keyword. Keyword-only parameters can be defined by including a single var-" @@ -2124,11 +2189,11 @@ msgstr "" "ように、関数定義の仮引数リストに含めた可変長位置引数または裸の ``*`` の後で" "す::" -#: ../../glossary.rst:944 +#: ../../glossary.rst:978 msgid "def func(arg, *, kw_only1, kw_only2): ..." msgstr "" -#: ../../glossary.rst:946 +#: ../../glossary.rst:980 msgid "" ":dfn:`var-positional`: specifies that an arbitrary sequence of positional " "arguments can be provided (in addition to any positional arguments already " @@ -2140,11 +2205,11 @@ msgstr "" "個数の位置引数が与えられることを指定します。このような仮引数は、以下の " "*args* のように仮引数名の前に ``*`` をつけることで定義できます::" -#: ../../glossary.rst:952 +#: ../../glossary.rst:986 msgid "def func(*args, **kwargs): ..." msgstr "" -#: ../../glossary.rst:954 +#: ../../glossary.rst:988 msgid "" ":dfn:`var-keyword`: specifies that arbitrarily many keyword arguments can be " "provided (in addition to any keyword arguments already accepted by other " @@ -2156,7 +2221,7 @@ msgstr "" "数は、上の例の *kwargs* のように仮引数名の前に ``**`` をつけることで定義でき" "ます。" -#: ../../glossary.rst:960 +#: ../../glossary.rst:994 msgid "" "Parameters can specify both optional and required arguments, as well as " "default values for some optional arguments." @@ -2164,7 +2229,7 @@ msgstr "" "仮引数はオプションと必須の引数のどちらも指定でき、オプションの引数にはデフォ" "ルト値も指定できます。" -#: ../../glossary.rst:963 +#: ../../glossary.rst:997 msgid "" "See also the :term:`argument` glossary entry, the FAQ question on :ref:`the " "difference between arguments and parameters `, " @@ -2175,11 +2240,11 @@ msgstr "" "` 、:class:`inspect.Parameter` クラス、 :ref:" "`function` セクション、:pep:`362` を参照してください。" -#: ../../glossary.rst:967 +#: ../../glossary.rst:1001 msgid "path entry" msgstr "path entry" -#: ../../glossary.rst:969 +#: ../../glossary.rst:1003 msgid "" "A single location on the :term:`import path` which the :term:`path based " "finder` consults to find modules for importing." @@ -2187,11 +2252,11 @@ msgstr "" ":term:`path based finder` が import するモジュールを探す :term:`import path` " "上の1つの場所です。" -#: ../../glossary.rst:971 +#: ../../glossary.rst:1005 msgid "path entry finder" msgstr "path entry finder" -#: ../../glossary.rst:973 +#: ../../glossary.rst:1007 msgid "" "A :term:`finder` returned by a callable on :data:`sys.path_hooks` (i.e. a :" "term:`path entry hook`) which knows how to locate modules given a :term:" @@ -2201,7 +2266,7 @@ msgstr "" "した :term:`finder` です。与えられた :term:`path entry` にあるモジュールを見" "つける方法を知っています。" -#: ../../glossary.rst:977 +#: ../../glossary.rst:1011 msgid "" "See :class:`importlib.abc.PathEntryFinder` for the methods that path entry " "finders implement." @@ -2209,22 +2274,22 @@ msgstr "" "パスエントリーファインダが実装するメソッドについては :class:`importlib.abc." "PathEntryFinder` を参照してください。" -#: ../../glossary.rst:979 +#: ../../glossary.rst:1013 msgid "path entry hook" msgstr "path entry hook" -#: ../../glossary.rst:981 +#: ../../glossary.rst:1015 msgid "" "A callable on the :data:`sys.path_hooks` list which returns a :term:`path " "entry finder` if it knows how to find modules on a specific :term:`path " "entry`." msgstr "" -#: ../../glossary.rst:984 +#: ../../glossary.rst:1018 msgid "path based finder" msgstr "path based finder" -#: ../../glossary.rst:986 +#: ../../glossary.rst:1020 msgid "" "One of the default :term:`meta path finders ` which " "searches an :term:`import path` for modules." @@ -2232,11 +2297,11 @@ msgstr "" "デフォルトの :term:`meta path finder` の1つは、モジュールの :term:`import " "path` を検索します。" -#: ../../glossary.rst:988 +#: ../../glossary.rst:1022 msgid "path-like object" msgstr "path-like object" -#: ../../glossary.rst:990 +#: ../../glossary.rst:1024 msgid "" "An object representing a file system path. A path-like object is either a :" "class:`str` or :class:`bytes` object representing a path, or an object " @@ -2257,11 +2322,11 @@ msgstr "" "れ :class:`str` あるいは :class:`bytes` になるのを保証するのに使えます。\n" ":pep:`519` で導入されました。" -#: ../../glossary.rst:998 +#: ../../glossary.rst:1032 msgid "PEP" msgstr "PEP" -#: ../../glossary.rst:1000 +#: ../../glossary.rst:1034 msgid "" "Python Enhancement Proposal. A PEP is a design document providing " "information to the Python community, or describing a new feature for Python " @@ -2273,7 +2338,7 @@ msgstr "" "PEP は、機能についての簡潔な技術的仕様と提案する機能の論拠 (理論) を伝えるべ" "きです。" -#: ../../glossary.rst:1006 +#: ../../glossary.rst:1040 msgid "" "PEPs are intended to be the primary mechanisms for proposing major new " "features, for collecting community input on an issue, and for documenting " @@ -2286,15 +2351,15 @@ msgstr "" "著者にはコミュニティ内の合意形成を行うこと、反対意見を文書化することの責務が" "あります。" -#: ../../glossary.rst:1012 +#: ../../glossary.rst:1046 msgid "See :pep:`1`." msgstr ":pep:`1` を参照してください。" -#: ../../glossary.rst:1013 +#: ../../glossary.rst:1047 msgid "portion" msgstr "portion" -#: ../../glossary.rst:1015 +#: ../../glossary.rst:1049 msgid "" "A set of files in a single directory (possibly stored in a zip file) that " "contribute to a namespace package, as defined in :pep:`420`." @@ -2302,15 +2367,15 @@ msgstr "" ":pep:`420` で定義されている、namespace package に属する、複数のファイルが " "(zipファイルに格納されている場合もある) 1つのディレクトリに格納されたもの。" -#: ../../glossary.rst:1017 +#: ../../glossary.rst:1051 msgid "positional argument" msgstr "位置引数 (positional argument)" -#: ../../glossary.rst:1020 +#: ../../glossary.rst:1054 msgid "provisional API" msgstr "provisional API" -#: ../../glossary.rst:1022 +#: ../../glossary.rst:1056 msgid "" "A provisional API is one which has been deliberately excluded from the " "standard library's backwards compatibility guarantees. While major changes " @@ -2327,7 +2392,7 @@ msgstr "" "ものではありません -- これは API を組み込む前には見落とされていた重大な欠陥が" "露呈したときにのみ行われます。" -#: ../../glossary.rst:1031 +#: ../../glossary.rst:1065 msgid "" "Even for provisional APIs, backwards incompatible changes are seen as a " "\"solution of last resort\" - every attempt will still be made to find a " @@ -2336,7 +2401,7 @@ msgstr "" "暫定 API についても、後方互換性のない変更は「最終手段」とみなされています。問" "題点が判明した場合でも後方互換な解決策を探すべきです。" -#: ../../glossary.rst:1035 +#: ../../glossary.rst:1069 msgid "" "This process allows the standard library to continue to evolve over time, " "without locking in problematic design errors for extended periods of time. " @@ -2346,19 +2411,19 @@ msgstr "" "られることなく、時代を超えて進化を続けられます。詳細は :pep:`411` を参照して" "ください。" -#: ../../glossary.rst:1038 +#: ../../glossary.rst:1072 msgid "provisional package" msgstr "provisional package" -#: ../../glossary.rst:1040 +#: ../../glossary.rst:1074 msgid "See :term:`provisional API`." msgstr ":term:`provisional API` を参照してください。" -#: ../../glossary.rst:1041 +#: ../../glossary.rst:1075 msgid "Python 3000" msgstr "Python 3000" -#: ../../glossary.rst:1043 +#: ../../glossary.rst:1077 msgid "" "Nickname for the Python 3.x release line (coined long ago when the release " "of version 3 was something in the distant future.) This is also abbreviated " @@ -2367,11 +2432,11 @@ msgstr "" "Python 3.x リリースラインのニックネームです。(Python 3 が遠い将来の話だった頃" "に作られた言葉です。) \"Py3k\" と略されることもあります。" -#: ../../glossary.rst:1046 +#: ../../glossary.rst:1080 msgid "Pythonic" msgstr "Pythonic" -#: ../../glossary.rst:1048 +#: ../../glossary.rst:1082 msgid "" "An idea or piece of code which closely follows the most common idioms of the " "Python language, rather than implementing code using concepts common to " @@ -2386,27 +2451,27 @@ msgstr "" "くの言語にはこの仕組みはないので、Python に慣れていない人は代わりに数値のカウ" "ンターを使うかもしれません::" -#: ../../glossary.rst:1055 +#: ../../glossary.rst:1089 msgid "" "for i in range(len(food)):\n" " print(food[i])" msgstr "" -#: ../../glossary.rst:1058 +#: ../../glossary.rst:1092 msgid "As opposed to the cleaner, Pythonic method::" msgstr "これに対し、きれいな Pythonic な方法は::" -#: ../../glossary.rst:1060 +#: ../../glossary.rst:1094 msgid "" "for piece in food:\n" " print(piece)" msgstr "" -#: ../../glossary.rst:1062 +#: ../../glossary.rst:1096 msgid "qualified name" msgstr "qualified name" -#: ../../glossary.rst:1064 +#: ../../glossary.rst:1098 msgid "" "A dotted name showing the \"path\" from a module's global scope to a class, " "function or method defined in that module, as defined in :pep:`3155`. For " @@ -2418,7 +2483,7 @@ msgstr "" "されています。トップレベルの関数やクラスでは、修飾名はオブジェクトの名前と同" "じです::" -#: ../../glossary.rst:1069 +#: ../../glossary.rst:1103 msgid "" ">>> class C:\n" "... class D:\n" @@ -2433,7 +2498,7 @@ msgid "" "'C.D.meth'" msgstr "" -#: ../../glossary.rst:1081 +#: ../../glossary.rst:1115 msgid "" "When used to refer to modules, the *fully qualified name* means the entire " "dotted path to the module, including any parent packages, e.g. ``email.mime." @@ -2443,18 +2508,18 @@ msgstr "" "の親パッケージを含む全体のドット名表記、例えば ``email.mime.text`` を意味しま" "す::" -#: ../../glossary.rst:1085 +#: ../../glossary.rst:1119 msgid "" ">>> import email.mime.text\n" ">>> email.mime.text.__name__\n" "'email.mime.text'" msgstr "" -#: ../../glossary.rst:1088 +#: ../../glossary.rst:1122 msgid "reference count" msgstr "reference count" -#: ../../glossary.rst:1090 +#: ../../glossary.rst:1124 msgid "" "The number of references to an object. When the reference count of an " "object drops to zero, it is deallocated. Some objects are :term:`immortal` " @@ -2471,11 +2536,11 @@ msgstr "" "の重要な要素です。プログラマーは、 任意のオブジェクトの参照カウントを知るため" "に :func:`sys.getrefcount` 関数を呼び出すことが出来ます。" -#: ../../glossary.rst:1098 +#: ../../glossary.rst:1132 msgid "regular package" msgstr "regular package" -#: ../../glossary.rst:1100 +#: ../../glossary.rst:1134 msgid "" "A traditional :term:`package`, such as a directory containing an ``__init__." "py`` file." @@ -2483,15 +2548,15 @@ msgstr "" "伝統的な、 ``__init__.py`` ファイルを含むディレクトリとしての :term:" "`package`。" -#: ../../glossary.rst:1103 +#: ../../glossary.rst:1137 msgid "See also :term:`namespace package`." msgstr ":term:`namespace package` を参照してください。" -#: ../../glossary.rst:1104 +#: ../../glossary.rst:1138 msgid "REPL" msgstr "REPL" -#: ../../glossary.rst:1106 +#: ../../glossary.rst:1140 msgid "" "An acronym for the \"read–eval–print loop\", another name for the :term:" "`interactive` interpreter shell." @@ -2499,11 +2564,11 @@ msgstr "" "\"read–eval–print loop\" の頭字語で、 :term:`対話型 ` インタープ" "リターシェルの別名。" -#: ../../glossary.rst:1108 +#: ../../glossary.rst:1142 msgid "__slots__" msgstr "__slots__" -#: ../../glossary.rst:1110 +#: ../../glossary.rst:1144 msgid "" "A declaration inside a class that saves memory by pre-declaring space for " "instance attributes and eliminating instance dictionaries. Though popular, " @@ -2517,11 +2582,11 @@ msgstr "" "となるアプリケーションでインスタンスが大量に存在する、といったときを除き、使" "わないのがベストです。" -#: ../../glossary.rst:1115 +#: ../../glossary.rst:1149 msgid "sequence" msgstr "sequence" -#: ../../glossary.rst:1117 +#: ../../glossary.rst:1151 msgid "" "An :term:`iterable` which supports efficient element access using integer " "indices via the :meth:`~object.__getitem__` special method and defines a :" @@ -2533,7 +2598,7 @@ msgid "" "integers." msgstr "" -#: ../../glossary.rst:1126 +#: ../../glossary.rst:1160 msgid "" "The :class:`collections.abc.Sequence` abstract base class defines a much " "richer interface that goes beyond just :meth:`~object.__getitem__` and :meth:" @@ -2544,11 +2609,11 @@ msgid "" "`Common Sequence Operations `." msgstr "" -#: ../../glossary.rst:1135 +#: ../../glossary.rst:1169 msgid "set comprehension" msgstr "" -#: ../../glossary.rst:1137 +#: ../../glossary.rst:1171 msgid "" "A compact way to process all or part of the elements in an iterable and " "return a set with the results. ``results = {c for c in 'abracadabra' if c " @@ -2560,22 +2625,22 @@ msgstr "" "if c not in 'abc'}`` とすると、``{'r', 'd'}`` という文字列の辞書を生成しま" "す。 :ref:`comprehensions` を参照してください。" -#: ../../glossary.rst:1141 +#: ../../glossary.rst:1175 msgid "single dispatch" msgstr "single dispatch" -#: ../../glossary.rst:1143 +#: ../../glossary.rst:1177 msgid "" "A form of :term:`generic function` dispatch where the implementation is " "chosen based on the type of a single argument." msgstr "" ":term:`generic function` の一種で実装は一つの引数の型により選択されます。" -#: ../../glossary.rst:1145 +#: ../../glossary.rst:1179 msgid "slice" msgstr "slice" -#: ../../glossary.rst:1147 +#: ../../glossary.rst:1181 msgid "" "An object usually containing a portion of a :term:`sequence`. A slice is " "created using the subscript notation, ``[]`` with colons between numbers " @@ -2587,40 +2652,34 @@ msgstr "" "ます。例えば、 ``variable_name[1:3:5]`` です。角括弧 (添字) 記号は :class:" "`slice` オブジェクトを内部で利用しています。" -#: ../../glossary.rst:1151 +#: ../../glossary.rst:1185 msgid "soft deprecated" msgstr "" -#: ../../glossary.rst:1153 +#: ../../glossary.rst:1187 msgid "" -"A soft deprecation can be used when using an API which should no longer be " -"used to write new code, but it remains safe to continue using it in existing " -"code. The API remains documented and tested, but will not be developed " -"further (no enhancement)." +"A soft deprecated API should not be used in new code, but it is safe for " +"already existing code to use it. The API remains documented and tested, but " +"will not be enhanced further." msgstr "" -#: ../../glossary.rst:1158 +#: ../../glossary.rst:1191 msgid "" -"The main difference between a \"soft\" and a (regular) \"hard\" deprecation " -"is that the soft deprecation does not imply scheduling the removal of the " -"deprecated API." -msgstr "" - -#: ../../glossary.rst:1162 -msgid "Another difference is that a soft deprecation does not issue a warning." +"Soft deprecation, unlike normal deprecation, does not plan on removing the " +"API and will not emit warnings." msgstr "" -#: ../../glossary.rst:1164 +#: ../../glossary.rst:1194 msgid "" "See `PEP 387: Soft Deprecation `_." msgstr "" -#: ../../glossary.rst:1166 +#: ../../glossary.rst:1196 msgid "special method" msgstr "special method" -#: ../../glossary.rst:1170 +#: ../../glossary.rst:1200 msgid "" "A method that is called implicitly by Python to execute a certain operation " "on a type, such as addition. Such methods have names starting and ending " @@ -2632,11 +2691,11 @@ msgstr "" "コア 2 つがついています。特殊メソッドについては :ref:`specialnames` で解説さ" "れています。" -#: ../../glossary.rst:1174 +#: ../../glossary.rst:1204 msgid "statement" msgstr "statement" -#: ../../glossary.rst:1176 +#: ../../glossary.rst:1206 msgid "" "A statement is part of a suite (a \"block\" of code). A statement is either " "an :term:`expression` or one of several constructs with a keyword, such as :" @@ -2646,22 +2705,22 @@ msgstr "" "` かキーワードから構成されるもののどちらかです。後者には :" "keyword:`if`、:keyword:`while`、:keyword:`for` があります。" -#: ../../glossary.rst:1179 +#: ../../glossary.rst:1209 msgid "static type checker" msgstr "" -#: ../../glossary.rst:1181 +#: ../../glossary.rst:1211 msgid "" "An external tool that reads Python code and analyzes it, looking for issues " "such as incorrect types. See also :term:`type hints ` and the :" "mod:`typing` module." msgstr "" -#: ../../glossary.rst:1184 +#: ../../glossary.rst:1214 msgid "strong reference" msgstr "" -#: ../../glossary.rst:1186 +#: ../../glossary.rst:1216 msgid "" "In Python's C API, a strong reference is a reference to an object which is " "owned by the code holding the reference. The strong reference is taken by " @@ -2669,7 +2728,7 @@ msgid "" "c:func:`Py_DECREF` when the reference is deleted." msgstr "" -#: ../../glossary.rst:1192 +#: ../../glossary.rst:1222 msgid "" "The :c:func:`Py_NewRef` function can be used to create a strong reference to " "an object. Usually, the :c:func:`Py_DECREF` function must be called on the " @@ -2677,38 +2736,38 @@ msgid "" "leaking one reference." msgstr "" -#: ../../glossary.rst:1197 +#: ../../glossary.rst:1227 msgid "See also :term:`borrowed reference`." msgstr "" -#: ../../glossary.rst:1198 +#: ../../glossary.rst:1228 msgid "text encoding" msgstr "text encoding" -#: ../../glossary.rst:1200 +#: ../../glossary.rst:1230 msgid "" "A string in Python is a sequence of Unicode code points (in range " "``U+0000``--``U+10FFFF``). To store or transfer a string, it needs to be " "serialized as a sequence of bytes." msgstr "" -#: ../../glossary.rst:1204 +#: ../../glossary.rst:1234 msgid "" "Serializing a string into a sequence of bytes is known as \"encoding\", and " "recreating the string from the sequence of bytes is known as \"decoding\"." msgstr "" -#: ../../glossary.rst:1207 +#: ../../glossary.rst:1237 msgid "" "There are a variety of different text serialization :ref:`codecs `, which are collectively referred to as \"text encodings\"." msgstr "" -#: ../../glossary.rst:1210 +#: ../../glossary.rst:1240 msgid "text file" msgstr "text file" -#: ../../glossary.rst:1212 +#: ../../glossary.rst:1242 msgid "" "A :term:`file object` able to read and write :class:`str` objects. Often, a " "text file actually accesses a byte-oriented datastream and handles the :term:" @@ -2724,7 +2783,7 @@ msgstr "" "StringIO` インスタンスなどをテキストモード (``'r'`` or ``'w'``) で開いたファ" "イルです。" -#: ../../glossary.rst:1219 +#: ../../glossary.rst:1249 msgid "" "See also :term:`binary file` for a file object able to read and write :term:" "`bytes-like objects `." @@ -2733,11 +2792,11 @@ msgstr "" "オブジェクトについては、 :term:`バイナリファイル ` も参照してく" "ださい。" -#: ../../glossary.rst:1221 +#: ../../glossary.rst:1251 msgid "triple-quoted string" msgstr "triple-quoted string" -#: ../../glossary.rst:1223 +#: ../../glossary.rst:1253 msgid "" "A string which is bound by three instances of either a quotation mark (\") " "or an apostrophe ('). While they don't provide any functionality not " @@ -2753,26 +2812,26 @@ msgstr "" "しに書くことができますし、行継続文字(\\\\)を使わなくても複数行にまたがること" "ができるので、ドキュメンテーション文字列を書く時に特に便利です。" -#: ../../glossary.rst:1230 +#: ../../glossary.rst:1260 msgid "type" msgstr "type" -#: ../../glossary.rst:1232 +#: ../../glossary.rst:1262 msgid "" "The type of a Python object determines what kind of object it is; every " "object has a type. An object's type is accessible as its :attr:`~object." "__class__` attribute or can be retrieved with ``type(obj)``." msgstr "" -#: ../../glossary.rst:1236 +#: ../../glossary.rst:1266 msgid "type alias" msgstr "type alias" -#: ../../glossary.rst:1238 +#: ../../glossary.rst:1268 msgid "A synonym for a type, created by assigning the type to an identifier." msgstr "(型エイリアス) 型の別名で、型を識別子に代入して作成します。" -#: ../../glossary.rst:1240 +#: ../../glossary.rst:1270 msgid "" "Type aliases are useful for simplifying :term:`type hints `. For " "example::" @@ -2780,18 +2839,18 @@ msgstr "" "型エイリアスは :term:`型ヒント ` を単純化するのに有用です。例え" "ば::" -#: ../../glossary.rst:1243 +#: ../../glossary.rst:1273 msgid "" "def remove_gray_shades(\n" " colors: list[tuple[int, int, int]]) -> list[tuple[int, int, int]]:\n" " pass" msgstr "" -#: ../../glossary.rst:1247 +#: ../../glossary.rst:1277 msgid "could be made more readable like this::" msgstr "これは次のようにより読みやすくできます::" -#: ../../glossary.rst:1249 +#: ../../glossary.rst:1279 msgid "" "Color = tuple[int, int, int]\n" "\n" @@ -2799,15 +2858,15 @@ msgid "" " pass" msgstr "" -#: ../../glossary.rst:1254 ../../glossary.rst:1268 +#: ../../glossary.rst:1284 ../../glossary.rst:1298 msgid "See :mod:`typing` and :pep:`484`, which describe this functionality." msgstr "機能の説明がある :mod:`typing` と :pep:`484` を参照してください。" -#: ../../glossary.rst:1255 +#: ../../glossary.rst:1285 msgid "type hint" msgstr "type hint" -#: ../../glossary.rst:1257 +#: ../../glossary.rst:1287 msgid "" "An :term:`annotation` that specifies the expected type for a variable, a " "class attribute, or a function parameter or return value." @@ -2815,14 +2874,14 @@ msgstr "" "(型ヒント) 変数、クラス属性、関数のパラメータや返り値の期待される型を指定す" "る :term:`annotation` です。" -#: ../../glossary.rst:1260 +#: ../../glossary.rst:1290 msgid "" "Type hints are optional and are not enforced by Python but they are useful " "to :term:`static type checkers `. They can also aid " "IDEs with code completion and refactoring." msgstr "" -#: ../../glossary.rst:1264 +#: ../../glossary.rst:1294 msgid "" "Type hints of global variables, class attributes, and functions, but not " "local variables, can be accessed using :func:`typing.get_type_hints`." @@ -2830,11 +2889,11 @@ msgstr "" "グローバル変数、クラス属性、関数で、ローカル変数でないものの型ヒントは :func:" "`typing.get_type_hints` で取得できます。" -#: ../../glossary.rst:1269 +#: ../../glossary.rst:1299 msgid "universal newlines" msgstr "universal newlines" -#: ../../glossary.rst:1271 +#: ../../glossary.rst:1301 msgid "" "A manner of interpreting text streams in which all of the following are " "recognized as ending a line: the Unix end-of-line convention ``'\\n'``, the " @@ -2847,26 +2906,26 @@ msgstr "" "``'\\r'``。利用法について詳しくは、 :pep:`278` と :pep:`3116` 、さらに :func:" "`bytes.splitlines` も参照してください。" -#: ../../glossary.rst:1276 +#: ../../glossary.rst:1306 msgid "variable annotation" msgstr "variable annotation" -#: ../../glossary.rst:1278 +#: ../../glossary.rst:1308 msgid "An :term:`annotation` of a variable or a class attribute." msgstr "(変数アノテーション) 変数あるいはクラス属性の :term:`annotation` 。" -#: ../../glossary.rst:1280 +#: ../../glossary.rst:1310 msgid "" "When annotating a variable or a class attribute, assignment is optional::" msgstr "変数あるいはクラス属性に注釈を付けたときは、代入部分は任意です::" -#: ../../glossary.rst:1282 +#: ../../glossary.rst:1312 msgid "" "class C:\n" " field: 'annotation'" msgstr "" -#: ../../glossary.rst:1285 +#: ../../glossary.rst:1315 msgid "" "Variable annotations are usually used for :term:`type hints `: " "for example this variable is expected to take :class:`int` values::" @@ -2874,16 +2933,16 @@ msgstr "" "変数アノテーションは通常は :term:`型ヒント` のために使われます: 例" "えば、この変数は :class:`int` の値を取ることを期待されています::" -#: ../../glossary.rst:1289 +#: ../../glossary.rst:1319 msgid "count: int = 0" msgstr "" -#: ../../glossary.rst:1291 +#: ../../glossary.rst:1321 msgid "Variable annotation syntax is explained in section :ref:`annassign`." msgstr "" "変数アノテーションの構文については :ref:`annassign` 節で解説しています。" -#: ../../glossary.rst:1293 +#: ../../glossary.rst:1323 msgid "" "See :term:`function annotation`, :pep:`484` and :pep:`526`, which describe " "this functionality. Also see :ref:`annotations-howto` for best practices on " @@ -2893,11 +2952,11 @@ msgstr "" "してください。また、アノテーションを利用するベストプラクティスとして :ref:" "`annotations-howto` も参照してください。" -#: ../../glossary.rst:1297 +#: ../../glossary.rst:1327 msgid "virtual environment" msgstr "virtual environment" -#: ../../glossary.rst:1299 +#: ../../glossary.rst:1329 msgid "" "A cooperatively isolated runtime environment that allows Python users and " "applications to install and upgrade Python distribution packages without " @@ -2908,15 +2967,15 @@ msgstr "" "ケーションは同じシステム上で動いている他の Python アプリケーションの挙動に干" "渉することなく Python パッケージのインストールと更新を行うことができます。" -#: ../../glossary.rst:1304 +#: ../../glossary.rst:1334 msgid "See also :mod:`venv`." msgstr ":mod:`venv` を参照してください。" -#: ../../glossary.rst:1305 +#: ../../glossary.rst:1335 msgid "virtual machine" msgstr "virtual machine" -#: ../../glossary.rst:1307 +#: ../../glossary.rst:1337 msgid "" "A computer defined entirely in software. Python's virtual machine executes " "the :term:`bytecode` emitted by the bytecode compiler." @@ -2925,11 +2984,11 @@ msgstr "" "シンは、バイトコードコンパイラが出力した :term:`バイトコード ` を実" "行します。" -#: ../../glossary.rst:1309 +#: ../../glossary.rst:1339 msgid "Zen of Python" msgstr "Zen of Python" -#: ../../glossary.rst:1311 +#: ../../glossary.rst:1341 msgid "" "Listing of Python design principles and philosophies that are helpful in " "understanding and using the language. The listing can be found by typing " @@ -2939,18 +2998,18 @@ msgstr "" "学をリストにしたものです。対話プロンプトで \"``import this``\" とするとこのリ" "ストを読めます。" -#: ../../glossary.rst:256 +#: ../../glossary.rst:278 msgid "C-contiguous" msgstr "" -#: ../../glossary.rst:256 +#: ../../glossary.rst:278 msgid "Fortran contiguous" msgstr "" -#: ../../glossary.rst:771 +#: ../../glossary.rst:803 msgid "magic" msgstr "" -#: ../../glossary.rst:1168 +#: ../../glossary.rst:1198 msgid "special" msgstr "特殊" diff --git a/library/_thread.po b/library/_thread.po index 28bef25f2..84b0d9f90 100644 --- a/library/_thread.po +++ b/library/_thread.po @@ -5,7 +5,6 @@ # # Translators: # Takanori Suzuki , 2021 -# 菊池 健志, 2023 # tomo, 2023 # Inada Naoki , 2023 # 石井明久, 2024 @@ -15,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:54+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -173,10 +172,8 @@ msgid "" "after which the value may be recycled by the OS)." msgstr "" -#: ../../library/_thread.rst:123 -msgid "" -":ref:`Availability `: Windows, FreeBSD, Linux, macOS, OpenBSD, " -"NetBSD, AIX, DragonFlyBSD, GNU/kFreeBSD." +#: ../../library/_thread.rst:123 ../../library/_thread.rst:148 +msgid "Availability" msgstr "" #: ../../library/_thread.rst:127 @@ -216,10 +213,6 @@ msgstr "" "トフォームに関する情報がない場合は 4096 の整数倍のスタックサイズを選ぶといい" "かもしれません)。" -#: ../../library/_thread.rst:148 -msgid ":ref:`Availability `: Windows, pthreads." -msgstr ":ref:`利用可能な環境 `: Windows, pthreads。" - #: ../../library/_thread.rst:150 msgid "Unix platforms with POSIX threads support." msgstr "" @@ -319,15 +312,11 @@ msgstr "**警告:**" #: ../../library/_thread.rst:216 msgid "" -"Threads interact strangely with interrupts: the :exc:`KeyboardInterrupt` " -"exception will be received by an arbitrary thread. (When the :mod:`signal` " -"module is available, interrupts always go to the main thread.)" +"Interrupts always go to the main thread (the :exc:`KeyboardInterrupt` " +"exception will be received by that thread.)" msgstr "" -"スレッドは割り込みと奇妙な相互作用をします: :exc:`KeyboardInterrupt` 例外は任" -"意のスレッドによって受け取られます。 (:mod:`signal` モジュールが利用可能なと" -"き、割り込みは常にメインスレッドへ行きます。)" -#: ../../library/_thread.rst:220 +#: ../../library/_thread.rst:219 msgid "" "Calling :func:`sys.exit` or raising the :exc:`SystemExit` exception is " "equivalent to calling :func:`_thread.exit`." @@ -335,14 +324,16 @@ msgstr "" ":func:`sys.exit` を呼び出す、あるいは :exc:`SystemExit` 例外を送出すること" "は、 :func:`_thread.exit` を呼び出すことと同じです。" -#: ../../library/_thread.rst:223 +#: ../../library/_thread.rst:222 msgid "" -"It is not possible to interrupt the :meth:`~threading.Lock.acquire` method " -"on a lock --- the :exc:`KeyboardInterrupt` exception will happen after the " -"lock has been acquired." +"It is platform-dependent whether the :meth:`~threading.Lock.acquire` method " +"on a lock can be interrupted (so that the :exc:`KeyboardInterrupt` exception " +"will happen immediately, rather than only after the lock has been acquired " +"or the operation has timed out). It can be interrupted on POSIX, but not on " +"Windows." msgstr "" -#: ../../library/_thread.rst:227 +#: ../../library/_thread.rst:228 msgid "" "When the main thread exits, it is system defined whether the other threads " "survive. On most systems, they are killed without executing :keyword:" @@ -352,16 +343,6 @@ msgstr "" "存します。多くのシステムでは、 :keyword:`try` ... :keyword:`finally` 節や、オ" "ブジェクトデストラクタを実行せずに終了されます。" -#: ../../library/_thread.rst:232 -msgid "" -"When the main thread exits, it does not do any of its usual cleanup (except " -"that :keyword:`try` ... :keyword:`finally` clauses are honored), and the " -"standard I/O files are not flushed." -msgstr "" -"メインスレッドが終了したとき、それの通常のクリーンアップは行なわれず、 (:" -"keyword:`try` ... :keyword:`finally` 節が尊重されることは除きます)、標準 I/O " -"ファイルはフラッシュされません。" - #: ../../library/_thread.rst:7 msgid "light-weight processes" msgstr "light-weight processes" diff --git a/library/argparse.po b/library/argparse.po index 8265354cd..7e07e7bea 100644 --- a/library/argparse.po +++ b/library/argparse.po @@ -8,20 +8,19 @@ # mollinaca, 2021 # Shin Saito, 2021 # Atsuo Ishimoto , 2022 -# tomo, 2023 # Takeshi Nakazato, 2023 # Takanori Suzuki , 2024 -# 石井明久, 2024 # Arihiro TAKASE, 2024 +# tomo, 2024 # #, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:54+0000\n" -"Last-Translator: Arihiro TAKASE, 2024\n" +"Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" "ja/)\n" "MIME-Version: 1.0\n" @@ -32,10 +31,9 @@ msgstr "" #: ../../library/argparse.rst:2 msgid "" -":mod:`!argparse` --- Parser for command-line options, arguments and sub-" -"commands" +":mod:`!argparse` --- Parser for command-line options, arguments and " +"subcommands" msgstr "" -":mod:`!argparse` --- コマンドラインオプション、引数、サブコマンドのパーサー" #: ../../library/argparse.rst:12 msgid "**Source code:** :source:`Lib/argparse.py`" @@ -57,37 +55,23 @@ msgstr "" #: ../../library/argparse.rst:22 msgid "" -"The :mod:`argparse` module makes it easy to write user-friendly command-line " -"interfaces. The program defines what arguments it requires, and :mod:" -"`argparse` will figure out how to parse those out of :data:`sys.argv`. The :" -"mod:`argparse` module also automatically generates help and usage messages. " -"The module will also issue errors when users give the program invalid " -"arguments." +"The :mod:`!argparse` module makes it easy to write user-friendly command-" +"line interfaces. The program defines what arguments it requires, and :mod:`!" +"argparse` will figure out how to parse those out of :data:`sys.argv`. The :" +"mod:`!argparse` module also automatically generates help and usage " +"messages. The module will also issue errors when users give the program " +"invalid arguments." msgstr "" -":mod:`argparse` モジュールは、ユーザーフレンドリーなコマンドラインインター" -"フェースの作成を簡単にします。プログラムは必要とする引数が何かを定義し、 :" -"mod:`argparse` は :data:`sys.argv` からそれらの引数を解析する方法を見つけ出し" -"ます。また、 :mod:`argparse` モジュールはヘルプや使用方法のメッセージを自動的" -"に生成します。さらに、このモジュールはユーザーが不正な引数をプログラムに与え" -"た場合にエラーを発生させます。" -#: ../../library/argparse.rst:30 -msgid "Core Functionality" -msgstr "中核的な機能" - -#: ../../library/argparse.rst:32 +#: ../../library/argparse.rst:28 msgid "" -"The :mod:`argparse` module's support for command-line interfaces is built " +"The :mod:`!argparse` module's support for command-line interfaces is built " "around an instance of :class:`argparse.ArgumentParser`. It is a container " "for argument specifications and has options that apply to the parser as " "whole::" msgstr "" -":mod:`argparse` モジュールのコマンドラインインターフェースのサポートは、 :" -"class:`argparse.ArgumentParser` のインスタンスを中心として構築されています。" -"これは引数の仕様に対するコンテナであり、引数解析器(パーサー)全体に適用され" -"るオプションを持っています::" -#: ../../library/argparse.rst:36 +#: ../../library/argparse.rst:32 msgid "" "parser = argparse.ArgumentParser(\n" " prog='ProgramName',\n" @@ -95,7 +79,7 @@ msgid "" " epilog='Text at the bottom of help')" msgstr "" -#: ../../library/argparse.rst:41 +#: ../../library/argparse.rst:37 msgid "" "The :meth:`ArgumentParser.add_argument` method attaches individual argument " "specifications to the parser. It supports positional arguments, options " @@ -105,7 +89,7 @@ msgstr "" "せます。このメソッドは位置引数、値を受け取るオプション、機能のオン/オフを切" "り替えるフラグをサポートします::" -#: ../../library/argparse.rst:45 +#: ../../library/argparse.rst:41 msgid "" "parser.add_argument('filename') # positional argument\n" "parser.add_argument('-c', '--count') # option that takes a value\n" @@ -113,7 +97,7 @@ msgid "" " action='store_true') # on/off flag" msgstr "" -#: ../../library/argparse.rst:50 +#: ../../library/argparse.rst:46 msgid "" "The :meth:`ArgumentParser.parse_args` method runs the parser and places the " "extracted data in a :class:`argparse.Namespace` object::" @@ -121,333 +105,23 @@ msgstr "" ":meth:`ArgumentParser.parse_args` メソッドはパーサーを実行し、抽出したデータ" "を :class:`argparse.Namespace` オブジェクト内に配置します::" -#: ../../library/argparse.rst:53 +#: ../../library/argparse.rst:49 msgid "" "args = parser.parse_args()\n" "print(args.filename, args.count, args.verbose)" msgstr "" -#: ../../library/argparse.rst:58 -msgid "Quick Links for add_argument()" -msgstr "add_argument() のためのクイックリンク" - -#: ../../library/argparse.rst:61 -msgid "Name" -msgstr "名前" - -#: ../../library/argparse.rst:61 -msgid "Description" -msgstr "説明" - -#: ../../library/argparse.rst:61 -msgid "Values" -msgstr "値" - -#: ../../library/argparse.rst:63 -msgid "action_" -msgstr "action_" - -#: ../../library/argparse.rst:63 -msgid "Specify how an argument should be handled" -msgstr "引数をどのように処理するかを指定します" - -#: ../../library/argparse.rst:63 -msgid "" -"``'store'``, ``'store_const'``, ``'store_true'``, ``'append'``, " -"``'append_const'``, ``'count'``, ``'help'``, ``'version'``" -msgstr "" -"``'store'``, ``'store_const'``, ``'store_true'``, ``'append'``, " -"``'append_const'``, ``'count'``, ``'help'``, ``'version'``" - -#: ../../library/argparse.rst:64 -msgid "choices_" -msgstr "choices_" - -#: ../../library/argparse.rst:64 -msgid "Limit values to a specific set of choices" -msgstr "特定の選択肢に値を制限します" - -#: ../../library/argparse.rst:64 -msgid "" -"``['foo', 'bar']``, ``range(1, 10)``, or :class:`~collections.abc.Container` " -"instance" -msgstr "" -"``['foo', 'bar']``, ``range(1, 10)``, または :class:`~collections.abc." -"Container` インスタンス" - -#: ../../library/argparse.rst:65 -msgid "const_" -msgstr "const_" - -#: ../../library/argparse.rst:65 -msgid "Store a constant value" -msgstr "定数値を保存します" - -#: ../../library/argparse.rst:66 -msgid "default_" -msgstr "default_" - -#: ../../library/argparse.rst:66 -msgid "Default value used when an argument is not provided" -msgstr "引数が指定されなかったときに使われるデフォルト値です" - -#: ../../library/argparse.rst:66 -msgid "Defaults to ``None``" -msgstr "特に指定がない場合は ``None`` となります" - -#: ../../library/argparse.rst:67 -msgid "dest_" -msgstr "dest_" - -#: ../../library/argparse.rst:67 -msgid "Specify the attribute name used in the result namespace" -msgstr "引数解析結果の名前空間で使われる属性名を指定します" - -#: ../../library/argparse.rst:68 -msgid "help_" -msgstr "help_" - -#: ../../library/argparse.rst:68 -msgid "Help message for an argument" -msgstr "引数のためのヘルプメッセージです" - -#: ../../library/argparse.rst:69 -msgid "metavar_" -msgstr "metavar_" - -#: ../../library/argparse.rst:69 -msgid "Alternate display name for the argument as shown in help" -msgstr "ヘルプで表示される、引数の代わりの名前です" - -#: ../../library/argparse.rst:70 -msgid "nargs_" -msgstr "nargs_" - -#: ../../library/argparse.rst:70 -msgid "Number of times the argument can be used" -msgstr "引数として受け取ることのできる数です" - -#: ../../library/argparse.rst:70 -msgid ":class:`int`, ``'?'``, ``'*'``, or ``'+'``" -msgstr ":class:`int`, ``'?'``, ``'*'``, または ``'+'``" - -#: ../../library/argparse.rst:71 -msgid "required_" -msgstr "required_" - -#: ../../library/argparse.rst:71 -msgid "Indicate whether an argument is required or optional" -msgstr "その引数が必須か、オプションかを指定します" - -#: ../../library/argparse.rst:71 -msgid "``True`` or ``False``" -msgstr "``True`` または ``False``" - -#: ../../library/argparse.rst:72 -msgid ":ref:`type `" -msgstr ":ref:`type `" - -#: ../../library/argparse.rst:72 -msgid "Automatically convert an argument to the given type" -msgstr "引数を与えられた型に自動的に変換します" - -#: ../../library/argparse.rst:72 -msgid "" -":class:`int`, :class:`float`, ``argparse.FileType('w')``, or callable " -"function" -msgstr "" -":class:`int`, :class:`float`, ``argparse.FileType('w')``, または呼び出し可能" -"な関数" - -#: ../../library/argparse.rst:77 -msgid "Example" -msgstr "使用例" - -#: ../../library/argparse.rst:79 -msgid "" -"The following code is a Python program that takes a list of integers and " -"produces either the sum or the max::" -msgstr "" -"次のコードは、整数のリストを受け取って合計か最大値を返す Python プログラムで" -"す::" - -#: ../../library/argparse.rst:82 -msgid "" -"import argparse\n" -"\n" -"parser = argparse.ArgumentParser(description='Process some integers.')\n" -"parser.add_argument('integers', metavar='N', type=int, nargs='+',\n" -" help='an integer for the accumulator')\n" -"parser.add_argument('--sum', dest='accumulate', action='store_const',\n" -" const=sum, default=max,\n" -" help='sum the integers (default: find the max)')\n" -"\n" -"args = parser.parse_args()\n" -"print(args.accumulate(args.integers))" -msgstr "" - -#: ../../library/argparse.rst:94 -msgid "" -"Assuming the above Python code is saved into a file called ``prog.py``, it " -"can be run at the command line and it provides useful help messages:" -msgstr "" -"上記の Python コードを ``prog.py`` という名前のファイルに保存したとすると、こ" -"のファイルはコマンドラインから実行可能で、次のような有用なヘルプメッセージを" -"提供します:" - -#: ../../library/argparse.rst:97 -msgid "" -"$ python prog.py -h\n" -"usage: prog.py [-h] [--sum] N [N ...]\n" -"\n" -"Process some integers.\n" -"\n" -"positional arguments:\n" -" N an integer for the accumulator\n" -"\n" -"options:\n" -" -h, --help show this help message and exit\n" -" --sum sum the integers (default: find the max)" -msgstr "" - -#: ../../library/argparse.rst:111 -msgid "" -"When run with the appropriate arguments, it prints either the sum or the max " -"of the command-line integers:" -msgstr "" -"適切な引数を与えて実行した場合、このプログラムはコマンドライン引数の整数列の" -"合計か最大値を表示します:" - -#: ../../library/argparse.rst:114 -msgid "" -"$ python prog.py 1 2 3 4\n" -"4\n" -"\n" -"$ python prog.py 1 2 3 4 --sum\n" -"10" -msgstr "" - -#: ../../library/argparse.rst:122 -msgid "If invalid arguments are passed in, an error will be displayed:" -msgstr "不正な引数が渡されると、エラーが表示されます:" - -#: ../../library/argparse.rst:124 -msgid "" -"$ python prog.py a b c\n" -"usage: prog.py [-h] [--sum] N [N ...]\n" -"prog.py: error: argument N: invalid int value: 'a'" -msgstr "" - -#: ../../library/argparse.rst:130 -msgid "The following sections walk you through this example." -msgstr "以降の節では、この例をひと通り説明して行きます。" - -#: ../../library/argparse.rst:134 -msgid "Creating a parser" -msgstr "パーサーを作る" - -#: ../../library/argparse.rst:136 -msgid "" -"The first step in using the :mod:`argparse` is creating an :class:" -"`ArgumentParser` object::" -msgstr "" -":mod:`argparse` を使うときの最初のステップは、:class:`ArgumentParser` オブ" -"ジェクトを生成することです::" - -#: ../../library/argparse.rst:139 -msgid "" -">>> parser = argparse.ArgumentParser(description='Process some integers.')" -msgstr "" - -#: ../../library/argparse.rst:141 -msgid "" -"The :class:`ArgumentParser` object will hold all the information necessary " -"to parse the command line into Python data types." -msgstr "" -":class:`ArgumentParser` オブジェクトはコマンドラインを解析して Python データ" -"型にするために必要なすべての情報を保持します。" - -#: ../../library/argparse.rst:146 -msgid "Adding arguments" -msgstr "引数を追加する" - -#: ../../library/argparse.rst:148 -msgid "" -"Filling an :class:`ArgumentParser` with information about program arguments " -"is done by making calls to the :meth:`~ArgumentParser.add_argument` method. " -"Generally, these calls tell the :class:`ArgumentParser` how to take the " -"strings on the command line and turn them into objects. This information is " -"stored and used when :meth:`~ArgumentParser.parse_args` is called. For " -"example::" -msgstr "" -":class:`ArgumentParser` にプログラム引数の情報を与えるために、:meth:" -"`~ArgumentParser.add_argument` メソッドを呼び出します。一般的に、このメソッド" -"の呼び出しは :class:`ArgumentParser` に、コマンドラインの文字列を受け取ってそ" -"れをオブジェクトにする方法を教えます。この情報は保存され、:meth:" -"`~ArgumentParser.parse_args` が呼び出されたときに利用されます。例えば::" - -#: ../../library/argparse.rst:154 -msgid "" -">>> parser.add_argument('integers', metavar='N', type=int, nargs='+',\n" -"... help='an integer for the accumulator')\n" -">>> parser.add_argument('--sum', dest='accumulate', action='store_const',\n" -"... const=sum, default=max,\n" -"... help='sum the integers (default: find the max)')" -msgstr "" - -#: ../../library/argparse.rst:160 -msgid "" -"Later, calling :meth:`~ArgumentParser.parse_args` will return an object with " -"two attributes, ``integers`` and ``accumulate``. The ``integers`` attribute " -"will be a list of one or more integers, and the ``accumulate`` attribute " -"will be either the :func:`sum` function, if ``--sum`` was specified at the " -"command line, or the :func:`max` function if it was not." -msgstr "" -"あとで :meth:`~ArgumentParser.parse_args` を呼び出すと、``integers`` と " -"``accumulate`` という2つの属性を持ったオブジェクトを返します。``integers`` 属" -"性は1つ以上の整数のリストで、``accumulate`` 属性はコマンドラインから ``--" -"sum`` が指定された場合は :func:`sum` 関数に、それ以外の場合は :func:`max` 関" -"数になります。" - -#: ../../library/argparse.rst:168 -msgid "Parsing arguments" -msgstr "引数を解析する" - -#: ../../library/argparse.rst:170 -msgid "" -":class:`ArgumentParser` parses arguments through the :meth:`~ArgumentParser." -"parse_args` method. This will inspect the command line, convert each " -"argument to the appropriate type and then invoke the appropriate action. In " -"most cases, this means a simple :class:`Namespace` object will be built up " -"from attributes parsed out of the command line::" -msgstr "" -":class:`ArgumentParser` は引数を :meth:`~ArgumentParser.parse_args` メソッド" -"で解析します。このメソッドはコマンドラインを調べ、各引数を正しい型に変換し" -"て、適切なアクションを実行します。ほとんどの場合、これはコマンドラインの解析" -"結果から、シンプルな :class:`Namespace` オブジェクトを構築することを意味しま" -"す::" - -#: ../../library/argparse.rst:176 -msgid "" -">>> parser.parse_args(['--sum', '7', '-1', '42'])\n" -"Namespace(accumulate=, integers=[7, -1, 42])" -msgstr "" - -#: ../../library/argparse.rst:179 +#: ../../library/argparse.rst:53 msgid "" -"In a script, :meth:`~ArgumentParser.parse_args` will typically be called " -"with no arguments, and the :class:`ArgumentParser` will automatically " -"determine the command-line arguments from :data:`sys.argv`." +"If you're looking a guide about how to upgrade optparse code to argparse, " +"see :ref:`Upgrading Optparse Code `." msgstr "" -"スクリプト内では、:meth:`~ArgumentParser.parse_args` は通常引数なしで呼び出さ" -"れ、:class:`ArgumentParser` は自動的に :data:`sys.argv` からコマンドライン引" -"数を取得します。" -#: ../../library/argparse.rst:185 +#: ../../library/argparse.rst:57 msgid "ArgumentParser objects" msgstr "ArgumentParser オブジェクト" -#: ../../library/argparse.rst:194 +#: ../../library/argparse.rst:66 msgid "" "Create a new :class:`ArgumentParser` object. All parameters should be passed " "as keyword arguments. Each parameter has its own more detailed description " @@ -457,12 +131,12 @@ msgstr "" "ワード引数として渡すべきです。各引数についてはあとで詳しく説明しますが、簡単" "に言うと:" -#: ../../library/argparse.rst:198 +#: ../../library/argparse.rst:70 msgid "" "prog_ - The name of the program (default: ``os.path.basename(sys.argv[0])``)" msgstr "prog_ - プログラム名(デフォルト: ``os.path.basename(sys.argv[0])``)" -#: ../../library/argparse.rst:201 +#: ../../library/argparse.rst:73 msgid "" "usage_ - The string describing the program usage (default: generated from " "arguments added to parser)" @@ -470,19 +144,19 @@ msgstr "" "usage_ - プログラムの利用方法を記述する文字列 (デフォルト: パーサーに追加され" "た引数から生成されます)" -#: ../../library/argparse.rst:204 +#: ../../library/argparse.rst:76 msgid "" "description_ - Text to display before the argument help (by default, no text)" msgstr "" "description_ - 引数のヘルプの前に表示されるテキスト (デフォルトはテキストなし" "です)" -#: ../../library/argparse.rst:207 +#: ../../library/argparse.rst:79 msgid "epilog_ - Text to display after the argument help (by default, no text)" msgstr "" "epilog_ - 引数のヘルプの後に表示されるテキスト (デフォルトはテキストなしです)" -#: ../../library/argparse.rst:209 +#: ../../library/argparse.rst:81 msgid "" "parents_ - A list of :class:`ArgumentParser` objects whose arguments should " "also be included" @@ -490,18 +164,18 @@ msgstr "" "parents_ - :class:`ArgumentParser` オブジェクトのリストで、このオブジェクトの" "引数が追加されます" -#: ../../library/argparse.rst:212 +#: ../../library/argparse.rst:84 msgid "formatter_class_ - A class for customizing the help output" msgstr "formatter_class_ - ヘルプ出力をカスタマイズするためのクラス" -#: ../../library/argparse.rst:214 +#: ../../library/argparse.rst:86 msgid "" "prefix_chars_ - The set of characters that prefix optional arguments " "(default: '-')" msgstr "" "prefix_chars_ - オプションの引数の prefix になる文字集合 (デフォルト: '-')" -#: ../../library/argparse.rst:217 +#: ../../library/argparse.rst:89 msgid "" "fromfile_prefix_chars_ - The set of characters that prefix files from which " "additional arguments should be read (default: ``None``)" @@ -509,27 +183,27 @@ msgstr "" "fromfile_prefix_chars_ - 追加の引数を読み込むファイルの prefix になる文字集" "合 (デフォルト: ``None``)" -#: ../../library/argparse.rst:220 +#: ../../library/argparse.rst:92 msgid "" "argument_default_ - The global default value for arguments (default: " "``None``)" msgstr "" "argument_default_ - 引数のグローバルなデフォルト値 (デフォルト: ``None``)" -#: ../../library/argparse.rst:223 +#: ../../library/argparse.rst:95 msgid "" "conflict_handler_ - The strategy for resolving conflicting optionals " "(usually unnecessary)" msgstr "conflict_handler_ - 衝突するオプションを解決する方法 (通常は不要)" -#: ../../library/argparse.rst:226 +#: ../../library/argparse.rst:98 msgid "" "add_help_ - Add a ``-h/--help`` option to the parser (default: ``True``)" msgstr "" "add_help_ - ``-h/--help`` オプションをパーサーに追加する (デフォルト: " "``True``)" -#: ../../library/argparse.rst:228 +#: ../../library/argparse.rst:100 msgid "" "allow_abbrev_ - Allows long options to be abbreviated if the abbreviation is " "unambiguous. (default: ``True``)" @@ -537,7 +211,7 @@ msgstr "" "allow_abbrev_ - 長いオプションが先頭文字列に短縮可能 (先頭の文字が一意) であ" "る場合に短縮指定を許可する。(デフォルト: ``True``)" -#: ../../library/argparse.rst:231 +#: ../../library/argparse.rst:103 msgid "" "exit_on_error_ - Determines whether or not ArgumentParser exits with error " "info when an error occurs. (default: ``True``)" @@ -545,11 +219,11 @@ msgstr "" "exit_on_error_ - エラーが起きたときに、ArgumentParser がエラー情報を出力して " "(訳注: プログラムが) 終了する。 (デフォルト: ``True``)" -#: ../../library/argparse.rst:234 +#: ../../library/argparse.rst:106 msgid "*allow_abbrev* parameter was added." msgstr "*allow_abbrev* 引数が追加されました。" -#: ../../library/argparse.rst:237 +#: ../../library/argparse.rst:109 msgid "" "In previous versions, *allow_abbrev* also disabled grouping of short flags " "such as ``-vv`` to mean ``-v -v``." @@ -557,70 +231,51 @@ msgstr "" "以前のバージョンでは、 *allow_abbrev* は、``-vv`` が ``-v -v`` と等価になるよ" "うな、短いフラグのグループ化を無効にしていました。" -#: ../../library/argparse.rst:241 +#: ../../library/argparse.rst:113 msgid "*exit_on_error* parameter was added." msgstr "*exit_on_error* 引数が追加されました。" -#: ../../library/argparse.rst:244 ../../library/argparse.rst:783 +#: ../../library/argparse.rst:116 ../../library/argparse.rst:598 msgid "The following sections describe how each of these are used." msgstr "以下の節では各オプションの利用方法を説明します。" -#: ../../library/argparse.rst:250 +#: ../../library/argparse.rst:122 msgid "prog" msgstr "``prog``" -#: ../../library/argparse.rst:252 +#: ../../library/argparse.rst:125 msgid "" -"By default, :class:`ArgumentParser` objects use the base name (see :func:`os." -"path.basename`) of ``sys.argv[0]`` to determine how to display the name of " -"the program in help messages. This default is almost always desirable " -"because it will make the help messages match the name that was used to " -"invoke the program on the command line. For example, consider a file named " -"``myprogram.py`` with the following code::" +"By default, :class:`ArgumentParser` calculates the name of the program to " +"display in help messages depending on the way the Python interpreter was run:" msgstr "" -#: ../../library/argparse.rst:259 ../../library/argparse.rst:679 +#: ../../library/argparse.rst:128 msgid "" -"import argparse\n" -"parser = argparse.ArgumentParser()\n" -"parser.add_argument('--foo', help='foo help')\n" -"args = parser.parse_args()" +"The :func:`base name ` of ``sys.argv[0]`` if a file was " +"passed as argument." msgstr "" -#: ../../library/argparse.rst:264 +#: ../../library/argparse.rst:130 msgid "" -"The help for this program will display ``myprogram.py`` as the program name " -"(regardless of where the program was invoked from):" +"The Python interpreter name followed by ``sys.argv[0]`` if a directory or a " +"zipfile was passed as argument." msgstr "" -"このプログラムのヘルプは、プログラム名として (プログラムがどこから起動された" -"のかに関わらず) ``myprogram.py`` を表示します:" -#: ../../library/argparse.rst:267 +#: ../../library/argparse.rst:132 msgid "" -"$ python myprogram.py --help\n" -"usage: myprogram.py [-h] [--foo FOO]\n" -"\n" -"options:\n" -" -h, --help show this help message and exit\n" -" --foo FOO foo help\n" -"$ cd ..\n" -"$ python subdir/myprogram.py --help\n" -"usage: myprogram.py [-h] [--foo FOO]\n" -"\n" -"options:\n" -" -h, --help show this help message and exit\n" -" --foo FOO foo help" +"The Python interpreter name followed by ``-m`` followed by the module or " +"package name if the :option:`-m` option was used." msgstr "" -#: ../../library/argparse.rst:283 +#: ../../library/argparse.rst:135 msgid "" -"To change this default behavior, another value can be supplied using the " -"``prog=`` argument to :class:`ArgumentParser`::" +"This default is almost always desirable because it will make the help " +"messages match the string that was used to invoke the program on the command " +"line. However, to change this default behavior, another value can be " +"supplied using the ``prog=`` argument to :class:`ArgumentParser`::" msgstr "" -"このデフォルトの動作を変更するには、:class:`ArgumentParser` の ``prog=`` 引数" -"に他の値を指定します::" -#: ../../library/argparse.rst:286 +#: ../../library/argparse.rst:140 msgid "" ">>> parser = argparse.ArgumentParser(prog='myprogram')\n" ">>> parser.print_help()\n" @@ -630,7 +285,7 @@ msgid "" " -h, --help show this help message and exit" msgstr "" -#: ../../library/argparse.rst:293 +#: ../../library/argparse.rst:147 msgid "" "Note that the program name, whether determined from ``sys.argv[0]`` or from " "the ``prog=`` argument, is available to help messages using the ``%(prog)s`` " @@ -640,7 +295,7 @@ msgstr "" "た場合でも、ヘルプメッセージ中では ``%(prog)s`` フォーマット指定子で利用でき" "ます。" -#: ../../library/argparse.rst:299 +#: ../../library/argparse.rst:153 msgid "" ">>> parser = argparse.ArgumentParser(prog='myprogram')\n" ">>> parser.add_argument('--foo', help='foo of the %(prog)s program')\n" @@ -652,40 +307,18 @@ msgid "" " --foo FOO foo of the myprogram program" msgstr "" -#: ../../library/argparse.rst:310 +#: ../../library/argparse.rst:164 msgid "usage" msgstr "usage" -#: ../../library/argparse.rst:312 +#: ../../library/argparse.rst:166 msgid "" "By default, :class:`ArgumentParser` calculates the usage message from the " -"arguments it contains::" -msgstr "" -"デフォルトでは、 :class:`ArgumentParser` は使用法メッセージを、保持している引" -"数から生成します::" - -#: ../../library/argparse.rst:315 -msgid "" -">>> parser = argparse.ArgumentParser(prog='PROG')\n" -">>> parser.add_argument('--foo', nargs='?', help='foo help')\n" -">>> parser.add_argument('bar', nargs='+', help='bar help')\n" -">>> parser.print_help()\n" -"usage: PROG [-h] [--foo [FOO]] bar [bar ...]\n" -"\n" -"positional arguments:\n" -" bar bar help\n" -"\n" -"options:\n" -" -h, --help show this help message and exit\n" -" --foo [FOO] foo help" +"arguments it contains. The default message can be overridden with the " +"``usage=`` keyword argument::" msgstr "" -#: ../../library/argparse.rst:328 -msgid "" -"The default message can be overridden with the ``usage=`` keyword argument::" -msgstr "デフォルトのメッセージは ``usage=`` キーワード引数で変更できます::" - -#: ../../library/argparse.rst:330 +#: ../../library/argparse.rst:170 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', usage='%(prog)s " "[options]')\n" @@ -702,7 +335,7 @@ msgid "" " --foo [FOO] foo help" msgstr "" -#: ../../library/argparse.rst:343 +#: ../../library/argparse.rst:183 msgid "" "The ``%(prog)s`` format specifier is available to fill in the program name " "in your usage messages." @@ -710,36 +343,20 @@ msgstr "" "``%(prog)s`` フォーマット指定子を、使用法メッセージ内でプログラム名として利用" "できます。" -#: ../../library/argparse.rst:350 +#: ../../library/argparse.rst:190 msgid "description" msgstr "description" -#: ../../library/argparse.rst:352 +#: ../../library/argparse.rst:192 msgid "" "Most calls to the :class:`ArgumentParser` constructor will use the " "``description=`` keyword argument. This argument gives a brief description " "of what the program does and how it works. In help messages, the " "description is displayed between the command-line usage string and the help " -"messages for the various arguments::" +"messages for the various arguments." msgstr "" -"多くの場合、:class:`ArgumentParser` のコンストラクターを呼び出すときに " -"``description=`` キーワード引数が使用されます。この引数はプログラムが何をして" -"どう動くのかについての短い説明になります。ヘルプメッセージで、この説明がコマ" -"ンドラインの利用法と引数のヘルプメッセージの間に表示されます::" -#: ../../library/argparse.rst:358 -msgid "" -">>> parser = argparse.ArgumentParser(description='A foo that bars')\n" -">>> parser.print_help()\n" -"usage: argparse.py [-h]\n" -"\n" -"A foo that bars\n" -"\n" -"options:\n" -" -h, --help show this help message and exit" -msgstr "" - -#: ../../library/argparse.rst:367 +#: ../../library/argparse.rst:198 msgid "" "By default, the description will be line-wrapped so that it fits within the " "given space. To change this behavior, see the formatter_class_ argument." @@ -747,11 +364,11 @@ msgstr "" "デフォルトでは、説明は与えられたスペースに合わせて折り返されます。この挙動を" "変更するには、formatter_class_ 引数を参照してください。" -#: ../../library/argparse.rst:372 +#: ../../library/argparse.rst:203 msgid "epilog" msgstr "epilog" -#: ../../library/argparse.rst:374 +#: ../../library/argparse.rst:205 msgid "" "Some programs like to display additional description of the program after " "the description of the arguments. Such text can be specified using the " @@ -761,7 +378,7 @@ msgstr "" "します。このテキストは :class:`ArgumentParser` の ``epilog=`` 引数に指定でき" "ます::" -#: ../../library/argparse.rst:378 +#: ../../library/argparse.rst:209 msgid "" ">>> parser = argparse.ArgumentParser(\n" "... description='A foo that bars',\n" @@ -777,7 +394,7 @@ msgid "" "And that's how you'd foo a bar" msgstr "" -#: ../../library/argparse.rst:391 +#: ../../library/argparse.rst:222 msgid "" "As with the description_ argument, the ``epilog=`` text is by default line-" "wrapped, but this behavior can be adjusted with the formatter_class_ " @@ -786,11 +403,11 @@ msgstr "" "description_ 引数と同じく、``epilog=`` テキストもデフォルトで折り返され、:" "class:`ArgumentParser` の formatter_class_ 引数で動作を調整できます。" -#: ../../library/argparse.rst:397 +#: ../../library/argparse.rst:228 msgid "parents" msgstr "parents" -#: ../../library/argparse.rst:399 +#: ../../library/argparse.rst:230 msgid "" "Sometimes, several parsers share a common set of arguments. Rather than " "repeating the definitions of these arguments, a single parser with all the " @@ -807,7 +424,7 @@ msgstr "" "すべての位置アクションとオプションのアクションをそれらから集め、そのアクショ" "ンを構築中の :class:`ArgumentParser` オブジェクトに追加します::" -#: ../../library/argparse.rst:406 +#: ../../library/argparse.rst:237 msgid "" ">>> parent_parser = argparse.ArgumentParser(add_help=False)\n" ">>> parent_parser.add_argument('--parent', type=int)\n" @@ -823,7 +440,7 @@ msgid "" "Namespace(bar='YYY', parent=None)" msgstr "" -#: ../../library/argparse.rst:419 +#: ../../library/argparse.rst:250 msgid "" "Note that most parent parsers will specify ``add_help=False``. Otherwise, " "the :class:`ArgumentParser` will see two ``-h/--help`` options (one in the " @@ -833,7 +450,7 @@ msgstr "" "い。こうしないと、:class:`ArgumentParser` は2つの ``-h/--help`` オプションを" "与えられる (1つは親から、もうひとつは子から) ことになり、エラーを発生します。" -#: ../../library/argparse.rst:424 +#: ../../library/argparse.rst:255 msgid "" "You must fully initialize the parsers before passing them via ``parents=``. " "If you change the parent parsers after the child parser, those changes will " @@ -842,11 +459,11 @@ msgstr "" "``parents=`` に渡す前にパーサーを完全に初期化する必要があります。子パーサーを" "作成してから親パーサーを変更した場合、その変更は子パーサーに反映されません。" -#: ../../library/argparse.rst:432 +#: ../../library/argparse.rst:263 msgid "formatter_class" msgstr "formatter_class" -#: ../../library/argparse.rst:434 +#: ../../library/argparse.rst:265 msgid "" ":class:`ArgumentParser` objects allow the help formatting to be customized " "by specifying an alternate formatting class. Currently, there are four such " @@ -856,7 +473,7 @@ msgstr "" "とでヘルプのフォーマットをカスタマイズできます。現在、4つのフォーマットクラス" "があります:" -#: ../../library/argparse.rst:443 +#: ../../library/argparse.rst:274 msgid "" ":class:`RawDescriptionHelpFormatter` and :class:`RawTextHelpFormatter` give " "more control over how textual descriptions are displayed. By default, :class:" @@ -868,7 +485,7 @@ msgstr "" "`ArgumentParser` オブジェクトはコマンドラインヘルプの中の description_ と " "epilog_ を折り返して表示します::" -#: ../../library/argparse.rst:448 +#: ../../library/argparse.rst:279 msgid "" ">>> parser = argparse.ArgumentParser(\n" "... prog='PROG',\n" @@ -892,7 +509,7 @@ msgid "" "will be wrapped across a couple lines" msgstr "" -#: ../../library/argparse.rst:468 +#: ../../library/argparse.rst:299 msgid "" "Passing :class:`RawDescriptionHelpFormatter` as ``formatter_class=`` " "indicates that description_ and epilog_ are already correctly formatted and " @@ -901,7 +518,7 @@ msgstr "" "``formatter_class=`` に :class:`RawDescriptionHelpFormatter` を渡した場合、 " "description_ と epilog_ は整形済みとされ改行されません::" -#: ../../library/argparse.rst:472 +#: ../../library/argparse.rst:303 msgid "" ">>> parser = argparse.ArgumentParser(\n" "... prog='PROG',\n" @@ -926,18 +543,15 @@ msgid "" " -h, --help show this help message and exit" msgstr "" -#: ../../library/argparse.rst:494 +#: ../../library/argparse.rst:325 msgid "" ":class:`RawTextHelpFormatter` maintains whitespace for all sorts of help " -"text, including argument descriptions. However, multiple new lines are " +"text, including argument descriptions. However, multiple newlines are " "replaced with one. If you wish to preserve multiple blank lines, add spaces " "between the newlines." msgstr "" -":class:`RawTextHelpFormatter` は引数の説明を含めてすべての種類のヘルプテキス" -"トで空白を維持します。例外として、複数の空行はひとつにまとめられます。複数の" -"空白行を保ちたい場合には、行に空白を含めるようにして下さい。" -#: ../../library/argparse.rst:499 +#: ../../library/argparse.rst:330 msgid "" ":class:`ArgumentDefaultsHelpFormatter` automatically adds information about " "default values to each of the argument help messages::" @@ -945,7 +559,7 @@ msgstr "" ":class:`ArgumentDefaultsHelpFormatter` は各引数のデフォルト値を自動的にヘルプ" "に追加します::" -#: ../../library/argparse.rst:502 +#: ../../library/argparse.rst:333 msgid "" ">>> parser = argparse.ArgumentParser(\n" "... prog='PROG',\n" @@ -963,7 +577,7 @@ msgid "" " --foo FOO FOO! (default: 42)" msgstr "" -#: ../../library/argparse.rst:517 +#: ../../library/argparse.rst:348 msgid "" ":class:`MetavarTypeHelpFormatter` uses the name of the type_ argument for " "each argument as the display name for its values (rather than using the " @@ -972,7 +586,7 @@ msgstr "" ":class:`MetavarTypeHelpFormatter` は、各引数の値の表示名に type_ 引数の値を使" "用します (通常は dest_ の値が使用されます)::" -#: ../../library/argparse.rst:521 +#: ../../library/argparse.rst:352 msgid "" ">>> parser = argparse.ArgumentParser(\n" "... prog='PROG',\n" @@ -990,11 +604,11 @@ msgid "" " --foo int" msgstr "" -#: ../../library/argparse.rst:538 +#: ../../library/argparse.rst:369 msgid "prefix_chars" msgstr "prefix_chars" -#: ../../library/argparse.rst:540 +#: ../../library/argparse.rst:371 msgid "" "Most command-line options will use ``-`` as the prefix, e.g. ``-f/--foo``. " "Parsers that need to support different or additional prefix characters, e.g. " @@ -1006,7 +620,7 @@ msgstr "" "トしなければならない場合、ArgumentParser のコンストラクターに " "``prefix_chars=`` 引数を使って指定します::" -#: ../../library/argparse.rst:546 +#: ../../library/argparse.rst:377 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', prefix_chars='-+')\n" ">>> parser.add_argument('+f')\n" @@ -1015,7 +629,7 @@ msgid "" "Namespace(bar='Y', f='X')" msgstr "" -#: ../../library/argparse.rst:552 +#: ../../library/argparse.rst:383 msgid "" "The ``prefix_chars=`` argument defaults to ``'-'``. Supplying a set of " "characters that does not include ``-`` will cause ``-f/--foo`` options to be " @@ -1024,11 +638,11 @@ msgstr "" "``prefix_chars=`` 引数のデフォルトは ``'-'`` です。``-`` を含まない文字セット" "を指定すると、``-f/--foo`` オプションが使用できなくなります。" -#: ../../library/argparse.rst:558 +#: ../../library/argparse.rst:389 msgid "fromfile_prefix_chars" msgstr "fromfile_prefix_chars" -#: ../../library/argparse.rst:560 +#: ../../library/argparse.rst:391 msgid "" "Sometimes, when dealing with a particularly long argument list, it may make " "sense to keep the list of arguments in a file rather than typing it out at " @@ -1043,7 +657,7 @@ msgstr "" "た場合、指定された文字のいずれかで始まる引数はファイルとして扱われ、そのファ" "イルに含まれる引数リストに置換されます。例えば::" -#: ../../library/argparse.rst:567 +#: ../../library/argparse.rst:398 msgid "" ">>> with open('args.txt', 'w', encoding=sys.getfilesystemencoding()) as fp:\n" "... fp.write('-f\\nbar')\n" @@ -1054,7 +668,7 @@ msgid "" "Namespace(f='bar')" msgstr "" -#: ../../library/argparse.rst:575 +#: ../../library/argparse.rst:406 msgid "" "Arguments read from a file must by default be one per line (but see also :" "meth:`~ArgumentParser.convert_arg_line_to_args`) and are treated as if they " @@ -1069,13 +683,13 @@ msgstr "" "ます。このため、上の例では、``['-f', 'foo', '@args.txt']`` は ``['-f', " "'foo', '-f', 'bar']`` と等価になります。" -#: ../../library/argparse.rst:581 +#: ../../library/argparse.rst:412 msgid "" ":class:`ArgumentParser` uses :term:`filesystem encoding and error handler` " "to read the file containing arguments." msgstr "" -#: ../../library/argparse.rst:584 +#: ../../library/argparse.rst:415 msgid "" "The ``fromfile_prefix_chars=`` argument defaults to ``None``, meaning that " "arguments will never be treated as file references." @@ -1083,20 +697,20 @@ msgstr "" "``fromfile_prefix_chars=`` 引数のデフォルト値は ``None`` で、引数がファイル参" "照として扱われることがないことを意味しています。" -#: ../../library/argparse.rst:587 +#: ../../library/argparse.rst:418 msgid "" ":class:`ArgumentParser` changed encoding and errors to read arguments files " "from default (e.g. :func:`locale.getpreferredencoding(False) ` and ``\"strict\"``) to :term:`filesystem encoding and " -"error handler`. Arguments file should be encoded in UTF-8 instead of ANSI " -"Codepage on Windows." +"getpreferredencoding>` and ``\"strict\"``) to the :term:`filesystem encoding " +"and error handler`. Arguments file should be encoded in UTF-8 instead of " +"ANSI Codepage on Windows." msgstr "" -#: ../../library/argparse.rst:595 +#: ../../library/argparse.rst:426 msgid "argument_default" msgstr "argument_default" -#: ../../library/argparse.rst:597 +#: ../../library/argparse.rst:428 msgid "" "Generally, argument defaults are specified either by passing a default to :" "meth:`~ArgumentParser.add_argument` or by calling the :meth:`~ArgumentParser." @@ -1115,7 +729,7 @@ msgstr "" "全体で :meth:`~ArgumentParser.parse_args` メソッド呼び出しの属性の生成を抑制" "するには、``argument_default=SUPPRESS`` を指定します::" -#: ../../library/argparse.rst:606 +#: ../../library/argparse.rst:437 msgid "" ">>> parser = argparse.ArgumentParser(argument_default=argparse.SUPPRESS)\n" ">>> parser.add_argument('--foo')\n" @@ -1126,11 +740,11 @@ msgid "" "Namespace()" msgstr "" -#: ../../library/argparse.rst:617 +#: ../../library/argparse.rst:448 msgid "allow_abbrev" msgstr "allow_abbrev" -#: ../../library/argparse.rst:619 +#: ../../library/argparse.rst:450 msgid "" "Normally, when you pass an argument list to the :meth:`~ArgumentParser." "parse_args` method of an :class:`ArgumentParser`, it :ref:`recognizes " @@ -1140,12 +754,12 @@ msgstr "" "リストを渡すとき、長いオプションは :ref:`短縮しても認識されます `。" -#: ../../library/argparse.rst:623 +#: ../../library/argparse.rst:454 msgid "This feature can be disabled by setting ``allow_abbrev`` to ``False``::" msgstr "" "この機能は、``allow_abbrev`` に ``False`` を指定することで無効にできます::" -#: ../../library/argparse.rst:625 +#: ../../library/argparse.rst:456 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', allow_abbrev=False)\n" ">>> parser.add_argument('--foobar', action='store_true')\n" @@ -1155,11 +769,11 @@ msgid "" "PROG: error: unrecognized arguments: --foon" msgstr "" -#: ../../library/argparse.rst:636 +#: ../../library/argparse.rst:467 msgid "conflict_handler" msgstr "conflict_handler" -#: ../../library/argparse.rst:638 +#: ../../library/argparse.rst:469 msgid "" ":class:`ArgumentParser` objects do not allow two actions with the same " "option string. By default, :class:`ArgumentParser` objects raise an " @@ -1171,7 +785,7 @@ msgstr "" "デフォルトでは、:class:`ArgumentParser` オブジェクトは、すでに利用されている" "オプション文字列を使って新しい引数をつくろうとしたときに例外を送出します::" -#: ../../library/argparse.rst:643 +#: ../../library/argparse.rst:474 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-f', '--foo', help='old foo help')\n" @@ -1181,7 +795,7 @@ msgid "" "ArgumentError: argument --foo: conflicting option string(s): --foo" msgstr "" -#: ../../library/argparse.rst:650 +#: ../../library/argparse.rst:481 msgid "" "Sometimes (e.g. when using parents_) it may be useful to simply override any " "older arguments with the same option string. To get this behavior, the " @@ -1192,7 +806,7 @@ msgstr "" "で上書きするほうが便利な場合があります。この動作をするには、:class:" "`ArgumentParser` の ``conflict_handler=`` 引数に ``'resolve'`` を渡します::" -#: ../../library/argparse.rst:655 +#: ../../library/argparse.rst:486 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', " "conflict_handler='resolve')\n" @@ -1207,7 +821,7 @@ msgid "" " --foo FOO new foo help" msgstr "" -#: ../../library/argparse.rst:666 +#: ../../library/argparse.rst:497 msgid "" "Note that :class:`ArgumentParser` objects only remove an action if all of " "its option strings are overridden. So, in the example above, the old ``-f/--" @@ -1219,39 +833,18 @@ msgstr "" "foo`` オプション文字列だけが上書きされているので、古い ``-f/--foo`` アクショ" "ンは ``-f`` アクションとして残っています。" -#: ../../library/argparse.rst:673 +#: ../../library/argparse.rst:504 msgid "add_help" msgstr "add_help" -#: ../../library/argparse.rst:675 +#: ../../library/argparse.rst:506 msgid "" "By default, ArgumentParser objects add an option which simply displays the " -"parser's help message. For example, consider a file named ``myprogram.py`` " -"containing the following code::" -msgstr "" -"デフォルトでは、ArgumentParser オブジェクトはシンプルにパーサーのヘルプメッ" -"セージを表示するオプションを自動的に追加します。例えば、以下のコードを含む " -"``myprogram.py`` ファイルについて考えてください::" - -#: ../../library/argparse.rst:684 -msgid "" -"If ``-h`` or ``--help`` is supplied at the command line, the ArgumentParser " -"help will be printed:" +"parser's help message. If ``-h`` or ``--help`` is supplied at the command " +"line, the ArgumentParser help will be printed." msgstr "" -"コマンドラインに ``-h`` か ``--help`` が指定された場合、ArgumentParser の " -"help が表示されます:" -#: ../../library/argparse.rst:687 -msgid "" -"$ python myprogram.py --help\n" -"usage: myprogram.py [-h] [--foo FOO]\n" -"\n" -"options:\n" -" -h, --help show this help message and exit\n" -" --foo FOO foo help" -msgstr "" - -#: ../../library/argparse.rst:696 +#: ../../library/argparse.rst:510 msgid "" "Occasionally, it may be useful to disable the addition of this help option. " "This can be achieved by passing ``False`` as the ``add_help=`` argument to :" @@ -1260,7 +853,7 @@ msgstr "" "必要に応じて、この help オプションを無効にする場合があります。これは :class:" "`ArgumentParser` の ``add_help=`` 引数に ``False`` を渡すことで可能です::" -#: ../../library/argparse.rst:700 +#: ../../library/argparse.rst:514 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', add_help=False)\n" ">>> parser.add_argument('--foo', help='foo help')\n" @@ -1271,7 +864,7 @@ msgid "" " --foo FOO foo help" msgstr "" -#: ../../library/argparse.rst:708 +#: ../../library/argparse.rst:522 msgid "" "The help option is typically ``-h/--help``. The exception to this is if the " "``prefix_chars=`` is specified and does not include ``-``, in which case ``-" @@ -1283,7 +876,7 @@ msgstr "" "オプションではありません。この場合、``prefix_chars`` の最初の文字がヘルプオプ" "ションの接頭辞として利用されます::" -#: ../../library/argparse.rst:714 +#: ../../library/argparse.rst:528 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', prefix_chars='+/')\n" ">>> parser.print_help()\n" @@ -1293,21 +886,18 @@ msgid "" " +h, ++help show this help message and exit" msgstr "" -#: ../../library/argparse.rst:723 +#: ../../library/argparse.rst:537 msgid "exit_on_error" msgstr "exit_on_error" -#: ../../library/argparse.rst:725 +#: ../../library/argparse.rst:539 msgid "" "Normally, when you pass an invalid argument list to the :meth:" "`~ArgumentParser.parse_args` method of an :class:`ArgumentParser`, it will " -"exit with error info." +"print a *message* to :data:`sys.stderr` and exit with a status code of 2." msgstr "" -"通常、不正な引数リストが :class:`ArgumentParser` の :meth:`~ArgumentParser." -"parse_args` メソッドに渡された場合、プログラムはエラー情報を出力して終了しま" -"す。" -#: ../../library/argparse.rst:728 +#: ../../library/argparse.rst:543 msgid "" "If the user would like to catch errors manually, the feature can be enabled " "by setting ``exit_on_error`` to ``False``::" @@ -1315,7 +905,7 @@ msgstr "" "もしエラーを例外としてプログラム内でキャッチしたい場合は、``exit_on_error`` " "を ``False`` に設定してください::" -#: ../../library/argparse.rst:731 +#: ../../library/argparse.rst:546 msgid "" ">>> parser = argparse.ArgumentParser(exit_on_error=False)\n" ">>> parser.add_argument('--integers', type=int)\n" @@ -1330,11 +920,11 @@ msgid "" "Catching an argumentError" msgstr "" -#: ../../library/argparse.rst:745 +#: ../../library/argparse.rst:560 msgid "The add_argument() method" msgstr "add_argument() メソッド" -#: ../../library/argparse.rst:751 +#: ../../library/argparse.rst:566 msgid "" "Define how a single command-line argument should be parsed. Each parameter " "has its own more detailed description below, but in short they are:" @@ -1342,7 +932,7 @@ msgstr "" "1つのコマンドライン引数がどう解析されるかを定義します。各引数についての詳細は" "後述しますが、簡単に言うと:" -#: ../../library/argparse.rst:754 +#: ../../library/argparse.rst:569 msgid "" "`name or flags`_ - Either a name or a list of option strings, e.g. ``foo`` " "or ``-f, --foo``." @@ -1350,22 +940,22 @@ msgstr "" "`name または flags`_ - 名前か、あるいはオプション文字列のリスト (例: ``foo`` " "や ``-f, --foo``)。" -#: ../../library/argparse.rst:757 +#: ../../library/argparse.rst:572 msgid "" "action_ - The basic type of action to be taken when this argument is " "encountered at the command line." msgstr "action_ - コマンドラインにこの引数があったときのアクション。" -#: ../../library/argparse.rst:760 +#: ../../library/argparse.rst:575 msgid "nargs_ - The number of command-line arguments that should be consumed." msgstr "nargs_ - 受け取るべきコマンドライン引数の数。" -#: ../../library/argparse.rst:762 +#: ../../library/argparse.rst:577 msgid "" "const_ - A constant value required by some action_ and nargs_ selections." msgstr "const_ - 一部の action_ と nargs_ の組み合わせで利用される定数。" -#: ../../library/argparse.rst:764 +#: ../../library/argparse.rst:579 msgid "" "default_ - The value produced if the argument is absent from the command " "line and if it is absent from the namespace object." @@ -1373,45 +963,45 @@ msgstr "" "default_ - コマンドラインに対応する引数が存在せず、さらに namespace オブジェ" "クトにも存在しない場合に利用される値。 " -#: ../../library/argparse.rst:767 +#: ../../library/argparse.rst:582 msgid "" "type_ - The type to which the command-line argument should be converted." msgstr "type_ - コマンドライン引数が変換されるべき型。" -#: ../../library/argparse.rst:769 +#: ../../library/argparse.rst:584 msgid "choices_ - A sequence of the allowable values for the argument." msgstr "choices_ - 引数として許される値のシーケンス。" -#: ../../library/argparse.rst:771 +#: ../../library/argparse.rst:586 msgid "" "required_ - Whether or not the command-line option may be omitted (optionals " "only)." msgstr "" "required_ - コマンドラインオプションが省略可能かどうか (オプション引数のみ)。" -#: ../../library/argparse.rst:774 +#: ../../library/argparse.rst:589 msgid "help_ - A brief description of what the argument does." msgstr "help_ - 引数が何なのかを示す簡潔な説明。" -#: ../../library/argparse.rst:776 +#: ../../library/argparse.rst:591 msgid "metavar_ - A name for the argument in usage messages." msgstr "metavar_ - 使用法メッセージの中で使われる引数の名前。" -#: ../../library/argparse.rst:778 +#: ../../library/argparse.rst:593 msgid "" "dest_ - The name of the attribute to be added to the object returned by :" "meth:`parse_args`." msgstr "dest_ - :meth:`parse_args` が返すオブジェクトに追加される属性名。" -#: ../../library/argparse.rst:781 +#: ../../library/argparse.rst:596 msgid "deprecated_ - Whether or not use of the argument is deprecated." msgstr "" -#: ../../library/argparse.rst:789 +#: ../../library/argparse.rst:604 msgid "name or flags" msgstr "name または flags" -#: ../../library/argparse.rst:791 +#: ../../library/argparse.rst:606 msgid "" "The :meth:`~ArgumentParser.add_argument` method must know whether an " "optional argument, like ``-f`` or ``--foo``, or a positional argument, like " @@ -1425,23 +1015,23 @@ msgstr "" "そのため、 :meth:`~ArgumentParser.add_argument` に初めに渡される引数は、一連" "のフラグか、単一の引数名のどちらかになります。" -#: ../../library/argparse.rst:797 +#: ../../library/argparse.rst:612 msgid "For example, an optional argument could be created like::" msgstr "たとえば、オプション引数は次のように作成します::" -#: ../../library/argparse.rst:799 +#: ../../library/argparse.rst:614 msgid ">>> parser.add_argument('-f', '--foo')" msgstr "" -#: ../../library/argparse.rst:801 +#: ../../library/argparse.rst:616 msgid "while a positional argument could be created like::" msgstr "一方、位置引数は次のように作成します::" -#: ../../library/argparse.rst:803 +#: ../../library/argparse.rst:618 msgid ">>> parser.add_argument('bar')" msgstr "" -#: ../../library/argparse.rst:805 +#: ../../library/argparse.rst:620 msgid "" "When :meth:`~ArgumentParser.parse_args` is called, optional arguments will " "be identified by the ``-`` prefix, and the remaining arguments will be " @@ -1450,7 +1040,7 @@ msgstr "" ":meth:`~ArgumentParser.parse_args` が呼ばれたとき、オプション引数は接頭辞 ``-" "`` により識別され、それ以外の引数は位置引数として扱われます::" -#: ../../library/argparse.rst:809 +#: ../../library/argparse.rst:624 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-f', '--foo')\n" @@ -1464,11 +1054,11 @@ msgid "" "PROG: error: the following arguments are required: bar" msgstr "" -#: ../../library/argparse.rst:824 +#: ../../library/argparse.rst:639 msgid "action" msgstr "action" -#: ../../library/argparse.rst:826 +#: ../../library/argparse.rst:641 msgid "" ":class:`ArgumentParser` objects associate command-line arguments with " "actions. These actions can do just about anything with the command-line " @@ -1484,23 +1074,13 @@ msgstr "" "引数は、コマンドライン引数がどう処理されるかを指定します。提供されているアク" "ションは:" -#: ../../library/argparse.rst:832 +#: ../../library/argparse.rst:647 msgid "" "``'store'`` - This just stores the argument's value. This is the default " -"action. For example::" -msgstr "" -"``'store'`` - これは単に引数の値を格納します。これはデフォルトのアクションで" -"す。例えば::" - -#: ../../library/argparse.rst:835 -msgid "" -">>> parser = argparse.ArgumentParser()\n" -">>> parser.add_argument('--foo')\n" -">>> parser.parse_args('--foo 1'.split())\n" -"Namespace(foo='1')" +"action." msgstr "" -#: ../../library/argparse.rst:840 +#: ../../library/argparse.rst:650 msgid "" "``'store_const'`` - This stores the value specified by the const_ keyword " "argument; note that the const_ keyword argument defaults to ``None``. The " @@ -1512,7 +1092,7 @@ msgstr "" "ください。``'store_const'`` アクションは、何かの種類のフラグを指定するオプ" "ション引数によく使われます。例えば::" -#: ../../library/argparse.rst:845 +#: ../../library/argparse.rst:655 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', action='store_const', const=42)\n" @@ -1520,18 +1100,15 @@ msgid "" "Namespace(foo=42)" msgstr "" -#: ../../library/argparse.rst:850 +#: ../../library/argparse.rst:660 msgid "" "``'store_true'`` and ``'store_false'`` - These are special cases of " "``'store_const'`` used for storing the values ``True`` and ``False`` " "respectively. In addition, they create default values of ``False`` and " -"``True`` respectively. For example::" +"``True`` respectively::" msgstr "" -"``'store_true'``, ``'store_false'`` - これらは ``'store_const'`` の、それぞ" -"れ ``True`` と ``False`` を格納する特別版になります。加えて、これらはそれぞれ" -"デフォルト値を順に ``False`` と ``True`` にします。例えば::" -#: ../../library/argparse.rst:855 +#: ../../library/argparse.rst:665 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', action='store_true')\n" @@ -1541,7 +1118,7 @@ msgid "" "Namespace(foo=True, bar=False, baz=True)" msgstr "" -#: ../../library/argparse.rst:862 +#: ../../library/argparse.rst:672 msgid "" "``'append'`` - This stores a list, and appends each argument value to the " "list. It is useful to allow an option to be specified multiple times. If the " @@ -1554,7 +1131,7 @@ msgstr "" "す。デフォルト値が空でない場合、デフォルト値は常にパースされたリストに含ま" "れ、コマンドラインで指定した値はデフォルト値の後に追加されます。使用例::" -#: ../../library/argparse.rst:868 +#: ../../library/argparse.rst:678 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', action='append')\n" @@ -1562,7 +1139,7 @@ msgid "" "Namespace(foo=['1', '2'])" msgstr "" -#: ../../library/argparse.rst:873 +#: ../../library/argparse.rst:683 msgid "" "``'append_const'`` - This stores a list, and appends the value specified by " "the const_ keyword argument to the list; note that the const_ keyword " @@ -1575,7 +1152,7 @@ msgstr "" "は ``None`` であることに注意してください。``'append_const'`` アクションは、定" "数を同じリストに複数回格納する場合に便利です。例えば::" -#: ../../library/argparse.rst:879 +#: ../../library/argparse.rst:689 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--str', dest='types', action='append_const', " @@ -1586,7 +1163,7 @@ msgid "" "Namespace(types=[, ])" msgstr "" -#: ../../library/argparse.rst:885 +#: ../../library/argparse.rst:695 msgid "" "``'count'`` - This counts the number of times a keyword argument occurs. For " "example, this is useful for increasing verbosity levels::" @@ -1594,7 +1171,7 @@ msgstr "" "``'count'`` - このアクションはキーワード引数の数を数えます。例えば、verboseレ" "ベルを上げるのに役立ちます::" -#: ../../library/argparse.rst:888 +#: ../../library/argparse.rst:698 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--verbose', '-v', action='count', default=0)\n" @@ -1602,13 +1179,13 @@ msgid "" "Namespace(verbose=3)" msgstr "" -#: ../../library/argparse.rst:893 +#: ../../library/argparse.rst:703 msgid "Note, the *default* will be ``None`` unless explicitly set to *0*." msgstr "" "*default* は明示的に *0* と指定されない場合は ``None`` であることに注意してく" "ださい。" -#: ../../library/argparse.rst:895 +#: ../../library/argparse.rst:705 msgid "" "``'help'`` - This prints a complete help message for all the options in the " "current parser and then exits. By default a help action is automatically " @@ -1619,7 +1196,7 @@ msgstr "" "セージを表示し、終了します。出力の生成方法の詳細については :class:" "`ArgumentParser` を参照してください。" -#: ../../library/argparse.rst:900 +#: ../../library/argparse.rst:710 msgid "" "``'version'`` - This expects a ``version=`` keyword argument in the :meth:" "`~ArgumentParser.add_argument` call, and prints version information and " @@ -1629,7 +1206,7 @@ msgstr "" "出しに ``version=`` キーワード引数を期待します。指定されたときはバージョン情" "報を表示して終了します::" -#: ../../library/argparse.rst:904 +#: ../../library/argparse.rst:714 msgid "" ">>> import argparse\n" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" @@ -1639,7 +1216,7 @@ msgid "" "PROG 2.0" msgstr "" -#: ../../library/argparse.rst:910 +#: ../../library/argparse.rst:720 msgid "" "``'extend'`` - This stores a list, and extends each argument value to the " "list. Example usage::" @@ -1647,7 +1224,7 @@ msgstr "" "``'extend'`` - このアクションはリストを格納して、各引数の値でそのリストを拡張" "します。利用例::" -#: ../../library/argparse.rst:914 +#: ../../library/argparse.rst:724 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument(\"--foo\", action=\"extend\", nargs=\"+\", " @@ -1657,7 +1234,7 @@ msgid "" "Namespace(foo=['f1', 'f2', 'f3', 'f4'])" msgstr "" -#: ../../library/argparse.rst:921 +#: ../../library/argparse.rst:731 msgid "" "You may also specify an arbitrary action by passing an Action subclass or " "other object that implements the same interface. The " @@ -1670,7 +1247,7 @@ msgstr "" "``--no-foo`` のようなオプションに対して真偽値を設定するアクションをサポートし" "ています::" -#: ../../library/argparse.rst:926 +#: ../../library/argparse.rst:736 msgid "" ">>> import argparse\n" ">>> parser = argparse.ArgumentParser()\n" @@ -1679,7 +1256,7 @@ msgid "" "Namespace(foo=False)" msgstr "" -#: ../../library/argparse.rst:934 +#: ../../library/argparse.rst:744 msgid "" "The recommended way to create a custom action is to extend :class:`Action`, " "overriding the ``__call__`` method and optionally the ``__init__`` and " @@ -1689,11 +1266,11 @@ msgstr "" "``__call__`` メソッド (および、任意で ``__init__`` および ``format_usage`` メ" "ソッド) をオーバーライドすることです。" -#: ../../library/argparse.rst:938 +#: ../../library/argparse.rst:748 msgid "An example of a custom action::" msgstr "カスタムアクションの例です::" -#: ../../library/argparse.rst:940 +#: ../../library/argparse.rst:750 msgid "" ">>> class FooAction(argparse.Action):\n" "... def __init__(self, option_strings, dest, nargs=None, **kwargs):\n" @@ -1714,15 +1291,15 @@ msgid "" "Namespace(bar='1', foo='2')" msgstr "" -#: ../../library/argparse.rst:958 +#: ../../library/argparse.rst:768 msgid "For more details, see :class:`Action`." msgstr "詳細は :class:`Action` を参照してください。" -#: ../../library/argparse.rst:964 +#: ../../library/argparse.rst:774 msgid "nargs" msgstr "nargs" -#: ../../library/argparse.rst:966 +#: ../../library/argparse.rst:776 msgid "" "ArgumentParser objects usually associate a single command-line argument with " "a single action to be taken. The ``nargs`` keyword argument associates a " @@ -1734,7 +1311,7 @@ msgstr "" "ン引数を割り当てます。:ref:`specifying-ambiguous-arguments` を参照してくださ" "い。指定できる値は:" -#: ../../library/argparse.rst:971 +#: ../../library/argparse.rst:781 msgid "" "``N`` (an integer). ``N`` arguments from the command line will be gathered " "together into a list. For example::" @@ -1742,7 +1319,7 @@ msgstr "" "``N`` (整数) -- ``N`` 個の引数がコマンドラインから集められ、リストに格納され" "ます。例えば::" -#: ../../library/argparse.rst:974 +#: ../../library/argparse.rst:784 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', nargs=2)\n" @@ -1751,7 +1328,7 @@ msgid "" "Namespace(bar=['c'], foo=['a', 'b'])" msgstr "" -#: ../../library/argparse.rst:980 +#: ../../library/argparse.rst:790 msgid "" "Note that ``nargs=1`` produces a list of one item. This is different from " "the default, in which the item is produced by itself." @@ -1759,7 +1336,7 @@ msgstr "" "``nargs=1`` は1要素のリストを作ることに注意してください。これはデフォルトの、" "要素がそのまま属性になる動作とは異なります。" -#: ../../library/argparse.rst:985 +#: ../../library/argparse.rst:795 msgid "" "``'?'``. One argument will be consumed from the command line if possible, " "and produced as a single item. If no command-line argument is present, the " @@ -1774,7 +1351,7 @@ msgstr "" "いというケースもありえます。この場合は const_ の値が生成されます。この動作の" "例です::" -#: ../../library/argparse.rst:992 +#: ../../library/argparse.rst:802 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', nargs='?', const='c', default='d')\n" @@ -1787,14 +1364,14 @@ msgid "" "Namespace(bar='d', foo='d')" msgstr "" -#: ../../library/argparse.rst:1002 +#: ../../library/argparse.rst:812 msgid "" "One of the more common uses of ``nargs='?'`` is to allow optional input and " "output files::" msgstr "" "``nargs='?'`` のよくある利用例の1つは、入出力ファイルの指定オプションです::" -#: ../../library/argparse.rst:1005 +#: ../../library/argparse.rst:815 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('infile', nargs='?', type=argparse.FileType('r'),\n" @@ -1809,7 +1386,7 @@ msgid "" " outfile=<_io.TextIOWrapper name='' encoding='UTF-8'>)" msgstr "" -#: ../../library/argparse.rst:1019 +#: ../../library/argparse.rst:829 msgid "" "``'*'``. All command-line arguments present are gathered into a list. Note " "that it generally doesn't make much sense to have more than one positional " @@ -1820,7 +1397,7 @@ msgstr "" "が ``nargs='*'`` を持つことにあまり意味はありませんが、複数のオプション引数" "が ``nargs='*'`` を持つことはありえます。例えば::" -#: ../../library/argparse.rst:1024 +#: ../../library/argparse.rst:834 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', nargs='*')\n" @@ -1830,7 +1407,7 @@ msgid "" "Namespace(bar=['1', '2'], baz=['a', 'b'], foo=['x', 'y'])" msgstr "" -#: ../../library/argparse.rst:1033 +#: ../../library/argparse.rst:843 msgid "" "``'+'``. Just like ``'*'``, all command-line args present are gathered into " "a list. Additionally, an error message will be generated if there wasn't at " @@ -1840,7 +1417,7 @@ msgstr "" "す。加えて、最低でも1つのコマンドライン引数が存在しない場合にエラーメッセージ" "を生成します。例えば::" -#: ../../library/argparse.rst:1037 +#: ../../library/argparse.rst:847 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('foo', nargs='+')\n" @@ -1851,7 +1428,7 @@ msgid "" "PROG: error: the following arguments are required: foo" msgstr "" -#: ../../library/argparse.rst:1045 +#: ../../library/argparse.rst:855 msgid "" "If the ``nargs`` keyword argument is not provided, the number of arguments " "consumed is determined by the action_. Generally this means a single " @@ -1862,11 +1439,11 @@ msgstr "" "て決定されます。通常これは、1つのコマンドライン引数は1つのアイテムになる (リ" "ストにはならない) ことを意味します。" -#: ../../library/argparse.rst:1053 +#: ../../library/argparse.rst:863 msgid "const" msgstr "const" -#: ../../library/argparse.rst:1055 +#: ../../library/argparse.rst:865 msgid "" "The ``const`` argument of :meth:`~ArgumentParser.add_argument` is used to " "hold constant values that are not read from the command line but are " @@ -1877,7 +1454,7 @@ msgstr "" "から読み込まれないけれども :class:`ArgumentParser` のいくつかのアクションで必" "要とされる値のために使われます。この引数のよくある2つの使用法は:" -#: ../../library/argparse.rst:1059 +#: ../../library/argparse.rst:869 msgid "" "When :meth:`~ArgumentParser.add_argument` is called with " "``action='store_const'`` or ``action='append_const'``. These actions add " @@ -1893,7 +1470,7 @@ msgstr "" "`~ArgumentParser.add_argument` に与えられなければ、``None`` のデフォルト値を" "受け取ります。" -#: ../../library/argparse.rst:1067 +#: ../../library/argparse.rst:877 msgid "" "When :meth:`~ArgumentParser.add_argument` is called with option strings " "(like ``-f`` or ``--foo``) and ``nargs='?'``. This creates an optional " @@ -1908,7 +1485,7 @@ msgstr "" "かなかった場合、代わりに ``const`` の値が ``None`` であると見なされます。サン" "プルは nargs_ の説明を参照してください。" -#: ../../library/argparse.rst:1074 +#: ../../library/argparse.rst:884 msgid "" "``const=None`` by default, including when ``action='append_const'`` or " "``action='store_const'``." @@ -1916,11 +1493,11 @@ msgstr "" "``action='append_const'`` や ``action='store_const'`` の場合も含め、デフォル" "トでは ``const=None`` です。" -#: ../../library/argparse.rst:1081 +#: ../../library/argparse.rst:891 msgid "default" msgstr "default" -#: ../../library/argparse.rst:1083 +#: ../../library/argparse.rst:893 msgid "" "All optional arguments and some positional arguments may be omitted at the " "command line. The ``default`` keyword argument of :meth:`~ArgumentParser." @@ -1935,7 +1512,7 @@ msgstr "" "る値を指定します。オプション引数では、オプション文字列がコマンドライン上に存" "在しなかったときに ``default`` の値が利用されます::" -#: ../../library/argparse.rst:1090 +#: ../../library/argparse.rst:900 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', default=42)\n" @@ -1945,15 +1522,13 @@ msgid "" "Namespace(foo=42)" msgstr "" -#: ../../library/argparse.rst:1097 +#: ../../library/argparse.rst:907 msgid "" "If the target namespace already has an attribute set, the action *default* " -"will not over write it::" +"will not overwrite it::" msgstr "" -"対象となる namespace がすでにその属性を持っている場合、それは default の値で" -"は上書きされません::" -#: ../../library/argparse.rst:1100 +#: ../../library/argparse.rst:910 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', default=42)\n" @@ -1961,7 +1536,7 @@ msgid "" "Namespace(foo=101)" msgstr "" -#: ../../library/argparse.rst:1105 +#: ../../library/argparse.rst:915 msgid "" "If the ``default`` value is a string, the parser parses the value as if it " "were a command-line argument. In particular, the parser applies any type_ " @@ -1973,7 +1548,7 @@ msgstr "" "に、type_ 変換引数が与えられていればそれらを適用します。そうでない場合、パー" "サーは値をそのまま使用します::" -#: ../../library/argparse.rst:1110 +#: ../../library/argparse.rst:920 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--length', default='10', type=int)\n" @@ -1982,7 +1557,7 @@ msgid "" "Namespace(length=10, width=10.5)" msgstr "" -#: ../../library/argparse.rst:1116 +#: ../../library/argparse.rst:926 msgid "" "For positional arguments with nargs_ equal to ``?`` or ``*``, the " "``default`` value is used when no command-line argument was present::" @@ -1990,7 +1565,7 @@ msgstr "" "nargs_ が ``?`` か ``*`` である位置引数では、コマンドライン引数が指定されな" "かった場合 ``default`` の値が使われます。例えば::" -#: ../../library/argparse.rst:1119 +#: ../../library/argparse.rst:929 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('foo', nargs='?', default=42)\n" @@ -2000,14 +1575,14 @@ msgid "" "Namespace(foo=42)" msgstr "" -#: ../../library/argparse.rst:1126 +#: ../../library/argparse.rst:936 msgid "" "For required_ arguments, the ``default`` value is ignored. For example, this " "applies to positional arguments with nargs_ values other than ``?`` or " "``*``, or optional arguments marked as ``required=True``." msgstr "" -#: ../../library/argparse.rst:1130 +#: ../../library/argparse.rst:940 msgid "" "Providing ``default=argparse.SUPPRESS`` causes no attribute to be added if " "the command-line argument was not present::" @@ -2015,7 +1590,7 @@ msgstr "" "``default=argparse.SUPPRESS`` を渡すと、コマンドライン引数が存在しないときに" "属性の追加をしなくなります::" -#: ../../library/argparse.rst:1133 +#: ../../library/argparse.rst:943 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', default=argparse.SUPPRESS)\n" @@ -2025,11 +1600,11 @@ msgid "" "Namespace(foo='1')" msgstr "" -#: ../../library/argparse.rst:1144 +#: ../../library/argparse.rst:954 msgid "type" msgstr "type" -#: ../../library/argparse.rst:1146 +#: ../../library/argparse.rst:956 msgid "" "By default, the parser reads command-line arguments in as simple strings. " "However, quite often the command-line string should instead be interpreted " @@ -2043,7 +1618,7 @@ msgstr "" "ワード引数に指定する type converter により、必要な型チェックと型変換を行うこ" "とができます。" -#: ../../library/argparse.rst:1152 +#: ../../library/argparse.rst:962 msgid "" "If the type_ keyword is used with the default_ keyword, the type converter " "is only applied if the default is a string." @@ -2051,7 +1626,7 @@ msgstr "" "もし type_ キーワードが default_ キーワードとともに使用された場合、default_ " "の値が文字列のときのみ、type converter による変換などが行われます。" -#: ../../library/argparse.rst:1155 +#: ../../library/argparse.rst:965 msgid "" "The argument to ``type`` can be any callable that accepts a single string. " "If the function raises :exc:`ArgumentTypeError`, :exc:`TypeError`, or :exc:" @@ -2064,12 +1639,12 @@ msgstr "" "出した場合は、parser がそれをキャッチして適切なエラーメッセージが表示されま" "す。それ以外の型の例外は処理されません。" -#: ../../library/argparse.rst:1160 +#: ../../library/argparse.rst:970 msgid "Common built-in types and functions can be used as type converters:" msgstr "" "一般的なビルトインデータ型や関数を ``type`` 引数の値として直接指定できます::" -#: ../../library/argparse.rst:1162 +#: ../../library/argparse.rst:972 msgid "" "import argparse\n" "import pathlib\n" @@ -2079,17 +1654,16 @@ msgid "" "parser.add_argument('distance', type=float)\n" "parser.add_argument('street', type=ascii)\n" "parser.add_argument('code_point', type=ord)\n" -"parser.add_argument('source_file', type=open)\n" "parser.add_argument('dest_file', type=argparse.FileType('w', " "encoding='latin-1'))\n" "parser.add_argument('datapath', type=pathlib.Path)" msgstr "" -#: ../../library/argparse.rst:1176 +#: ../../library/argparse.rst:985 msgid "User defined functions can be used as well:" msgstr "ユーザが定義した関数も使用できます::" -#: ../../library/argparse.rst:1178 +#: ../../library/argparse.rst:987 msgid "" ">>> def hyphenated(string):\n" "... return '-'.join([word[:4] for word in string.casefold().split()])\n" @@ -2100,7 +1674,7 @@ msgid "" "Namespace(short_title='\"the-tale-of-two-citi')" msgstr "" -#: ../../library/argparse.rst:1188 +#: ../../library/argparse.rst:997 msgid "" "The :func:`bool` function is not recommended as a type converter. All it " "does is convert empty strings to ``False`` and non-empty strings to " @@ -2111,7 +1685,7 @@ msgstr "" "これはおそらく望まれる動作ではないからです (訳注: 文字列 ``'false'`` を " "``False`` に変換してくれたりはしません)。" -#: ../../library/argparse.rst:1192 +#: ../../library/argparse.rst:1001 msgid "" "In general, the ``type`` keyword is a convenience that should only be used " "for simple conversions that can only raise one of the three supported " @@ -2123,7 +1697,7 @@ msgstr "" "ラー処理、またはリソース管理を伴うものは、引数を解析したあとに別個の処理とし" "て行うべきです。" -#: ../../library/argparse.rst:1197 +#: ../../library/argparse.rst:1006 msgid "" "For example, JSON or YAML conversions have complex error cases that require " "better reporting than can be given by the ``type`` keyword. A :exc:`~json." @@ -2135,21 +1709,17 @@ msgstr "" "発生しうる) :exc:`~json.JSONDecodeError` は適切に整形されて表示されません。ま" "た、:exc:`FileNotFoundError` が発生しても parser は何も処理しません。" -#: ../../library/argparse.rst:1202 +#: ../../library/argparse.rst:1011 msgid "" "Even :class:`~argparse.FileType` has its limitations for use with the " -"``type`` keyword. If one argument uses *FileType* and then a subsequent " -"argument fails, an error is reported but the file is not automatically " -"closed. In this case, it would be better to wait until after the parser has " -"run and then use the :keyword:`with`-statement to manage the files." +"``type`` keyword. If one argument uses :class:`~argparse.FileType` and then " +"a subsequent argument fails, an error is reported but the file is not " +"automatically closed. In this case, it would be better to wait until after " +"the parser has run and then use the :keyword:`with`-statement to manage the " +"files." msgstr "" -"また、``type`` キーワードに :class:`~argparse.FileType` を指定した場合には制" -"限があります。ある引数に *FileType* を指定してファイルが開かれ、その後ろのど" -"こかの引数で処理が失敗した場合、エラーが表示されますが、開かれたファイルは自" -"動では close されません。これを好まない場合は、parser による引数の処理が終わ" -"るまで待ち、その後に :keyword:`with` 文などでファイルを開くのがよいでしょう。" -#: ../../library/argparse.rst:1208 +#: ../../library/argparse.rst:1018 msgid "" "For type checkers that simply check against a fixed set of values, consider " "using the choices_ keyword instead." @@ -2157,11 +1727,11 @@ msgstr "" "なお、引数が、あらかじめ決められた値の候補のいずれかに一致するかをチェックし" "たいだけの場合には、代わりに choices_ キーワードの使用を検討してください。" -#: ../../library/argparse.rst:1215 +#: ../../library/argparse.rst:1025 msgid "choices" msgstr "choices" -#: ../../library/argparse.rst:1217 +#: ../../library/argparse.rst:1027 msgid "" "Some command-line arguments should be selected from a restricted set of " "values. These can be handled by passing a sequence object as the *choices* " @@ -2175,7 +1745,7 @@ msgstr "" "き、引数の値がチェックされ、その値が選択肢の中に含まれていない場合はエラー" "メッセージを表示します::" -#: ../../library/argparse.rst:1223 +#: ../../library/argparse.rst:1033 msgid "" ">>> parser = argparse.ArgumentParser(prog='game.py')\n" ">>> parser.add_argument('move', choices=['rock', 'paper', 'scissors'])\n" @@ -2187,28 +1757,14 @@ msgid "" "'paper', 'scissors')" msgstr "" -#: ../../library/argparse.rst:1232 +#: ../../library/argparse.rst:1042 msgid "" "Note that inclusion in the *choices* sequence is checked after any type_ " "conversions have been performed, so the type of the objects in the *choices* " -"sequence should match the type_ specified::" +"sequence should match the type_ specified." msgstr "" -"*choices* シーケンスに含まれているかどうかのチェックは、type_ による型変換が" -"実行された後であることに注意してください。このため、*choices* シーケンス中の" -"オブジェクトの型は指定された type_ にマッチしている必要があります::" -#: ../../library/argparse.rst:1236 -msgid "" -">>> parser = argparse.ArgumentParser(prog='doors.py')\n" -">>> parser.add_argument('door', type=int, choices=range(1, 4))\n" -">>> print(parser.parse_args(['3']))\n" -"Namespace(door=3)\n" -">>> parser.parse_args(['4'])\n" -"usage: doors.py [-h] {1,2,3}\n" -"doors.py: error: argument door: invalid choice: 4 (choose from 1, 2, 3)" -msgstr "" - -#: ../../library/argparse.rst:1244 +#: ../../library/argparse.rst:1046 msgid "" "Any sequence can be passed as the *choices* value, so :class:`list` " "objects, :class:`tuple` objects, and custom sequences are all supported." @@ -2217,7 +1773,7 @@ msgstr "" "ブジェクト、 :class:`tuple` オブジェクト、カスタムシーケンスはすべてサポート" "されています。" -#: ../../library/argparse.rst:1247 +#: ../../library/argparse.rst:1049 msgid "" "Use of :class:`enum.Enum` is not recommended because it is difficult to " "control its appearance in usage, help, and error messages." @@ -2225,7 +1781,7 @@ msgstr "" "ただし、:class:`enum.Enum` を渡すことは推奨されません。使用方法、ヘルプ、エ" "ラーメッセージなどでどのように表示されるかを制御することが難いからです。" -#: ../../library/argparse.rst:1250 +#: ../../library/argparse.rst:1052 msgid "" "Formatted choices override the default *metavar* which is normally derived " "from *dest*. This is usually what you want because the user never sees the " @@ -2238,11 +1794,11 @@ msgstr "" "しくない場合 (おそらく多くの選択肢がある場合など) は、 metavar_ を明示的に指" "定してください。" -#: ../../library/argparse.rst:1259 +#: ../../library/argparse.rst:1061 msgid "required" msgstr "required" -#: ../../library/argparse.rst:1261 +#: ../../library/argparse.rst:1063 msgid "" "In general, the :mod:`argparse` module assumes that flags like ``-f`` and " "``--bar`` indicate *optional* arguments, which can always be omitted at the " @@ -2254,7 +1810,7 @@ msgstr "" "て扱います。フラグの指定を *必須* にするには、:meth:`~ArgumentParser." "add_argument` の ``required=`` キーワード引数に ``True`` を指定します::" -#: ../../library/argparse.rst:1266 +#: ../../library/argparse.rst:1068 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', required=True)\n" @@ -2265,7 +1821,7 @@ msgid "" ": error: the following arguments are required: --foo" msgstr "" -#: ../../library/argparse.rst:1274 +#: ../../library/argparse.rst:1076 msgid "" "As the example shows, if an option is marked as ``required``, :meth:" "`~ArgumentParser.parse_args` will report an error if that option is not " @@ -2275,7 +1831,7 @@ msgstr "" "parse_args` はそのフラグがコマンドラインに存在しないときにエラーを表示しま" "す。" -#: ../../library/argparse.rst:1280 +#: ../../library/argparse.rst:1082 msgid "" "Required options are generally considered bad form because users expect " "*options* to be *optional*, and thus they should be avoided when possible." @@ -2283,40 +1839,19 @@ msgstr "" "ユーザーは、通常 *フラグ* の指定は *任意* であると認識しているため、必須にす" "るのは一般的には悪いやり方で、できる限り避けるべきです。" -#: ../../library/argparse.rst:1287 +#: ../../library/argparse.rst:1089 msgid "help" msgstr "help" -#: ../../library/argparse.rst:1289 +#: ../../library/argparse.rst:1091 msgid "" "The ``help`` value is a string containing a brief description of the " "argument. When a user requests help (usually by using ``-h`` or ``--help`` " "at the command line), these ``help`` descriptions will be displayed with " -"each argument::" -msgstr "" -"``help`` の値はその引数の簡潔な説明を含む文字列です。ユーザーが (コマンドライ" -"ン上で ``-h`` か ``--help`` を指定するなどして) ヘルプを要求したとき、この " -"``help`` の説明が各引数に表示されます::" - -#: ../../library/argparse.rst:1294 -msgid "" -">>> parser = argparse.ArgumentParser(prog='frobble')\n" -">>> parser.add_argument('--foo', action='store_true',\n" -"... help='foo the bars before frobbling')\n" -">>> parser.add_argument('bar', nargs='+',\n" -"... help='one of the bars to be frobbled')\n" -">>> parser.parse_args(['-h'])\n" -"usage: frobble [-h] [--foo] bar [bar ...]\n" -"\n" -"positional arguments:\n" -" bar one of the bars to be frobbled\n" -"\n" -"options:\n" -" -h, --help show this help message and exit\n" -" --foo foo the bars before frobbling" +"each argument." msgstr "" -#: ../../library/argparse.rst:1309 +#: ../../library/argparse.rst:1096 msgid "" "The ``help`` strings can include various format specifiers to avoid " "repetition of things like the program name or the argument default_. The " @@ -2329,7 +1864,7 @@ msgstr "" "プログラム名 ``%(prog)s`` と、 ``%(default)s`` や ``%(type)s`` など :meth:" "`~ArgumentParser.add_argument` のキーワード引数の多くが含まれます::" -#: ../../library/argparse.rst:1314 +#: ../../library/argparse.rst:1101 msgid "" ">>> parser = argparse.ArgumentParser(prog='frobble')\n" ">>> parser.add_argument('bar', nargs='?', type=int, default=42,\n" @@ -2344,7 +1879,7 @@ msgid "" " -h, --help show this help message and exit" msgstr "" -#: ../../library/argparse.rst:1326 +#: ../../library/argparse.rst:1113 msgid "" "As the help string supports %-formatting, if you want a literal ``%`` to " "appear in the help string, you must escape it as ``%%``." @@ -2352,7 +1887,7 @@ msgstr "" "ヘルプ文字列は %-フォーマットをサポートしているので、ヘルプ文字列内にリテラ" "ル ``%`` を表示したい場合は ``%%`` のようにエスケープしなければなりません。" -#: ../../library/argparse.rst:1329 +#: ../../library/argparse.rst:1116 msgid "" ":mod:`argparse` supports silencing the help entry for certain options, by " "setting the ``help`` value to ``argparse.SUPPRESS``::" @@ -2360,7 +1895,7 @@ msgstr "" ":mod:`argparse` は ``help`` に ``argparse.SUPPRESS`` を設定することで、特定の" "オプションをヘルプに表示させないことができます::" -#: ../../library/argparse.rst:1332 +#: ../../library/argparse.rst:1119 msgid "" ">>> parser = argparse.ArgumentParser(prog='frobble')\n" ">>> parser.add_argument('--foo', help=argparse.SUPPRESS)\n" @@ -2371,11 +1906,11 @@ msgid "" " -h, --help show this help message and exit" msgstr "" -#: ../../library/argparse.rst:1344 +#: ../../library/argparse.rst:1131 msgid "metavar" msgstr "metavar" -#: ../../library/argparse.rst:1346 +#: ../../library/argparse.rst:1133 msgid "" "When :class:`ArgumentParser` generates help messages, it needs some way to " "refer to each expected argument. By default, ArgumentParser objects use the " @@ -2394,7 +1929,7 @@ msgstr "" "として参照されます。 1つのオプション引数 ``--foo`` が1つのコマンドライン引数" "を要求するときは、その引数は ``FOO`` として参照されます。以下に例を示します::" -#: ../../library/argparse.rst:1355 +#: ../../library/argparse.rst:1142 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo')\n" @@ -2412,11 +1947,11 @@ msgid "" " --foo FOO" msgstr "" -#: ../../library/argparse.rst:1370 +#: ../../library/argparse.rst:1157 msgid "An alternative name can be specified with ``metavar``::" msgstr "代わりの名前を、``metavar`` として指定できます::" -#: ../../library/argparse.rst:1372 +#: ../../library/argparse.rst:1159 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', metavar='YYY')\n" @@ -2434,7 +1969,7 @@ msgid "" " --foo YYY" msgstr "" -#: ../../library/argparse.rst:1387 +#: ../../library/argparse.rst:1174 msgid "" "Note that ``metavar`` only changes the *displayed* name - the name of the " "attribute on the :meth:`~ArgumentParser.parse_args` object is still " @@ -2444,7 +1979,7 @@ msgstr "" "`~ArgumentParser.parse_args` の返すオブジェクトの属性名は dest_ の値のままで" "す。" -#: ../../library/argparse.rst:1391 +#: ../../library/argparse.rst:1178 msgid "" "Different values of ``nargs`` may cause the metavar to be used multiple " "times. Providing a tuple to ``metavar`` specifies a different display for " @@ -2453,7 +1988,7 @@ msgstr "" "``nargs`` を指定した場合、metavar が複数回利用されるかもしれません。" "``metavar`` にタプルを渡すと、各引数に対して異なる名前を指定できます::" -#: ../../library/argparse.rst:1395 +#: ../../library/argparse.rst:1182 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-x', nargs=2)\n" @@ -2467,11 +2002,11 @@ msgid "" " --foo bar baz" msgstr "" -#: ../../library/argparse.rst:1410 +#: ../../library/argparse.rst:1197 msgid "dest" msgstr "dest" -#: ../../library/argparse.rst:1412 +#: ../../library/argparse.rst:1199 msgid "" "Most :class:`ArgumentParser` actions add some value as an attribute of the " "object returned by :meth:`~ArgumentParser.parse_args`. The name of this " @@ -2486,7 +2021,7 @@ msgstr "" "決定されます。位置引数のアクションについては、 ``dest`` は通常 :meth:" "`~ArgumentParser.add_argument` の第一引数として渡します::" -#: ../../library/argparse.rst:1419 +#: ../../library/argparse.rst:1206 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('bar')\n" @@ -2494,7 +2029,7 @@ msgid "" "Namespace(bar='XXX')" msgstr "" -#: ../../library/argparse.rst:1424 +#: ../../library/argparse.rst:1211 msgid "" "For optional argument actions, the value of ``dest`` is normally inferred " "from the option strings. :class:`ArgumentParser` generates the value of " @@ -2513,7 +2048,7 @@ msgstr "" "な属性名になるように ``_`` 文字へ変換されます。次の例はこの動作を示していま" "す::" -#: ../../library/argparse.rst:1433 +#: ../../library/argparse.rst:1220 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('-f', '--foo-bar', '--foo')\n" @@ -2524,11 +2059,11 @@ msgid "" "Namespace(foo_bar='1', x='2')" msgstr "" -#: ../../library/argparse.rst:1441 +#: ../../library/argparse.rst:1228 msgid "``dest`` allows a custom attribute name to be provided::" msgstr "``dest`` にカスタムの属性名を与えることも可能です::" -#: ../../library/argparse.rst:1443 +#: ../../library/argparse.rst:1230 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', dest='bar')\n" @@ -2536,11 +2071,11 @@ msgid "" "Namespace(bar='XXX')" msgstr "" -#: ../../library/argparse.rst:1452 +#: ../../library/argparse.rst:1239 msgid "deprecated" msgstr "" -#: ../../library/argparse.rst:1454 +#: ../../library/argparse.rst:1241 msgid "" "During a project's lifetime, some arguments may need to be removed from the " "command line. Before removing them, you should inform your users that the " @@ -2551,7 +2086,7 @@ msgid "" "will be printed to :data:`sys.stderr` when the argument is used::" msgstr "" -#: ../../library/argparse.rst:1464 +#: ../../library/argparse.rst:1251 msgid "" ">>> import argparse\n" ">>> parser = argparse.ArgumentParser(prog='snake.py')\n" @@ -2563,11 +2098,11 @@ msgid "" "Namespace(legs=4)" msgstr "" -#: ../../library/argparse.rst:1477 +#: ../../library/argparse.rst:1264 msgid "Action classes" msgstr "Action クラス" -#: ../../library/argparse.rst:1479 +#: ../../library/argparse.rst:1266 msgid "" "Action classes implement the Action API, a callable which returns a callable " "which processes arguments from the command-line. Any object which follows " @@ -2579,7 +2114,7 @@ msgstr "" "あらゆるオブジェクトは ``action`` 引数として :meth:`~ArgumentParser." "add_argument` に渡すことができます。" -#: ../../library/argparse.rst:1488 +#: ../../library/argparse.rst:1275 msgid "" "Action objects are used by an ArgumentParser to represent the information " "needed to parse a single argument from one or more strings from the command " @@ -2593,7 +2128,7 @@ msgstr "" "`ArgumentParser.add_argument` に渡されるすべてのキーワード引数を受け付けなけ" "ればなりません。" -#: ../../library/argparse.rst:1494 +#: ../../library/argparse.rst:1281 msgid "" "Instances of Action (or return value of any callable to the ``action`` " "parameter) should have attributes \"dest\", \"option_strings\", \"default\", " @@ -2606,7 +2141,7 @@ msgstr "" "性を定義するのを確実にするためにもっとも簡単な方法は、``Action.__init__`` を" "呼び出すことです。" -#: ../../library/argparse.rst:1499 +#: ../../library/argparse.rst:1286 msgid "" "Action instances should be callable, so subclasses must override the " "``__call__`` method, which should accept four parameters:" @@ -2614,41 +2149,43 @@ msgstr "" "Action インスタンスは呼び出し可能でなければならず、したがって、サブクラスは " "4 つの引数を受け取る ``__call__`` メソッドをオーバライドしなければなりません:" -#: ../../library/argparse.rst:1502 -msgid "``parser`` - The ArgumentParser object which contains this action." -msgstr "``parser`` - このアクションを持っている ArgumentParser オブジェクト。" +#: ../../library/argparse.rst:1289 +msgid "*parser* - The ArgumentParser object which contains this action." +msgstr "" -#: ../../library/argparse.rst:1504 +#: ../../library/argparse.rst:1291 +msgid "*namespace* - The :class:`Namespace` object that will be returned by" +msgstr "" + +#: ../../library/argparse.rst:1292 msgid "" -"``namespace`` - The :class:`Namespace` object that will be returned by :meth:" -"`~ArgumentParser.parse_args`. Most actions add an attribute to this object " -"using :func:`setattr`." +":meth:`~ArgumentParser.parse_args`. Most actions add an attribute to this " +"object using :func:`setattr`." msgstr "" -"``namespace`` - :meth:`~ArgumentParser.parse_args` が返す :class:`Namespace` " -"オブジェクト。ほとんどのアクションはこのオブジェクトに属性を :func:`setattr` " -"を使って追加します。" -#: ../../library/argparse.rst:1508 +#: ../../library/argparse.rst:1295 +msgid "" +"*values* - The associated command-line arguments, with any type conversions" +msgstr "" + +#: ../../library/argparse.rst:1296 +msgid "" +"applied. Type conversions are specified with the type_ keyword argument to :" +"meth:`~ArgumentParser.add_argument`." +msgstr "" + +#: ../../library/argparse.rst:1299 msgid "" -"``values`` - The associated command-line arguments, with any type " -"conversions applied. Type conversions are specified with the type_ keyword " -"argument to :meth:`~ArgumentParser.add_argument`." +"*option_string* - The option string that was used to invoke this action." msgstr "" -"``values`` - 型変換が適用された後の、関連付けられたコマンドライン引数。型変換" -"は :meth:`~ArgumentParser.add_argument` メソッドの type_ キーワード引数で指定" -"されます。" -#: ../../library/argparse.rst:1512 +#: ../../library/argparse.rst:1300 msgid "" -"``option_string`` - The option string that was used to invoke this action. " "The ``option_string`` argument is optional, and will be absent if the action " "is associated with a positional argument." msgstr "" -"``option_string`` - このアクションを実行したオプション文字列。" -"``option_string`` 引数はオプションで、アクションが位置引数に関連付けられた場" -"合は渡されません。" -#: ../../library/argparse.rst:1516 +#: ../../library/argparse.rst:1303 msgid "" "The ``__call__`` method may perform arbitrary actions, but will typically " "set attributes on the ``namespace`` based on ``dest`` and ``values``." @@ -2656,7 +2193,7 @@ msgstr "" "``__call__`` メソッドでは任意のアクションを行えます。典型的には ``dest`` およ" "び ``values`` に基いて ``namespace`` に属性をセットします。" -#: ../../library/argparse.rst:1519 +#: ../../library/argparse.rst:1306 msgid "" "Action subclasses can define a ``format_usage`` method that takes no " "argument and return a string which will be used when printing the usage of " @@ -2668,11 +2205,11 @@ msgstr "" "は、sensible default (訳注: システムにより上手く設定されたデフォルト値) が使" "われます。" -#: ../../library/argparse.rst:1524 +#: ../../library/argparse.rst:1312 msgid "The parse_args() method" msgstr "parse_args() メソッド" -#: ../../library/argparse.rst:1528 +#: ../../library/argparse.rst:1316 msgid "" "Convert argument strings to objects and assign them as attributes of the " "namespace. Return the populated namespace." @@ -2680,7 +2217,7 @@ msgstr "" "引数の文字列をオブジェクトに変換し、namespace オブジェクトの属性に代入しま" "す。結果の namespace オブジェクトを返します。" -#: ../../library/argparse.rst:1531 +#: ../../library/argparse.rst:1319 msgid "" "Previous calls to :meth:`add_argument` determine exactly what objects are " "created and how they are assigned. See the documentation for :meth:" @@ -2690,7 +2227,7 @@ msgstr "" "されてどう代入されるかが決定されます。詳細は :meth:`add_argument` のドキュメ" "ントを参照してください。" -#: ../../library/argparse.rst:1535 +#: ../../library/argparse.rst:1323 msgid "" "args_ - List of strings to parse. The default is taken from :data:`sys." "argv`." @@ -2698,7 +2235,7 @@ msgstr "" "args_ - 解析する文字列のリスト。デフォルトでは :data:`sys.argv` から取得され" "ます。" -#: ../../library/argparse.rst:1538 +#: ../../library/argparse.rst:1326 msgid "" "namespace_ - An object to take the attributes. The default is a new empty :" "class:`Namespace` object." @@ -2706,11 +2243,11 @@ msgstr "" "namespace_ - 属性を代入するオブジェクト。デフォルトでは、新しい空の :class:" "`Namespace` オブジェクトです。" -#: ../../library/argparse.rst:1543 +#: ../../library/argparse.rst:1331 msgid "Option value syntax" msgstr "オプション値の文法" -#: ../../library/argparse.rst:1545 +#: ../../library/argparse.rst:1333 msgid "" "The :meth:`~ArgumentParser.parse_args` method supports several ways of " "specifying the value of an option (if it takes one). In the simplest case, " @@ -2720,7 +2257,7 @@ msgstr "" "オプションの値の指定に複数の方法をサポートしています。もっとも単純な場合に" "は、オプションとその値は次のように2つの別々の引数として渡されます::" -#: ../../library/argparse.rst:1549 +#: ../../library/argparse.rst:1337 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-x')\n" @@ -2731,7 +2268,7 @@ msgid "" "Namespace(foo='FOO', x=None)" msgstr "" -#: ../../library/argparse.rst:1557 +#: ../../library/argparse.rst:1345 msgid "" "For long options (options with names longer than a single character), the " "option and value can also be passed as a single command-line argument, using " @@ -2741,13 +2278,13 @@ msgstr "" "値は次のように ``=`` で区切られた1つのコマンドライン引数として渡すこともでき" "ます::" -#: ../../library/argparse.rst:1561 +#: ../../library/argparse.rst:1349 msgid "" ">>> parser.parse_args(['--foo=FOO'])\n" "Namespace(foo='FOO', x=None)" msgstr "" -#: ../../library/argparse.rst:1564 +#: ../../library/argparse.rst:1352 msgid "" "For short options (options only one character long), the option and its " "value can be concatenated::" @@ -2755,13 +2292,13 @@ msgstr "" "短いオプション (1文字のオプション) では、オプションとその値は次のように連結し" "て渡すことができます::" -#: ../../library/argparse.rst:1567 +#: ../../library/argparse.rst:1355 msgid "" ">>> parser.parse_args(['-xX'])\n" "Namespace(foo=None, x='X')" msgstr "" -#: ../../library/argparse.rst:1570 +#: ../../library/argparse.rst:1358 msgid "" "Several short options can be joined together, using only a single ``-`` " "prefix, as long as only the last option (or none of them) requires a value::" @@ -2770,7 +2307,7 @@ msgstr "" "い場合、複数の短いオプションは次のように1つの接頭辞 ``-`` だけで連結できま" "す::" -#: ../../library/argparse.rst:1573 +#: ../../library/argparse.rst:1361 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-x', action='store_true')\n" @@ -2780,11 +2317,11 @@ msgid "" "Namespace(x=True, y=True, z='Z')" msgstr "" -#: ../../library/argparse.rst:1582 +#: ../../library/argparse.rst:1370 msgid "Invalid arguments" msgstr "不正な引数" -#: ../../library/argparse.rst:1584 +#: ../../library/argparse.rst:1372 msgid "" "While parsing the command line, :meth:`~ArgumentParser.parse_args` checks " "for a variety of errors, including ambiguous options, invalid types, invalid " @@ -2796,7 +2333,7 @@ msgstr "" "ます。それらのエラーが発生した場合、エラーメッセージと使用法メッセージを表示" "して終了します::" -#: ../../library/argparse.rst:1589 +#: ../../library/argparse.rst:1377 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('--foo', type=int)\n" @@ -2818,11 +2355,11 @@ msgid "" "PROG: error: extra arguments found: badger" msgstr "" -#: ../../library/argparse.rst:1610 +#: ../../library/argparse.rst:1398 msgid "Arguments containing ``-``" msgstr "``-`` を含む引数" -#: ../../library/argparse.rst:1612 +#: ../../library/argparse.rst:1400 msgid "" "The :meth:`~ArgumentParser.parse_args` method attempts to give errors " "whenever the user has clearly made a mistake, but some situations are " @@ -2840,7 +2377,7 @@ msgstr "" "負の数として解釈でき、パーサーに負の数のように解釈できるオプションが存在しな" "い場合にのみ、``-`` で始まる位置引数になりえます::" -#: ../../library/argparse.rst:1620 +#: ../../library/argparse.rst:1408 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-x')\n" @@ -2873,7 +2410,7 @@ msgid "" "PROG: error: argument -1: expected one argument" msgstr "" -#: ../../library/argparse.rst:1650 +#: ../../library/argparse.rst:1438 msgid "" "If you have positional arguments that must begin with ``-`` and don't look " "like negative numbers, you can insert the pseudo-argument ``'--'`` which " @@ -2884,23 +2421,23 @@ msgstr "" "引数 ``'--'`` を挿入して、:meth:`~ArgumentParser.parse_args` にそれ以降のすべ" "てが位置引数だと教えることができます::" -#: ../../library/argparse.rst:1655 +#: ../../library/argparse.rst:1443 msgid "" ">>> parser.parse_args(['--', '-f'])\n" "Namespace(foo='-f', one=None)" msgstr "" -#: ../../library/argparse.rst:1658 +#: ../../library/argparse.rst:1446 msgid "" "See also :ref:`the argparse howto on ambiguous arguments ` for more details." msgstr "" -#: ../../library/argparse.rst:1664 +#: ../../library/argparse.rst:1452 msgid "Argument abbreviations (prefix matching)" msgstr "引数の短縮形 (先頭文字でのマッチング)" -#: ../../library/argparse.rst:1666 +#: ../../library/argparse.rst:1454 msgid "" "The :meth:`~ArgumentParser.parse_args` method :ref:`by default " "` allows long options to be abbreviated to a prefix, if the " @@ -2910,7 +2447,7 @@ msgstr "" "`、長いオプションに曖昧さがない (先頭文字列が一意である) かぎ" "り、先頭文字列に短縮して指定できます::" -#: ../../library/argparse.rst:1670 +#: ../../library/argparse.rst:1458 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('-bacon')\n" @@ -2924,7 +2461,7 @@ msgid "" "PROG: error: ambiguous option: -ba could match -badger, -bacon" msgstr "" -#: ../../library/argparse.rst:1681 +#: ../../library/argparse.rst:1469 msgid "" "An error is produced for arguments that could produce more than one options. " "This feature can be disabled by setting :ref:`allow_abbrev` to ``False``." @@ -2932,11 +2469,11 @@ msgstr "" "先頭の文字が同じ引数が複数ある場合に短縮指定を行うとエラーを発生させます。こ" "の機能は :ref:`allow_abbrev` に ``False`` を指定することで無効にできます。" -#: ../../library/argparse.rst:1687 +#: ../../library/argparse.rst:1475 msgid "Beyond ``sys.argv``" msgstr "``sys.argv`` 以外" -#: ../../library/argparse.rst:1689 +#: ../../library/argparse.rst:1477 msgid "" "Sometimes it may be useful to have an ArgumentParser parse arguments other " "than those of :data:`sys.argv`. This can be accomplished by passing a list " @@ -2947,7 +2484,7 @@ msgstr "" "ます。その場合は文字列のリストを :meth:`~ArgumentParser.parse_args` に渡しま" "す。これはインタラクティブプロンプトからテストするときに便利です::" -#: ../../library/argparse.rst:1694 +#: ../../library/argparse.rst:1482 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument(\n" @@ -2962,11 +2499,11 @@ msgid "" "Namespace(accumulate=, integers=[1, 2, 3, 4])" msgstr "" -#: ../../library/argparse.rst:1709 +#: ../../library/argparse.rst:1497 msgid "The Namespace object" msgstr "Namespace オブジェクト" -#: ../../library/argparse.rst:1713 +#: ../../library/argparse.rst:1501 msgid "" "Simple class used by default by :meth:`~ArgumentParser.parse_args` to create " "an object holding attributes and return it." @@ -2974,7 +2511,7 @@ msgstr "" ":meth:`~ArgumentParser.parse_args` が属性を格納して返すためのオブジェクトにデ" "フォルトで使用されるシンプルなクラスです。" -#: ../../library/argparse.rst:1716 +#: ../../library/argparse.rst:1504 msgid "" "This class is deliberately simple, just an :class:`object` subclass with a " "readable string representation. If you prefer to have dict-like view of the " @@ -2984,7 +2521,7 @@ msgstr "" "class:`object` のサブクラスです。もし属性を辞書のように扱える方が良ければ、標" "準的な Python のイディオム :func:`vars` を利用できます::" -#: ../../library/argparse.rst:1720 +#: ../../library/argparse.rst:1508 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo')\n" @@ -2993,7 +2530,7 @@ msgid "" "{'foo': 'BAR'}" msgstr "" -#: ../../library/argparse.rst:1726 +#: ../../library/argparse.rst:1514 msgid "" "It may also be useful to have an :class:`ArgumentParser` assign attributes " "to an already existing object, rather than a new :class:`Namespace` object. " @@ -3003,7 +2540,7 @@ msgstr "" "既存のオブジェクトに属性を設定する方が良い場合があります。これは " "``namespace=`` キーワード引数を指定することで可能です::" -#: ../../library/argparse.rst:1730 +#: ../../library/argparse.rst:1518 msgid "" ">>> class C:\n" "... pass\n" @@ -3016,86 +2553,66 @@ msgid "" "'BAR'" msgstr "" -#: ../../library/argparse.rst:1742 +#: ../../library/argparse.rst:1530 msgid "Other utilities" msgstr "その他のユーティリティ" -#: ../../library/argparse.rst:1745 +#: ../../library/argparse.rst:1533 msgid "Sub-commands" msgstr "サブコマンド" -#: ../../library/argparse.rst:1752 -msgid "" -"Many programs split up their functionality into a number of sub-commands, " -"for example, the ``svn`` program can invoke sub-commands like ``svn " -"checkout``, ``svn update``, and ``svn commit``. Splitting up functionality " -"this way can be a particularly good idea when a program performs several " -"different functions which require different kinds of command-line " -"arguments. :class:`ArgumentParser` supports the creation of such sub-" -"commands with the :meth:`add_subparsers` method. The :meth:`add_subparsers` " -"method is normally called with no arguments and returns a special action " -"object. This object has a single method, :meth:`~_SubParsersAction." -"add_parser`, which takes a command name and any :class:`ArgumentParser` " -"constructor arguments, and returns an :class:`ArgumentParser` object that " -"can be modified as usual." -msgstr "" -"多くのプログラムは、その機能をサブコマンドへと分割します。 例えば ``svn`` プ" -"ログラムは ``svn checkout``, ``svn update``, ``svn commit`` などのサブコマン" -"ドを利用できます。 機能をサブコマンドに分割するのは、プログラムがいくつかの異" -"なった機能を持っていて、 それぞれが異なるコマンドライン引数を必要とする場合に" -"は良いアイデアです。 :class:`ArgumentParser` は :meth:`add_subparsers` メソッ" -"ドによりサブコマンドを サポートしています。 :meth:`add_subparsers` メソッドは" -"通常引数なしに呼び出され、 特殊なアクションオブジェクトを返します。このオブ" -"ジェクトには1つのメソッド :meth:`~_SubParsersAction.add_parser` があり、コマ" -"ンド名と :class:`ArgumentParser` コンストラクターの任意の引数を受け取り、通常" -"の方法で操作できる :class:`ArgumentParser` オブジェクトを返します。" - -#: ../../library/argparse.rst:1764 +#: ../../library/argparse.rst:1540 +msgid "" +"Many programs split up their functionality into a number of subcommands, for " +"example, the ``svn`` program can invoke subcommands like ``svn checkout``, " +"``svn update``, and ``svn commit``. Splitting up functionality this way can " +"be a particularly good idea when a program performs several different " +"functions which require different kinds of command-line arguments. :class:" +"`ArgumentParser` supports the creation of such subcommands with the :meth:" +"`add_subparsers` method. The :meth:`add_subparsers` method is normally " +"called with no arguments and returns a special action object. This object " +"has a single method, :meth:`~_SubParsersAction.add_parser`, which takes a " +"command name and any :class:`ArgumentParser` constructor arguments, and " +"returns an :class:`ArgumentParser` object that can be modified as usual." +msgstr "" + +#: ../../library/argparse.rst:1552 msgid "Description of parameters:" msgstr "引数の説明:" -#: ../../library/argparse.rst:1766 +#: ../../library/argparse.rst:1554 msgid "" -"title - title for the sub-parser group in help output; by default " +"*title* - title for the sub-parser group in help output; by default " "\"subcommands\" if description is provided, otherwise uses title for " "positional arguments" msgstr "" -"title - ヘルプ出力でのサブパーサーグループのタイトルです。デフォルトは、" -"description が指定されている場合は \"subcommands\" に、指定されていない場合は" -"位置引数のタイトルになります" -#: ../../library/argparse.rst:1770 +#: ../../library/argparse.rst:1558 msgid "" -"description - description for the sub-parser group in help output, by " +"*description* - description for the sub-parser group in help output, by " "default ``None``" msgstr "" -"description - ヘルプ出力に表示されるサブパーサーグループの説明です。デフォル" -"トは ``None`` になります" -#: ../../library/argparse.rst:1773 +#: ../../library/argparse.rst:1561 msgid "" -"prog - usage information that will be displayed with sub-command help, by " +"*prog* - usage information that will be displayed with sub-command help, by " "default the name of the program and any positional arguments before the " "subparser argument" msgstr "" -"prog - サブコマンドのヘルプに表示される使用方法の説明です。デフォルトではプロ" -"グラム名と位置引数の後ろに、サブパーサーの引数が続きます" -#: ../../library/argparse.rst:1777 +#: ../../library/argparse.rst:1565 msgid "" -"parser_class - class which will be used to create sub-parser instances, by " +"*parser_class* - class which will be used to create sub-parser instances, by " "default the class of the current parser (e.g. ArgumentParser)" msgstr "" -"parser_class - サブパーサーのインスタンスを作成するときに使用されるクラスで" -"す。デフォルトでは現在のパーサーのクラス (例: ArgumentParser) になります" -#: ../../library/argparse.rst:1780 +#: ../../library/argparse.rst:1568 msgid "" "action_ - the basic type of action to be taken when this argument is " "encountered at the command line" msgstr "action_ - コマンドラインにこの引数があったときの基本のアクション。" -#: ../../library/argparse.rst:1783 +#: ../../library/argparse.rst:1571 msgid "" "dest_ - name of the attribute under which sub-command name will be stored; " "by default ``None`` and no value is stored" @@ -3103,7 +2620,7 @@ msgstr "" "dest_ - サブコマンド名を格納する属性の名前です。デフォルトは ``None`` で値は" "格納されません" -#: ../../library/argparse.rst:1786 +#: ../../library/argparse.rst:1574 msgid "" "required_ - Whether or not a subcommand must be provided, by default " "``False`` (added in 3.7)" @@ -3111,30 +2628,28 @@ msgstr "" "required_ - サブコマンドが必須であるかどうかを指定し、デフォルトは ``False`` " "です。(3.7 より追加)" -#: ../../library/argparse.rst:1789 +#: ../../library/argparse.rst:1577 msgid "help_ - help for sub-parser group in help output, by default ``None``" msgstr "" "help_ - ヘルプ出力に表示されるサブパーサーグループのヘルプです。デフォルトは " "``None`` です" -#: ../../library/argparse.rst:1791 +#: ../../library/argparse.rst:1579 msgid "" -"metavar_ - string presenting available sub-commands in help; by default it " -"is ``None`` and presents sub-commands in form {cmd1, cmd2, ..}" +"metavar_ - string presenting available subcommands in help; by default it is " +"``None`` and presents subcommands in form {cmd1, cmd2, ..}" msgstr "" -"metavar_ - 利用可能なサブコマンドをヘルプ内で表示するための文字列です。デフォ" -"ルトは ``None`` で、サブコマンドを {cmd1, cmd2, ..} のような形式で表します" -#: ../../library/argparse.rst:1794 +#: ../../library/argparse.rst:1582 msgid "Some example usage::" msgstr "いくつかの使用例::" -#: ../../library/argparse.rst:1796 +#: ../../library/argparse.rst:1584 msgid "" ">>> # create the top-level parser\n" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> parser.add_argument('--foo', action='store_true', help='foo help')\n" -">>> subparsers = parser.add_subparsers(help='sub-command help')\n" +">>> subparsers = parser.add_subparsers(help='subcommand help')\n" ">>>\n" ">>> # create the parser for the \"a\" command\n" ">>> parser_a = subparsers.add_parser('a', help='a help')\n" @@ -3142,7 +2657,8 @@ msgid "" ">>>\n" ">>> # create the parser for the \"b\" command\n" ">>> parser_b = subparsers.add_parser('b', help='b help')\n" -">>> parser_b.add_argument('--baz', choices='XYZ', help='baz help')\n" +">>> parser_b.add_argument('--baz', choices=('X', 'Y', 'Z'), help='baz " +"help')\n" ">>>\n" ">>> # parse some argument lists\n" ">>> parser.parse_args(['a', '12'])\n" @@ -3151,7 +2667,7 @@ msgid "" "Namespace(baz='Z', foo=True)" msgstr "" -#: ../../library/argparse.rst:1815 +#: ../../library/argparse.rst:1603 msgid "" "Note that the object returned by :meth:`parse_args` will only contain " "attributes for the main parser and the subparser that was selected by the " @@ -3166,7 +2682,7 @@ msgstr "" "では、``a`` コマンドが指定されたときは ``foo``, ``bar`` 属性だけが存在し、" "``b`` コマンドが指定されたときは ``foo``, ``baz`` 属性だけが存在しています。" -#: ../../library/argparse.rst:1822 +#: ../../library/argparse.rst:1610 msgid "" "Similarly, when a help message is requested from a subparser, only the help " "for that particular parser will be printed. The help message will not " @@ -3180,13 +2696,13 @@ msgstr "" "メッセージは、上の例にもあるように :meth:`~_SubParsersAction.add_parser` の " "``help=`` 引数によって指定できます)" -#: ../../library/argparse.rst:1830 +#: ../../library/argparse.rst:1618 msgid "" ">>> parser.parse_args(['--help'])\n" "usage: PROG [-h] [--foo] {a,b} ...\n" "\n" "positional arguments:\n" -" {a,b} sub-command help\n" +" {a,b} subcommand help\n" " a a help\n" " b b help\n" "\n" @@ -3211,7 +2727,7 @@ msgid "" " --baz {X,Y,Z} baz help" msgstr "" -#: ../../library/argparse.rst:1858 +#: ../../library/argparse.rst:1646 msgid "" "The :meth:`add_subparsers` method also supports ``title`` and " "``description`` keyword arguments. When either is present, the subparser's " @@ -3221,7 +2737,7 @@ msgstr "" "もサポートしています。どちらかが存在する場合、サブパーサーのコマンドはヘルプ" "出力でそれぞれのグループの中に表示されます。例えば::" -#: ../../library/argparse.rst:1862 +#: ../../library/argparse.rst:1650 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> subparsers = parser.add_subparsers(title='subcommands',\n" @@ -3241,7 +2757,7 @@ msgid "" " {foo,bar} additional help" msgstr "" -#: ../../library/argparse.rst:1879 +#: ../../library/argparse.rst:1667 msgid "" "Furthermore, :meth:`~_SubParsersAction.add_parser` supports an additional " "*aliases* argument, which allows multiple strings to refer to the same " @@ -3249,7 +2765,7 @@ msgid "" "``checkout``::" msgstr "" -#: ../../library/argparse.rst:1884 +#: ../../library/argparse.rst:1672 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> subparsers = parser.add_subparsers()\n" @@ -3259,26 +2775,23 @@ msgid "" "Namespace(foo='bar')" msgstr "" -#: ../../library/argparse.rst:1891 +#: ../../library/argparse.rst:1679 msgid "" ":meth:`~_SubParsersAction.add_parser` supports also an additional " "*deprecated* argument, which allows to deprecate the subparser." msgstr "" -#: ../../library/argparse.rst:1905 +#: ../../library/argparse.rst:1693 msgid "" -"One particularly effective way of handling sub-commands is to combine the " -"use of the :meth:`add_subparsers` method with calls to :meth:`set_defaults` " -"so that each subparser knows which Python function it should execute. For " +"One particularly effective way of handling subcommands is to combine the use " +"of the :meth:`add_subparsers` method with calls to :meth:`set_defaults` so " +"that each subparser knows which Python function it should execute. For " "example::" msgstr "" -"サブコマンドを扱う1つの便利な方法は :meth:`add_subparsers` メソッドと :meth:" -"`set_defaults` を組み合わせて、各サブパーサーにどの Python 関数を実行するかを" -"教えることです。例えば::" -#: ../../library/argparse.rst:1910 +#: ../../library/argparse.rst:1698 msgid "" -">>> # sub-command functions\n" +">>> # subcommand functions\n" ">>> def foo(args):\n" "... print(args.x * args.y)\n" "...\n" @@ -3311,7 +2824,7 @@ msgid "" "((XYZYX))" msgstr "" -#: ../../library/argparse.rst:1942 +#: ../../library/argparse.rst:1730 msgid "" "This way, you can let :meth:`parse_args` do the job of calling the " "appropriate function after argument parsing is complete. Associating " @@ -3326,7 +2839,7 @@ msgstr "" "ブパーサーの名前を確認する必要がある場合は、:meth:`add_subparsers` を呼び出す" "ときに ``dest`` キーワードを指定できます::" -#: ../../library/argparse.rst:1949 +#: ../../library/argparse.rst:1737 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> subparsers = parser.add_subparsers(dest='subparser_name')\n" @@ -3338,15 +2851,15 @@ msgid "" "Namespace(subparser_name='2', y='frobble')" msgstr "" -#: ../../library/argparse.rst:1958 +#: ../../library/argparse.rst:1746 msgid "New *required* keyword argument." msgstr "新しい *required* キーワード引数。" -#: ../../library/argparse.rst:1963 +#: ../../library/argparse.rst:1751 msgid "FileType objects" msgstr "FileType オブジェクト" -#: ../../library/argparse.rst:1967 +#: ../../library/argparse.rst:1755 msgid "" "The :class:`FileType` factory creates objects that can be passed to the type " "argument of :meth:`ArgumentParser.add_argument`. Arguments that have :class:" @@ -3360,7 +2873,7 @@ msgstr "" "ズ、エンコーディング、エラー処理でファイルとして開きます (詳細は :func:" "`open` 関数を参照してください。)::" -#: ../../library/argparse.rst:1973 +#: ../../library/argparse.rst:1761 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--raw', type=argparse.FileType('wb', 0))\n" @@ -3371,7 +2884,7 @@ msgid "" "raw=<_io.FileIO name='raw.dat' mode='wb'>)" msgstr "" -#: ../../library/argparse.rst:1979 +#: ../../library/argparse.rst:1767 msgid "" "FileType objects understand the pseudo-argument ``'-'`` and automatically " "convert this into :data:`sys.stdin` for readable :class:`FileType` objects " @@ -3381,7 +2894,7 @@ msgstr "" "`FileType` であれば :data:`sys.stdin` を、書き込み用の :class:`FileType` であ" "れば :data:`sys.stdout` に変換します::" -#: ../../library/argparse.rst:1983 +#: ../../library/argparse.rst:1771 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('infile', type=argparse.FileType('r'))\n" @@ -3389,15 +2902,15 @@ msgid "" "Namespace(infile=<_io.TextIOWrapper name='' encoding='UTF-8'>)" msgstr "" -#: ../../library/argparse.rst:1988 +#: ../../library/argparse.rst:1776 msgid "Added the *encodings* and *errors* parameters." msgstr "*encodings* と *errors* がパラメータに追加されました。" -#: ../../library/argparse.rst:1993 +#: ../../library/argparse.rst:1781 msgid "Argument groups" msgstr "引数グループ" -#: ../../library/argparse.rst:1997 +#: ../../library/argparse.rst:1785 msgid "" "By default, :class:`ArgumentParser` groups command-line arguments into " "\"positional arguments\" and \"options\" when displaying help messages. When " @@ -3410,7 +2923,7 @@ msgstr "" "デフォルトの動作よりも良い引数のグループ化方法がある場合、 :meth:" "`add_argument_group` メソッドで適切なグループを作成できます::" -#: ../../library/argparse.rst:2003 +#: ../../library/argparse.rst:1791 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', add_help=False)\n" ">>> group = parser.add_argument_group('group')\n" @@ -3424,7 +2937,7 @@ msgid "" " --foo FOO foo help" msgstr "" -#: ../../library/argparse.rst:2014 +#: ../../library/argparse.rst:1802 msgid "" "The :meth:`add_argument_group` method returns an argument group object which " "has an :meth:`~ArgumentParser.add_argument` method just like a regular :" @@ -3441,7 +2954,7 @@ msgstr "" "に表示します。 :meth:`add_argument_group` メソッドには、この表示をカスタマイ" "ズするための *title* と *description* 引数があります::" -#: ../../library/argparse.rst:2022 +#: ../../library/argparse.rst:1810 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG', add_help=False)\n" ">>> group1 = parser.add_argument_group('group1', 'group1 description')\n" @@ -3462,7 +2975,7 @@ msgid "" " --bar BAR bar help" msgstr "" -#: ../../library/argparse.rst:2040 +#: ../../library/argparse.rst:1828 msgid "" "Note that any arguments not in your user-defined groups will end up back in " "the usual \"positional arguments\" and \"optional arguments\" sections." @@ -3470,7 +2983,7 @@ msgstr "" "ユーザー定義グループにないすべての引数は通常の \"位置引数\" と \"オプション引" "数\" セクションに表示されます。" -#: ../../library/argparse.rst:2043 +#: ../../library/argparse.rst:1831 msgid "" "Calling :meth:`add_argument_group` on an argument group is deprecated. This " "feature was never supported and does not always work correctly. The function " @@ -3482,11 +2995,11 @@ msgstr "" "ん。この関数は継承を通じて思いがけず API に存在することになったもので、将来削" "除される予定です。" -#: ../../library/argparse.rst:2051 +#: ../../library/argparse.rst:1839 msgid "Mutual exclusion" msgstr "相互排他" -#: ../../library/argparse.rst:2055 +#: ../../library/argparse.rst:1843 msgid "" "Create a mutually exclusive group. :mod:`argparse` will make sure that only " "one of the arguments in the mutually exclusive group was present on the " @@ -3495,7 +3008,7 @@ msgstr "" "相互排他グループを作ります。:mod:`argparse` は相互排他グループの中でただ1つの" "引数のみが存在することを確認します::" -#: ../../library/argparse.rst:2059 +#: ../../library/argparse.rst:1847 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> group = parser.add_mutually_exclusive_group()\n" @@ -3510,7 +3023,7 @@ msgid "" "PROG: error: argument --bar: not allowed with argument --foo" msgstr "" -#: ../../library/argparse.rst:2071 +#: ../../library/argparse.rst:1859 msgid "" "The :meth:`add_mutually_exclusive_group` method also accepts a *required* " "argument, to indicate that at least one of the mutually exclusive arguments " @@ -3519,7 +3032,7 @@ msgstr "" ":meth:`add_mutually_exclusive_group` メソッドの引数 *required* に True 値を指" "定すると、その相互排他引数のどれか1つを選ぶことが要求されます::" -#: ../../library/argparse.rst:2075 +#: ../../library/argparse.rst:1863 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> group = parser.add_mutually_exclusive_group(required=True)\n" @@ -3530,7 +3043,7 @@ msgid "" "PROG: error: one of the arguments --foo --bar is required" msgstr "" -#: ../../library/argparse.rst:2083 +#: ../../library/argparse.rst:1871 msgid "" "Note that currently mutually exclusive argument groups do not support the " "*title* and *description* arguments of :meth:`~ArgumentParser." @@ -3538,7 +3051,7 @@ msgid "" "argument group that has a title and description. For example::" msgstr "" -#: ../../library/argparse.rst:2089 +#: ../../library/argparse.rst:1877 msgid "" ">>> parser = argparse.ArgumentParser(prog='PROG')\n" ">>> group = parser.add_argument_group('Group title', 'Group description')\n" @@ -3558,7 +3071,7 @@ msgid "" " --bar BAR bar help" msgstr "" -#: ../../library/argparse.rst:2106 +#: ../../library/argparse.rst:1894 msgid "" "Calling :meth:`add_argument_group` or :meth:`add_mutually_exclusive_group` " "on a mutually exclusive group is deprecated. These features were never " @@ -3571,11 +3084,11 @@ msgstr "" "の関数は継承により偶然 API に存在することになったもので、将来削除される予定で" "す。" -#: ../../library/argparse.rst:2114 +#: ../../library/argparse.rst:1902 msgid "Parser defaults" msgstr "パーサーのデフォルト値" -#: ../../library/argparse.rst:2118 +#: ../../library/argparse.rst:1906 msgid "" "Most of the time, the attributes of the object returned by :meth:" "`parse_args` will be fully determined by inspecting the command-line " @@ -3588,7 +3101,7 @@ msgstr "" "を使うと与えられたコマンドライン引数の内容によらず追加の属性を決定することが" "可能です::" -#: ../../library/argparse.rst:2124 +#: ../../library/argparse.rst:1912 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('foo', type=int)\n" @@ -3597,13 +3110,13 @@ msgid "" "Namespace(bar=42, baz='badger', foo=736)" msgstr "" -#: ../../library/argparse.rst:2130 +#: ../../library/argparse.rst:1918 msgid "" "Note that parser-level defaults always override argument-level defaults::" msgstr "" "パーサーレベルのデフォルト値は常に引数レベルのデフォルト値を上書きします::" -#: ../../library/argparse.rst:2132 +#: ../../library/argparse.rst:1920 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', default='bar')\n" @@ -3612,7 +3125,7 @@ msgid "" "Namespace(foo='spam')" msgstr "" -#: ../../library/argparse.rst:2138 +#: ../../library/argparse.rst:1926 msgid "" "Parser-level defaults can be particularly useful when working with multiple " "parsers. See the :meth:`~ArgumentParser.add_subparsers` method for an " @@ -3622,7 +3135,7 @@ msgstr "" "プの例については :meth:`~ArgumentParser.add_subparsers` メソッドを参照してく" "ださい。" -#: ../../library/argparse.rst:2144 +#: ../../library/argparse.rst:1932 msgid "" "Get the default value for a namespace attribute, as set by either :meth:" "`~ArgumentParser.add_argument` or by :meth:`~ArgumentParser.set_defaults`::" @@ -3630,7 +3143,7 @@ msgstr "" ":meth:`~ArgumentParser.add_argument` か :meth:`~ArgumentParser.set_defaults` " "によって指定された、 namespace の属性のデフォルト値を取得します::" -#: ../../library/argparse.rst:2148 +#: ../../library/argparse.rst:1936 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', default='badger')\n" @@ -3638,11 +3151,11 @@ msgid "" "'badger'" msgstr "" -#: ../../library/argparse.rst:2155 +#: ../../library/argparse.rst:1943 msgid "Printing help" msgstr "ヘルプの表示" -#: ../../library/argparse.rst:2157 +#: ../../library/argparse.rst:1945 msgid "" "In most typical applications, :meth:`~ArgumentParser.parse_args` will take " "care of formatting and printing any usage or error messages. However, " @@ -3652,7 +3165,7 @@ msgstr "" "使用法やエラーメッセージのフォーマットと表示について面倒を見ます。しかし、い" "くつかのフォーマットメソッドが利用できます:" -#: ../../library/argparse.rst:2163 +#: ../../library/argparse.rst:1951 msgid "" "Print a brief description of how the :class:`ArgumentParser` should be " "invoked on the command line. If *file* is ``None``, :data:`sys.stdout` is " @@ -3661,7 +3174,7 @@ msgstr "" ":class:`ArgumentParser` がコマンドラインからどう実行されるべきかの短い説明を" "表示します。 *file* が ``None`` の時は、 :data:`sys.stdout` に出力されます。" -#: ../../library/argparse.rst:2169 +#: ../../library/argparse.rst:1957 msgid "" "Print a help message, including the program usage and information about the " "arguments registered with the :class:`ArgumentParser`. If *file* is " @@ -3671,7 +3184,7 @@ msgstr "" "含むヘルプメッセージを表示します。 *file* が ``None`` の時は、 :data:`sys." "stdout` に出力されます。" -#: ../../library/argparse.rst:2173 +#: ../../library/argparse.rst:1961 msgid "" "There are also variants of these methods that simply return a string instead " "of printing it:" @@ -3679,7 +3192,7 @@ msgstr "" "これらのメソッドの、表示する代わりにシンプルに文字列を返すバージョンもありま" "す:" -#: ../../library/argparse.rst:2178 +#: ../../library/argparse.rst:1966 msgid "" "Return a string containing a brief description of how the :class:" "`ArgumentParser` should be invoked on the command line." @@ -3687,7 +3200,7 @@ msgstr "" ":class:`ArgumentParser` がコマンドラインからどう実行されるべきかの短い説明を" "格納した文字列を返します。" -#: ../../library/argparse.rst:2183 +#: ../../library/argparse.rst:1971 msgid "" "Return a string containing a help message, including the program usage and " "information about the arguments registered with the :class:`ArgumentParser`." @@ -3695,11 +3208,11 @@ msgstr "" "プログラムの使用法と :class:`ArgumentParser` に登録された引数についての情報を" "含むヘルプメッセージを格納した文字列を返します。" -#: ../../library/argparse.rst:2188 +#: ../../library/argparse.rst:1976 msgid "Partial parsing" msgstr "部分解析" -#: ../../library/argparse.rst:2192 +#: ../../library/argparse.rst:1980 msgid "" "Sometimes a script may only parse a few of the command-line arguments, " "passing the remaining arguments on to another script or program. In these " @@ -3716,7 +3229,7 @@ msgstr "" "エラーを生成しません。代わりに、評価された namespace オブジェクトと、残りの引" "数文字列のリストからなる2要素タプルを返します。" -#: ../../library/argparse.rst:2201 +#: ../../library/argparse.rst:1989 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo', action='store_true')\n" @@ -3725,7 +3238,7 @@ msgid "" "(Namespace(bar='BAR', foo=True), ['--badger', 'spam'])" msgstr "" -#: ../../library/argparse.rst:2208 +#: ../../library/argparse.rst:1996 msgid "" ":ref:`Prefix matching ` rules apply to :meth:" "`~ArgumentParser.parse_known_args`. The parser may consume an option even if " @@ -3737,11 +3250,11 @@ msgstr "" "先頭文字に過ぎない場合でも、パーサは引数リストに残さずに、オプションを受け取" "る場合があります。" -#: ../../library/argparse.rst:2215 +#: ../../library/argparse.rst:2003 msgid "Customizing file parsing" msgstr "ファイル解析のカスタマイズ" -#: ../../library/argparse.rst:2219 +#: ../../library/argparse.rst:2007 msgid "" "Arguments that are read from a file (see the *fromfile_prefix_chars* keyword " "argument to the :class:`ArgumentParser` constructor) are read one argument " @@ -3753,7 +3266,7 @@ msgstr "" "す。 :meth:`convert_arg_line_to_args` を変更することでこの動作をカスタマイズ" "できます。" -#: ../../library/argparse.rst:2224 +#: ../../library/argparse.rst:2012 msgid "" "This method takes a single argument *arg_line* which is a string read from " "the argument file. It returns a list of arguments parsed from this string. " @@ -3763,7 +3276,7 @@ msgstr "" "け取ります。そしてその文字列を解析した結果の引数のリストを返します。このメ" "ソッドはファイルから1行読みこむごとに、順番に呼ばれます。" -#: ../../library/argparse.rst:2228 +#: ../../library/argparse.rst:2016 msgid "" "A useful override of this method is one that treats each space-separated " "word as an argument. The following example demonstrates how to do this::" @@ -3771,25 +3284,25 @@ msgstr "" "このメソッドをオーバーライドすると便利なこととして、スペースで区切られた行の" "単語1つ1つを別々の引数として扱えます。次の例でその方法を示します::" -#: ../../library/argparse.rst:2231 +#: ../../library/argparse.rst:2019 msgid "" "class MyArgumentParser(argparse.ArgumentParser):\n" " def convert_arg_line_to_args(self, arg_line):\n" " return arg_line.split()" msgstr "" -#: ../../library/argparse.rst:2237 +#: ../../library/argparse.rst:2025 msgid "Exiting methods" msgstr "終了メソッド" -#: ../../library/argparse.rst:2241 +#: ../../library/argparse.rst:2029 msgid "" "This method terminates the program, exiting with the specified *status* and, " "if given, it prints a *message* to :data:`sys.stderr` before that. The user " "can override this method to handle these steps differently::" msgstr "" -#: ../../library/argparse.rst:2245 +#: ../../library/argparse.rst:2033 msgid "" "class ErrorCatchingArgumentParser(argparse.ArgumentParser):\n" " def exit(self, status=0, message=None):\n" @@ -3798,17 +3311,17 @@ msgid "" " exit(status)" msgstr "" -#: ../../library/argparse.rst:2253 +#: ../../library/argparse.rst:2041 msgid "" "This method prints a usage message, including the *message*, to :data:`sys." "stderr` and terminates the program with a status code of 2." msgstr "" -#: ../../library/argparse.rst:2258 +#: ../../library/argparse.rst:2046 msgid "Intermixed parsing" msgstr "混在した引数の解析" -#: ../../library/argparse.rst:2263 +#: ../../library/argparse.rst:2051 msgid "" "A number of Unix commands allow the user to intermix optional arguments with " "positional arguments. The :meth:`~ArgumentParser.parse_intermixed_args` " @@ -3820,7 +3333,7 @@ msgstr "" "parse_known_intermixed_args` メソッドは、このような方法での解析をサポートして" "います。" -#: ../../library/argparse.rst:2268 +#: ../../library/argparse.rst:2056 msgid "" "These parsers do not support all the argparse features, and will raise " "exceptions if unsupported features are used. In particular, subparsers, and " @@ -3831,7 +3344,7 @@ msgstr "" "使われた場合、例外を送出します。特に、サブパーサーや、位置引数とオプション引" "数を両方含むような相互排他的なグループは、サポートされていません。" -#: ../../library/argparse.rst:2273 +#: ../../library/argparse.rst:2061 msgid "" "The following example shows the difference between :meth:`~ArgumentParser." "parse_known_args` and :meth:`~ArgumentParser.parse_intermixed_args`: the " @@ -3842,7 +3355,7 @@ msgstr "" "parse_intermixed_args` の違いを表しています: 前者は ``['2', '3']`` を、解析さ" "れない引数として返し、後者は全ての位置引数を ``rest`` に入れて返しています::" -#: ../../library/argparse.rst:2279 +#: ../../library/argparse.rst:2067 msgid "" ">>> parser = argparse.ArgumentParser()\n" ">>> parser.add_argument('--foo')\n" @@ -3854,7 +3367,7 @@ msgid "" "Namespace(cmd='doit', foo='bar', rest=[1, 2, 3])" msgstr "" -#: ../../library/argparse.rst:2288 +#: ../../library/argparse.rst:2076 msgid "" ":meth:`~ArgumentParser.parse_known_intermixed_args` returns a two item tuple " "containing the populated namespace and the list of remaining argument " @@ -3866,149 +3379,15 @@ msgstr "" ":meth:`~ArgumentParser.parse_intermixed_args` は、解析されない引数が残された" "場合にはエラーを送出します。" -#: ../../library/argparse.rst:2298 -msgid "Upgrading optparse code" -msgstr "optparse からのアップグレード" - -#: ../../library/argparse.rst:2300 -msgid "" -"Originally, the :mod:`argparse` module had attempted to maintain " -"compatibility with :mod:`optparse`. However, :mod:`optparse` was difficult " -"to extend transparently, particularly with the changes required to support " -"the new ``nargs=`` specifiers and better usage messages. When most " -"everything in :mod:`optparse` had either been copy-pasted over or monkey-" -"patched, it no longer seemed practical to try to maintain the backwards " -"compatibility." -msgstr "" -"もともと、:mod:`argparse` モジュールは :mod:`optparse` モジュールとの互換性を" -"保って開発しようと試みられました。しかし、特に新しい ``nargs=`` 指定子とより" -"良い使用法メッセージのために必要な変更のために、:mod:`optparse` を透過的に拡" -"張することは難しかったのです。:mod:`optparse` のほとんどすべてがコピーアンド" -"ペーストされたりモンキーパッチを当てられたりしたとき、もはや後方互換性を保と" -"うとすることは現実的ではありませんでした。" - -#: ../../library/argparse.rst:2307 -msgid "" -"The :mod:`argparse` module improves on the standard library :mod:`optparse` " -"module in a number of ways including:" -msgstr "" -":mod:`argparse` モジュールは標準ライブラリ :mod:`optparse` モジュールを、以下" -"を含むたくさんの方法で改善しています:" - -#: ../../library/argparse.rst:2310 -msgid "Handling positional arguments." -msgstr "位置引数を扱う" - -#: ../../library/argparse.rst:2311 -msgid "Supporting sub-commands." -msgstr "サブコマンドのサポート" - -#: ../../library/argparse.rst:2312 -msgid "Allowing alternative option prefixes like ``+`` and ``/``." -msgstr "``+``, ``/`` のような代替オプションプレフィクスを許容する" - -#: ../../library/argparse.rst:2313 -msgid "Handling zero-or-more and one-or-more style arguments." -msgstr "zero-or-more スタイル、one-or-more スタイルの引数を扱う" - -#: ../../library/argparse.rst:2314 -msgid "Producing more informative usage messages." -msgstr "より有益な使用方法メッセージの生成" - -#: ../../library/argparse.rst:2315 -msgid "Providing a much simpler interface for custom ``type`` and ``action``." -msgstr "" -"カスタム ``type``, カスタム ``action`` のために遥かに簡単なインターフェイスを" -"提供する" - -#: ../../library/argparse.rst:2317 -msgid "A partial upgrade path from :mod:`optparse` to :mod:`argparse`:" -msgstr ":mod:`optparse` から :mod:`argparse` への現実的なアップグレードパス:" - -#: ../../library/argparse.rst:2319 -msgid "" -"Replace all :meth:`optparse.OptionParser.add_option` calls with :meth:" -"`ArgumentParser.add_argument` calls." -msgstr "" -"すべての :meth:`optparse.OptionParser.add_option` の呼び出しを、:meth:" -"`ArgumentParser.add_argument` の呼び出しに置き換える。" - -#: ../../library/argparse.rst:2322 -msgid "" -"Replace ``(options, args) = parser.parse_args()`` with ``args = parser." -"parse_args()`` and add additional :meth:`ArgumentParser.add_argument` calls " -"for the positional arguments. Keep in mind that what was previously called " -"``options``, now in the :mod:`argparse` context is called ``args``." -msgstr "" -"``(options, args) = parser.parse_args()`` を ``args = parser.parse_args()`` " -"に置き換え、位置引数のために必要に応じて :meth:`ArgumentParser.add_argument` " -"の呼び出しを追加する。これまで ``options`` と呼ばれていたものが、:mod:" -"`argparse` では ``args`` と呼ばれていることに留意してください。" - -#: ../../library/argparse.rst:2327 -msgid "" -"Replace :meth:`optparse.OptionParser.disable_interspersed_args` by using :" -"meth:`~ArgumentParser.parse_intermixed_args` instead of :meth:" -"`~ArgumentParser.parse_args`." -msgstr "" -":meth:`optparse.OptionParser.disable_interspersed_args` を、:meth:" -"`~ArgumentParser.parse_args` ではなく :meth:`~ArgumentParser." -"parse_intermixed_args` で置き換える。" - -#: ../../library/argparse.rst:2331 -msgid "" -"Replace callback actions and the ``callback_*`` keyword arguments with " -"``type`` or ``action`` arguments." -msgstr "" -"コールバック・アクションと ``callback_*`` キーワード引数を ``type`` や " -"``action`` 引数に置き換える。" - -#: ../../library/argparse.rst:2334 -msgid "" -"Replace string names for ``type`` keyword arguments with the corresponding " -"type objects (e.g. int, float, complex, etc)." -msgstr "" -"``type`` キーワード引数に渡していた文字列の名前を、それに応じたオブジェクト " -"(例: int, float, complex, ...) に置き換える。" - -#: ../../library/argparse.rst:2337 -msgid "" -"Replace :class:`optparse.Values` with :class:`Namespace` and :exc:`optparse." -"OptionError` and :exc:`optparse.OptionValueError` with :exc:`ArgumentError`." -msgstr "" -":class:`optparse.Values` を :class:`Namespace` に置き換え、:exc:`optparse." -"OptionError` と :exc:`optparse.OptionValueError` を :exc:`ArgumentError` に置" -"き換える。" - -#: ../../library/argparse.rst:2341 -msgid "" -"Replace strings with implicit arguments such as ``%default`` or ``%prog`` " -"with the standard Python syntax to use dictionaries to format strings, that " -"is, ``%(default)s`` and ``%(prog)s``." -msgstr "" -"``%default`` や ``%prog`` などの暗黙の引数を含む文字列を、``%(default)s`` や " -"``%(prog)s`` などの、通常の Python で辞書を使う場合のフォーマット文字列に置き" -"換える。" - -#: ../../library/argparse.rst:2345 -msgid "" -"Replace the OptionParser constructor ``version`` argument with a call to " -"``parser.add_argument('--version', action='version', version='')``." -msgstr "" -"OptionParser のコンストラクターの ``version`` 引数を、``parser." -"add_argument('--version', action='version', version='')`` に置き" -"換える" - -#: ../../library/argparse.rst:2349 +#: ../../library/argparse.rst:2085 msgid "Exceptions" msgstr "例外" -#: ../../library/argparse.rst:2353 +#: ../../library/argparse.rst:2089 msgid "An error from creating or using an argument (optional or positional)." msgstr "引数 (オプション引数または位置引数) の生成時または利用時のエラーです。" -#: ../../library/argparse.rst:2355 +#: ../../library/argparse.rst:2091 msgid "" "The string value of this exception is the message, augmented with " "information about the argument that caused it." @@ -4016,26 +3395,30 @@ msgstr "" "この例外の文字列表現は、エラーの原因となった引数についての情報を補足するメッ" "セージです。" -#: ../../library/argparse.rst:2360 +#: ../../library/argparse.rst:2096 msgid "" "Raised when something goes wrong converting a command line string to a type." msgstr "" "コマンドラインの文字列を、指定された型に変換するのに失敗した時に送出されま" "す。" -#: ../../library/argparse.rst:983 +#: ../../library/argparse.rst:2100 +msgid "Guides and Tutorials" +msgstr "ガイドとチュートリアル" + +#: ../../library/argparse.rst:793 msgid "? (question mark)" msgstr "? (クエスチョンマーク)" -#: ../../library/argparse.rst:983 ../../library/argparse.rst:1017 -#: ../../library/argparse.rst:1031 +#: ../../library/argparse.rst:793 ../../library/argparse.rst:827 +#: ../../library/argparse.rst:841 msgid "in argparse module" msgstr "argparse モジュール内" -#: ../../library/argparse.rst:1017 +#: ../../library/argparse.rst:827 msgid "* (asterisk)" msgstr "* (アスタリスク)" -#: ../../library/argparse.rst:1031 +#: ../../library/argparse.rst:841 msgid "+ (plus)" msgstr "+ (プラス記号)" diff --git a/library/ast.po b/library/ast.po index 5a32f2e28..9d0d760a5 100644 --- a/library/ast.po +++ b/library/ast.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:54+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -1323,7 +1323,7 @@ msgid "" "(indicating a \"simple\" target). A \"simple\" target consists solely of a :" "class:`Name` node that does not appear between parentheses; all other " "targets are considered complex. Only simple targets appear in the :attr:" -"`__annotations__` dictionary of modules and classes." +"`~object.__annotations__` dictionary of modules and classes." msgstr "" #: ../../library/ast.rst:902 diff --git a/library/asyncio-eventloop.po b/library/asyncio-eventloop.po index 62cd42c62..c52fc8920 100644 --- a/library/asyncio-eventloop.po +++ b/library/asyncio-eventloop.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:54+0000\n" "Last-Translator: souma987, 2023\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -1093,8 +1093,10 @@ msgstr "" #: ../../library/asyncio-eventloop.rst:652 #: ../../library/asyncio-eventloop.rst:806 #: ../../library/asyncio-eventloop.rst:1249 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +#: ../../library/asyncio-eventloop.rst:1782 +#: ../../library/asyncio-eventloop.rst:1789 +msgid "Availability" +msgstr "" #: ../../library/asyncio-eventloop.rst:654 msgid "" @@ -2712,20 +2714,12 @@ msgid "" "asyncio.set_event_loop_policy(MyPolicy())" msgstr "" -#: ../../library/asyncio-eventloop.rst:1782 -msgid ":ref:`Availability `: Unix, Windows." -msgstr ":ref:`Availability `: Unix, Windows。" - #: ../../library/asyncio-eventloop.rst:1787 msgid "" "A subclass of :class:`AbstractEventLoop` for Windows that uses \"I/O " "Completion Ports\" (IOCP)." msgstr "" -#: ../../library/asyncio-eventloop.rst:1789 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" - #: ../../library/asyncio-eventloop.rst:1793 msgid "" "`MSDN documentation on I/O Completion Ports `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +msgid "Availability" +msgstr "" #: ../../library/asyncio-policy.rst:136 msgid "" diff --git a/library/asyncio-stream.po b/library/asyncio-stream.po index 5553791cf..1119066d9 100644 --- a/library/asyncio-stream.po +++ b/library/asyncio-stream.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:55+0000\n" "Last-Translator: Rafael Fontenelle , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -206,8 +206,8 @@ msgid "See also the documentation of :meth:`loop.create_unix_connection`." msgstr ":meth:`loop.create_unix_connection` のドキュメントも参照してください。" #: ../../library/asyncio-stream.rst:151 ../../library/asyncio-stream.rst:181 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +msgid "Availability" +msgstr "" #: ../../library/asyncio-stream.rst:153 msgid "" diff --git a/library/asyncio.po b/library/asyncio.po index 3cbd840f5..450aa263c 100644 --- a/library/asyncio.po +++ b/library/asyncio.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:55+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -146,8 +146,8 @@ msgstr "" "し `" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/codecs.po b/library/codecs.po index ae8ec8a8e..f8f7757ea 100644 --- a/library/codecs.po +++ b/library/codecs.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:56+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -3183,8 +3183,8 @@ msgid "This module implements the ANSI codepage (CP_ACP)." msgstr "" #: ../../library/codecs.rst:1542 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +msgid "Availability" +msgstr "" #: ../../library/codecs.rst:1544 msgid "" diff --git a/library/compileall.po b/library/compileall.po index d08fa4ac9..1cdf5e44a 100644 --- a/library/compileall.po +++ b/library/compileall.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:57+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -48,8 +48,8 @@ msgstr "" "み権限をもたないユーザでも、これらを利用できるようになります。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/concurrent.futures.po b/library/concurrent.futures.po index bb9f86372..772d7645e 100644 --- a/library/concurrent.futures.po +++ b/library/concurrent.futures.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:57+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -61,8 +61,8 @@ msgstr "" "を実装します。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/configparser.po b/library/configparser.po index c58ed45fd..3217e52cb 100644 --- a/library/configparser.po +++ b/library/configparser.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 00:57+0000\n" "Last-Translator: Takeshi Nakazato, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -91,15 +91,15 @@ msgid "" "sometimes used for configuration, but does not support comments." msgstr "" -#: ../../library/configparser.rst:60 +#: ../../library/configparser.rst:61 msgid "Quick Start" msgstr "クイックスタート" -#: ../../library/configparser.rst:62 +#: ../../library/configparser.rst:63 msgid "Let's take a very basic configuration file that looks like this:" msgstr "次のような、非常に簡単な設定ファイルを例に考えましょう:" -#: ../../library/configparser.rst:64 +#: ../../library/configparser.rst:65 msgid "" "[DEFAULT]\n" "ServerAliveInterval = 45\n" @@ -115,7 +115,7 @@ msgid "" "ForwardX11 = no" msgstr "" -#: ../../library/configparser.rst:79 +#: ../../library/configparser.rst:80 msgid "" "The structure of INI files is described `in the following section " "<#supported-ini-file-structure>`_. Essentially, the file consists of " @@ -130,7 +130,7 @@ msgstr "" ":mod:`configparser` のクラス群はそれらのファイルを読み書きできます。\n" "まずは上のような設定ファイルをプログラムから作成してみましょう。" -#: ../../library/configparser.rst:85 +#: ../../library/configparser.rst:86 msgid "" ">>> import configparser\n" ">>> config = configparser.ConfigParser()\n" @@ -149,7 +149,7 @@ msgid "" "..." msgstr "" -#: ../../library/configparser.rst:103 +#: ../../library/configparser.rst:104 msgid "" "As you can see, we can treat a config parser much like a dictionary. There " "are differences, `outlined later <#mapping-protocol-access>`_, but the " @@ -159,7 +159,7 @@ msgstr "" "の違いは `後に <#mapping-protocol-access>`_ 説明しますが、このインターフェイ" "スは辞書に対して期待するのととても近い動作をします。" -#: ../../library/configparser.rst:107 +#: ../../library/configparser.rst:108 msgid "" "Now that we have created and saved a configuration file, let's read it back " "and explore the data it holds." @@ -167,7 +167,7 @@ msgstr "" "これで設定ファイルを作成して保存できました。次はこれを読み込み直して、中の" "データを取り出してみましょう。" -#: ../../library/configparser.rst:110 +#: ../../library/configparser.rst:111 msgid "" ">>> config = configparser.ConfigParser()\n" ">>> config.sections()\n" @@ -200,7 +200,7 @@ msgid "" "'yes'" msgstr "" -#: ../../library/configparser.rst:142 +#: ../../library/configparser.rst:143 msgid "" "As we can see above, the API is pretty straightforward. The only bit of " "magic involves the ``DEFAULT`` section which provides default values for all " @@ -212,7 +212,7 @@ msgstr "" "[1]_。 また、セクション内の各キーは大文字小文字を区別せず、全て小文字で保存さ" "れていることにも注意してください [1]_。" -#: ../../library/configparser.rst:147 ../../library/configparser.rst:992 +#: ../../library/configparser.rst:148 ../../library/configparser.rst:993 msgid "" "It is possible to read several configurations into a single :class:" "`ConfigParser`, where the most recently added configuration has the highest " @@ -222,13 +222,13 @@ msgid "" "``example.ini`` file." msgstr "" -#: ../../library/configparser.rst:154 ../../library/configparser.rst:999 +#: ../../library/configparser.rst:155 ../../library/configparser.rst:1000 msgid "" "[DEFAULT]\n" "ServerAliveInterval = -1" msgstr "" -#: ../../library/configparser.rst:159 ../../library/configparser.rst:1004 +#: ../../library/configparser.rst:160 ../../library/configparser.rst:1005 msgid "" ">>> config_override = configparser.ConfigParser()\n" ">>> config_override['DEFAULT'] = {'ServerAliveInterval': '-1'}\n" @@ -242,17 +242,17 @@ msgid "" "-1" msgstr "" -#: ../../library/configparser.rst:173 +#: ../../library/configparser.rst:174 msgid "" "This behaviour is equivalent to a :meth:`ConfigParser.read` call with " "several files passed to the *filenames* parameter." msgstr "" -#: ../../library/configparser.rst:178 +#: ../../library/configparser.rst:179 msgid "Supported Datatypes" msgstr "サポートされるデータ型" -#: ../../library/configparser.rst:180 +#: ../../library/configparser.rst:181 msgid "" "Config parsers do not guess datatypes of values in configuration files, " "always storing them internally as strings. This means that if you need " @@ -261,7 +261,7 @@ msgstr "" "Config parser は値のデータ型について何も推論せず、常に文字列のまま内部に保存" "します。他のデータ型が必要な場合は自分で変換する必要があります:" -#: ../../library/configparser.rst:184 +#: ../../library/configparser.rst:185 msgid "" ">>> int(topsecret['Port'])\n" "50022\n" @@ -269,7 +269,7 @@ msgid "" "9.0" msgstr "" -#: ../../library/configparser.rst:191 +#: ../../library/configparser.rst:192 msgid "" "Since this task is so common, config parsers provide a range of handy getter " "methods to handle integers, floats and booleans. The last one is the most " @@ -287,7 +287,7 @@ msgstr "" "``'on'``/``'off'``、``'true'``/``'false'``、``'1'``/``'0'`` を真偽値として認" "識します [1]_。例えば:" -#: ../../library/configparser.rst:199 +#: ../../library/configparser.rst:200 msgid "" ">>> topsecret.getboolean('ForwardX11')\n" "False\n" @@ -297,7 +297,7 @@ msgid "" "True" msgstr "" -#: ../../library/configparser.rst:208 +#: ../../library/configparser.rst:209 msgid "" "Apart from :meth:`~ConfigParser.getboolean`, config parsers also provide " "equivalent :meth:`~ConfigParser.getint` and :meth:`~ConfigParser.getfloat` " @@ -309,17 +309,17 @@ msgstr "" "います。独自のコンバーターの登録、提供されたメソッドのカスタマイズもできま" "す。 [1]_" -#: ../../library/configparser.rst:214 +#: ../../library/configparser.rst:215 msgid "Fallback Values" msgstr "代替値" -#: ../../library/configparser.rst:216 +#: ../../library/configparser.rst:217 msgid "" "As with a dictionary, you can use a section's :meth:`~ConfigParser.get` " "method to provide fallback values:" msgstr "" -#: ../../library/configparser.rst:219 +#: ../../library/configparser.rst:220 msgid "" ">>> topsecret.get('Port')\n" "'50022'\n" @@ -330,7 +330,7 @@ msgid "" "'3des-cbc'" msgstr "" -#: ../../library/configparser.rst:229 +#: ../../library/configparser.rst:230 msgid "" "Please note that default values have precedence over fallback values. For " "instance, in our example the ``'CompressionLevel'`` key was specified only " @@ -343,13 +343,13 @@ msgstr "" "ん。その値を ``'topsecret.server.example'`` から取得しようとした場合、代替値" "を指定しても常にデフォルト値を返します:" -#: ../../library/configparser.rst:235 +#: ../../library/configparser.rst:236 msgid "" ">>> topsecret.get('CompressionLevel', '3')\n" "'9'" msgstr "" -#: ../../library/configparser.rst:240 +#: ../../library/configparser.rst:241 msgid "" "One more thing to be aware of is that the parser-level :meth:`~ConfigParser." "get` method provides a custom, more complex interface, maintained for " @@ -357,14 +357,14 @@ msgid "" "provided via the ``fallback`` keyword-only argument:" msgstr "" -#: ../../library/configparser.rst:245 +#: ../../library/configparser.rst:246 msgid "" ">>> config.get('forge.example', 'monster',\n" "... fallback='No such things as monsters')\n" "'No such things as monsters'" msgstr "" -#: ../../library/configparser.rst:251 +#: ../../library/configparser.rst:252 msgid "" "The same ``fallback`` argument can be used with the :meth:`~ConfigParser." "getint`, :meth:`~ConfigParser.getfloat` and :meth:`~ConfigParser.getboolean` " @@ -374,7 +374,7 @@ msgstr "" "`~ConfigParser.getfloat` と :meth:`~ConfigParser.getboolean` メソッドでも使え" "ます。例えば:" -#: ../../library/configparser.rst:255 +#: ../../library/configparser.rst:256 msgid "" ">>> 'BatchMode' in topsecret\n" "False\n" @@ -385,11 +385,11 @@ msgid "" "False" msgstr "" -#: ../../library/configparser.rst:267 +#: ../../library/configparser.rst:268 msgid "Supported INI File Structure" msgstr "サポートするINI ファイルの構造" -#: ../../library/configparser.rst:269 +#: ../../library/configparser.rst:270 msgid "" "A configuration file consists of sections, each led by a ``[section]`` " "header, followed by key/value entries separated by a specific string (``=`` " @@ -402,13 +402,13 @@ msgid "" "parts of multiline values or ignored." msgstr "" -#: ../../library/configparser.rst:279 +#: ../../library/configparser.rst:280 msgid "" "By default, a valid section name can be any string that does not contain '\\" "\\n'. To change this, see :attr:`ConfigParser.SECTCRE`." msgstr "" -#: ../../library/configparser.rst:282 +#: ../../library/configparser.rst:283 msgid "" "The first section name may be omitted if the parser is configured to allow " "an unnamed top level section with ``allow_unnamed_section=True``. In this " @@ -416,7 +416,7 @@ msgid "" "``config[UNNAMED_SECTION]``." msgstr "" -#: ../../library/configparser.rst:287 +#: ../../library/configparser.rst:288 msgid "" "Configuration files may include comments, prefixed by specific characters " "(``#`` and ``;`` by default [1]_). Comments may appear on their own on an " @@ -426,11 +426,11 @@ msgstr "" "つけてコメントをつけることができます。コメントは、他の内容がない行に置くこと" "ができ、インデントされていても構いません。[1]_" -#: ../../library/configparser.rst:291 ../../library/configparser.rst:375 +#: ../../library/configparser.rst:292 ../../library/configparser.rst:376 msgid "For example:" msgstr "例えば:" -#: ../../library/configparser.rst:293 +#: ../../library/configparser.rst:294 msgid "" "[Simple Values]\n" "key=value\n" @@ -475,17 +475,17 @@ msgid "" " # Did I mention we can indent comments, too?" msgstr "" -#: ../../library/configparser.rst:341 +#: ../../library/configparser.rst:342 msgid "Unnamed Sections" msgstr "" -#: ../../library/configparser.rst:343 +#: ../../library/configparser.rst:344 msgid "" "The name of the first section (or unique) may be omitted and values " "retrieved by the :const:`UNNAMED_SECTION` attribute." msgstr "" -#: ../../library/configparser.rst:346 +#: ../../library/configparser.rst:347 msgid "" ">>> config = \"\"\"\n" "... option = value\n" @@ -499,11 +499,11 @@ msgid "" "'value'" msgstr "" -#: ../../library/configparser.rst:360 +#: ../../library/configparser.rst:361 msgid "Interpolation of values" msgstr "値の補間" -#: ../../library/configparser.rst:362 +#: ../../library/configparser.rst:363 msgid "" "On top of the core functionality, :class:`ConfigParser` supports " "interpolation. This means values can be preprocessed before returning them " @@ -513,7 +513,7 @@ msgstr "" "ポートします。これは ``get()`` コールが値を返す前に、その値に対して前処理を行" "えることを意味します。" -#: ../../library/configparser.rst:370 +#: ../../library/configparser.rst:371 msgid "" "The default implementation used by :class:`ConfigParser`. It enables values " "to contain format strings which refer to other values in the same section, " @@ -524,7 +524,7 @@ msgstr "" "別なデフォルトセクション中 [1]_ の他の値を参照するフォーマット文字列を含める" "ことができます。追加のデフォルト値を初期化時に提供できます。" -#: ../../library/configparser.rst:377 +#: ../../library/configparser.rst:378 msgid "" "[Paths]\n" "home_dir: /Users\n" @@ -537,7 +537,7 @@ msgid "" "gain: 80%%" msgstr "" -#: ../../library/configparser.rst:388 +#: ../../library/configparser.rst:389 msgid "" "In the example above, :class:`ConfigParser` with *interpolation* set to " "``BasicInterpolation()`` would resolve ``%(home_dir)s`` to the value of " @@ -552,7 +552,7 @@ msgstr "" "lumberjack`` になります。全ての補間は必要に応じて実行されるため、設定ファイル" "中で参照の連鎖をもつキーを特定の順序で記述する必要はありません。" -#: ../../library/configparser.rst:395 +#: ../../library/configparser.rst:396 msgid "" "With ``interpolation`` set to ``None``, the parser would simply return " "``%(my_dir)s/Pictures`` as the value of ``my_pictures`` and ``%(home_dir)s/" @@ -562,7 +562,7 @@ msgstr "" "値として ``%(my_dir)s/Pictures`` を返し、``my_dir`` の値として " "``%(home_dir)s/lumberjack`` を返します。" -#: ../../library/configparser.rst:403 +#: ../../library/configparser.rst:404 msgid "" "An alternative handler for interpolation which implements a more advanced " "syntax, used for instance in ``zc.buildout``. Extended interpolation is " @@ -577,7 +577,7 @@ msgstr "" "``section:`` の部分が省略されると、現在のセクションがデフォルト値となります" "(スペシャルセクション中のデフォルト値を使用することもできます)。" -#: ../../library/configparser.rst:410 +#: ../../library/configparser.rst:411 msgid "" "For example, the configuration specified above with basic interpolation, " "would look like this with extended interpolation:" @@ -585,7 +585,7 @@ msgstr "" "たとえば、上記の basic interpolation で指定した設定は、extended " "interpolation を使うと下記のようになります:" -#: ../../library/configparser.rst:413 +#: ../../library/configparser.rst:414 msgid "" "[Paths]\n" "home_dir: /Users\n" @@ -598,11 +598,11 @@ msgid "" "cost: $$80" msgstr "" -#: ../../library/configparser.rst:424 +#: ../../library/configparser.rst:425 msgid "Values from other sections can be fetched as well:" msgstr "他のセクションから値を持ってくることもできます:" -#: ../../library/configparser.rst:426 +#: ../../library/configparser.rst:427 msgid "" "[Common]\n" "home_dir: /Users\n" @@ -622,11 +622,11 @@ msgid "" "python_dir: ${Frameworks:path}/Python/Versions/${Frameworks:Python}" msgstr "" -#: ../../library/configparser.rst:446 +#: ../../library/configparser.rst:447 msgid "Mapping Protocol Access" msgstr "マップ型プロトコルアクセス" -#: ../../library/configparser.rst:450 +#: ../../library/configparser.rst:451 msgid "" "Mapping protocol access is a generic name for functionality that enables " "using custom objects as if they were dictionaries. In case of :mod:" @@ -637,7 +637,7 @@ msgstr "" "ための機能の総称です。 :mod:`configparser` の場合、マップ型インターフェースの" "実装は ``parser['section']['option']`` 表記を使います。" -#: ../../library/configparser.rst:455 +#: ../../library/configparser.rst:456 msgid "" "``parser['section']`` in particular returns a proxy for the section's data " "in the parser. This means that the values are not copied but they are taken " @@ -650,7 +650,7 @@ msgstr "" "サーから取られます。さらに重要なことに、セクションのプロキシの値が変更される" "と、オリジナルのパーサー中の値が実際に変更されます。" -#: ../../library/configparser.rst:461 +#: ../../library/configparser.rst:462 msgid "" ":mod:`configparser` objects behave as close to actual dictionaries as " "possible. The mapping interface is complete and adheres to the :class:" @@ -661,7 +661,7 @@ msgstr "" "ンターフェースは :class:`~collections.abc.MutableMapping` を矛盾なく完成しま" "す。しかし、考慮するべき違いがいくつかあります:" -#: ../../library/configparser.rst:466 +#: ../../library/configparser.rst:467 msgid "" "By default, all keys in sections are accessible in a case-insensitive manner " "[1]_. E.g. ``for option in parser[\"section\"]`` yields only " @@ -675,13 +675,13 @@ msgstr "" "す。同時に、キー ``'a'`` を含むセクションにおいて、どちらの式も ``True`` を返" "します::" -#: ../../library/configparser.rst:471 +#: ../../library/configparser.rst:472 msgid "" "\"a\" in parser[\"section\"]\n" "\"A\" in parser[\"section\"]" msgstr "" -#: ../../library/configparser.rst:474 +#: ../../library/configparser.rst:475 msgid "" "All sections include ``DEFAULTSECT`` values as well which means that ``." "clear()`` on a section may not leave the section visibly empty. This is " @@ -696,23 +696,23 @@ msgstr "" "上書きされた場合、それが削除されるとデフォルト値が再び見えるようになります。" "デフォルト値を削除しようとすると :exc:`KeyError` が発生します。" -#: ../../library/configparser.rst:481 +#: ../../library/configparser.rst:482 msgid "``DEFAULTSECT`` cannot be removed from the parser:" msgstr "``DEFAULTSECT`` はパーサーから取り除けません:" -#: ../../library/configparser.rst:483 +#: ../../library/configparser.rst:484 msgid "trying to delete it raises :exc:`ValueError`," msgstr "削除しようとすると :exc:`ValueError` が発生します。" -#: ../../library/configparser.rst:485 +#: ../../library/configparser.rst:486 msgid "``parser.clear()`` leaves it intact," msgstr "``parser.clear()`` はこれをそのまま残し、" -#: ../../library/configparser.rst:487 +#: ../../library/configparser.rst:488 msgid "``parser.popitem()`` never returns it." msgstr "``parser.popitem()`` がこれを返すことはありません。" -#: ../../library/configparser.rst:489 +#: ../../library/configparser.rst:490 msgid "" "``parser.get(section, option, **kwargs)`` - the second argument is **not** a " "fallback value. Note however that the section-level ``get()`` methods are " @@ -722,7 +722,7 @@ msgstr "" "*。ただし、セクションごとの ``get()`` メソッドはマップ型プロトコルと旧式の " "configparser API の両方に互換です。" -#: ../../library/configparser.rst:493 +#: ../../library/configparser.rst:494 msgid "" "``parser.items()`` is compatible with the mapping protocol (returns a list " "of *section_name*, *section_proxy* pairs including the DEFAULTSECT). " @@ -737,7 +737,7 @@ msgstr "" "出せます。後者の呼び出しは指定された ``section`` の *option*, *value* 対のリ" "ストを、(``raw=True`` が与えられない限り) 全ての補間を展開して返します。" -#: ../../library/configparser.rst:500 +#: ../../library/configparser.rst:501 msgid "" "The mapping protocol is implemented on top of the existing legacy API so " "that subclasses overriding the original interface still should have mappings " @@ -746,11 +746,11 @@ msgstr "" "マップ型プロトコルは、既存のレガシーな API の上に実装されているので、オリジナ" "ルのインターフェースを上書きする派生クラスもまたは期待どおりにはたらきます。" -#: ../../library/configparser.rst:506 +#: ../../library/configparser.rst:507 msgid "Customizing Parser Behaviour" msgstr "パーサーの振る舞いをカスタマイズする" -#: ../../library/configparser.rst:508 +#: ../../library/configparser.rst:509 msgid "" "There are nearly as many INI format variants as there are applications using " "it. :mod:`configparser` goes a long way to provide support for the largest " @@ -763,17 +763,17 @@ msgstr "" "合をサポートするために、非常に役立ちます。デフォルトの機能は主に歴史的背景に" "よって決められたので、機能によってはカスタマイズしてお使いください。" -#: ../../library/configparser.rst:514 +#: ../../library/configparser.rst:515 msgid "" "The most common way to change the way a specific config parser works is to " "use the :meth:`!__init__` options:" msgstr "" -#: ../../library/configparser.rst:517 +#: ../../library/configparser.rst:518 msgid "*defaults*, default value: ``None``" msgstr "*defaults*, デフォルト値: ``None``" -#: ../../library/configparser.rst:519 +#: ../../library/configparser.rst:520 msgid "" "This option accepts a dictionary of key-value pairs which will be initially " "put in the ``DEFAULT`` section. This makes for an elegant way to support " @@ -783,17 +783,17 @@ msgstr "" "このオプションは最初に ``DEFAULT`` セクションに加えられるキー-値の対の辞書を" "受け付けます。" -#: ../../library/configparser.rst:524 +#: ../../library/configparser.rst:525 msgid "" "Hint: if you want to specify default values for a specific section, use :" "meth:`~ConfigParser.read_dict` before you read the actual file." msgstr "" -#: ../../library/configparser.rst:527 +#: ../../library/configparser.rst:528 msgid "*dict_type*, default value: :class:`dict`" msgstr "*dict_type*, デフォルト値: :class:`dict`" -#: ../../library/configparser.rst:529 +#: ../../library/configparser.rst:530 msgid "" "This option has a major impact on how the mapping protocol will behave and " "how the written configuration files look. With the standard dictionary, " @@ -804,7 +804,7 @@ msgstr "" "た目に大きく影響します。標準の辞書では、全てのセクションはパーサーに加えられ" "た順に並びます。同じことがセクション内のオプションにも言えます。" -#: ../../library/configparser.rst:534 +#: ../../library/configparser.rst:535 msgid "" "An alternative dictionary type can be used for example to sort sections and " "options on write-back." @@ -812,7 +812,7 @@ msgstr "" "セクションとオプションをライトバック時にソートするためなどに、別の辞書型も使" "えます。" -#: ../../library/configparser.rst:537 +#: ../../library/configparser.rst:538 msgid "" "Please note: there are ways to add a set of key-value pairs in a single " "operation. When you use a regular dictionary in those operations, the order " @@ -821,7 +821,7 @@ msgstr "" "注意: 一度の操作でキー-値の対を複数追加する方法もあります。そのような操作に普" "通の辞書を使うと、キーの並びは挿入順になります。例えば:" -#: ../../library/configparser.rst:541 +#: ../../library/configparser.rst:542 msgid "" ">>> parser = configparser.ConfigParser()\n" ">>> parser.read_dict({'section1': {'key1': 'value1',\n" @@ -840,11 +840,11 @@ msgid "" "['foo', 'bar', 'baz']" msgstr "" -#: ../../library/configparser.rst:559 +#: ../../library/configparser.rst:560 msgid "*allow_no_value*, default value: ``False``" msgstr "*allow_no_value*, デフォルト値: ``False``" -#: ../../library/configparser.rst:561 +#: ../../library/configparser.rst:562 msgid "" "Some configuration files are known to include settings without values, but " "which otherwise conform to the syntax supported by :mod:`configparser`. The " @@ -855,7 +855,7 @@ msgstr "" "`ConfigParser` がサポートする文法に従います。コンストラクタの " "*allow_no_value* 引数で、そのような値を許可することができます。" -#: ../../library/configparser.rst:566 +#: ../../library/configparser.rst:567 msgid "" ">>> import configparser\n" "\n" @@ -886,11 +886,11 @@ msgid "" "KeyError: 'does-not-exist'" msgstr "" -#: ../../library/configparser.rst:596 +#: ../../library/configparser.rst:597 msgid "*delimiters*, default value: ``('=', ':')``" msgstr "*delimiters*, デフォルト値: ``('=', ':')``" -#: ../../library/configparser.rst:598 +#: ../../library/configparser.rst:599 msgid "" "Delimiters are substrings that delimit keys from values within a section. " "The first occurrence of a delimiting substring on a line is considered a " @@ -900,7 +900,7 @@ msgstr "" "区切り部分文字列がデリミタと見なされます。つまり値にはデリミタを含めることが" "できます (キーには含めることができません)。" -#: ../../library/configparser.rst:602 +#: ../../library/configparser.rst:603 msgid "" "See also the *space_around_delimiters* argument to :meth:`ConfigParser." "write`." @@ -908,15 +908,15 @@ msgstr "" ":meth:`ConfigParser.write` の *space_around_delimiters* 引数も参照してくださ" "い。" -#: ../../library/configparser.rst:605 +#: ../../library/configparser.rst:606 msgid "*comment_prefixes*, default value: ``('#', ';')``" msgstr "*comment_prefixes*, デフォルト値: ``('#', ';')``" -#: ../../library/configparser.rst:607 +#: ../../library/configparser.rst:608 msgid "*inline_comment_prefixes*, default value: ``None``" msgstr "*inline_comment_prefixes*, デフォルト値: ``None``" -#: ../../library/configparser.rst:609 +#: ../../library/configparser.rst:610 msgid "" "Comment prefixes are strings that indicate the start of a valid comment " "within a config file. *comment_prefixes* are used only on otherwise empty " @@ -931,7 +931,7 @@ msgstr "" "ン、空行も可能) の後に使えます。デフォルトではインラインコメントは無効化され" "ていて、``'#'`` と ``';'`` を行全体のコメントに使用します。" -#: ../../library/configparser.rst:616 +#: ../../library/configparser.rst:617 msgid "" "In previous versions of :mod:`configparser` behaviour matched " "``comment_prefixes=('#',';')`` and ``inline_comment_prefixes=(';',)``." @@ -940,7 +940,7 @@ msgstr "" "``comment_prefixes=('#',';')`` および ``inline_comment_prefixes=(';',)`` に該" "当します。" -#: ../../library/configparser.rst:620 +#: ../../library/configparser.rst:621 msgid "" "Please note that config parsers don't support escaping of comment prefixes " "so using *inline_comment_prefixes* may prevent users from specifying option " @@ -956,7 +956,7 @@ msgstr "" "も、複数行にわたる値で、行の先頭にコメント接頭辞文字を保存する唯一の方法は、" "次の例のように接頭辞を補間することです::" -#: ../../library/configparser.rst:627 +#: ../../library/configparser.rst:628 msgid "" ">>> from configparser import ConfigParser, ExtendedInterpolation\n" ">>> parser = ConfigParser(interpolation=ExtendedInterpolation())\n" @@ -998,11 +998,11 @@ msgid "" "line #3" msgstr "" -#: ../../library/configparser.rst:666 +#: ../../library/configparser.rst:667 msgid "*strict*, default value: ``True``" msgstr "*strict*, デフォルト値: ``True``" -#: ../../library/configparser.rst:668 +#: ../../library/configparser.rst:669 msgid "" "When set to ``True``, the parser will not allow for any section or option " "duplicates while reading from a single source (using :meth:`~ConfigParser." @@ -1010,7 +1010,7 @@ msgid "" "read_dict`). It is recommended to use strict parsers in new applications." msgstr "" -#: ../../library/configparser.rst:673 +#: ../../library/configparser.rst:674 msgid "" "In previous versions of :mod:`configparser` behaviour matched " "``strict=False``." @@ -1018,11 +1018,11 @@ msgstr "" "以前のバージョンの :mod:`configparser` の振る舞いは ``strict=False`` に該当し" "ます。" -#: ../../library/configparser.rst:677 +#: ../../library/configparser.rst:678 msgid "*empty_lines_in_values*, default value: ``True``" msgstr "*empty_lines_in_values*, デフォルト値: ``True``" -#: ../../library/configparser.rst:679 +#: ../../library/configparser.rst:680 msgid "" "In config parsers, values can span multiple lines as long as they are " "indented more than the key that holds them. By default parsers also let " @@ -1037,7 +1037,7 @@ msgstr "" "ルが大きく複雑になったとき、ユーザーがファイル構造を見失いやすいです。この例" "をご覧ください:" -#: ../../library/configparser.rst:686 +#: ../../library/configparser.rst:687 msgid "" "[Section]\n" "key = multiline\n" @@ -1046,7 +1046,7 @@ msgid "" " this = is still a part of the multiline value of 'key'" msgstr "" -#: ../../library/configparser.rst:694 +#: ../../library/configparser.rst:695 msgid "" "This can be especially problematic for the user to see if she's using a " "proportional font to edit the file. That is why when your application does " @@ -1059,7 +1059,7 @@ msgstr "" "なら、空行を認めないべきです。これによって空行で必ずキーが分かれます。上の例" "では、2 つのキー、``key`` および ``this`` が作られます。" -#: ../../library/configparser.rst:700 +#: ../../library/configparser.rst:701 msgid "" "*default_section*, default value: ``configparser.DEFAULTSECT`` (that is: " "``\"DEFAULT\"``)" @@ -1067,7 +1067,7 @@ msgstr "" "*default_section*, デフォルト値: ``configparser.DEFAULTSECT`` (すなわち: " "``\"DEFAULT\"``)" -#: ../../library/configparser.rst:703 +#: ../../library/configparser.rst:704 msgid "" "The convention of allowing a special section of default values for other " "sections or interpolation purposes is a powerful concept of this library, " @@ -1090,11 +1090,11 @@ msgstr "" "時 (すなわちファイルを別のフォーマットに変換するとき) に変更することもできま" "す。" -#: ../../library/configparser.rst:714 +#: ../../library/configparser.rst:715 msgid "*interpolation*, default value: ``configparser.BasicInterpolation``" msgstr "*interpolation*, デフォルト値: ``configparser.BasicInterpolation``" -#: ../../library/configparser.rst:716 +#: ../../library/configparser.rst:717 msgid "" "Interpolation behaviour may be customized by providing a custom handler " "through the *interpolation* argument. ``None`` can be used to turn off " @@ -1110,11 +1110,11 @@ msgstr "" "of-values>`_ をご覧ください。 :class:`RawConfigParser` のデフォルト値は " "``None`` です。" -#: ../../library/configparser.rst:723 +#: ../../library/configparser.rst:724 msgid "*converters*, default value: not set" msgstr "*converters*, デフォルト値: 未設定" -#: ../../library/configparser.rst:725 +#: ../../library/configparser.rst:726 msgid "" "Config parsers provide option value getters that perform type conversion. " "By default :meth:`~ConfigParser.getint`, :meth:`~ConfigParser.getfloat`, " @@ -1128,7 +1128,7 @@ msgid "" "``parser_instance['section'].getdecimal('key', 0)``." msgstr "" -#: ../../library/configparser.rst:736 +#: ../../library/configparser.rst:737 msgid "" "If the converter needs to access the state of the parser, it can be " "implemented as a method on a config parser subclass. If the name of this " @@ -1140,7 +1140,7 @@ msgstr "" "始まる場合、すべてのセクションプロキシで、辞書と互換性のある形式で利用できま" "す (上記の ``getdecimal()`` の例を参照)。" -#: ../../library/configparser.rst:741 +#: ../../library/configparser.rst:742 msgid "" "More advanced customization may be achieved by overriding default values of " "these parser attributes. The defaults are defined on the classes, so they " @@ -1150,7 +1150,7 @@ msgstr "" "できます。デフォルトはクラスで定義されているので、派生クラスや属性の代入で上" "書きできます。" -#: ../../library/configparser.rst:747 +#: ../../library/configparser.rst:748 msgid "" "By default when using :meth:`~ConfigParser.getboolean`, config parsers " "consider the following values ``True``: ``'1'``, ``'yes'``, ``'true'``, " @@ -1164,7 +1164,7 @@ msgstr "" "``'false'``, ``'off'`` 。文字列と対応するブール値のカスタム辞書を指定すること" "でこれを上書きできます。たとえば:" -#: ../../library/configparser.rst:753 +#: ../../library/configparser.rst:754 msgid "" ">>> custom = configparser.ConfigParser()\n" ">>> custom['section1'] = {'funky': 'nope'}\n" @@ -1177,7 +1177,7 @@ msgid "" "False" msgstr "" -#: ../../library/configparser.rst:765 +#: ../../library/configparser.rst:766 msgid "" "Other typical Boolean pairs include ``accept``/``reject`` or ``enabled``/" "``disabled``." @@ -1185,7 +1185,7 @@ msgstr "" "ほかの典型的なブール値ペアには ``accept``/``reject`` や ``enabled``/" "``disabled`` などがあります。" -#: ../../library/configparser.rst:771 +#: ../../library/configparser.rst:772 msgid "" "This method transforms option names on every read, get, or set operation. " "The default converts the name to lowercase. This also means that when a " @@ -1197,7 +1197,7 @@ msgstr "" "すべてのキーは小文字になります。それがふさわしくなければ、このメソッドを上書" "きしてください。例えば:" -#: ../../library/configparser.rst:777 +#: ../../library/configparser.rst:778 msgid "" ">>> config = \"\"\"\n" "... [Section1]\n" @@ -1221,14 +1221,14 @@ msgid "" "['AnotherKey']" msgstr "" -#: ../../library/configparser.rst:801 +#: ../../library/configparser.rst:802 msgid "" "The optionxform function transforms option names to a canonical form. This " "should be an idempotent function: if the name is already in canonical form, " "it should be returned unchanged." msgstr "" -#: ../../library/configparser.rst:808 +#: ../../library/configparser.rst:809 msgid "" "A compiled regular expression used to parse section headers. The default " "matches ``[section]`` to the name ``\"section\"``. Whitespace is considered " @@ -1242,7 +1242,7 @@ msgstr "" "名のセクションとして読み込まれます。これがふさわしくない場合、このメソッドを" "上書きしてください。例えば:" -#: ../../library/configparser.rst:814 +#: ../../library/configparser.rst:815 msgid "" ">>> import re\n" ">>> config = \"\"\"\n" @@ -1263,7 +1263,7 @@ msgid "" "['Section 1', 'Section 2']" msgstr "" -#: ../../library/configparser.rst:836 +#: ../../library/configparser.rst:837 msgid "" "While ConfigParser objects also use an ``OPTCRE`` attribute for recognizing " "option lines, it's not recommended to override it because that would " @@ -1273,11 +1273,11 @@ msgstr "" "これを上書きすることは推奨されません。上書きするとコンストラクタオプション " "*allow_no_value* および *delimiters* に干渉します。" -#: ../../library/configparser.rst:842 +#: ../../library/configparser.rst:843 msgid "Legacy API Examples" msgstr "レガシーな API の例" -#: ../../library/configparser.rst:844 +#: ../../library/configparser.rst:845 msgid "" "Mainly because of backwards compatibility concerns, :mod:`configparser` " "provides also a legacy API with explicit ``get``/``set`` methods. While " @@ -1291,11 +1291,11 @@ msgstr "" "いです。レガシーな API は時折高度で、低レベルで、まったく直感的ではありませ" "ん。" -#: ../../library/configparser.rst:850 +#: ../../library/configparser.rst:851 msgid "An example of writing to a configuration file::" msgstr "設定ファイルを書き出す例::" -#: ../../library/configparser.rst:852 +#: ../../library/configparser.rst:853 msgid "" "import configparser\n" "\n" @@ -1319,11 +1319,11 @@ msgid "" " config.write(configfile)" msgstr "" -#: ../../library/configparser.rst:873 +#: ../../library/configparser.rst:874 msgid "An example of reading the configuration file again::" msgstr "設定ファイルを読み込む例::" -#: ../../library/configparser.rst:875 +#: ../../library/configparser.rst:876 msgid "" "import configparser\n" "\n" @@ -1342,11 +1342,11 @@ msgid "" " print(config.get('Section1', 'foo'))" msgstr "" -#: ../../library/configparser.rst:891 +#: ../../library/configparser.rst:892 msgid "To get interpolation, use :class:`ConfigParser`::" msgstr "補間するには、 :class:`ConfigParser` を使ってください::" -#: ../../library/configparser.rst:893 +#: ../../library/configparser.rst:894 msgid "" "import configparser\n" "\n" @@ -1381,7 +1381,7 @@ msgid "" " # -> None" msgstr "" -#: ../../library/configparser.rst:924 +#: ../../library/configparser.rst:925 msgid "" "Default values are available in both types of ConfigParsers. They are used " "in interpolation if an option used is not defined elsewhere. ::" @@ -1389,7 +1389,7 @@ msgstr "" "どちらの型の ConfigParsers でもデフォルト値が利用できます。使われているオプ" "ションがどこにも定義されていなければ、そのデフォルト値が補間に使われます。 ::" -#: ../../library/configparser.rst:927 +#: ../../library/configparser.rst:928 msgid "" "import configparser\n" "\n" @@ -1403,11 +1403,11 @@ msgid "" "print(config.get('Section1', 'foo')) # -> \"Life is hard!\"" msgstr "" -#: ../../library/configparser.rst:942 +#: ../../library/configparser.rst:943 msgid "ConfigParser Objects" msgstr "ConfigParser オブジェクト" -#: ../../library/configparser.rst:946 +#: ../../library/configparser.rst:947 msgid "" "The main configuration parser. When *defaults* is given, it is initialized " "into the dictionary of intrinsic defaults. When *dict_type* is given, it " @@ -1418,7 +1418,7 @@ msgstr "" "化されます。*dict_type* が与えられれば、それがセクションの一覧、セクション中" "のオプション、およびデフォルト値の辞書オブジェクトを作成するのに使われます。" -#: ../../library/configparser.rst:951 +#: ../../library/configparser.rst:952 msgid "" "When *delimiters* is given, it is used as the set of substrings that divide " "keys from values. When *comment_prefixes* is given, it will be used as the " @@ -1432,7 +1432,7 @@ msgstr "" "す。*inline_comment_prefixes* が与えられた場合、非空行のコメントに接頭する部" "分文字列としての組み合わせとして使われます。" -#: ../../library/configparser.rst:957 +#: ../../library/configparser.rst:958 msgid "" "When *strict* is ``True`` (the default), the parser won't allow for any " "section or option duplicates while reading from a single source (file, " @@ -1452,7 +1452,7 @@ msgstr "" "``False``) なら、値のないオプションが受け付けられます。そのオプションの値は " "``None`` となり、後端のデリミタを除いてシリアル化されます。" -#: ../../library/configparser.rst:967 +#: ../../library/configparser.rst:968 msgid "" "When *default_section* is given, it specifies the name for the special " "section holding default values for other sections and interpolation purposes " @@ -1462,7 +1462,7 @@ msgid "" "settings to a new config file." msgstr "" -#: ../../library/configparser.rst:974 +#: ../../library/configparser.rst:975 msgid "" "Interpolation behaviour may be customized by providing a custom handler " "through the *interpolation* argument. ``None`` can be used to turn off " @@ -1476,7 +1476,7 @@ msgstr "" "を提供します。この件に `特化したドキュメントのセクション <#interpolation-of-" "values>`_ を参照してください。" -#: ../../library/configparser.rst:980 +#: ../../library/configparser.rst:981 msgid "" "All option names used in interpolation will be passed through the :meth:" "`optionxform` method just like any other option name reference. For " @@ -1489,7 +1489,7 @@ msgstr "" "フォルトの実装を使うと、値 ``foo %(bar)s`` と ``foo %(BAR)s`` は等しくなりま" "す。" -#: ../../library/configparser.rst:986 +#: ../../library/configparser.rst:987 msgid "" "When *converters* is given, it should be a dictionary where each key " "represents the name of a type converter and each value is a callable " @@ -1498,11 +1498,11 @@ msgid "" "object and section proxies." msgstr "" -#: ../../library/configparser.rst:1017 +#: ../../library/configparser.rst:1018 msgid "The default *dict_type* is :class:`collections.OrderedDict`." msgstr "デフォルトの *dict_type* は :class:`collections.OrderedDict` です。" -#: ../../library/configparser.rst:1020 +#: ../../library/configparser.rst:1021 msgid "" "*allow_no_value*, *delimiters*, *comment_prefixes*, *strict*, " "*empty_lines_in_values*, *default_section* and *interpolation* were added." @@ -1511,34 +1511,34 @@ msgstr "" "*empty_lines_in_values*, *default_section* および *interpolation* が追加され" "ました。" -#: ../../library/configparser.rst:1025 +#: ../../library/configparser.rst:1026 msgid "The *converters* argument was added." msgstr "*converters* 引数が追加されました。" -#: ../../library/configparser.rst:1028 +#: ../../library/configparser.rst:1029 msgid "" "The *defaults* argument is read with :meth:`read_dict`, providing consistent " "behavior across the parser: non-string keys and values are implicitly " "converted to strings." msgstr "" -#: ../../library/configparser.rst:1033 ../../library/configparser.rst:1305 +#: ../../library/configparser.rst:1034 ../../library/configparser.rst:1306 msgid "" "The default *dict_type* is :class:`dict`, since it now preserves insertion " "order." msgstr "" -#: ../../library/configparser.rst:1037 +#: ../../library/configparser.rst:1038 msgid "" "Raise a :exc:`MultilineContinuationError` when *allow_no_value* is ``True``, " "and a key without a value is continued with an indented line." msgstr "" -#: ../../library/configparser.rst:1043 +#: ../../library/configparser.rst:1044 msgid "Return a dictionary containing the instance-wide defaults." msgstr "インスタンス全体で使われるデフォルト値の辞書を返します。" -#: ../../library/configparser.rst:1048 +#: ../../library/configparser.rst:1049 msgid "" "Return a list of the sections available; the *default section* is not " "included in the list." @@ -1546,7 +1546,7 @@ msgstr "" "利用できるセクションのリストを返します。*default section* はリストに含まれま" "せん。" -#: ../../library/configparser.rst:1054 +#: ../../library/configparser.rst:1055 msgid "" "Add a section named *section* to the instance. If a section by the given " "name already exists, :exc:`DuplicateSectionError` is raised. If the " @@ -1559,11 +1559,11 @@ msgstr "" "ンの名前は文字列でなければなりません。そうでなければ、 :exc:`TypeError` が送" "出されます。" -#: ../../library/configparser.rst:1059 +#: ../../library/configparser.rst:1060 msgid "Non-string section names raise :exc:`TypeError`." msgstr "文字列でないセクション名は :exc:`TypeError` を送出します。" -#: ../../library/configparser.rst:1065 +#: ../../library/configparser.rst:1066 msgid "" "Indicates whether the named *section* is present in the configuration. The " "*default section* is not acknowledged." @@ -1571,11 +1571,11 @@ msgstr "" "指名された *section* が設定中に存在するかを示します。*default section* は認識" "されません。" -#: ../../library/configparser.rst:1071 +#: ../../library/configparser.rst:1072 msgid "Return a list of options available in the specified *section*." msgstr "指定された *section* 中で利用できるオプションのリストを返します。" -#: ../../library/configparser.rst:1076 +#: ../../library/configparser.rst:1077 msgid "" "If the given *section* exists, and contains the given *option*, return :" "const:`True`; otherwise return :const:`False`. If the specified *section* " @@ -1585,7 +1585,7 @@ msgstr "" "`True` を返します。それ以外の場合には、 :const:`False` を返します。指定され" "た *section* が :const:`None` または空文字列の場合、 DEFAULT が仮定されます。" -#: ../../library/configparser.rst:1083 +#: ../../library/configparser.rst:1084 msgid "" "Attempt to read and parse an iterable of filenames, returning a list of " "filenames which were successfully parsed." @@ -1593,7 +1593,7 @@ msgstr "" "ファイル名の iterable を読み込んでパースしようと試みます。正常にパースできた" "ファイル名のリストを返します。" -#: ../../library/configparser.rst:1086 +#: ../../library/configparser.rst:1087 msgid "" "If *filenames* is a string, a :class:`bytes` object or a :term:`path-like " "object`, it is treated as a single filename. If a file named in *filenames* " @@ -1610,7 +1610,7 @@ msgstr "" "リ、システム全体の設定を行うディレクトリ)のイテラブルを指定して、イテラブルの" "中で存在する全ての設定ファイルを読むことを想定して設計されています。 " -#: ../../library/configparser.rst:1095 +#: ../../library/configparser.rst:1096 msgid "" "If none of the named files exist, the :class:`ConfigParser` instance will " "contain an empty dataset. An application which requires initial values to " @@ -1623,7 +1623,7 @@ msgstr "" "を呼ぶ前に 、まず :meth:`read_file` を用いて必要なファイルを読み込んでくださ" "い::" -#: ../../library/configparser.rst:1101 +#: ../../library/configparser.rst:1102 msgid "" "import configparser, os\n" "\n" @@ -1633,23 +1633,23 @@ msgid "" " encoding='cp1250')" msgstr "" -#: ../../library/configparser.rst:1108 +#: ../../library/configparser.rst:1109 msgid "" "Added the *encoding* parameter. Previously, all files were read using the " "default encoding for :func:`open`." msgstr "" -#: ../../library/configparser.rst:1112 +#: ../../library/configparser.rst:1113 msgid "The *filenames* parameter accepts a :term:`path-like object`." msgstr "" "*filenames* 引数が :term:`path-like object` を受け入れるようになりました。" -#: ../../library/configparser.rst:1115 +#: ../../library/configparser.rst:1116 msgid "The *filenames* parameter accepts a :class:`bytes` object." msgstr "" "*filenames* 引数が :class:`bytes` オブジェクトを受け入れるようになりました。" -#: ../../library/configparser.rst:1121 +#: ../../library/configparser.rst:1122 msgid "" "Read and parse configuration data from *f* which must be an iterable " "yielding Unicode strings (for example files opened in text mode)." @@ -1657,22 +1657,22 @@ msgstr "" "設定データを *f* から読み込んで解析します。*f* は Unicode 文字列を yield する" "イテラブル (例えばテキストモードで開かれたファイル) です。" -#: ../../library/configparser.rst:1124 +#: ../../library/configparser.rst:1125 msgid "" "Optional argument *source* specifies the name of the file being read. If " "not given and *f* has a :attr:`!name` attribute, that is used for *source*; " "the default is ``''``." msgstr "" -#: ../../library/configparser.rst:1128 +#: ../../library/configparser.rst:1129 msgid "Replaces :meth:`!readfp`." msgstr ":meth:`!readfp` を置き換えます。" -#: ../../library/configparser.rst:1133 +#: ../../library/configparser.rst:1134 msgid "Parse configuration data from a string." msgstr "設定データを文字列から解析します。" -#: ../../library/configparser.rst:1135 +#: ../../library/configparser.rst:1136 msgid "" "Optional argument *source* specifies a context-specific name of the string " "passed. If not given, ``''`` is used. This should commonly be a " @@ -1682,7 +1682,7 @@ msgstr "" "ます。与えられなければ、``''`` が使われます。これは一般にファイルシス" "テムパスや URL にします。" -#: ../../library/configparser.rst:1144 +#: ../../library/configparser.rst:1145 msgid "" "Load configuration from any object that provides a dict-like ``items()`` " "method. Keys are section names, values are dictionaries with keys and " @@ -1695,7 +1695,7 @@ msgstr "" "使われた辞書型が順序を保存するなら、セクションおよびそのキーは順に加えられま" "す。値は自動で文字列に変換されます。" -#: ../../library/configparser.rst:1150 +#: ../../library/configparser.rst:1151 msgid "" "Optional argument *source* specifies a context-specific name of the " "dictionary passed. If not given, ```` is used." @@ -1703,11 +1703,11 @@ msgstr "" "オプションの引数 *source* はコンテキストにおける渡された辞書の名前を指定しま" "す。与えられなければ、```` が使われます。" -#: ../../library/configparser.rst:1153 +#: ../../library/configparser.rst:1154 msgid "This method can be used to copy state between parsers." msgstr "このメソッドを使ってパーサー間で状態をコピーできます。" -#: ../../library/configparser.rst:1160 +#: ../../library/configparser.rst:1161 msgid "" "Get an *option* value for the named *section*. If *vars* is provided, it " "must be a dictionary. The *option* is looked up in *vars* (if provided), " @@ -1720,7 +1720,7 @@ msgstr "" "*DEFAULTSECT* 内からこの順で *option* が探索されます。*fallback* の値として " "``None`` を与えられます。" -#: ../../library/configparser.rst:1166 +#: ../../library/configparser.rst:1167 msgid "" "All the ``'%'`` interpolations are expanded in the return values, unless the " "*raw* argument is true. Values for interpolation keys are looked up in the " @@ -1729,7 +1729,7 @@ msgstr "" "*raw* が真でない時には、全ての ``'%'`` 置換は展開されてから返されます。置換後" "の値はオプションと同じ順序で探されます。" -#: ../../library/configparser.rst:1170 +#: ../../library/configparser.rst:1171 msgid "" "Arguments *raw*, *vars* and *fallback* are keyword only to protect users " "from trying to use the third argument as the *fallback* fallback (especially " @@ -1739,7 +1739,7 @@ msgstr "" "ときに) ユーザーが第 3 引数を *fallback* フォールバックとして使おうとしないよ" "うに、キーワード専用となりました。" -#: ../../library/configparser.rst:1178 +#: ../../library/configparser.rst:1179 msgid "" "A convenience method which coerces the *option* in the specified *section* " "to an integer. See :meth:`get` for explanation of *raw*, *vars* and " @@ -1748,14 +1748,14 @@ msgstr "" "指定された *section* 中の *option* を整数に型強制する補助メソッドです。 " "*raw*, *vars* および *fallback* の説明は :meth:`get` を参照してください。" -#: ../../library/configparser.rst:1185 +#: ../../library/configparser.rst:1186 msgid "" "A convenience method which coerces the *option* in the specified *section* " "to a floating-point number. See :meth:`get` for explanation of *raw*, " "*vars* and *fallback*." msgstr "" -#: ../../library/configparser.rst:1192 +#: ../../library/configparser.rst:1193 msgid "" "A convenience method which coerces the *option* in the specified *section* " "to a Boolean value. Note that the accepted values for the option are " @@ -1773,7 +1773,7 @@ msgstr "" "も :exc:`ValueError` を送出します。 *raw*, *vars* および *fallback* の説明" "は :meth:`get` を参照してください。" -#: ../../library/configparser.rst:1205 +#: ../../library/configparser.rst:1206 msgid "" "When *section* is not given, return a list of *section_name*, " "*section_proxy* pairs, including DEFAULTSECT." @@ -1781,7 +1781,7 @@ msgstr "" "*section* が与えられなければ、DEFAULTSECT を含めた *section_name*, " "*section_proxy* の対のリストを返します。" -#: ../../library/configparser.rst:1208 +#: ../../library/configparser.rst:1209 msgid "" "Otherwise, return a list of *name*, *value* pairs for the options in the " "given *section*. Optional arguments have the same meaning as for the :meth:" @@ -1791,7 +1791,7 @@ msgstr "" "ストを返します。オプションの引数は :meth:`get` メソッドに与えるものと同じ意味" "を持ちます。" -#: ../../library/configparser.rst:1212 +#: ../../library/configparser.rst:1213 msgid "" "Items present in *vars* no longer appear in the result. The previous " "behaviour mixed actual parser options with variables provided for " @@ -1800,7 +1800,7 @@ msgstr "" "*vars* に現れる項目は結果に表れなくなりました。以前の挙動は、実際のパーサーオ" "プションを補間のために与えられた変数と混合していました。" -#: ../../library/configparser.rst:1220 +#: ../../library/configparser.rst:1221 msgid "" "If the given section exists, set the given option to the specified value; " "otherwise raise :exc:`NoSectionError`. *option* and *value* must be " @@ -1811,7 +1811,7 @@ msgstr "" "*value* は文字列でなければなりません。そうでなければ :exc:`TypeError` が送出" "されます。" -#: ../../library/configparser.rst:1227 +#: ../../library/configparser.rst:1228 msgid "" "Write a representation of the configuration to the specified :term:`file " "object`, which must be opened in text mode (accepting strings). This " @@ -1824,14 +1824,14 @@ msgstr "" "後で :meth:`read` を呼び出すことでパースできます。 *space_around_delimiters* " "が真なら、キーと値の間のデリミタはスペースで囲まれます。" -#: ../../library/configparser.rst:1235 +#: ../../library/configparser.rst:1236 msgid "" "Comments in the original configuration file are not preserved when writing " "the configuration back. What is considered a comment, depends on the given " "values for *comment_prefix* and *inline_comment_prefix*." msgstr "" -#: ../../library/configparser.rst:1243 +#: ../../library/configparser.rst:1244 msgid "" "Remove the specified *option* from the specified *section*. If the section " "does not exist, raise :exc:`NoSectionError`. If the option existed to be " @@ -1841,7 +1841,7 @@ msgstr "" "なければ、 :exc:`NoSectionError` を送出します。オプションが存在して削除されれ" "ば、 :const:`True` を返します。そうでなければ :const:`False` を返します。" -#: ../../library/configparser.rst:1251 +#: ../../library/configparser.rst:1252 msgid "" "Remove the specified *section* from the configuration. If the section in " "fact existed, return ``True``. Otherwise return ``False``." @@ -1849,7 +1849,7 @@ msgstr "" "指定された *section* を設定から削除します。セクションが実際に存在すれば、" "``True`` を返します。そうでなければ ``False`` を返します。" -#: ../../library/configparser.rst:1257 +#: ../../library/configparser.rst:1258 msgid "" "Transforms the option name *option* as found in an input file or as passed " "in by client code to the form that should be used in the internal " @@ -1863,7 +1863,7 @@ msgstr "" "コードでインスタンス上のこの名前の属性を設定して、この動作に影響を与えること" "ができます。" -#: ../../library/configparser.rst:1263 +#: ../../library/configparser.rst:1264 msgid "" "You don't need to subclass the parser to use this method, you can also set " "it on an instance, to a function that takes a string argument and returns a " @@ -1874,13 +1874,13 @@ msgstr "" "上で、これを文字列引数をとって文字列を返す関数に設定できます。例えば、これを " "``str`` に設定すると、オプション名に大文字小文字の区別をつけられます::" -#: ../../library/configparser.rst:1268 +#: ../../library/configparser.rst:1269 msgid "" "cfgparser = ConfigParser()\n" "cfgparser.optionxform = str" msgstr "" -#: ../../library/configparser.rst:1271 +#: ../../library/configparser.rst:1272 msgid "" "Note that when reading configuration files, whitespace around the option " "names is stripped before :meth:`optionxform` is called." @@ -1888,24 +1888,24 @@ msgstr "" "なお、設定ファイルを読み込むとき、オプション名の周りの空白は :meth:" "`optionxform` が呼び出される前に取り除かれます。" -#: ../../library/configparser.rst:1277 +#: ../../library/configparser.rst:1278 msgid "" "A special object representing a section name used to reference the unnamed " "section (see :ref:`unnamed-sections`)." msgstr "" -#: ../../library/configparser.rst:1282 +#: ../../library/configparser.rst:1283 msgid "" "The maximum depth for recursive interpolation for :meth:`~configparser." "ConfigParser.get` when the *raw* parameter is false. This is relevant only " "when the default *interpolation* is used." msgstr "" -#: ../../library/configparser.rst:1290 +#: ../../library/configparser.rst:1291 msgid "RawConfigParser Objects" msgstr "RawConfigParser オブジェクト" -#: ../../library/configparser.rst:1300 +#: ../../library/configparser.rst:1301 msgid "" "Legacy variant of the :class:`ConfigParser`. It has interpolation disabled " "by default and allows for non-string section names, option names, and values " @@ -1913,7 +1913,7 @@ msgid "" "``defaults=`` keyword argument handling." msgstr "" -#: ../../library/configparser.rst:1310 +#: ../../library/configparser.rst:1311 msgid "" "Consider using :class:`ConfigParser` instead which checks types of the " "values to be stored internally. If you don't want interpolation, you can " @@ -1923,7 +1923,7 @@ msgstr "" "してください。補間を望まない場合、 ``ConfigParser(interpolation=None)`` を使" "用できます。" -#: ../../library/configparser.rst:1317 +#: ../../library/configparser.rst:1318 msgid "" "Add a section named *section* to the instance. If a section by the given " "name already exists, :exc:`DuplicateSectionError` is raised. If the " @@ -1933,7 +1933,7 @@ msgstr "" "クションがすでに存在すれば、 :exc:`DuplicateSectionError` が送出されます。 " "*default section* 名が渡されると、 :exc:`ValueError` が送出されます。" -#: ../../library/configparser.rst:1321 +#: ../../library/configparser.rst:1322 msgid "" "Type of *section* is not checked which lets users create non-string named " "sections. This behaviour is unsupported and may cause internal errors." @@ -1942,7 +1942,7 @@ msgstr "" "ることができます。この振る舞いはサポートされておらず、内部エラーを起こす可能" "性があります。" -#: ../../library/configparser.rst:1327 +#: ../../library/configparser.rst:1328 msgid "" "If the given section exists, set the given option to the specified value; " "otherwise raise :exc:`NoSectionError`. While it is possible to use :class:" @@ -1958,7 +1958,7 @@ msgstr "" "ですが、すべての機能 (置換やファイルへの出力を含む) がサポートされるのは文字" "列を値として使った場合だけです。" -#: ../../library/configparser.rst:1334 +#: ../../library/configparser.rst:1335 msgid "" "This method lets users assign non-string values to keys internally. This " "behaviour is unsupported and will cause errors when attempting to write to a " @@ -1970,32 +1970,32 @@ msgstr "" "みた際にエラーの原因となりえます。このような代入を許さない **マッピングプロ" "トコルAPIを使用してください**。" -#: ../../library/configparser.rst:1341 +#: ../../library/configparser.rst:1342 msgid "Exceptions" msgstr "例外" -#: ../../library/configparser.rst:1345 +#: ../../library/configparser.rst:1346 msgid "Base class for all other :mod:`configparser` exceptions." msgstr "他の全ての :mod:`configparser` 例外の基底クラスです。" -#: ../../library/configparser.rst:1350 +#: ../../library/configparser.rst:1351 msgid "Exception raised when a specified section is not found." msgstr "指定したセクションが見つからなかった時に起きる例外です。" -#: ../../library/configparser.rst:1355 +#: ../../library/configparser.rst:1356 msgid "" "Exception raised if :meth:`~ConfigParser.add_section` is called with the " "name of a section that is already present or in strict parsers when a " "section if found more than once in a single input file, string or dictionary." msgstr "" -#: ../../library/configparser.rst:1359 +#: ../../library/configparser.rst:1360 msgid "" "Added the optional *source* and *lineno* attributes and parameters to :meth:" "`!__init__`." msgstr "" -#: ../../library/configparser.rst:1366 +#: ../../library/configparser.rst:1367 msgid "" "Exception raised by strict parsers if a single option appears twice during " "reading from a single file, string or dictionary. This catches misspellings " @@ -2007,7 +2007,7 @@ msgstr "" "するエラー、例えば辞書の二つのキーが同じ大文字小文字の区別のない設定キーを表" "すこと、を捕捉します。" -#: ../../library/configparser.rst:1374 +#: ../../library/configparser.rst:1375 msgid "" "Exception raised when a specified option is not found in the specified " "section." @@ -2015,13 +2015,13 @@ msgstr "" "指定されたオプションが指定されたセクションに見つからないときに送出される例外" "です。" -#: ../../library/configparser.rst:1380 +#: ../../library/configparser.rst:1381 msgid "" "Base class for exceptions raised when problems occur performing string " "interpolation." msgstr "文字列の補間中に問題が起きた時に発生する例外の基底クラスです。" -#: ../../library/configparser.rst:1386 +#: ../../library/configparser.rst:1387 msgid "" "Exception raised when string interpolation cannot be completed because the " "number of iterations exceeds :const:`MAX_INTERPOLATION_DEPTH`. Subclass of :" @@ -2031,7 +2031,7 @@ msgstr "" "完了しなかったときに送出される例外です。 :exc:`InterpolationError` の派生クラ" "スです。" -#: ../../library/configparser.rst:1393 +#: ../../library/configparser.rst:1394 msgid "" "Exception raised when an option referenced from a value does not exist. " "Subclass of :exc:`InterpolationError`." @@ -2039,7 +2039,7 @@ msgstr "" ":exc:`InterpolationError` の派生クラスで、値が参照しているオプションが見つか" "らない場合に発生する例外です。" -#: ../../library/configparser.rst:1399 +#: ../../library/configparser.rst:1400 msgid "" "Exception raised when the source text into which substitutions are made does " "not conform to the required syntax. Subclass of :exc:`InterpolationError`." @@ -2047,34 +2047,34 @@ msgstr "" "置換がなされるソーステキストが要求された文法を満たさないときに送出される例外" "です。 :exc:`InterpolationError` の派生クラスです。" -#: ../../library/configparser.rst:1405 +#: ../../library/configparser.rst:1406 msgid "" "Exception raised when attempting to parse a file which has no section " "headers." msgstr "" "セクションヘッダを持たないファイルを構文解析しようとした時に起きる例外です。" -#: ../../library/configparser.rst:1411 +#: ../../library/configparser.rst:1412 msgid "Exception raised when errors occur attempting to parse a file." msgstr "ファイルの構文解析中にエラーが起きた場合に発生する例外です。" -#: ../../library/configparser.rst:1413 +#: ../../library/configparser.rst:1414 msgid "" "The ``filename`` attribute and :meth:`!__init__` constructor argument were " "removed. They have been available using the name ``source`` since 3.2." msgstr "" -#: ../../library/configparser.rst:1419 +#: ../../library/configparser.rst:1420 msgid "" "Exception raised when a key without a corresponding value is continued with " "an indented line." msgstr "" -#: ../../library/configparser.rst:1425 +#: ../../library/configparser.rst:1426 msgid "Footnotes" msgstr "脚注" -#: ../../library/configparser.rst:1426 +#: ../../library/configparser.rst:1427 msgid "" "Config parsers allow for heavy customization. If you are interested in " "changing the behaviour outlined by the footnote reference, consult the " @@ -2104,14 +2104,14 @@ msgstr "ini ファイル" msgid "Windows ini file" msgstr "Windows ini ファイル" -#: ../../library/configparser.rst:366 +#: ../../library/configparser.rst:367 msgid "% (percent)" msgstr "% (パーセント)" -#: ../../library/configparser.rst:366 ../../library/configparser.rst:399 +#: ../../library/configparser.rst:367 ../../library/configparser.rst:400 msgid "interpolation in configuration files" msgstr "" -#: ../../library/configparser.rst:399 +#: ../../library/configparser.rst:400 msgid "$ (dollar)" msgstr "$ (ダラー)" diff --git a/library/ctypes.po b/library/ctypes.po index 1745a59b3..e156a8a30 100644 --- a/library/ctypes.po +++ b/library/ctypes.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:03+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -4093,7 +4093,7 @@ msgid "" "attribute to 0 is the same as not setting it at all." msgstr "" -#: ../../library/ctypes.rst:2545 +#: ../../library/ctypes.rst:2547 msgid "" "An optional sequence that lists the names of unnamed (anonymous) fields. :" "attr:`_anonymous_` must be already defined when :attr:`_fields_` is " @@ -4103,7 +4103,7 @@ msgstr "" "`_fields_` が代入されたとき、 :attr:`_anonymous_` がすでに定義されていなけれ" "ばなりません。そうでなければ、何ら影響はありません。" -#: ../../library/ctypes.rst:2549 +#: ../../library/ctypes.rst:2551 msgid "" "The fields listed in this variable must be structure or union type fields. :" "mod:`ctypes` will create descriptors in the structure type that allows " @@ -4115,11 +4115,11 @@ msgstr "" "になったフィールドに直接アクセスできるようにするために、 :mod:`ctypes` は構造" "体型の中に記述子を作成します。" -#: ../../library/ctypes.rst:2554 +#: ../../library/ctypes.rst:2556 msgid "Here is an example type (Windows)::" msgstr "型の例です (Windows)::" -#: ../../library/ctypes.rst:2556 +#: ../../library/ctypes.rst:2558 msgid "" "class _U(Union):\n" " _fields_ = [(\"lptdesc\", POINTER(TYPEDESC)),\n" @@ -4132,7 +4132,7 @@ msgid "" " (\"vt\", VARTYPE)]" msgstr "" -#: ../../library/ctypes.rst:2567 +#: ../../library/ctypes.rst:2569 msgid "" "The ``TYPEDESC`` structure describes a COM data type, the ``vt`` field " "specifies which one of the union fields is valid. Since the ``u`` field is " @@ -4148,7 +4148,7 @@ msgstr "" "者がより高速です。なぜなら一時的な共用体インスタンスを作る必要がないためで" "す。::" -#: ../../library/ctypes.rst:2574 +#: ../../library/ctypes.rst:2576 msgid "" "td = TYPEDESC()\n" "td.vt = VT_PTR\n" @@ -4156,7 +4156,7 @@ msgid "" "td.u.lptdesc = POINTER(some_type)" msgstr "" -#: ../../library/ctypes.rst:2579 +#: ../../library/ctypes.rst:2581 msgid "" "It is possible to define sub-subclasses of structures, they inherit the " "fields of the base class. If the subclass definition has a separate :attr:" @@ -4168,7 +4168,7 @@ msgstr "" "サブクラス定義に別の :attr:`_fields_` 変数がある場合は、この中で指定された" "フィールドは基底クラスのフィールドへ追加されます。" -#: ../../library/ctypes.rst:2584 +#: ../../library/ctypes.rst:2586 msgid "" "Structure and union constructors accept both positional and keyword " "arguments. Positional arguments are used to initialize member fields in the " @@ -4183,15 +4183,15 @@ msgstr "" "解釈され、そのため、同じ名前をもつ :attr:`_fields_` を初期化するか、 :attr:" "`_fields_` に存在しない名前に対しては新しい属性を作ります。" -#: ../../library/ctypes.rst:2595 +#: ../../library/ctypes.rst:2597 msgid "Arrays and pointers" msgstr "配列とポインタ" -#: ../../library/ctypes.rst:2599 +#: ../../library/ctypes.rst:2601 msgid "Abstract base class for arrays." msgstr "配列のための抽象基底クラスです。" -#: ../../library/ctypes.rst:2601 +#: ../../library/ctypes.rst:2603 msgid "" "The recommended way to create concrete array types is by multiplying any :" "mod:`ctypes` data type with a non-negative integer. Alternatively, you can " @@ -4207,7 +4207,7 @@ msgstr "" "す。スライスの読み込みでは、結果のオブジェクト自体は :class:`Array` ではあり" "ません。" -#: ../../library/ctypes.rst:2611 +#: ../../library/ctypes.rst:2613 msgid "" "A positive integer specifying the number of elements in the array. Out-of-" "range subscripts result in an :exc:`IndexError`. Will be returned by :func:" @@ -4216,11 +4216,11 @@ msgstr "" "配列の要素数を指定する正の整数。範囲外の添え字を指定すると、 :exc:" "`IndexError` が送出されます。:func:`len` がこの整数を返します。" -#: ../../library/ctypes.rst:2618 +#: ../../library/ctypes.rst:2620 msgid "Specifies the type of each element in the array." msgstr "配列内の各要素の型を指定します。" -#: ../../library/ctypes.rst:2621 +#: ../../library/ctypes.rst:2623 msgid "" "Array subclass constructors accept positional arguments, used to initialize " "the elements in order." @@ -4228,23 +4228,23 @@ msgstr "" "配列のサブクラスのコンストラクタは、位置引数を受け付けて、配列を順番に初期化" "するために使用します。" -#: ../../library/ctypes.rst:2626 +#: ../../library/ctypes.rst:2628 msgid "" "Create an array. Equivalent to ``type * length``, where *type* is a :mod:" "`ctypes` data type and *length* an integer." msgstr "" -#: ../../library/ctypes.rst:2630 +#: ../../library/ctypes.rst:2632 msgid "" "This function is :term:`soft deprecated` in favor of multiplication. There " "are no plans to remove it." msgstr "" -#: ../../library/ctypes.rst:2636 +#: ../../library/ctypes.rst:2638 msgid "Private, abstract base class for pointers." msgstr "ポインタのためのプライベートな抽象基底クラスです。" -#: ../../library/ctypes.rst:2638 +#: ../../library/ctypes.rst:2640 msgid "" "Concrete pointer types are created by calling :func:`POINTER` with the type " "that will be pointed to; this is done automatically by :func:`pointer`." @@ -4252,7 +4252,7 @@ msgstr "" "具象ポインタ型は、ポイント先の型を持つ :func:`POINTER` を呼び出すことで、作成" "できます。これは、 :func:`pointer` により自動的に行われます。" -#: ../../library/ctypes.rst:2642 +#: ../../library/ctypes.rst:2644 msgid "" "If a pointer points to an array, its elements can be read and written using " "standard subscript and slice accesses. Pointer objects have no size, so :" @@ -4266,11 +4266,11 @@ msgstr "" "様に) ポインタの *前* のメモリから読み込み、範囲外の添え字はおそらく (幸運な" "場合でも) アクセス違反によりクラッシュを起こします。" -#: ../../library/ctypes.rst:2652 +#: ../../library/ctypes.rst:2654 msgid "Specifies the type pointed to." msgstr "ポイント先の型を指定します。" -#: ../../library/ctypes.rst:2656 +#: ../../library/ctypes.rst:2658 msgid "" "Returns the object to which to pointer points. Assigning to this attribute " "changes the pointer to point to the assigned object." diff --git a/library/curses.po b/library/curses.po index 34c7d1601..f833b4ddf 100644 --- a/library/curses.po +++ b/library/curses.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:03+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -55,7 +55,7 @@ msgstr "" "curses ライブラリである ncurses の API に合致するように設計されています。" #: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." +msgid "Availability" msgstr "" #: ../../includes/wasm-mobile-notavail.rst:5 diff --git a/library/datetime.po b/library/datetime.po index fb8e7c774..fe2b77bb4 100644 --- a/library/datetime.po +++ b/library/datetime.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:04+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -499,8 +499,8 @@ msgid "" msgstr "" #: ../../library/datetime.rst:265 ../../library/datetime.rst:566 -#: ../../library/datetime.rst:1122 ../../library/datetime.rst:1760 -#: ../../library/datetime.rst:2365 +#: ../../library/datetime.rst:1126 ../../library/datetime.rst:1764 +#: ../../library/datetime.rst:2369 msgid "Class attributes:" msgstr "以下にクラス属性を示します:" @@ -538,7 +538,7 @@ msgstr "" "現することができません。" #: ../../library/datetime.rst:287 ../../library/datetime.rst:584 -#: ../../library/datetime.rst:1142 ../../library/datetime.rst:1780 +#: ../../library/datetime.rst:1146 ../../library/datetime.rst:1784 msgid "Instance attributes (read-only):" msgstr "インスタンスの属性 (読み出しのみ):" @@ -572,17 +572,17 @@ msgid "Between 0 and 999,999 inclusive." msgstr "" #: ../../library/datetime.rst:318 ../../library/datetime.rst:601 -#: ../../library/datetime.rst:1195 +#: ../../library/datetime.rst:1199 msgid "Supported operations:" msgstr "サポートされている演算を以下に示します:" #: ../../library/datetime.rst:323 ../../library/datetime.rst:604 -#: ../../library/datetime.rst:1198 +#: ../../library/datetime.rst:1202 msgid "Operation" msgstr "演算" #: ../../library/datetime.rst:323 ../../library/datetime.rst:604 -#: ../../library/datetime.rst:1198 +#: ../../library/datetime.rst:1202 msgid "Result" msgstr "結果" @@ -748,7 +748,7 @@ msgstr "" "性値を持つコンストラクタ呼び出しのコードになっています。" #: ../../library/datetime.rst:384 ../../library/datetime.rst:623 -#: ../../library/datetime.rst:2596 +#: ../../library/datetime.rst:2600 msgid "Notes:" msgstr "注釈:" @@ -832,7 +832,7 @@ msgstr "" "``timedelta(0)`` に等しくない場合かつそのときに限り真となります。" #: ../../library/datetime.rst:428 ../../library/datetime.rst:665 -#: ../../library/datetime.rst:1285 ../../library/datetime.rst:1887 +#: ../../library/datetime.rst:1289 ../../library/datetime.rst:1891 msgid "Instance methods:" msgstr "インスタンスメソッド:" @@ -1016,23 +1016,23 @@ msgstr "" "以下の例外を除く、有効な ISO 8601 フォーマットで与えられた *date_string* に対" "応する :class:`date` を返します :" -#: ../../library/datetime.rst:538 ../../library/datetime.rst:1044 +#: ../../library/datetime.rst:538 ../../library/datetime.rst:1048 msgid "" "Reduced precision dates are not currently supported (``YYYY-MM``, ``YYYY``)." msgstr "精度の低い日付は現在サポートされていません(``YYYY-MM``, ``YYYY``)。" -#: ../../library/datetime.rst:540 ../../library/datetime.rst:1046 +#: ../../library/datetime.rst:540 ../../library/datetime.rst:1050 msgid "" "Extended date representations are not currently supported (``±YYYYYY-MM-" "DD``)." msgstr "拡張された日付表現は現在サポートされていません(``±YYYYYY-MM-DD``)。" -#: ../../library/datetime.rst:542 ../../library/datetime.rst:1048 +#: ../../library/datetime.rst:542 ../../library/datetime.rst:1052 msgid "Ordinal dates are not currently supported (``YYYY-OOO``)." msgstr "序数の日付は現在サポートされていません(``YYYY-OOO``)。" -#: ../../library/datetime.rst:544 ../../library/datetime.rst:1050 -#: ../../library/datetime.rst:1516 +#: ../../library/datetime.rst:544 ../../library/datetime.rst:1054 +#: ../../library/datetime.rst:1520 msgid "Examples::" msgstr "例::" @@ -1075,15 +1075,15 @@ msgid "" "``timedelta(days=1)``." msgstr "等しくない日付オブジェクト間の最小の差で、``timedelta(days=1)`` です。" -#: ../../library/datetime.rst:588 ../../library/datetime.rst:1146 +#: ../../library/datetime.rst:588 ../../library/datetime.rst:1150 msgid "Between :const:`MINYEAR` and :const:`MAXYEAR` inclusive." msgstr "両端値を含む :const:`MINYEAR` から :const:`MAXYEAR` までの値です。" -#: ../../library/datetime.rst:593 ../../library/datetime.rst:1151 +#: ../../library/datetime.rst:593 ../../library/datetime.rst:1155 msgid "Between 1 and 12 inclusive." msgstr "両端値を含む 1 から 12 までの値です。" -#: ../../library/datetime.rst:598 ../../library/datetime.rst:1156 +#: ../../library/datetime.rst:598 ../../library/datetime.rst:1160 msgid "Between 1 and the number of days in the given month of the given year." msgstr "1 から与えられた月と年における日数までの値です。" @@ -1108,7 +1108,7 @@ msgstr "" msgid "``timedelta = date1 - date2``" msgstr "``timedelta = date1 - date2``" -#: ../../library/datetime.rst:612 ../../library/datetime.rst:1204 +#: ../../library/datetime.rst:612 ../../library/datetime.rst:1208 msgid "\\(3)" msgstr "\\(3)" @@ -1120,7 +1120,7 @@ msgstr "``date1 == date2``" msgid "``date1 != date2``" msgstr "``date1 != date2``" -#: ../../library/datetime.rst:614 ../../library/datetime.rst:1206 +#: ../../library/datetime.rst:614 ../../library/datetime.rst:1210 msgid "Equality comparison. (4)" msgstr "等価性の比較。(4)" @@ -1140,7 +1140,7 @@ msgstr "``date1 <= date2``" msgid "``date1 >= date2``" msgstr "``date1 >= date2``" -#: ../../library/datetime.rst:617 ../../library/datetime.rst:1209 +#: ../../library/datetime.rst:617 ../../library/datetime.rst:1213 msgid "Order comparison. (5)" msgstr "順序の比較。(5)" @@ -1199,7 +1199,7 @@ msgid "" "datetime` instance and a :class:`!datetime` object raises :exc:`TypeError`." msgstr "" -#: ../../library/datetime.rst:655 ../../library/datetime.rst:1277 +#: ../../library/datetime.rst:655 ../../library/datetime.rst:1281 msgid "" "Comparison between :class:`.datetime` object and an instance of the :class:" "`date` subclass that is not a :class:`!datetime` subclass no longer converts " @@ -1223,7 +1223,7 @@ msgstr "" "キーワード引数で指定されたパラメータが置き換えられることを除き、同じ値を持" "つ :class:`date` オブジェクトを返します。" -#: ../../library/datetime.rst:672 ../../library/datetime.rst:1933 +#: ../../library/datetime.rst:672 ../../library/datetime.rst:1937 msgid "Example::" msgstr "以下はプログラム例です::" @@ -1243,7 +1243,7 @@ msgstr "" ":class:`date` オブジェクトは汎用的な関数 :func:`copy.replace` にもサポートさ" "れています。" -#: ../../library/datetime.rst:685 ../../library/datetime.rst:1401 +#: ../../library/datetime.rst:685 ../../library/datetime.rst:1405 msgid "" "Return a :class:`time.struct_time` such as returned by :func:`time." "localtime`." @@ -1254,7 +1254,7 @@ msgstr "" msgid "The hours, minutes and seconds are 0, and the DST flag is -1." msgstr "時分秒が 0 で、 DST フラグが -1 です。" -#: ../../library/datetime.rst:689 ../../library/datetime.rst:1403 +#: ../../library/datetime.rst:689 ../../library/datetime.rst:1407 msgid "``d.timetuple()`` is equivalent to::" msgstr "``d.timetuple()`` は次の式と等価です::" @@ -1377,11 +1377,11 @@ msgid "" "'Wed Dec 4 00:00:00 2002'" msgstr "" -#: ../../library/datetime.rst:763 ../../library/datetime.rst:1587 +#: ../../library/datetime.rst:763 ../../library/datetime.rst:1591 msgid "``d.ctime()`` is equivalent to::" msgstr "``d.ctime()`` は次の式と等価です::" -#: ../../library/datetime.rst:765 ../../library/datetime.rst:1589 +#: ../../library/datetime.rst:765 ../../library/datetime.rst:1593 msgid "time.ctime(time.mktime(d.timetuple()))" msgstr "" @@ -1546,28 +1546,28 @@ msgstr "``1 <= month <= 12``," msgid "``1 <= day <= number of days in the given month and year``," msgstr "``1 <= day <= 指定された月と年における日数``," -#: ../../library/datetime.rst:877 ../../library/datetime.rst:1751 +#: ../../library/datetime.rst:877 ../../library/datetime.rst:1755 msgid "``0 <= hour < 24``," msgstr "``0 <= hour < 24``," -#: ../../library/datetime.rst:878 ../../library/datetime.rst:1752 +#: ../../library/datetime.rst:878 ../../library/datetime.rst:1756 msgid "``0 <= minute < 60``," msgstr "``0 <= minute < 60``," -#: ../../library/datetime.rst:879 ../../library/datetime.rst:1753 +#: ../../library/datetime.rst:879 ../../library/datetime.rst:1757 msgid "``0 <= second < 60``," msgstr "``0 <= second < 60``," -#: ../../library/datetime.rst:880 ../../library/datetime.rst:1754 +#: ../../library/datetime.rst:880 ../../library/datetime.rst:1758 msgid "``0 <= microsecond < 1000000``," msgstr "``0 <= microsecond < 1000000``," -#: ../../library/datetime.rst:881 ../../library/datetime.rst:1755 +#: ../../library/datetime.rst:881 ../../library/datetime.rst:1759 msgid "``fold in [0, 1]``." msgstr "``fold in [0, 1]``." -#: ../../library/datetime.rst:885 ../../library/datetime.rst:1322 -#: ../../library/datetime.rst:1900 +#: ../../library/datetime.rst:885 ../../library/datetime.rst:1326 +#: ../../library/datetime.rst:1904 msgid "Added the *fold* parameter." msgstr "*fold* パラメータが追加されました。" @@ -1626,12 +1626,18 @@ msgid "This function is preferred over :meth:`today` and :meth:`utcnow`." msgstr "" ":meth:`today` および :meth:`utcnow` よりもこの関数を使う方が好ましいです。" -#: ../../library/datetime.rst:921 +#: ../../library/datetime.rst:920 +msgid "" +"Subsequent calls to :meth:`!datetime.now` may return the same instant " +"depending on the precision of the underlying clock." +msgstr "" + +#: ../../library/datetime.rst:925 msgid "Return the current UTC date and time, with :attr:`.tzinfo` ``None``." msgstr "" ":attr:`tzinfo` が ``None`` である現在の UTC の日付および時刻を返します。" -#: ../../library/datetime.rst:923 +#: ../../library/datetime.rst:927 msgid "" "This is like :meth:`now`, but returns the current UTC date and time, as a " "naive :class:`.datetime` object. An aware current UTC datetime can be " @@ -1643,7 +1649,7 @@ msgstr "" "で取得できます。\n" ":meth:`now` も参照してください。" -#: ../../library/datetime.rst:929 +#: ../../library/datetime.rst:933 msgid "" "Because naive ``datetime`` objects are treated by many ``datetime`` methods " "as local times, it is preferred to use aware datetimes to represent times in " @@ -1656,11 +1662,11 @@ msgstr "" "そのため、 UTC での現在の時刻を表すオブジェクトの作成では ``datetime." "now(timezone.utc)`` を呼び出す方法が推奨されます。" -#: ../../library/datetime.rst:936 +#: ../../library/datetime.rst:940 msgid "Use :meth:`datetime.now` with :attr:`UTC` instead." msgstr "代わりに :attr:`UTC` で :meth:`datetime.now` を使用してください。" -#: ../../library/datetime.rst:941 +#: ../../library/datetime.rst:945 msgid "" "Return the local date and time corresponding to the POSIX timestamp, such as " "is returned by :func:`time.time`. If optional argument *tz* is ``None`` or " @@ -1672,7 +1678,7 @@ msgstr "" "い場合、タイムスタンプはプラットフォームのローカルな日付および時刻に変換さ" "れ、返される :class:`.datetime` オブジェクトは naive なものになります。" -#: ../../library/datetime.rst:946 +#: ../../library/datetime.rst:950 msgid "" "If *tz* is not ``None``, it must be an instance of a :class:`tzinfo` " "subclass, and the timestamp is converted to *tz*’s time zone." @@ -1680,7 +1686,7 @@ msgstr "" "*tz* が ``None`` でない場合、 *tz* は :class:`tzinfo` のサブクラスのインスタ" "ンスでなければならず、タイムスタンプは *tz* のタイムゾーンに変換されます。" -#: ../../library/datetime.rst:949 +#: ../../library/datetime.rst:953 msgid "" ":meth:`fromtimestamp` may raise :exc:`OverflowError`, if the timestamp is " "out of the range of values supported by the platform C :c:func:`localtime` " @@ -1704,7 +1710,7 @@ msgstr "" "クトとなることが起こり得ます。\n" ":meth:`utcfromtimestamp` よりも、このメソッドの方が好ましいです。" -#: ../../library/datetime.rst:960 +#: ../../library/datetime.rst:964 msgid "" "Raise :exc:`OverflowError` instead of :exc:`ValueError` if the timestamp is " "out of the range of values supported by the platform C :c:func:`localtime` " @@ -1717,12 +1723,12 @@ msgstr "" "くは :c:func:`gmtime` の呼び出し失敗で :exc:`ValueError` ではなく :exc:" "`OSError` を送出するようになりました。" -#: ../../library/datetime.rst:967 +#: ../../library/datetime.rst:971 msgid ":meth:`fromtimestamp` may return instances with :attr:`.fold` set to 1." msgstr "" ":meth:`fromtimestamp` は :attr:`.fold` を1にしてインスタンスを返します。" -#: ../../library/datetime.rst:972 +#: ../../library/datetime.rst:976 msgid "" "Return the UTC :class:`.datetime` corresponding to the POSIX timestamp, " "with :attr:`.tzinfo` ``None``. (The resulting object is naive.)" @@ -1730,7 +1736,7 @@ msgstr "" "POSIX タイムスタンプに対応する、:attr:`tzinfo` が ``None`` の UTC での :" "class:`.datetime` を返します。(返されるオブジェクトは naive です。)" -#: ../../library/datetime.rst:975 +#: ../../library/datetime.rst:979 msgid "" "This may raise :exc:`OverflowError`, if the timestamp is out of the range of " "values supported by the platform C :c:func:`gmtime` function, and :exc:" @@ -1742,28 +1748,28 @@ msgstr "" "`gmtime` が失敗した場合には :exc:`OSError` を送出します。\n" "これはたいてい 1970 年から 2038 年に制限されています。" -#: ../../library/datetime.rst:980 +#: ../../library/datetime.rst:984 msgid "To get an aware :class:`.datetime` object, call :meth:`fromtimestamp`::" msgstr "" "aware な :class:`.datetime` オブジェクトを得るには :meth:`fromtimestamp` を呼" "んでください::" -#: ../../library/datetime.rst:982 +#: ../../library/datetime.rst:986 msgid "datetime.fromtimestamp(timestamp, timezone.utc)" msgstr "" -#: ../../library/datetime.rst:984 +#: ../../library/datetime.rst:988 msgid "" "On the POSIX compliant platforms, it is equivalent to the following " "expression::" msgstr "POSIX 互換プラットフォームでは、これは以下の表現と等価です::" -#: ../../library/datetime.rst:987 +#: ../../library/datetime.rst:991 msgid "" "datetime(1970, 1, 1, tzinfo=timezone.utc) + timedelta(seconds=timestamp)" msgstr "" -#: ../../library/datetime.rst:989 +#: ../../library/datetime.rst:993 msgid "" "except the latter formula always supports the full years range: between :" "const:`MINYEAR` and :const:`MAXYEAR` inclusive." @@ -1771,7 +1777,7 @@ msgstr "" "後者を除き、式は常に年の全範囲 (:const:`MINYEAR` から :const:`MAXYEAR` を含み" "ます) をサポートします。" -#: ../../library/datetime.rst:994 +#: ../../library/datetime.rst:998 msgid "" "Because naive ``datetime`` objects are treated by many ``datetime`` methods " "as local times, it is preferred to use aware datetimes to represent times in " @@ -1786,7 +1792,7 @@ msgstr "" "``datetime.fromtimestamp(timestamp, tz=timezone.utc)`` を呼び出す方法が推奨さ" "れます。" -#: ../../library/datetime.rst:1000 +#: ../../library/datetime.rst:1004 msgid "" "Raise :exc:`OverflowError` instead of :exc:`ValueError` if the timestamp is " "out of the range of values supported by the platform C :c:func:`gmtime` " @@ -1798,12 +1804,12 @@ msgstr "" "るようになりました。 :c:func:`gmtime` の呼び出し失敗で :exc:`ValueError` では" "なく :exc:`OSError` を送出するようになりました。" -#: ../../library/datetime.rst:1008 +#: ../../library/datetime.rst:1012 msgid "Use :meth:`datetime.fromtimestamp` with :attr:`UTC` instead." msgstr "" "代わりに :attr:`UTC` で :meth:`datetime.fromtimestamp` を使用してください。" -#: ../../library/datetime.rst:1013 +#: ../../library/datetime.rst:1017 msgid "" "Return the :class:`.datetime` corresponding to the proleptic Gregorian " "ordinal, where January 1 of year 1 has ordinal 1. :exc:`ValueError` is " @@ -1818,7 +1824,7 @@ msgstr "" "返されるオブジェクトの時間、分、秒、およびマイクロ秒はすべて 0 で、 :attr:" "`tzinfo` は ``None`` となっています。" -#: ../../library/datetime.rst:1021 +#: ../../library/datetime.rst:1025 msgid "" "Return a new :class:`.datetime` object whose date components are equal to " "the given :class:`date` object's, and whose time components are equal to the " @@ -1836,7 +1842,7 @@ msgstr "" "使われます。*date* 引数に :class:`.datetime` オブジェクトが与えられた場合、そ" "の時刻部分と :attr:`.tzinfo` 属性は無視されます。" -#: ../../library/datetime.rst:1029 +#: ../../library/datetime.rst:1033 msgid "" "For any :class:`.datetime` object *d*, ``d == datetime.combine(d.date(), d." "time(), d.tzinfo)``." @@ -1844,11 +1850,11 @@ msgstr "" "任意の :class:`.datetime` オブジェクト *d* に対して、``d == datetime." "combine(d.date(), d.time(), d.tzinfo)`` となります。" -#: ../../library/datetime.rst:1032 +#: ../../library/datetime.rst:1036 msgid "Added the *tzinfo* argument." msgstr "*tzinfo* 引数が追加されました。" -#: ../../library/datetime.rst:1038 +#: ../../library/datetime.rst:1042 msgid "" "Return a :class:`.datetime` corresponding to a *date_string* in any valid " "ISO 8601 format, with the following exceptions:" @@ -1856,19 +1862,19 @@ msgstr "" "以下の例外を除く、有効な ISO 8601 フォーマットで与えられた *date_string* に対" "応する :class:`.datetime` を返します :" -#: ../../library/datetime.rst:1041 ../../library/datetime.rst:1851 +#: ../../library/datetime.rst:1045 ../../library/datetime.rst:1855 msgid "Time zone offsets may have fractional seconds." msgstr "小数の秒があるタイムゾーンオフセット。" -#: ../../library/datetime.rst:1042 +#: ../../library/datetime.rst:1046 msgid "The ``T`` separator may be replaced by any single unicode character." msgstr "``T`` セパレーターを他の1文字のユニコードに置き換えたもの。" -#: ../../library/datetime.rst:1043 ../../library/datetime.rst:1856 +#: ../../library/datetime.rst:1047 ../../library/datetime.rst:1860 msgid "Fractional hours and minutes are not supported." msgstr "少数の時と分はサポートされていません。" -#: ../../library/datetime.rst:1052 +#: ../../library/datetime.rst:1056 msgid "" ">>> from datetime import datetime\n" ">>> datetime.fromisoformat('2011-11-04')\n" @@ -1893,13 +1899,13 @@ msgid "" " tzinfo=datetime.timezone(datetime.timedelta(seconds=14400)))" msgstr "" -#: ../../library/datetime.rst:1074 +#: ../../library/datetime.rst:1078 msgid "" "Previously, this method only supported formats that could be emitted by :" "meth:`date.isoformat` or :meth:`datetime.isoformat`." msgstr "" -#: ../../library/datetime.rst:1081 +#: ../../library/datetime.rst:1085 msgid "" "Return a :class:`.datetime` corresponding to the ISO calendar date specified " "by year, week and day. The non-date components of the datetime are populated " @@ -1910,7 +1916,7 @@ msgstr "" "datetime の日付でない部分は、標準のデフォルト値で埋められます。\n" "この関数は :meth:`datetime.isocalendar` の逆関数です。" -#: ../../library/datetime.rst:1090 +#: ../../library/datetime.rst:1094 msgid "" "Return a :class:`.datetime` corresponding to *date_string*, parsed according " "to *format*." @@ -1918,18 +1924,18 @@ msgstr "" "*date_string* に対応した :class:`.datetime` を返します。 *format* にしたがっ" "て構文解析されます。" -#: ../../library/datetime.rst:1093 +#: ../../library/datetime.rst:1097 msgid "" "If *format* does not contain microseconds or time zone information, this is " "equivalent to::" msgstr "" "*format* がマイクロ秒やタイムゾーン情報を含まない場合は、以下と等価です::" -#: ../../library/datetime.rst:1095 ../../library/datetime.rst:2576 +#: ../../library/datetime.rst:1099 ../../library/datetime.rst:2580 msgid "datetime(*(time.strptime(date_string, format)[0:6]))" msgstr "" -#: ../../library/datetime.rst:1097 +#: ../../library/datetime.rst:1101 msgid "" ":exc:`ValueError` is raised if the date_string and format can't be parsed " "by :func:`time.strptime` or if it returns a value which isn't a time tuple. " @@ -1941,7 +1947,7 @@ msgstr "" "`strftime-strptime-behavior` および :meth:`datetime.fromisoformat` も参照して" "ください。" -#: ../../library/datetime.rst:1104 +#: ../../library/datetime.rst:1108 msgid "" "If *format* specifies a day of month without a year a :exc:" "`DeprecationWarning` is now emitted. This is to avoid a quadrennial leap " @@ -1952,7 +1958,7 @@ msgid "" "not have a year, explicitly add a year that is a leap year before parsing:" msgstr "" -#: ../../library/datetime.rst:1113 +#: ../../library/datetime.rst:1117 msgid "" ">>> from datetime import datetime\n" ">>> date_string = \"02/29\"\n" @@ -1962,7 +1968,7 @@ msgid "" "'February 29'" msgstr "" -#: ../../library/datetime.rst:1126 +#: ../../library/datetime.rst:1130 msgid "" "The earliest representable :class:`.datetime`, ``datetime(MINYEAR, 1, 1, " "tzinfo=None)``." @@ -1970,7 +1976,7 @@ msgstr "" "表現できる最も古い :class:`.datetime` で、 ``datetime(MINYEAR, 1, 1, " "tzinfo=None)`` です。" -#: ../../library/datetime.rst:1132 +#: ../../library/datetime.rst:1136 msgid "" "The latest representable :class:`.datetime`, ``datetime(MAXYEAR, 12, 31, 23, " "59, 59, 999999, tzinfo=None)``." @@ -1978,7 +1984,7 @@ msgstr "" "表現できる最も新しい :class:`.datetime` で、 ``datetime(MAXYEAR, 12, 31, 23, " "59, 59, 999999, tzinfo=None)`` です。" -#: ../../library/datetime.rst:1138 +#: ../../library/datetime.rst:1142 msgid "" "The smallest possible difference between non-equal :class:`.datetime` " "objects, ``timedelta(microseconds=1)``." @@ -1986,20 +1992,20 @@ msgstr "" "等しくない :class:`.datetime` オブジェクト間の最小の差で、 " "``timedelta(microseconds=1)`` です。" -#: ../../library/datetime.rst:1161 ../../library/datetime.rst:1784 +#: ../../library/datetime.rst:1165 ../../library/datetime.rst:1788 msgid "In ``range(24)``." msgstr "in ``range(24)`` を満たします。" -#: ../../library/datetime.rst:1166 ../../library/datetime.rst:1171 -#: ../../library/datetime.rst:1789 ../../library/datetime.rst:1794 +#: ../../library/datetime.rst:1170 ../../library/datetime.rst:1175 +#: ../../library/datetime.rst:1793 ../../library/datetime.rst:1798 msgid "In ``range(60)``." msgstr "in ``range(60)`` を満たします。" -#: ../../library/datetime.rst:1176 ../../library/datetime.rst:1799 +#: ../../library/datetime.rst:1180 ../../library/datetime.rst:1803 msgid "In ``range(1000000)``." msgstr "in ``range(1000000)`` を満たします。" -#: ../../library/datetime.rst:1181 +#: ../../library/datetime.rst:1185 msgid "" "The object passed as the *tzinfo* argument to the :class:`.datetime` " "constructor, or ``None`` if none was passed." @@ -2007,7 +2013,7 @@ msgstr "" ":class:`.datetime` コンストラクタに *tzinfo* 引数として与えられたオブジェクト" "になり、何も渡されなかった場合には ``None`` になります。" -#: ../../library/datetime.rst:1187 ../../library/datetime.rst:1810 +#: ../../library/datetime.rst:1191 ../../library/datetime.rst:1814 msgid "" "In ``[0, 1]``. Used to disambiguate wall times during a repeated interval. " "(A repeated interval occurs when clocks are rolled back at the end of " @@ -2023,26 +2029,26 @@ msgstr "" "0または1という値は、同じ実時間で表現される 2 つの時刻のうちのそれぞれ早い方ま" "たは遅い方を表します。" -#: ../../library/datetime.rst:1200 +#: ../../library/datetime.rst:1204 msgid "``datetime2 = datetime1 + timedelta``" msgstr "``datetime2 = datetime1 + timedelta``" -#: ../../library/datetime.rst:1200 ../../library/datetime.rst:2423 -#: ../../library/datetime.rst:2428 ../../library/datetime.rst:2440 -#: ../../library/datetime.rst:2445 ../../library/datetime.rst:2505 -#: ../../library/datetime.rst:2510 ../../library/datetime.rst:2514 +#: ../../library/datetime.rst:1204 ../../library/datetime.rst:2427 +#: ../../library/datetime.rst:2432 ../../library/datetime.rst:2444 +#: ../../library/datetime.rst:2449 ../../library/datetime.rst:2509 +#: ../../library/datetime.rst:2514 ../../library/datetime.rst:2518 msgid "\\(1)" msgstr "\\(1)" -#: ../../library/datetime.rst:1202 +#: ../../library/datetime.rst:1206 msgid "``datetime2 = datetime1 - timedelta``" msgstr "``datetime2 = datetime1 - timedelta``" -#: ../../library/datetime.rst:1202 ../../library/datetime.rst:2456 +#: ../../library/datetime.rst:1206 ../../library/datetime.rst:2460 msgid "\\(2)" msgstr "\\(2)" -#: ../../library/datetime.rst:1204 +#: ../../library/datetime.rst:1208 msgid "``timedelta = datetime1 - datetime2``" msgstr "``timedelta = datetime1 - datetime2``" @@ -2070,7 +2076,7 @@ msgstr "``datetime1 <= datetime2``" msgid "``datetime1 >= datetime2``" msgstr "``datetime1 >= datetime2``" -#: ../../library/datetime.rst:1216 +#: ../../library/datetime.rst:1220 msgid "" "``datetime2`` is a duration of ``timedelta`` removed from ``datetime1``, " "moving forward in time if ``timedelta.days > 0``, or backward if ``timedelta." @@ -2089,7 +2095,7 @@ msgstr "" "大きい場合には :exc:`OverflowError` が送出されます。\n" "入力が aware なオブジェクトの場合でもタイムゾーン修正は全く行われません。" -#: ../../library/datetime.rst:1225 +#: ../../library/datetime.rst:1229 msgid "" "Computes the ``datetime2`` such that ``datetime2 + timedelta == datetime1``. " "As for addition, the result has the same :attr:`~.datetime.tzinfo` attribute " @@ -2101,7 +2107,7 @@ msgstr "" "ちなみに、結果は入力の datetime と同じ :attr:`~.datetime.tzinfo` 属性を持ち、" "入力が aware だとしてもタイムゾーン修正は全く行われません。" -#: ../../library/datetime.rst:1230 +#: ../../library/datetime.rst:1234 msgid "" "Subtraction of a :class:`.datetime` from a :class:`.datetime` is defined " "only if both operands are naive, or if both are aware. If one is aware and " @@ -2111,7 +2117,7 @@ msgstr "" "あるか、両方とも aware である場合にのみ定義されています。片方が aware でもう" "一方が naive の場合、 :exc:`TypeError` が送出されます。" -#: ../../library/datetime.rst:1234 +#: ../../library/datetime.rst:1238 msgid "" "If both are naive, or both are aware and have the same :attr:`~.datetime." "tzinfo` attribute, the :attr:`~.datetime.tzinfo` attributes are ignored, and " @@ -2123,7 +2129,7 @@ msgstr "" "datetime1`` であるような :class:`timedelta` オブジェクト *t* となります。\n" "この場合タイムゾーン修正は全く行われません。" -#: ../../library/datetime.rst:1239 +#: ../../library/datetime.rst:1243 msgid "" "If both are aware and have different :attr:`~.datetime.tzinfo` attributes, " "``a-b`` acts as if *a* and *b* were first converted to naive UTC datetimes. " @@ -2138,7 +2144,7 @@ msgstr "" "replace(tzinfo=None) - a.utcoffset()) - (b.replace(tzinfo=None) - b." "utcoffset())`` と同じになります。" -#: ../../library/datetime.rst:1245 +#: ../../library/datetime.rst:1249 msgid "" ":class:`.datetime` objects are equal if they represent the same date and " "time, taking into account the time zone." @@ -2146,11 +2152,11 @@ msgstr "" ":class:`.datetime` オブジェクトはタイムゾーンを考慮して同じ日付と時刻を表す場" "合、等しいです。" -#: ../../library/datetime.rst:1248 +#: ../../library/datetime.rst:1252 msgid "Naive and aware :class:`!datetime` objects are never equal." msgstr "" -#: ../../library/datetime.rst:1250 +#: ../../library/datetime.rst:1254 msgid "" "If both comparands are aware, and have the same :attr:`!tzinfo` attribute, " "the :attr:`!tzinfo` and :attr:`~.datetime.fold` attributes are ignored and " @@ -2161,7 +2167,7 @@ msgid "" "interval are never equal to :class:`!datetime` instances in other time zone." msgstr "" -#: ../../library/datetime.rst:1260 +#: ../../library/datetime.rst:1264 msgid "" "*datetime1* is considered less than *datetime2* when *datetime1* precedes " "*datetime2* in time, taking into account the time zone." @@ -2169,13 +2175,13 @@ msgstr "" "タイムゾーンを考慮して、*datetime1* が時刻として *datetime2* よりも前を表す場" "合に、*datetime1* は *datetime2* よりも小さいと見なされます。" -#: ../../library/datetime.rst:1263 +#: ../../library/datetime.rst:1267 msgid "" "Order comparison between naive and aware :class:`.datetime` objects raises :" "exc:`TypeError`." msgstr "" -#: ../../library/datetime.rst:1266 +#: ../../library/datetime.rst:1270 msgid "" "If both comparands are aware, and have the same :attr:`!tzinfo` attribute, " "the :attr:`!tzinfo` and :attr:`~.datetime.fold` attributes are ignored and " @@ -2185,7 +2191,7 @@ msgid "" "implementation never overflows." msgstr "" -#: ../../library/datetime.rst:1273 +#: ../../library/datetime.rst:1277 msgid "" "Equality comparisons between aware and naive :class:`.datetime` instances " "don't raise :exc:`TypeError`." @@ -2193,11 +2199,11 @@ msgstr "" "aware な :class:`datetime` インスタンスと naive な :class:`datetime` インスタ" "ンスの等価比較では :exc:`TypeError` は送出されません。" -#: ../../library/datetime.rst:1289 +#: ../../library/datetime.rst:1293 msgid "Return :class:`date` object with same year, month and day." msgstr "同じ年、月、日の :class:`date` オブジェクトを返します。" -#: ../../library/datetime.rst:1294 +#: ../../library/datetime.rst:1298 msgid "" "Return :class:`.time` object with same hour, minute, second, microsecond and " "fold. :attr:`.tzinfo` is ``None``. See also method :meth:`timetz`." @@ -2206,11 +2212,11 @@ msgstr "" "クトを返します。 :attr:`.tzinfo` は ``None`` です。 :meth:`timetz` も参照して" "ください。" -#: ../../library/datetime.rst:1297 ../../library/datetime.rst:1306 +#: ../../library/datetime.rst:1301 ../../library/datetime.rst:1310 msgid "The fold value is copied to the returned :class:`.time` object." msgstr "値 foldは返される :class:`.time` オブジェクトにコピーされます。" -#: ../../library/datetime.rst:1303 +#: ../../library/datetime.rst:1307 msgid "" "Return :class:`.time` object with same hour, minute, second, microsecond, " "fold, and tzinfo attributes. See also method :meth:`time`." @@ -2218,7 +2224,7 @@ msgstr "" "同じhour、minute、second、microsecond、fold および tzinfo 属性を持つ :class:" "`.time` オブジェクトを返します。 :meth:`time` メソッドも参照してください。" -#: ../../library/datetime.rst:1314 +#: ../../library/datetime.rst:1318 msgid "" "Return a datetime with the same attributes, except for those attributes " "given new values by whichever keyword arguments are specified. Note that " @@ -2230,7 +2236,7 @@ msgstr "" "naive な datetime オブジェクトを生成するために、``tzinfo=None`` を指定するこ" "ともできます。" -#: ../../library/datetime.rst:1319 +#: ../../library/datetime.rst:1323 msgid "" ":class:`.datetime` objects are also supported by generic function :func:" "`copy.replace`." @@ -2238,7 +2244,7 @@ msgstr "" ":class:`.datetime` オブジェクトは汎用的な関数 :func:`copy.replace` にもサポー" "トされています。" -#: ../../library/datetime.rst:1328 +#: ../../library/datetime.rst:1332 msgid "" "Return a :class:`.datetime` object with new :attr:`.tzinfo` attribute *tz*, " "adjusting the date and time data so the result is the same UTC time as " @@ -2249,7 +2255,7 @@ msgstr "" "日付および時刻データを調整して、返り値が *self* と同じ UTC 時刻を持ち、 *tz* " "におけるローカルな時刻を表すようにします。" -#: ../../library/datetime.rst:1332 +#: ../../library/datetime.rst:1336 msgid "" "If provided, *tz* must be an instance of a :class:`tzinfo` subclass, and " "its :meth:`utcoffset` and :meth:`dst` methods must not return ``None``. If " @@ -2260,7 +2266,7 @@ msgstr "" "``None`` を返してはなりません。もし *self* が naive ならば、おそらくシステム" "のタイムゾーンで時間を表現します。" -#: ../../library/datetime.rst:1336 +#: ../../library/datetime.rst:1340 msgid "" "If called without arguments (or with ``tz=None``) the system local time zone " "is assumed for the target time zone. The ``.tzinfo`` attribute of the " @@ -2272,7 +2278,7 @@ msgstr "" "変換後の datetime インスタンスの ``.tzinfo`` 属性には、 OS から取得したゾーン" "名とオフセットを持つ :class:`timezone` インスタンスが設定されます。" -#: ../../library/datetime.rst:1341 +#: ../../library/datetime.rst:1345 msgid "" "If ``self.tzinfo`` is *tz*, ``self.astimezone(tz)`` is equal to *self*: no " "adjustment of date or time data is performed. Else the result is local time " @@ -2287,7 +2293,7 @@ msgstr "" "astz.utcoffset()`` は通常 ``dt - dt.utcoffset()`` と同じ date および time を" "持つことを示します。" -#: ../../library/datetime.rst:1347 +#: ../../library/datetime.rst:1351 msgid "" "If you merely want to attach a :class:`timezone` object *tz* to a datetime " "*dt* without adjustment of date and time data, use ``dt." @@ -2302,7 +2308,7 @@ msgstr "" "時刻データの変換を行わないのなら、``dt.replace(tzinfo=None)`` を使ってくださ" "い。" -#: ../../library/datetime.rst:1352 +#: ../../library/datetime.rst:1356 msgid "" "Note that the default :meth:`tzinfo.fromutc` method can be overridden in a :" "class:`tzinfo` subclass to affect the result returned by :meth:`astimezone`. " @@ -2312,7 +2318,7 @@ msgstr "" "上書きして, :meth:`astimezone` が返す結果に影響を及ぼすことができます。エラー" "の場合を無視すると、 :meth:`astimezone` は以下のように動作します::" -#: ../../library/datetime.rst:1356 +#: ../../library/datetime.rst:1360 msgid "" "def astimezone(self, tz):\n" " if self.tzinfo is tz:\n" @@ -2323,11 +2329,11 @@ msgid "" " return tz.fromutc(utc)" msgstr "" -#: ../../library/datetime.rst:1364 +#: ../../library/datetime.rst:1368 msgid "*tz* now can be omitted." msgstr "*tz* が省略可能になりました。" -#: ../../library/datetime.rst:1367 +#: ../../library/datetime.rst:1371 msgid "" "The :meth:`astimezone` method can now be called on naive instances that are " "presumed to represent system local time." @@ -2336,7 +2342,7 @@ msgstr "" "呼び出せるようになりました。これは、システムのローカルな時間を表現していると" "想定されます。" -#: ../../library/datetime.rst:1374 +#: ../../library/datetime.rst:1378 msgid "" "If :attr:`.tzinfo` is ``None``, returns ``None``, else returns ``self.tzinfo." "utcoffset(self)``, and raises an exception if the latter doesn't return " @@ -2347,13 +2353,13 @@ msgstr "" "後者の式が ``None`` あるいは 1 日以下の大きさを持つ :class:`timedelta` オブ" "ジェクトのいずれかを返さない場合には例外を送出します。" -#: ../../library/datetime.rst:1378 ../../library/datetime.rst:1973 -#: ../../library/datetime.rst:2080 ../../library/datetime.rst:2325 -#: ../../library/datetime.rst:2337 ../../library/datetime.rst:2649 +#: ../../library/datetime.rst:1382 ../../library/datetime.rst:1977 +#: ../../library/datetime.rst:2084 ../../library/datetime.rst:2329 +#: ../../library/datetime.rst:2341 ../../library/datetime.rst:2653 msgid "The UTC offset is not restricted to a whole number of minutes." msgstr "UTC オフセットが分単位でなければならない制限が無くなりました。" -#: ../../library/datetime.rst:1384 +#: ../../library/datetime.rst:1388 msgid "" "If :attr:`.tzinfo` is ``None``, returns ``None``, else returns ``self.tzinfo." "dst(self)``, and raises an exception if the latter doesn't return ``None`` " @@ -2364,12 +2370,12 @@ msgstr "" "後者の式が ``None`` もしくは、1 日未満の大きさを持つ :class:`timedelta` オブ" "ジェクトのいずれかを返さない場合には例外を送出します。" -#: ../../library/datetime.rst:1388 ../../library/datetime.rst:1983 -#: ../../library/datetime.rst:2134 +#: ../../library/datetime.rst:1392 ../../library/datetime.rst:1987 +#: ../../library/datetime.rst:2138 msgid "The DST offset is not restricted to a whole number of minutes." msgstr "DST オフセットが分単位でなければならない制限が無くなりました。" -#: ../../library/datetime.rst:1394 +#: ../../library/datetime.rst:1398 msgid "" "If :attr:`.tzinfo` is ``None``, returns ``None``, else returns ``self.tzinfo." "tzname(self)``, raises an exception if the latter doesn't return ``None`` or " @@ -2380,14 +2386,14 @@ msgstr "" "後者の式が ``None`` か文字列オブジェクトのいずれかを返さない場合には例外を送" "出します。" -#: ../../library/datetime.rst:1405 +#: ../../library/datetime.rst:1409 msgid "" "time.struct_time((d.year, d.month, d.day,\n" " d.hour, d.minute, d.second,\n" " d.weekday(), yday, dst))" msgstr "" -#: ../../library/datetime.rst:1409 +#: ../../library/datetime.rst:1413 msgid "" "where ``yday = d.toordinal() - date(d.year, 1, 1).toordinal() + 1`` is the " "day number within the current year starting with 1 for January 1st. The :" @@ -2405,7 +2411,7 @@ msgstr "" "場合、 :meth:`dst` がゼロでない値を返すと :attr:`!tm_isdst` は1となります; そ" "れ以外の場合には :attr:`!tm_isdst` は0に設定されます。" -#: ../../library/datetime.rst:1420 +#: ../../library/datetime.rst:1424 msgid "" "If :class:`.datetime` instance *d* is naive, this is the same as ``d." "timetuple()`` except that :attr:`~.time.struct_time.tm_isdst` is forced to 0 " @@ -2417,7 +2423,7 @@ msgstr "" "time.struct_time.tm_isdst` が 0 に強制される点だけが異なります。 DST が UTC " "時刻に影響を及ぼすことは決してありません。" -#: ../../library/datetime.rst:1424 +#: ../../library/datetime.rst:1428 msgid "" "If *d* is aware, *d* is normalized to UTC time, by subtracting ``d." "utcoffset()``, and a :class:`time.struct_time` for the normalized time is " @@ -2431,7 +2437,7 @@ msgstr "" "``MAXYEAR`` であり、 UTC 時刻への調整により適切な年の範囲を越えた場合、 :exc:" "`OverflowError` が送出される可能性があることに注意してください。" -#: ../../library/datetime.rst:1433 +#: ../../library/datetime.rst:1437 msgid "" "Because naive ``datetime`` objects are treated by many ``datetime`` methods " "as local times, it is preferred to use aware datetimes to represent times in " @@ -2448,7 +2454,7 @@ msgstr "" "が使えるところでは ``datetime.replace(tzinfo=timezone.utc)`` で aware にしま" "す。" -#: ../../library/datetime.rst:1442 +#: ../../library/datetime.rst:1446 msgid "" "Return the proleptic Gregorian ordinal of the date. The same as ``self." "date().toordinal()``." @@ -2456,7 +2462,7 @@ msgstr "" "先発グレゴリオ暦における日付序数を返します。``self.date().toordinal()`` と同" "じです。" -#: ../../library/datetime.rst:1447 +#: ../../library/datetime.rst:1451 msgid "" "Return POSIX timestamp corresponding to the :class:`.datetime` instance. The " "return value is a :class:`float` similar to that returned by :func:`time." @@ -2465,7 +2471,7 @@ msgstr "" ":class:`.datetime` インスタンスに対応する POSIX タイムスタンプを返します。\n" "返り値は :func:`time.time` で返される値に近い :class:`float` です。" -#: ../../library/datetime.rst:1451 +#: ../../library/datetime.rst:1455 msgid "" "Naive :class:`.datetime` instances are assumed to represent local time and " "this method relies on the platform C :c:func:`mktime` function to perform " @@ -2480,18 +2486,18 @@ msgstr "" "値をサポートしているので、遥か過去の時刻や遥か未来の時刻に対し、このメソッド" "は :exc:`OverflowError` または :exc:`OSError` を送出するかもしれません。" -#: ../../library/datetime.rst:1458 +#: ../../library/datetime.rst:1462 msgid "" "For aware :class:`.datetime` instances, the return value is computed as::" msgstr "" "aware な :class:`.datetime` インスタンスに対しては以下のように返り値が計算さ" "れます::" -#: ../../library/datetime.rst:1461 +#: ../../library/datetime.rst:1465 msgid "(dt - datetime(1970, 1, 1, tzinfo=timezone.utc)).total_seconds()" msgstr "" -#: ../../library/datetime.rst:1465 +#: ../../library/datetime.rst:1469 msgid "" "The :meth:`timestamp` method uses the :attr:`.fold` attribute to " "disambiguate the times during a repeated interval." @@ -2499,7 +2505,7 @@ msgstr "" " :meth:`timestamp` メソッドは :attr:`.fold` 属性を繰り返し時間での曖昧さ回避" "に使用します。" -#: ../../library/datetime.rst:1471 +#: ../../library/datetime.rst:1475 msgid "" "There is no method to obtain the POSIX timestamp directly from a naive :" "class:`.datetime` instance representing UTC time. If your application uses " @@ -2512,19 +2518,19 @@ msgstr "" "れていなかった場合、 ``tzinfo=timezone.utc`` を引数に与えることで POSIX タイ" "ムスタンプを取得できます::" -#: ../../library/datetime.rst:1477 +#: ../../library/datetime.rst:1481 msgid "timestamp = dt.replace(tzinfo=timezone.utc).timestamp()" msgstr "" -#: ../../library/datetime.rst:1479 +#: ../../library/datetime.rst:1483 msgid "or by calculating the timestamp directly::" msgstr "もしくは直接タイムスタンプを計算することもできます::" -#: ../../library/datetime.rst:1481 +#: ../../library/datetime.rst:1485 msgid "timestamp = (dt - datetime(1970, 1, 1)) / timedelta(seconds=1)" msgstr "" -#: ../../library/datetime.rst:1485 +#: ../../library/datetime.rst:1489 msgid "" "Return the day of the week as an integer, where Monday is 0 and Sunday is 6. " "The same as ``self.date().weekday()``. See also :meth:`isoweekday`." @@ -2532,7 +2538,7 @@ msgstr "" "月曜日を 0、日曜日を 6 として、曜日を整数で返します。 ``self.date()." "weekday()`` と同じです。 :meth:`isoweekday` も参照してください。" -#: ../../library/datetime.rst:1491 +#: ../../library/datetime.rst:1495 msgid "" "Return the day of the week as an integer, where Monday is 1 and Sunday is 7. " "The same as ``self.date().isoweekday()``. See also :meth:`weekday`, :meth:" @@ -2542,7 +2548,7 @@ msgstr "" "isoweekday()`` と等価です。 :meth:`weekday` 、 :meth:`isocalendar` も参照して" "ください。" -#: ../../library/datetime.rst:1498 +#: ../../library/datetime.rst:1502 msgid "" "Return a :term:`named tuple` with three components: ``year``, ``week`` and " "``weekday``. The same as ``self.date().isocalendar()``." @@ -2550,19 +2556,19 @@ msgstr "" "``year``、``week``、``weekday`` の3つで構成された :term:`named tuple` を返し" "ます。 ``self.date().isocalendar()`` と等価です。" -#: ../../library/datetime.rst:1504 +#: ../../library/datetime.rst:1508 msgid "Return a string representing the date and time in ISO 8601 format:" msgstr "日時を ISO 8601 書式で表した文字列で返します::" -#: ../../library/datetime.rst:1506 +#: ../../library/datetime.rst:1510 msgid "``YYYY-MM-DDTHH:MM:SS.ffffff``, if :attr:`microsecond` is not 0" msgstr ":attr:`microsecond` が 0 でない場合は ``YYYY-MM-DDTHH:MM:SS.ffffff``" -#: ../../library/datetime.rst:1507 +#: ../../library/datetime.rst:1511 msgid "``YYYY-MM-DDTHH:MM:SS``, if :attr:`microsecond` is 0" msgstr ":attr:`microsecond` が 0 の場合は ``YYYY-MM-DDTHH:MM:SS``" -#: ../../library/datetime.rst:1509 +#: ../../library/datetime.rst:1513 msgid "" "If :meth:`utcoffset` does not return ``None``, a string is appended, giving " "the UTC offset:" @@ -2570,7 +2576,7 @@ msgstr "" ":meth:`utcoffset` が ``None`` を返さない場合は、文字列の後ろに UTC オフセット" "が追記されます:" -#: ../../library/datetime.rst:1512 +#: ../../library/datetime.rst:1516 msgid "" "``YYYY-MM-DDTHH:MM:SS.ffffff+HH:MM[:SS[.ffffff]]``, if :attr:`microsecond` " "is not 0" @@ -2578,13 +2584,13 @@ msgstr "" ":attr:`microsecond` が 0 でない場合は ``YYYY-MM-DDTHH:MM:SS.ffffff+HH:MM[:" "SS[.ffffff]]``" -#: ../../library/datetime.rst:1514 +#: ../../library/datetime.rst:1518 msgid "" "``YYYY-MM-DDTHH:MM:SS+HH:MM[:SS[.ffffff]]``, if :attr:`microsecond` is 0" msgstr "" ":attr:`microsecond` が 0 の場合は ``YYYY-MM-DDTHH:MM:SS+HH:MM[:SS[.ffffff]]``" -#: ../../library/datetime.rst:1518 +#: ../../library/datetime.rst:1522 msgid "" ">>> from datetime import datetime, timezone\n" ">>> datetime(2019, 5, 18, 15, 17, 8, 132263).isoformat()\n" @@ -2593,7 +2599,7 @@ msgid "" "'2019-05-18T15:17:00+00:00'" msgstr "" -#: ../../library/datetime.rst:1524 +#: ../../library/datetime.rst:1528 msgid "" "The optional argument *sep* (default ``'T'``) is a one-character separator, " "placed between the date and time portions of the result. For example::" @@ -2601,7 +2607,7 @@ msgstr "" "オプションの引数 *sep* (デフォルトでは ``'T'`` です) は 1 文字のセパレータ" "で、結果の文字列の日付と時刻の間に置かれます。例えば::" -#: ../../library/datetime.rst:1527 +#: ../../library/datetime.rst:1531 msgid "" ">>> from datetime import tzinfo, timedelta, datetime\n" ">>> class TZ(tzinfo):\n" @@ -2615,7 +2621,7 @@ msgid "" "'2009-11-27T00:00:00.000100-06:39'" msgstr "" -#: ../../library/datetime.rst:1538 ../../library/datetime.rst:1913 +#: ../../library/datetime.rst:1542 ../../library/datetime.rst:1917 msgid "" "The optional argument *timespec* specifies the number of additional " "components of the time to include (the default is ``'auto'``). It can be one " @@ -2624,7 +2630,7 @@ msgstr "" "オプション引数 *timespec* は、含める追加の時間の要素の数を指定します(デフォル" "トでは ``'auto'`` です)。以下の内一つを指定してください。" -#: ../../library/datetime.rst:1542 ../../library/datetime.rst:1917 +#: ../../library/datetime.rst:1546 ../../library/datetime.rst:1921 msgid "" "``'auto'``: Same as ``'seconds'`` if :attr:`microsecond` is 0, same as " "``'microseconds'`` otherwise." @@ -2632,18 +2638,18 @@ msgstr "" "``'auto'``: :attr:`microsecond` が0である場合 ``'seconds'`` と等しく、そうで" "ない場合は ``'microseconds'`` と等しくなります。" -#: ../../library/datetime.rst:1544 ../../library/datetime.rst:1919 +#: ../../library/datetime.rst:1548 ../../library/datetime.rst:1923 msgid "``'hours'``: Include the :attr:`hour` in the two-digit ``HH`` format." msgstr "``'hours'``: :attr:`hour` を2桁の ``HH`` 書式で含めます。" -#: ../../library/datetime.rst:1545 ../../library/datetime.rst:1920 +#: ../../library/datetime.rst:1549 ../../library/datetime.rst:1924 msgid "" "``'minutes'``: Include :attr:`hour` and :attr:`minute` in ``HH:MM`` format." msgstr "" "``'minutes'``: :attr:`hour` および :attr:`minute` を ``HH:MM`` の書式で含めま" "す。" -#: ../../library/datetime.rst:1546 ../../library/datetime.rst:1921 +#: ../../library/datetime.rst:1550 ../../library/datetime.rst:1925 msgid "" "``'seconds'``: Include :attr:`hour`, :attr:`minute`, and :attr:`second` in " "``HH:MM:SS`` format." @@ -2651,7 +2657,7 @@ msgstr "" "``'seconds'``: :attr:`hour` 、 :attr:`minute` 、 :attr:`second` を ``HH:MM:" "SS`` の書式で含めます。" -#: ../../library/datetime.rst:1548 ../../library/datetime.rst:1923 +#: ../../library/datetime.rst:1552 ../../library/datetime.rst:1927 msgid "" "``'milliseconds'``: Include full time, but truncate fractional second part " "to milliseconds. ``HH:MM:SS.sss`` format." @@ -2660,20 +2666,20 @@ msgstr "" "す。\n" "``HH:MM:SS.sss`` の書式で表現します。" -#: ../../library/datetime.rst:1550 ../../library/datetime.rst:1925 +#: ../../library/datetime.rst:1554 ../../library/datetime.rst:1929 msgid "``'microseconds'``: Include full time in ``HH:MM:SS.ffffff`` format." msgstr "" "``'microseconds'``: 全ての時刻を ``HH:MM:SS.mmmmmm`` の書式で含めます。" -#: ../../library/datetime.rst:1554 ../../library/datetime.rst:1929 +#: ../../library/datetime.rst:1558 ../../library/datetime.rst:1933 msgid "Excluded time components are truncated, not rounded." msgstr "除外された要素は丸め込みではなく、切り捨てされます。" -#: ../../library/datetime.rst:1556 +#: ../../library/datetime.rst:1560 msgid ":exc:`ValueError` will be raised on an invalid *timespec* argument::" msgstr "不正な *timespec* 引数には :exc:`ValueError` があげられます::" -#: ../../library/datetime.rst:1559 +#: ../../library/datetime.rst:1563 msgid "" ">>> from datetime import datetime\n" ">>> datetime.now().isoformat(timespec='minutes') \n" @@ -2683,11 +2689,11 @@ msgid "" "'2015-01-01T12:30:59.000000'" msgstr "" -#: ../../library/datetime.rst:1566 ../../library/datetime.rst:1944 +#: ../../library/datetime.rst:1570 ../../library/datetime.rst:1948 msgid "Added the *timespec* parameter." msgstr "*timespec* パラメータを追加しました." -#: ../../library/datetime.rst:1572 +#: ../../library/datetime.rst:1576 msgid "" "For a :class:`.datetime` instance *d*, ``str(d)`` is equivalent to ``d." "isoformat(' ')``." @@ -2695,18 +2701,18 @@ msgstr "" ":class:`.datetime` オブジェクト *d* において、 ``str(d)`` は ``d.isoformat(' " "')`` と等価です。" -#: ../../library/datetime.rst:1578 +#: ../../library/datetime.rst:1582 msgid "Return a string representing the date and time::" msgstr "日付および時刻を表す文字列を返します::" -#: ../../library/datetime.rst:1580 +#: ../../library/datetime.rst:1584 msgid "" ">>> from datetime import datetime\n" ">>> datetime(2002, 12, 4, 20, 30, 40).ctime()\n" "'Wed Dec 4 20:30:40 2002'" msgstr "" -#: ../../library/datetime.rst:1584 +#: ../../library/datetime.rst:1588 msgid "" "The output string will *not* include time zone information, regardless of " "whether the input is aware or naive." @@ -2714,7 +2720,7 @@ msgstr "" "出力文字列は入力が aware であれ naive であれ、タイムゾーン情報を含み *ません" "*。" -#: ../../library/datetime.rst:1591 +#: ../../library/datetime.rst:1595 msgid "" "on platforms where the native C :c:func:`ctime` function (which :func:`time." "ctime` invokes, but which :meth:`datetime.ctime` does not invoke) conforms " @@ -2724,7 +2730,7 @@ msgstr "" "ctime` に呼び出されない) ネイティブの C 関数 :c:func:`ctime` が C 標準に準拠" "しているプラットフォーム上でです。" -#: ../../library/datetime.rst:1598 +#: ../../library/datetime.rst:1602 msgid "" "Return a string representing the date and time, controlled by an explicit " "format string. See also :ref:`strftime-strptime-behavior` and :meth:" @@ -2734,7 +2740,7 @@ msgstr "" "ref:`strftime-strptime-behavior` および :meth:`datetime.isoformat` も参照して" "ください。" -#: ../../library/datetime.rst:1605 +#: ../../library/datetime.rst:1609 msgid "" "Same as :meth:`.datetime.strftime`. This makes it possible to specify a " "format string for a :class:`.datetime` object in :ref:`formatted string " @@ -2748,15 +2754,15 @@ msgstr "" ":ref:`strftime-strptime-behavior` および :meth:`datetime.isoformat` も参照し" "てください。" -#: ../../library/datetime.rst:1612 +#: ../../library/datetime.rst:1616 msgid "Examples of Usage: :class:`.datetime`" msgstr "使用例: :class:`.datetime`" -#: ../../library/datetime.rst:1614 +#: ../../library/datetime.rst:1618 msgid "Examples of working with :class:`.datetime` objects:" msgstr ":class:`.datetime` オブジェクトを使う例::" -#: ../../library/datetime.rst:1616 +#: ../../library/datetime.rst:1620 msgid "" ">>> from datetime import datetime, date, time, timezone\n" "\n" @@ -2810,7 +2816,7 @@ msgid "" "'The day is 21, the month is November, the time is 04:30PM.'" msgstr "" -#: ../../library/datetime.rst:1667 +#: ../../library/datetime.rst:1671 msgid "" "The example below defines a :class:`tzinfo` subclass capturing time zone " "information for Kabul, Afghanistan, which used +4 UTC until 1945 and then " @@ -2820,7 +2826,7 @@ msgstr "" "ガニスタンのカブールのタイムゾーン情報を表現する :class:`tzinfo` のサブクラス" "を定義しています::" -#: ../../library/datetime.rst:1671 +#: ../../library/datetime.rst:1675 msgid "" "from datetime import timedelta, datetime, tzinfo, timezone\n" "\n" @@ -2867,11 +2873,11 @@ msgid "" " return \"+04\"" msgstr "" -#: ../../library/datetime.rst:1714 +#: ../../library/datetime.rst:1718 msgid "Usage of ``KabulTz`` from above::" msgstr "上に出てきた ``KabulTz`` の使い方::" -#: ../../library/datetime.rst:1716 +#: ../../library/datetime.rst:1720 msgid "" ">>> tz1 = KabulTz()\n" "\n" @@ -2895,11 +2901,11 @@ msgid "" "True" msgstr "" -#: ../../library/datetime.rst:1740 +#: ../../library/datetime.rst:1744 msgid ":class:`.time` Objects" msgstr ":class:`.time` オブジェクト" -#: ../../library/datetime.rst:1742 +#: ../../library/datetime.rst:1746 msgid "" "A :class:`.time` object represents a (local) time of day, independent of any " "particular day, and subject to adjustment via a :class:`tzinfo` object." @@ -2908,7 +2914,7 @@ msgstr "" "この時刻表現は特定の日の影響を受けず、 :class:`tzinfo` オブジェクトを介した修" "正の対象となります。" -#: ../../library/datetime.rst:1747 +#: ../../library/datetime.rst:1751 msgid "" "All arguments are optional. *tzinfo* may be ``None``, or an instance of a :" "class:`tzinfo` subclass. The remaining arguments must be integers in the " @@ -2918,7 +2924,7 @@ msgstr "" "スのサブクラスのインスタンスにすることができます。残りの引数は整数で、以下の" "ような範囲に入らなければなりません:" -#: ../../library/datetime.rst:1757 +#: ../../library/datetime.rst:1761 msgid "" "If an argument outside those ranges is given, :exc:`ValueError` is raised. " "All default to 0 except *tzinfo*, which defaults to ``None``." @@ -2926,16 +2932,16 @@ msgstr "" "引数がこれらの範囲外にある場合、 :exc:`ValueError` が送出されます。 *tzinfo* " "のデフォルト値が ``None`` である以外のデフォルト値は0です。" -#: ../../library/datetime.rst:1765 +#: ../../library/datetime.rst:1769 msgid "The earliest representable :class:`.time`, ``time(0, 0, 0, 0)``." msgstr "表現できる最も古い :class:`.time` で、 ``time(0, 0, 0, 0)`` です。" -#: ../../library/datetime.rst:1770 +#: ../../library/datetime.rst:1774 msgid "The latest representable :class:`.time`, ``time(23, 59, 59, 999999)``." msgstr "" "表現できる最も新しい :class:`.time` で、 ``time(23, 59, 59, 999999)`` です。" -#: ../../library/datetime.rst:1775 +#: ../../library/datetime.rst:1779 msgid "" "The smallest possible difference between non-equal :class:`.time` objects, " "``timedelta(microseconds=1)``, although note that arithmetic on :class:`." @@ -2945,7 +2951,7 @@ msgstr "" "``timedelta(microseconds=1)`` ですが, :class:`.time` オブジェクト間の四則演算" "はサポートされていないので注意してください。" -#: ../../library/datetime.rst:1804 +#: ../../library/datetime.rst:1808 msgid "" "The object passed as the tzinfo argument to the :class:`.time` constructor, " "or ``None`` if none was passed." @@ -2953,19 +2959,19 @@ msgstr "" ":class:`.time` コンストラクタに *tzinfo* 引数として与えられたオブジェクトにな" "り、何も渡されなかった場合には ``None`` になります。" -#: ../../library/datetime.rst:1818 +#: ../../library/datetime.rst:1822 msgid "" ":class:`.time` objects support equality and order comparisons, where *a* is " "considered less than *b* when *a* precedes *b* in time." msgstr "" -#: ../../library/datetime.rst:1821 +#: ../../library/datetime.rst:1825 msgid "" "Naive and aware :class:`!time` objects are never equal. Order comparison " "between naive and aware :class:`!time` objects raises :exc:`TypeError`." msgstr "" -#: ../../library/datetime.rst:1825 +#: ../../library/datetime.rst:1829 msgid "" "If both comparands are aware, and have the same :attr:`~.time.tzinfo` " "attribute, the :attr:`!tzinfo` and :attr:`!fold` attributes are ignored and " @@ -2979,7 +2985,7 @@ msgstr "" "まず最初に (``self.utcoffset()`` で取得できる) それぞれの UTC オフセットを引" "く調整が行われます。" -#: ../../library/datetime.rst:1831 +#: ../../library/datetime.rst:1835 msgid "" "Equality comparisons between aware and naive :class:`.time` instances don't " "raise :exc:`TypeError`." @@ -2987,13 +2993,13 @@ msgstr "" "aware な インスタンスと naive な :class:`.time` インスタンスの等価比較では :" "exc:`TypeError` は送出されません。" -#: ../../library/datetime.rst:1835 +#: ../../library/datetime.rst:1839 msgid "" "In Boolean contexts, a :class:`.time` object is always considered to be true." msgstr "" "ブール値の文脈では、 :class:`.time` オブジェクトは常に真とみなされます。" -#: ../../library/datetime.rst:1837 +#: ../../library/datetime.rst:1841 msgid "" "Before Python 3.5, a :class:`.time` object was considered to be false if it " "represented midnight in UTC. This behavior was considered obscure and error-" @@ -3006,11 +3012,11 @@ msgstr "" "た。\n" "全詳細については :issue:`13936` を参照してください。" -#: ../../library/datetime.rst:1844 +#: ../../library/datetime.rst:1848 msgid "Other constructor:" msgstr "その他のコンストラクタ:" -#: ../../library/datetime.rst:1848 +#: ../../library/datetime.rst:1852 msgid "" "Return a :class:`.time` corresponding to a *time_string* in any valid ISO " "8601 format, with the following exceptions:" @@ -3018,23 +3024,23 @@ msgstr "" "以下の例外を除く、有効な ISO 8601 フォーマットで与えられた *time_string* に対" "応する :class:`.time` を返します :" -#: ../../library/datetime.rst:1852 +#: ../../library/datetime.rst:1856 msgid "" "The leading ``T``, normally required in cases where there may be ambiguity " "between a date and a time, is not required." msgstr "" -#: ../../library/datetime.rst:1854 +#: ../../library/datetime.rst:1858 msgid "" "Fractional seconds may have any number of digits (anything beyond 6 will be " "truncated)." msgstr "" -#: ../../library/datetime.rst:1858 +#: ../../library/datetime.rst:1862 msgid "Examples:" msgstr "例:" -#: ../../library/datetime.rst:1860 +#: ../../library/datetime.rst:1864 msgid "" ">>> from datetime import time\n" ">>> time.fromisoformat('04:23:01')\n" @@ -3056,13 +3062,13 @@ msgid "" "datetime.time(4, 23, 1, tzinfo=datetime.timezone.utc)" msgstr "" -#: ../../library/datetime.rst:1882 +#: ../../library/datetime.rst:1886 msgid "" "Previously, this method only supported formats that could be emitted by :" "meth:`time.isoformat`." msgstr "" -#: ../../library/datetime.rst:1892 +#: ../../library/datetime.rst:1896 msgid "" "Return a :class:`.time` with the same value, except for those attributes " "given new values by whichever keyword arguments are specified. Note that " @@ -3074,7 +3080,7 @@ msgstr "" "ジェクトから naive な :class:`.time` オブジェクトを生成するために、 " "``tzinfo=None`` を指定することもできます。" -#: ../../library/datetime.rst:1897 +#: ../../library/datetime.rst:1901 msgid "" ":class:`.time` objects are also supported by generic function :func:`copy." "replace`." @@ -3082,19 +3088,19 @@ msgstr "" ":class:`.time` オブジェクトは汎用的な関数 :func:`copy.replace` にもサポートさ" "れています。" -#: ../../library/datetime.rst:1906 +#: ../../library/datetime.rst:1910 msgid "Return a string representing the time in ISO 8601 format, one of:" msgstr "時刻を ISO 8601 書式で表した次の文字列のうち1つを返します::" -#: ../../library/datetime.rst:1908 +#: ../../library/datetime.rst:1912 msgid "``HH:MM:SS.ffffff``, if :attr:`microsecond` is not 0" msgstr ":attr:`microsecond` が 0 でない場合は ``HH:MM:SS.ffffff``" -#: ../../library/datetime.rst:1909 +#: ../../library/datetime.rst:1913 msgid "``HH:MM:SS``, if :attr:`microsecond` is 0" msgstr ":attr:`microsecond` が 0 の場合は ``HH:MM:SS``" -#: ../../library/datetime.rst:1910 +#: ../../library/datetime.rst:1914 msgid "" "``HH:MM:SS.ffffff+HH:MM[:SS[.ffffff]]``, if :meth:`utcoffset` does not " "return ``None``" @@ -3102,7 +3108,7 @@ msgstr "" ":meth:`utcoffset` が ``None`` を返さない場合、 ``HH:MM:SS.ffffff+HH:MM[:SS[." "ffffff]]``" -#: ../../library/datetime.rst:1911 +#: ../../library/datetime.rst:1915 msgid "" "``HH:MM:SS+HH:MM[:SS[.ffffff]]``, if :attr:`microsecond` is 0 and :meth:" "`utcoffset` does not return ``None``" @@ -3110,11 +3116,11 @@ msgstr "" ":attr:`microsecond` が 0 で :meth:`utcoffset` が ``None`` を返さない場合、 " "``HH:MM:SS+HH:MM[:SS[.ffffff]]``" -#: ../../library/datetime.rst:1931 +#: ../../library/datetime.rst:1935 msgid ":exc:`ValueError` will be raised on an invalid *timespec* argument." msgstr "不正な *timespec* 引数には :exc:`ValueError` があげられます。" -#: ../../library/datetime.rst:1935 +#: ../../library/datetime.rst:1939 msgid "" ">>> from datetime import time\n" ">>> time(hour=12, minute=34, second=56, microsecond=123456)." @@ -3127,13 +3133,13 @@ msgid "" "'12:34:56'" msgstr "" -#: ../../library/datetime.rst:1950 +#: ../../library/datetime.rst:1954 msgid "For a time *t*, ``str(t)`` is equivalent to ``t.isoformat()``." msgstr "" ":class:`time` オブジェクト *t* において、``str(t)`` は ``t.isoformat()`` と等" "価です。" -#: ../../library/datetime.rst:1955 +#: ../../library/datetime.rst:1959 msgid "" "Return a string representing the time, controlled by an explicit format " "string. See also :ref:`strftime-strptime-behavior` and :meth:`time." @@ -3143,7 +3149,7 @@ msgstr "" "`strftime-strptime-behavior` および :meth:`time.isoformat` も参照してくださ" "い。" -#: ../../library/datetime.rst:1961 +#: ../../library/datetime.rst:1965 msgid "" "Same as :meth:`.time.strftime`. This makes it possible to specify a format " "string for a :class:`.time` object in :ref:`formatted string literals >> from datetime import time, tzinfo, timedelta\n" ">>> class TZ1(tzinfo):\n" @@ -3226,11 +3232,11 @@ msgid "" "'The time is 12:10.'" msgstr "" -#: ../../library/datetime.rst:2026 +#: ../../library/datetime.rst:2030 msgid ":class:`tzinfo` Objects" msgstr ":class:`tzinfo` オブジェクト" -#: ../../library/datetime.rst:2030 +#: ../../library/datetime.rst:2034 msgid "" "This is an abstract base class, meaning that this class should not be " "instantiated directly. Define a subclass of :class:`tzinfo` to capture " @@ -3241,7 +3247,7 @@ msgstr "" ":class:`tzinfo` のサブクラスを定義し、ある特定のタイムゾーンに関する情報を保" "持するようにしてください。" -#: ../../library/datetime.rst:2034 +#: ../../library/datetime.rst:2038 msgid "" "An instance of (a concrete subclass of) :class:`tzinfo` can be passed to the " "constructors for :class:`.datetime` and :class:`.time` objects. The latter " @@ -3257,7 +3263,7 @@ msgstr "" "ンの名前、 DST オフセットを、渡された日付および時刻オブジェクトからの相対で示" "すためのメソッドを提供します。" -#: ../../library/datetime.rst:2040 +#: ../../library/datetime.rst:2044 msgid "" "You need to derive a concrete subclass, and (at least) supply " "implementations of the standard :class:`tzinfo` methods needed by the :class:" @@ -3273,7 +3279,7 @@ msgstr "" "これは UTC そのものか北アメリカの EST と EDT のような UTC からの固定されたオ" "フセットを持つタイムゾーンを表せます。" -#: ../../library/datetime.rst:2047 +#: ../../library/datetime.rst:2051 msgid "" "Special requirement for pickling: A :class:`tzinfo` subclass must have an :" "meth:`~object.__init__` method that can be called with no arguments, " @@ -3286,7 +3292,7 @@ msgstr "" "とはできないでしょう。これは技術的な側面からの要求であり、将来緩和されるかも" "しれません。" -#: ../../library/datetime.rst:2053 +#: ../../library/datetime.rst:2057 msgid "" "A concrete subclass of :class:`tzinfo` may need to implement the following " "methods. Exactly which methods are needed depends on the uses made of aware :" @@ -3297,7 +3303,7 @@ msgstr "" "トがこのサブクラスのインスタンスをどのように使うかに依存します。不確かなら" "ば、単に全てを実装してください。" -#: ../../library/datetime.rst:2060 +#: ../../library/datetime.rst:2064 msgid "" "Return offset of local time from UTC, as a :class:`timedelta` object that is " "positive east of UTC. If local time is west of UTC, this should be negative." @@ -3306,7 +3312,7 @@ msgstr "" "`timedelta` オブジェクトで返します。ローカル時間が UTC の西側にある場合、この" "値は負になります。" -#: ../../library/datetime.rst:2063 +#: ../../library/datetime.rst:2067 msgid "" "This represents the *total* offset from UTC; for example, if a :class:" "`tzinfo` object represents both time zone and DST adjustments, :meth:" @@ -3327,13 +3333,13 @@ msgstr "" "ほとんどの :meth:`utcoffset` 実装は、おそらく以下の二つのうちの一つに似たもの" "になるでしょう::" -#: ../../library/datetime.rst:2071 +#: ../../library/datetime.rst:2075 msgid "" "return CONSTANT # fixed-offset class\n" "return CONSTANT + self.dst(dt) # daylight-aware class" msgstr "" -#: ../../library/datetime.rst:2074 +#: ../../library/datetime.rst:2078 msgid "" "If :meth:`utcoffset` does not return ``None``, :meth:`dst` should not return " "``None`` either." @@ -3341,7 +3347,7 @@ msgstr "" ":meth:`utcoffset` が ``None`` を返さない場合、 :meth:`dst` も ``None`` を返し" "てはなりません。" -#: ../../library/datetime.rst:2077 +#: ../../library/datetime.rst:2081 msgid "" "The default implementation of :meth:`utcoffset` raises :exc:" "`NotImplementedError`." @@ -3349,7 +3355,7 @@ msgstr "" ":meth:`utcoffset` のデフォルトの実装は :exc:`NotImplementedError` を送出しま" "す。" -#: ../../library/datetime.rst:2086 +#: ../../library/datetime.rst:2090 msgid "" "Return the daylight saving time (DST) adjustment, as a :class:`timedelta` " "object or ``None`` if DST information isn't known." @@ -3357,7 +3363,7 @@ msgstr "" "夏時間 (DST) 修正を、 :class:`timedelta` オブジェクトで返します。\n" "DST 情報が未知の場合、 ``None`` が返されます。" -#: ../../library/datetime.rst:2090 +#: ../../library/datetime.rst:2094 msgid "" "Return ``timedelta(0)`` if DST is not in effect. If DST is in effect, return " "the offset as a :class:`timedelta` object (see :meth:`utcoffset` for " @@ -3380,7 +3386,7 @@ msgstr "" "されているかどうか判断し、 :meth:`tzinfo.fromutc` は :meth:`dst` タイムゾーン" "を移動する際に DST による変更があるかどうかを調べます。" -#: ../../library/datetime.rst:2100 +#: ../../library/datetime.rst:2104 msgid "" "An instance *tz* of a :class:`tzinfo` subclass that models both standard and " "daylight times must be consistent in this sense:" @@ -3388,11 +3394,11 @@ msgstr "" "標準および夏時間の両方をモデル化している :class:`tzinfo` サブクラスのインスタ" "ンス *tz* は以下の式:" -#: ../../library/datetime.rst:2103 +#: ../../library/datetime.rst:2107 msgid "``tz.utcoffset(dt) - tz.dst(dt)``" msgstr "``tz.utcoffset(dt) - tz.dst(dt)``" -#: ../../library/datetime.rst:2105 +#: ../../library/datetime.rst:2109 msgid "" "must return the same result for every :class:`.datetime` *dt* with ``dt." "tzinfo == tz``. For sane :class:`tzinfo` subclasses, this expression yields " @@ -3414,7 +3420,7 @@ msgstr "" "れを保証することができない場合、 :meth:`tzinfo.fromutc` の実装をオーバライド" "して、 :meth:`astimezone` に関わらず正しく動作するようにしてもかまいません。" -#: ../../library/datetime.rst:2114 +#: ../../library/datetime.rst:2118 msgid "" "Most implementations of :meth:`dst` will probably look like one of these " "two::" @@ -3422,18 +3428,18 @@ msgstr "" "ほとんどの :meth:`dst` 実装は、おそらく以下の二つのうちの一つに似たものになる" "でしょう::" -#: ../../library/datetime.rst:2116 +#: ../../library/datetime.rst:2120 msgid "" "def dst(self, dt):\n" " # a fixed-offset class: doesn't account for DST\n" " return timedelta(0)" msgstr "" -#: ../../library/datetime.rst:2120 +#: ../../library/datetime.rst:2124 msgid "or::" msgstr "もしくは::" -#: ../../library/datetime.rst:2122 +#: ../../library/datetime.rst:2126 msgid "" "def dst(self, dt):\n" " # Code to set dston and dstoff to the time zone's DST\n" @@ -3446,13 +3452,13 @@ msgid "" " return timedelta(0)" msgstr "" -#: ../../library/datetime.rst:2132 +#: ../../library/datetime.rst:2136 msgid "" "The default implementation of :meth:`dst` raises :exc:`NotImplementedError`." msgstr "" "デフォルトの :meth:`dst` 実装は :exc:`NotImplementedError` を送出します。" -#: ../../library/datetime.rst:2140 +#: ../../library/datetime.rst:2144 msgid "" "Return the time zone name corresponding to the :class:`.datetime` object " "*dt*, as a string. Nothing about string names is defined by the :mod:`!" @@ -3475,14 +3481,14 @@ msgstr "" "の特定の値によって異なった名前を返したい場合があるため、文字列値ではなくメ" "ソッドとなっていることに注意してください。" -#: ../../library/datetime.rst:2150 +#: ../../library/datetime.rst:2154 msgid "" "The default implementation of :meth:`tzname` raises :exc:" "`NotImplementedError`." msgstr "" "デフォルトの :meth:`tzname` 実装は :exc:`NotImplementedError` を送出します。" -#: ../../library/datetime.rst:2153 +#: ../../library/datetime.rst:2157 msgid "" "These methods are called by a :class:`.datetime` or :class:`.time` object, " "in response to their methods of the same names. A :class:`.datetime` object " @@ -3498,7 +3504,7 @@ msgstr "" "におけるメソッドは引数 *dt* が ``None`` の場合と、 :class:`.datetime` の場合" "を受理するように用意しなければなりません。" -#: ../../library/datetime.rst:2159 +#: ../../library/datetime.rst:2163 msgid "" "When ``None`` is passed, it's up to the class designer to decide the best " "response. For example, returning ``None`` is appropriate if the class wishes " @@ -3512,7 +3518,7 @@ msgstr "" "場合には、標準 UTC オフセットを返すために ``utcoffset(None)`` を使うともっと" "便利かもしれません。" -#: ../../library/datetime.rst:2165 +#: ../../library/datetime.rst:2169 msgid "" "When a :class:`.datetime` object is passed in response to a :class:`." "datetime` method, ``dt.tzinfo`` is the same object as *self*. :class:" @@ -3528,7 +3534,7 @@ msgstr "" "`tzinfo` メソッドは *dt* がローカル時間であると解釈するので、他のタイムゾーン" "でのオブジェクトの振る舞いについて心配する必要がありません。" -#: ../../library/datetime.rst:2171 +#: ../../library/datetime.rst:2175 msgid "" "There is one more :class:`tzinfo` method that a subclass may wish to " "override:" @@ -3536,7 +3542,7 @@ msgstr "" "サブクラスでオーバーライドすると良い、もう 1 つの :class:`tzinfo` のメソッド" "があります:" -#: ../../library/datetime.rst:2176 +#: ../../library/datetime.rst:2180 msgid "" "This is called from the default :meth:`datetime.astimezone` implementation. " "When called from that, ``dt.tzinfo`` is *self*, and *dt*'s date and time " @@ -3550,7 +3556,7 @@ msgstr "" "ル時刻に等しい :class:`datetime` オブジェクトを返すことにより日付と時刻データ" "メンバを修正することにあります。" -#: ../../library/datetime.rst:2182 +#: ../../library/datetime.rst:2186 msgid "" "Most :class:`tzinfo` subclasses should be able to inherit the default :meth:" "`fromutc` implementation without problems. It's strong enough to handle " @@ -3575,7 +3581,7 @@ msgstr "" "化にまたがる何時間かの中にある場合、期待通りの結果を生成しないかもしれませ" "ん。" -#: ../../library/datetime.rst:2193 +#: ../../library/datetime.rst:2197 msgid "" "Skipping code for error cases, the default :meth:`fromutc` implementation " "acts like::" @@ -3583,7 +3589,7 @@ msgstr "" "エラーの場合のためのコードを除き、デフォルトの :meth:`fromutc` の実装は以下の" "ように動作します::" -#: ../../library/datetime.rst:2196 +#: ../../library/datetime.rst:2200 msgid "" "def fromutc(self, dt):\n" " # raise ValueError error if dt.tzinfo is not self\n" @@ -3601,7 +3607,7 @@ msgid "" " return dt" msgstr "" -#: ../../library/datetime.rst:2211 +#: ../../library/datetime.rst:2215 msgid "" "In the following :download:`tzinfo_examples.py <../includes/tzinfo_examples." "py>` file there are some examples of :class:`tzinfo` classes:" @@ -3609,7 +3615,7 @@ msgstr "" "次の :download:`tzinfo_examples.py <../includes/tzinfo_examples.py>` ファイル" "には、 :class:`tzinfo` クラスの例がいくつか載っています:" -#: ../../library/datetime.rst:2215 +#: ../../library/datetime.rst:2219 msgid "" "from datetime import tzinfo, timedelta, datetime\n" "\n" @@ -3789,7 +3795,7 @@ msgid "" "Pacific = USTimeZone(-8, \"Pacific\", \"PST\", \"PDT\")\n" msgstr "" -#: ../../library/datetime.rst:2217 +#: ../../library/datetime.rst:2221 msgid "" "Note that there are unavoidable subtleties twice per year in a :class:" "`tzinfo` subclass accounting for both standard and daylight time, at the DST " @@ -3803,7 +3809,7 @@ msgstr "" "EDT は 3 月の第二日曜日の 1:59 (EST) の 1 分後に開始し、11 月の最初の日曜日" "の (EDTの) 1:59 に終了します::" -#: ../../library/datetime.rst:2223 +#: ../../library/datetime.rst:2227 msgid "" " UTC 3:MM 4:MM 5:MM 6:MM 7:MM 8:MM\n" " EST 22:MM 23:MM 0:MM 1:MM 2:MM 3:MM\n" @@ -3814,7 +3820,7 @@ msgid "" " end 23:MM 0:MM 1:MM 1:MM 2:MM 3:MM" msgstr "" -#: ../../library/datetime.rst:2231 +#: ../../library/datetime.rst:2235 msgid "" "When DST starts (the \"start\" line), the local wall clock leaps from 1:59 " "to 3:00. A wall time of the form 2:MM doesn't really make sense on that day, " @@ -3829,7 +3835,7 @@ msgstr "" "ん。\n" "例として、 2016 年の春方向の移行では、次のような結果になります::" -#: ../../library/datetime.rst:2236 +#: ../../library/datetime.rst:2240 msgid "" ">>> from datetime import datetime, timezone\n" ">>> from tzinfo_examples import HOUR, Eastern\n" @@ -3845,7 +3851,7 @@ msgid "" "08:00:00 UTC = 04:00:00 EDT" msgstr "" -#: ../../library/datetime.rst:2250 +#: ../../library/datetime.rst:2254 msgid "" "When DST ends (the \"end\" line), there's a potentially worse problem: " "there's an hour that can't be spelled unambiguously in local wall time: the " @@ -3873,7 +3879,7 @@ msgstr "" "fold` 属性を 0 にし、以降の時間では 1 にします。例えば、 2016 年での秋方向の" "移行では、次のような結果になります::" -#: ../../library/datetime.rst:2261 +#: ../../library/datetime.rst:2265 msgid "" ">>> u0 = datetime(2016, 11, 6, 4, tzinfo=timezone.utc)\n" ">>> for i in range(4):\n" @@ -3887,7 +3893,7 @@ msgid "" "07:00:00 UTC = 02:00:00 EST 0" msgstr "" -#: ../../library/datetime.rst:2272 +#: ../../library/datetime.rst:2276 msgid "" "Note that the :class:`.datetime` instances that differ only by the value of " "the :attr:`~.datetime.fold` attribute are considered equal in comparisons." @@ -3895,7 +3901,7 @@ msgstr "" ":attr:`~.datetime.fold` 属性が異なるだけの :class:`.datetime` インスタンスは" "比較において等しいとみなされることに注意してください。" -#: ../../library/datetime.rst:2275 +#: ../../library/datetime.rst:2279 msgid "" "Applications that can't bear wall-time ambiguities should explicitly check " "the value of the :attr:`~.datetime.fold` attribute or avoid using hybrid :" @@ -3912,11 +3918,11 @@ msgstr "" "このような曖昧さを許容できないアプリケーションは、このような手法によって回避" "すべきです。" -#: ../../library/datetime.rst:2283 +#: ../../library/datetime.rst:2287 msgid ":mod:`zoneinfo`" msgstr ":mod:`zoneinfo`" -#: ../../library/datetime.rst:2284 +#: ../../library/datetime.rst:2288 msgid "" "The :mod:`!datetime` module has a basic :class:`timezone` class (for " "handling arbitrary fixed offsets from UTC) and its :attr:`timezone.utc` " @@ -3926,7 +3932,7 @@ msgstr "" "な :class:`timezone` クラスと、(UTC :class:`!timezone` のインスタンスであ" "る) :attr:`timezone.utc` 属性があります。" -#: ../../library/datetime.rst:2288 +#: ../../library/datetime.rst:2292 msgid "" "``zoneinfo`` brings the *IANA time zone database* (also known as the Olson " "database) to Python, and its usage is recommended." @@ -3935,11 +3941,11 @@ msgstr "" "スとしても知られています) を導入するもので、これを使うことが推奨されていま" "す。" -#: ../../library/datetime.rst:2291 +#: ../../library/datetime.rst:2295 msgid "`IANA time zone database `_" msgstr "`IANA タイムゾーンデータベース `_" -#: ../../library/datetime.rst:2292 +#: ../../library/datetime.rst:2296 msgid "" "The Time Zone Database (often called tz, tzdata or zoneinfo) contains code " "and data that represent the history of local time for many representative " @@ -3952,11 +3958,11 @@ msgstr "" "時刻の履歴を表しています。政治団体によるタイムゾーンの境界、UTC オフセット、" "夏時間のルールの変更を反映するため、定期的にデータベースが更新されます。" -#: ../../library/datetime.rst:2302 +#: ../../library/datetime.rst:2306 msgid ":class:`timezone` Objects" msgstr ":class:`timezone` オブジェクト" -#: ../../library/datetime.rst:2304 +#: ../../library/datetime.rst:2308 msgid "" "The :class:`timezone` class is a subclass of :class:`tzinfo`, each instance " "of which represents a time zone defined by a fixed offset from UTC." @@ -3964,7 +3970,7 @@ msgstr "" ":class:`timezone` クラスは :class:`tzinfo` のサブクラスで、各インスタンスは " "UTC からの固定されたオフセットで定義されたタイムゾーンを表しています。" -#: ../../library/datetime.rst:2308 +#: ../../library/datetime.rst:2312 msgid "" "Objects of this class cannot be used to represent time zone information in " "the locations where different offsets are used in different days of the year " @@ -3974,7 +3980,7 @@ msgstr "" "たり、常用時 (civil time) に歴史的な変化が起きた場所のタイムゾーン情報を表す" "のには使えないので注意してください。" -#: ../../library/datetime.rst:2315 +#: ../../library/datetime.rst:2319 msgid "" "The *offset* argument must be specified as a :class:`timedelta` object " "representing the difference between the local time and UTC. It must be " @@ -3986,7 +3992,7 @@ msgstr "" "``timedelta(hours=24)`` までの両端を含まない範囲に収まっていなくてはなりませ" "ん。そうでない場合 :exc:`ValueError` が送出されます。" -#: ../../library/datetime.rst:2320 +#: ../../library/datetime.rst:2324 msgid "" "The *name* argument is optional. If specified it must be a string that will " "be used as the value returned by the :meth:`datetime.tzname` method." @@ -3994,14 +4000,14 @@ msgstr "" "*name* 引数は必須ではありません。もし指定された場合、その値は :meth:" "`datetime.tzname` メソッドの返り値として使われる文字列でなければなりません。" -#: ../../library/datetime.rst:2331 ../../library/datetime.rst:2342 +#: ../../library/datetime.rst:2335 ../../library/datetime.rst:2346 msgid "" "Return the fixed value specified when the :class:`timezone` instance is " "constructed." msgstr "" ":class:`timezone` インスタンスが構築されたときに指定された固定値を返します。" -#: ../../library/datetime.rst:2334 +#: ../../library/datetime.rst:2338 msgid "" "The *dt* argument is ignored. The return value is a :class:`timedelta` " "instance equal to the difference between the local time and UTC." @@ -4010,7 +4016,7 @@ msgstr "" "返り値は、ローカル時刻と UTC の差分に等しい :class:`timedelta` インスタンスで" "す。" -#: ../../library/datetime.rst:2345 +#: ../../library/datetime.rst:2349 msgid "" "If *name* is not provided in the constructor, the name returned by " "``tzname(dt)`` is generated from the value of the ``offset`` as follows. If " @@ -4025,7 +4031,7 @@ msgstr "" "HH と MM はそれぞれ二桁の ``offset.hours`` と ``offset.minutes`` を表現しま" "す。" -#: ../../library/datetime.rst:2351 +#: ../../library/datetime.rst:2355 msgid "" "Name generated from ``offset=timedelta(0)`` is now plain ``'UTC'``, not " "``'UTC+00:00'``." @@ -4033,11 +4039,11 @@ msgstr "" "``offset=timedelta(0)`` によって生成される名前はプレーンな `'UTC'` であり " "``'UTC+00:00'`` ではありません。" -#: ../../library/datetime.rst:2358 +#: ../../library/datetime.rst:2362 msgid "Always returns ``None``." msgstr "常に ``None`` を返します。" -#: ../../library/datetime.rst:2362 +#: ../../library/datetime.rst:2366 msgid "" "Return ``dt + offset``. The *dt* argument must be an aware :class:`." "datetime` instance, with ``tzinfo`` set to ``self``." @@ -4045,15 +4051,15 @@ msgstr "" "``dt + offset`` を返します。 *dt* 引数は ``tzinfo`` が ``self`` になっている " "aware な :class:`.datetime` インスタンスでなければなりません。" -#: ../../library/datetime.rst:2369 +#: ../../library/datetime.rst:2373 msgid "The UTC time zone, ``timezone(timedelta(0))``." msgstr "UTC タイムゾーン ``timezone(timedelta(0))`` です。" -#: ../../library/datetime.rst:2378 +#: ../../library/datetime.rst:2382 msgid ":meth:`~.datetime.strftime` and :meth:`~.datetime.strptime` Behavior" msgstr ":meth:`~.datetime.strftime` と :meth:`~.datetime.strptime` の振る舞い" -#: ../../library/datetime.rst:2380 +#: ../../library/datetime.rst:2384 msgid "" ":class:`date`, :class:`.datetime`, and :class:`.time` objects all support a " "``strftime(format)`` method, to create a string representing the time under " @@ -4063,7 +4069,7 @@ msgstr "" "``strftime(format)`` メソッドをサポートし、時刻を表現する文字列を明示的な書式" "文字列で統制して作成しています。" -#: ../../library/datetime.rst:2384 +#: ../../library/datetime.rst:2388 msgid "" "Conversely, the :meth:`datetime.strptime` class method creates a :class:`." "datetime` object from a string representing a date and time and a " @@ -4072,7 +4078,7 @@ msgstr "" "逆に :meth:`datetime.strptime` クラスメソッドは日付や時刻に対応する書式文字列" "から :class:`.datetime` オブジェクトを生成します。" -#: ../../library/datetime.rst:2388 +#: ../../library/datetime.rst:2392 msgid "" "The table below provides a high-level comparison of :meth:`~.datetime." "strftime` versus :meth:`~.datetime.strptime`:" @@ -4080,78 +4086,78 @@ msgstr "" "下の表は :meth:`~.datetime.strftime` と :meth:`~.datetime.strptime` との高レ" "ベルの対比を表しています。" -#: ../../library/datetime.rst:2392 +#: ../../library/datetime.rst:2396 msgid "``strftime``" msgstr "``strftime``" -#: ../../library/datetime.rst:2392 +#: ../../library/datetime.rst:2396 msgid "``strptime``" msgstr "``strptime``" -#: ../../library/datetime.rst:2394 +#: ../../library/datetime.rst:2398 msgid "Usage" msgstr "使用法" -#: ../../library/datetime.rst:2394 +#: ../../library/datetime.rst:2398 msgid "Convert object to a string according to a given format" msgstr "オブジェクトを与えられた書式に従って文字列に変換する" -#: ../../library/datetime.rst:2394 +#: ../../library/datetime.rst:2398 msgid "" "Parse a string into a :class:`.datetime` object given a corresponding format" msgstr "" "指定された対応する書式で文字列を構文解析して :class:`.datetime` オブジェクト" "にする" -#: ../../library/datetime.rst:2396 +#: ../../library/datetime.rst:2400 msgid "Type of method" msgstr "メソッドの種類" -#: ../../library/datetime.rst:2396 +#: ../../library/datetime.rst:2400 msgid "Instance method" msgstr "インスタンスメソッド" -#: ../../library/datetime.rst:2396 +#: ../../library/datetime.rst:2400 msgid "Class method" msgstr "クラスメソッド" -#: ../../library/datetime.rst:2398 +#: ../../library/datetime.rst:2402 msgid "Method of" msgstr "メソッドを持つクラス" -#: ../../library/datetime.rst:2398 +#: ../../library/datetime.rst:2402 msgid ":class:`date`; :class:`.datetime`; :class:`.time`" msgstr ":class:`date`; :class:`.datetime`; :class:`.time`" -#: ../../library/datetime.rst:2398 +#: ../../library/datetime.rst:2402 msgid ":class:`.datetime`" msgstr ":class:`.datetime`" -#: ../../library/datetime.rst:2400 +#: ../../library/datetime.rst:2404 msgid "Signature" msgstr "シグネチャ" -#: ../../library/datetime.rst:2400 +#: ../../library/datetime.rst:2404 msgid "``strftime(format)``" msgstr "``strftime(format)``" -#: ../../library/datetime.rst:2400 +#: ../../library/datetime.rst:2404 msgid "``strptime(date_string, format)``" msgstr "``strptime(date_string, format)``" -#: ../../library/datetime.rst:2407 +#: ../../library/datetime.rst:2411 msgid "" ":meth:`~.datetime.strftime` and :meth:`~.datetime.strptime` Format Codes" msgstr "" ":meth:`~.datetime.strftime` と :meth:`~.datetime.strptime` の書式コード" -#: ../../library/datetime.rst:2409 +#: ../../library/datetime.rst:2413 msgid "" "These methods accept format codes that can be used to parse and format " "dates::" msgstr "" -#: ../../library/datetime.rst:2411 +#: ../../library/datetime.rst:2415 msgid "" ">>> datetime.strptime('31/01/22 23:59:59.999999',\n" "... '%d/%m/%y %H:%M:%S.%f')\n" @@ -4160,7 +4166,7 @@ msgid "" "'Mon 31 Jan 2022, 11:59PM'" msgstr "" -#: ../../library/datetime.rst:2417 +#: ../../library/datetime.rst:2421 msgid "" "The following is a list of all the format codes that the 1989 C standard " "requires, and these work on all platforms with a standard C implementation." @@ -4168,27 +4174,27 @@ msgstr "" "以下のリストは 1989 C 標準が要求する全ての書式コードで、標準 C 実装があれば全" "ての環境で動作します。" -#: ../../library/datetime.rst:2421 ../../library/datetime.rst:2524 +#: ../../library/datetime.rst:2425 ../../library/datetime.rst:2528 msgid "Directive" msgstr "ディレクティブ" -#: ../../library/datetime.rst:2421 ../../library/datetime.rst:2524 +#: ../../library/datetime.rst:2425 ../../library/datetime.rst:2528 msgid "Meaning" msgstr "意味" -#: ../../library/datetime.rst:2421 ../../library/datetime.rst:2524 +#: ../../library/datetime.rst:2425 ../../library/datetime.rst:2528 msgid "Example" msgstr "使用例" -#: ../../library/datetime.rst:2421 ../../library/datetime.rst:2524 +#: ../../library/datetime.rst:2425 ../../library/datetime.rst:2528 msgid "Notes" msgstr "注釈" -#: ../../library/datetime.rst:2423 +#: ../../library/datetime.rst:2427 msgid "``%a``" msgstr "``%a``" -#: ../../library/datetime.rst:2423 +#: ../../library/datetime.rst:2427 msgid "Weekday as locale's abbreviated name." msgstr "ロケールの曜日名を短縮形で表示します。" @@ -4200,11 +4206,11 @@ msgstr "Sun, Mon, ..., Sat (en_US);" msgid "So, Mo, ..., Sa (de_DE)" msgstr "So, Mo, ..., Sa (de_DE)" -#: ../../library/datetime.rst:2428 +#: ../../library/datetime.rst:2432 msgid "``%A``" msgstr "``%A``" -#: ../../library/datetime.rst:2428 +#: ../../library/datetime.rst:2432 msgid "Weekday as locale's full name." msgstr "ロケールの曜日名を表示します。" @@ -4216,43 +4222,43 @@ msgstr "Sunday, Monday, ..., Saturday (en_US);" msgid "Sonntag, Montag, ..., Samstag (de_DE)" msgstr "Sonntag, Montag, ..., Samstag (de_DE)" -#: ../../library/datetime.rst:2433 +#: ../../library/datetime.rst:2437 msgid "``%w``" msgstr "``%w``" -#: ../../library/datetime.rst:2433 +#: ../../library/datetime.rst:2437 msgid "Weekday as a decimal number, where 0 is Sunday and 6 is Saturday." msgstr "" "曜日を10進表記した文字列を表示します。0 が日曜日で、6 が土曜日を表します。" -#: ../../library/datetime.rst:2433 +#: ../../library/datetime.rst:2437 msgid "0, 1, ..., 6" msgstr "0, 1, ..., 6" -#: ../../library/datetime.rst:2437 +#: ../../library/datetime.rst:2441 msgid "``%d``" msgstr "``%d``" -#: ../../library/datetime.rst:2437 +#: ../../library/datetime.rst:2441 msgid "Day of the month as a zero-padded decimal number." msgstr "0埋めした10進数で表記した月中の日にち。" -#: ../../library/datetime.rst:2437 +#: ../../library/datetime.rst:2441 msgid "01, 02, ..., 31" msgstr "01, 02, ..., 31" -#: ../../library/datetime.rst:2437 ../../library/datetime.rst:2450 -#: ../../library/datetime.rst:2453 ../../library/datetime.rst:2459 -#: ../../library/datetime.rst:2462 ../../library/datetime.rst:2468 -#: ../../library/datetime.rst:2486 +#: ../../library/datetime.rst:2441 ../../library/datetime.rst:2454 +#: ../../library/datetime.rst:2457 ../../library/datetime.rst:2463 +#: ../../library/datetime.rst:2466 ../../library/datetime.rst:2472 +#: ../../library/datetime.rst:2490 msgid "\\(9)" msgstr "\\(9)" -#: ../../library/datetime.rst:2440 +#: ../../library/datetime.rst:2444 msgid "``%b``" msgstr "``%b``" -#: ../../library/datetime.rst:2440 +#: ../../library/datetime.rst:2444 msgid "Month as locale's abbreviated name." msgstr "ロケールの月名を短縮形で表示します。" @@ -4264,11 +4270,11 @@ msgstr "Jan, Feb, ..., Dec (en_US);" msgid "Jan, Feb, ..., Dez (de_DE)" msgstr "Jan, Feb, ..., Dez (de_DE)" -#: ../../library/datetime.rst:2445 +#: ../../library/datetime.rst:2449 msgid "``%B``" msgstr "``%B``" -#: ../../library/datetime.rst:2445 +#: ../../library/datetime.rst:2449 msgid "Month as locale's full name." msgstr "ロケールの月名を表示します。" @@ -4280,67 +4286,67 @@ msgstr "January, February, ..., December (en_US);" msgid "Januar, Februar, ..., Dezember (de_DE)" msgstr "Januar, Februar, ..., Dezember (de_DE)" -#: ../../library/datetime.rst:2450 +#: ../../library/datetime.rst:2454 msgid "``%m``" msgstr "``%m``" -#: ../../library/datetime.rst:2450 +#: ../../library/datetime.rst:2454 msgid "Month as a zero-padded decimal number." msgstr "0埋めした10進数で表記した月。" -#: ../../library/datetime.rst:2450 ../../library/datetime.rst:2462 +#: ../../library/datetime.rst:2454 ../../library/datetime.rst:2466 msgid "01, 02, ..., 12" msgstr "01, 02, ..., 12" -#: ../../library/datetime.rst:2453 +#: ../../library/datetime.rst:2457 msgid "``%y``" msgstr "``%y``" -#: ../../library/datetime.rst:2453 +#: ../../library/datetime.rst:2457 msgid "Year without century as a zero-padded decimal number." msgstr "0埋めした10進数で表記した世紀無しの年。" -#: ../../library/datetime.rst:2453 +#: ../../library/datetime.rst:2457 msgid "00, 01, ..., 99" msgstr "00, 01, ..., 99" -#: ../../library/datetime.rst:2456 +#: ../../library/datetime.rst:2460 msgid "``%Y``" msgstr "``%Y``" -#: ../../library/datetime.rst:2456 +#: ../../library/datetime.rst:2460 msgid "Year with century as a decimal number." msgstr "西暦 ( 4桁) の 10 進表記を表します。" -#: ../../library/datetime.rst:2456 ../../library/datetime.rst:2526 +#: ../../library/datetime.rst:2460 ../../library/datetime.rst:2530 msgid "0001, 0002, ..., 2013, 2014, ..., 9998, 9999" msgstr "0001, 0002, ..., 2013, 2014, ..., 9998, 9999" -#: ../../library/datetime.rst:2459 +#: ../../library/datetime.rst:2463 msgid "``%H``" msgstr "``%H``" -#: ../../library/datetime.rst:2459 +#: ../../library/datetime.rst:2463 msgid "Hour (24-hour clock) as a zero-padded decimal number." msgstr "0埋めした10進数で表記した時 (24時間表記)。" -#: ../../library/datetime.rst:2459 +#: ../../library/datetime.rst:2463 msgid "00, 01, ..., 23" msgstr "00, 01, ..., 23" -#: ../../library/datetime.rst:2462 +#: ../../library/datetime.rst:2466 msgid "``%I``" msgstr "``%I``" -#: ../../library/datetime.rst:2462 +#: ../../library/datetime.rst:2466 msgid "Hour (12-hour clock) as a zero-padded decimal number." msgstr "0埋めした10進数で表記した時 (12時間表記)。" -#: ../../library/datetime.rst:2465 +#: ../../library/datetime.rst:2469 msgid "``%p``" msgstr "``%p``" -#: ../../library/datetime.rst:2465 +#: ../../library/datetime.rst:2469 msgid "Locale's equivalent of either AM or PM." msgstr "ロケールの AM もしくは PM と等価な文字列になります。" @@ -4352,55 +4358,55 @@ msgstr "AM, PM (en_US);" msgid "am, pm (de_DE)" msgstr "am, pm (de_DE)" -#: ../../library/datetime.rst:2465 +#: ../../library/datetime.rst:2469 msgid "\\(1), \\(3)" msgstr "\\(1), \\(3)" -#: ../../library/datetime.rst:2468 +#: ../../library/datetime.rst:2472 msgid "``%M``" msgstr "``%M``" -#: ../../library/datetime.rst:2468 +#: ../../library/datetime.rst:2472 msgid "Minute as a zero-padded decimal number." msgstr "0埋めした10進数で表記した分。" -#: ../../library/datetime.rst:2468 ../../library/datetime.rst:2471 +#: ../../library/datetime.rst:2472 ../../library/datetime.rst:2475 msgid "00, 01, ..., 59" msgstr "00, 01, ..., 59" -#: ../../library/datetime.rst:2471 +#: ../../library/datetime.rst:2475 msgid "``%S``" msgstr "``%S``" -#: ../../library/datetime.rst:2471 +#: ../../library/datetime.rst:2475 msgid "Second as a zero-padded decimal number." msgstr "0埋めした10進数で表記した秒。" -#: ../../library/datetime.rst:2471 +#: ../../library/datetime.rst:2475 msgid "\\(4), \\(9)" msgstr "\\(4), \\(9)" -#: ../../library/datetime.rst:2474 +#: ../../library/datetime.rst:2478 msgid "``%f``" msgstr "``%f``" -#: ../../library/datetime.rst:2474 +#: ../../library/datetime.rst:2478 msgid "Microsecond as a decimal number, zero-padded to 6 digits." msgstr "10進数で表記したマイクロ秒 (6桁に0埋めされます)。" -#: ../../library/datetime.rst:2474 +#: ../../library/datetime.rst:2478 msgid "000000, 000001, ..., 999999" msgstr "000000, 000001, ..., 999999" -#: ../../library/datetime.rst:2474 +#: ../../library/datetime.rst:2478 msgid "\\(5)" msgstr "\\(5)" -#: ../../library/datetime.rst:2478 ../../library/datetime.rst:2637 +#: ../../library/datetime.rst:2482 ../../library/datetime.rst:2641 msgid "``%z``" msgstr "``%z``" -#: ../../library/datetime.rst:2478 +#: ../../library/datetime.rst:2482 msgid "" "UTC offset in the form ``±HHMM[SS[.ffffff]]`` (empty string if the object is " "naive)." @@ -4408,44 +4414,44 @@ msgstr "" "UTCオフセットを ``±HHMM[SS[.ffffff]]`` の形式で表示します (オブジェクトが" "naiveであれば空文字列)。" -#: ../../library/datetime.rst:2478 +#: ../../library/datetime.rst:2482 msgid "(empty), +0000, -0400, +1030, +063415, -030712.345216" msgstr "(空文字列), +0000, -0400, +1030, +063415, -030712.345216" -#: ../../library/datetime.rst:2478 ../../library/datetime.rst:2483 -#: ../../library/datetime.rst:2540 +#: ../../library/datetime.rst:2482 ../../library/datetime.rst:2487 +#: ../../library/datetime.rst:2544 msgid "\\(6)" msgstr "\\(6)" -#: ../../library/datetime.rst:2483 ../../library/datetime.rst:2663 +#: ../../library/datetime.rst:2487 ../../library/datetime.rst:2667 msgid "``%Z``" msgstr "``%Z``" -#: ../../library/datetime.rst:2483 +#: ../../library/datetime.rst:2487 msgid "Time zone name (empty string if the object is naive)." msgstr "タイムゾーンの名前を表示します (オブジェクトがnaiveであれば空文字列)。" -#: ../../library/datetime.rst:2483 +#: ../../library/datetime.rst:2487 msgid "(empty), UTC, GMT" msgstr "(空文字列), UTC, GMT" -#: ../../library/datetime.rst:2486 +#: ../../library/datetime.rst:2490 msgid "``%j``" msgstr "``%j``" -#: ../../library/datetime.rst:2486 +#: ../../library/datetime.rst:2490 msgid "Day of the year as a zero-padded decimal number." msgstr "0埋めした10進数で表記した年中の日にち。" -#: ../../library/datetime.rst:2486 +#: ../../library/datetime.rst:2490 msgid "001, 002, ..., 366" msgstr "001, 002, ..., 366" -#: ../../library/datetime.rst:2489 +#: ../../library/datetime.rst:2493 msgid "``%U``" msgstr "``%U``" -#: ../../library/datetime.rst:2489 +#: ../../library/datetime.rst:2493 msgid "" "Week number of the year (Sunday as the first day of the week) as a zero-" "padded decimal number. All days in a new year preceding the first Sunday are " @@ -4454,19 +4460,19 @@ msgstr "" "0埋めした10進数で表記した年中の週番号 (週の始まりは日曜日とする)。新年の最初" "の日曜日に先立つ日は 0週に属するとします。" -#: ../../library/datetime.rst:2489 ../../library/datetime.rst:2497 +#: ../../library/datetime.rst:2493 ../../library/datetime.rst:2501 msgid "00, 01, ..., 53" msgstr "00, 01, ..., 53" -#: ../../library/datetime.rst:2489 ../../library/datetime.rst:2497 +#: ../../library/datetime.rst:2493 ../../library/datetime.rst:2501 msgid "\\(7), \\(9)" msgstr "\\(7), \\(9)" -#: ../../library/datetime.rst:2497 +#: ../../library/datetime.rst:2501 msgid "``%W``" msgstr "``%W``" -#: ../../library/datetime.rst:2497 +#: ../../library/datetime.rst:2501 msgid "" "Week number of the year (Monday as the first day of the week) as a zero-" "padded decimal number. All days in a new year preceding the first Monday are " @@ -4475,11 +4481,11 @@ msgstr "" "0埋めした10進数で表記した年中の週番号 (週の始まりは月曜日とする)。新年の最初" "の月曜日に先立つ日は 0週に属するとします。" -#: ../../library/datetime.rst:2505 +#: ../../library/datetime.rst:2509 msgid "``%c``" msgstr "``%c``" -#: ../../library/datetime.rst:2505 +#: ../../library/datetime.rst:2509 msgid "Locale's appropriate date and time representation." msgstr "ロケールの日時を適切な形式で表します。" @@ -4491,11 +4497,11 @@ msgstr "Tue Aug 16 21:30:00 1988 (en_US);" msgid "Di 16 Aug 21:30:00 1988 (de_DE)" msgstr "Di 16 Aug 21:30:00 1988 (de_DE)" -#: ../../library/datetime.rst:2510 +#: ../../library/datetime.rst:2514 msgid "``%x``" msgstr "``%x``" -#: ../../library/datetime.rst:2510 +#: ../../library/datetime.rst:2514 msgid "Locale's appropriate date representation." msgstr "ロケールの日付を適切な形式で表します。" @@ -4511,11 +4517,11 @@ msgstr "08/16/1988 (en_US);" msgid "16.08.1988 (de_DE)" msgstr "16.08.1988 (de_DE)" -#: ../../library/datetime.rst:2514 +#: ../../library/datetime.rst:2518 msgid "``%X``" msgstr "``%X``" -#: ../../library/datetime.rst:2514 +#: ../../library/datetime.rst:2518 msgid "Locale's appropriate time representation." msgstr "ロケールの時間を適切な形式で表します。" @@ -4527,19 +4533,19 @@ msgstr "21:30:00 (en_US);" msgid "21:30:00 (de_DE)" msgstr "21:30:00 (de_DE)" -#: ../../library/datetime.rst:2517 +#: ../../library/datetime.rst:2521 msgid "``%%``" msgstr "``%%``" -#: ../../library/datetime.rst:2517 +#: ../../library/datetime.rst:2521 msgid "A literal ``'%'`` character." msgstr "文字 ``'%'`` を表します。" -#: ../../library/datetime.rst:2517 +#: ../../library/datetime.rst:2521 msgid "%" msgstr "%" -#: ../../library/datetime.rst:2520 +#: ../../library/datetime.rst:2524 msgid "" "Several additional directives not required by the C89 standard are included " "for convenience. These parameters all correspond to ISO 8601 date values." @@ -4547,37 +4553,37 @@ msgstr "" "C89規格により要求されない幾つかの追加のコードが便宜上含まれています。これらの" "パラメータはすべてISO 8601の日付値に対応しています。" -#: ../../library/datetime.rst:2526 +#: ../../library/datetime.rst:2530 msgid "``%G``" msgstr "``%G``" -#: ../../library/datetime.rst:2526 +#: ../../library/datetime.rst:2530 msgid "" "ISO 8601 year with century representing the year that contains the greater " "part of the ISO week (``%V``)." msgstr "ISO week(``%V``)の内過半数を含む西暦表記の ISO 8601 year です。" -#: ../../library/datetime.rst:2526 +#: ../../library/datetime.rst:2530 msgid "\\(8)" msgstr "\\(8)" -#: ../../library/datetime.rst:2531 +#: ../../library/datetime.rst:2535 msgid "``%u``" msgstr "``%u``" -#: ../../library/datetime.rst:2531 +#: ../../library/datetime.rst:2535 msgid "ISO 8601 weekday as a decimal number where 1 is Monday." msgstr "1 を月曜日を表す 10進数表記の ISO 8601 weekday です。" -#: ../../library/datetime.rst:2531 +#: ../../library/datetime.rst:2535 msgid "1, 2, ..., 7" msgstr "1, 2, ..., 7" -#: ../../library/datetime.rst:2534 +#: ../../library/datetime.rst:2538 msgid "``%V``" msgstr "``%V``" -#: ../../library/datetime.rst:2534 +#: ../../library/datetime.rst:2538 msgid "" "ISO 8601 week as a decimal number with Monday as the first day of the week. " "Week 01 is the week containing Jan 4." @@ -4585,19 +4591,19 @@ msgstr "" "週で最初の月曜日を始めとする ISO 8601 week です。Week 01 は 1月4日を含みま" "す。" -#: ../../library/datetime.rst:2534 +#: ../../library/datetime.rst:2538 msgid "01, 02, ..., 53" msgstr "01, 02, ..., 53" -#: ../../library/datetime.rst:2534 +#: ../../library/datetime.rst:2538 msgid "\\(8), \\(9)" msgstr "\\(8), \\(9)" -#: ../../library/datetime.rst:2540 ../../library/datetime.rst:2659 +#: ../../library/datetime.rst:2544 ../../library/datetime.rst:2663 msgid "``%:z``" msgstr "``%:z``" -#: ../../library/datetime.rst:2540 +#: ../../library/datetime.rst:2544 msgid "" "UTC offset in the form ``±HH:MM[:SS[.ffffff]]`` (empty string if the object " "is naive)." @@ -4605,11 +4611,11 @@ msgstr "" "UTCオフセットを ``±HH:MM[:SS[.ffffff]]`` の形式で表示します (オブジェクトが" "naiveであれば空文字列)。" -#: ../../library/datetime.rst:2540 +#: ../../library/datetime.rst:2544 msgid "(empty), +00:00, -04:00, +10:30, +06:34:15, -03:07:12.345216" msgstr "(空文字列), +00:00, -04:00, +10:30, +06:34:15, -03:07:12.345216" -#: ../../library/datetime.rst:2546 +#: ../../library/datetime.rst:2550 msgid "" "These may not be available on all platforms when used with the :meth:`~." "datetime.strftime` method. The ISO 8601 year and ISO 8601 week directives " @@ -4623,7 +4629,7 @@ msgstr "" "せん。不完全またはあいまいなISO 8601 指定子で :meth:`~.datetime.strptime` を" "呼び出すと、 :exc:`ValueError` が送出されます。" -#: ../../library/datetime.rst:2551 +#: ../../library/datetime.rst:2555 msgid "" "The full set of format codes supported varies across platforms, because " "Python calls the platform C library's :c:func:`strftime` function, and " @@ -4640,19 +4646,19 @@ msgstr "" "サポートされていないフォーマット指定子の扱いもプラットフォーム間で差異があり" "ます。" -#: ../../library/datetime.rst:2557 +#: ../../library/datetime.rst:2561 msgid "``%G``, ``%u`` and ``%V`` were added." msgstr "``%G``, ``%u`` および ``%V`` が追加されました。" -#: ../../library/datetime.rst:2560 +#: ../../library/datetime.rst:2564 msgid "``%:z`` was added." msgstr "``%:z`` が追加されました。" -#: ../../library/datetime.rst:2564 +#: ../../library/datetime.rst:2568 msgid "Technical Detail" msgstr "技術詳細" -#: ../../library/datetime.rst:2566 +#: ../../library/datetime.rst:2570 msgid "" "Broadly speaking, ``d.strftime(fmt)`` acts like the :mod:`time` module's " "``time.strftime(fmt, d.timetuple())`` although not all objects support a :" @@ -4662,7 +4668,7 @@ msgstr "" "strftime(fmt, d.timetuple())`` のように動作します。ただし全てのオブジェクト" "が :meth:`~date.timetuple` メソッドをサポートしているわけではありません。" -#: ../../library/datetime.rst:2570 +#: ../../library/datetime.rst:2574 msgid "" "For the :meth:`.datetime.strptime` class method, the default value is " "``1900-01-01T00:00:00.000``: any components not specified in the format " @@ -4672,11 +4678,11 @@ msgstr "" "``1900-01-01T00:00:00.000`` です。書式文字列で指定されなかった部分はデフォル" "ト値から引っ張ってきます。 [#]_" -#: ../../library/datetime.rst:2574 +#: ../../library/datetime.rst:2578 msgid "Using ``datetime.strptime(date_string, format)`` is equivalent to::" msgstr "``datetime.strptime(date_string, format)`` は次の式と等価です::" -#: ../../library/datetime.rst:2578 +#: ../../library/datetime.rst:2582 msgid "" "except when the format includes sub-second components or time zone offset " "information, which are supported in ``datetime.strptime`` but are discarded " @@ -4686,7 +4692,7 @@ msgstr "" "い、秒未満の単位やタイムゾーンオフセットの情報が format に 含まれているときは" "除きます。" -#: ../../library/datetime.rst:2582 +#: ../../library/datetime.rst:2586 msgid "" "For :class:`.time` objects, the format codes for year, month, and day should " "not be used, as :class:`!time` objects have no such values. If they're used " @@ -4696,7 +4702,7 @@ msgstr "" "を使うことができません。\n" "無理矢理使った場合、年は1900に置き換えられ、月と日は1に置き換えられます。" -#: ../../library/datetime.rst:2586 +#: ../../library/datetime.rst:2590 msgid "" "For :class:`date` objects, the format codes for hours, minutes, seconds, and " "microseconds should not be used, as :class:`date` objects have no such " @@ -4706,7 +4712,7 @@ msgstr "" "の書式コードを使うことができません。\n" "無理矢理使った場合、これらの値は0に置き換えられます。" -#: ../../library/datetime.rst:2590 +#: ../../library/datetime.rst:2594 msgid "" "For the same reason, handling of format strings containing Unicode code " "points that can't be represented in the charset of the current locale is " @@ -4720,7 +4726,7 @@ msgstr "" "方、他のプラットフォームでは ``strftime`` が :exc:`UnicodeError` を送出した" "り、その代わりに空文字列を返したりするかもしれません。" -#: ../../library/datetime.rst:2599 +#: ../../library/datetime.rst:2603 msgid "" "Because the format depends on the current locale, care should be taken when " "making assumptions about the output value. Field orderings will vary (for " @@ -4728,7 +4734,7 @@ msgid "" "contain non-ASCII characters." msgstr "" -#: ../../library/datetime.rst:2605 +#: ../../library/datetime.rst:2609 msgid "" "The :meth:`~.datetime.strptime` method can parse years in the full [1, 9999] " "range, but years < 1000 must be zero-filled to 4-digit width." @@ -4737,7 +4743,7 @@ msgstr "" "きますが、 year < 1000 の範囲の年数は 0 埋めされた 4 桁の数字でなければなりま" "せん。" -#: ../../library/datetime.rst:2608 +#: ../../library/datetime.rst:2612 msgid "" "In previous versions, :meth:`~.datetime.strftime` method was restricted to " "years >= 1900." @@ -4745,7 +4751,7 @@ msgstr "" "以前のバージョンでは、 :meth:`~.datetime.strftime` メソッドは years >= 1900 " "の範囲の年数しか扱えませんでした。" -#: ../../library/datetime.rst:2612 +#: ../../library/datetime.rst:2616 msgid "" "In version 3.2, :meth:`~.datetime.strftime` method was restricted to years " ">= 1000." @@ -4753,7 +4759,7 @@ msgstr "" "バージョン 3.2 では、 :meth:`~.datetime.strftime` メソッドは years >= 1000 の" "範囲の年数しか扱えませんでした。" -#: ../../library/datetime.rst:2617 +#: ../../library/datetime.rst:2621 msgid "" "When used with the :meth:`~.datetime.strptime` method, the ``%p`` directive " "only affects the output hour field if the ``%I`` directive is used to parse " @@ -4763,7 +4769,7 @@ msgstr "" "の時間フィールドのみに影響し、 ``%I`` 指定子が使われたかのように振る舞いま" "す。" -#: ../../library/datetime.rst:2621 +#: ../../library/datetime.rst:2625 msgid "" "Unlike the :mod:`time` module, the :mod:`!datetime` module does not support " "leap seconds." @@ -4771,7 +4777,7 @@ msgstr "" ":mod:`time` モジュールと違い、 :mod:`!datetime` モジュールはうるう秒をサポー" "トしていません。" -#: ../../library/datetime.rst:2625 +#: ../../library/datetime.rst:2629 msgid "" "When used with the :meth:`~.datetime.strptime` method, the ``%f`` directive " "accepts from one to six digits and zero pads on the right. ``%f`` is an " @@ -4783,7 +4789,7 @@ msgstr "" "``%f`` は C 標準規格の書式文字セットの拡張です (とは言え、 datetime モジュー" "ルのオブジェクトそれぞれに実装されているので、どれででも使えます)。" -#: ../../library/datetime.rst:2632 +#: ../../library/datetime.rst:2636 msgid "" "For a naive object, the ``%z``, ``%:z`` and ``%Z`` format codes are replaced " "by empty strings." @@ -4791,11 +4797,11 @@ msgstr "" "naive オブジェクトでは、書式コード ``%z``、``%:z`` および ``%Z`` は空文字列に" "置き換えられます。" -#: ../../library/datetime.rst:2635 +#: ../../library/datetime.rst:2639 msgid "For an aware object:" msgstr "aware オブジェクトでは次のようになります:" -#: ../../library/datetime.rst:2638 +#: ../../library/datetime.rst:2642 msgid "" ":meth:`~.datetime.utcoffset` is transformed into a string of the form " "``±HHMM[SS[.ffffff]]``, where ``HH`` is a 2-digit string giving the number " @@ -4818,7 +4824,7 @@ msgstr "" "例えば、 :meth:`~.datetime.utcoffset` が ``timedelta(hours=-3, " "minutes=-30)`` を返す場合、 ``%z`` は文字列 ``'-0330'`` に置き換えられます。" -#: ../../library/datetime.rst:2652 +#: ../../library/datetime.rst:2656 msgid "" "When the ``%z`` directive is provided to the :meth:`~.datetime.strptime` " "method, the UTC offsets can have a colon as a separator between hours, " @@ -4831,13 +4837,13 @@ msgstr "" "例えば、 ``'+01:00:00'`` は 1 時間のオフセットだと構文解析されます。\n" "加えて、 ``'Z'`` を渡すことは ``'+00:00'`` を渡すことと同等です。" -#: ../../library/datetime.rst:2660 +#: ../../library/datetime.rst:2664 msgid "" "Behaves exactly as ``%z``, but has a colon separator added between hours, " "minutes and seconds." msgstr "" -#: ../../library/datetime.rst:2664 +#: ../../library/datetime.rst:2668 msgid "" "In :meth:`~.datetime.strftime`, ``%Z`` is replaced by an empty string if :" "meth:`~.datetime.tzname` returns ``None``; otherwise ``%Z`` is replaced by " @@ -4847,19 +4853,19 @@ msgstr "" "返した場合、 ``%Z`` は空文字列に置き換わります。そうでない場合、 ``%Z`` は返" "された値に置き換わりますが、 これは文字列でなければなりません。" -#: ../../library/datetime.rst:2668 +#: ../../library/datetime.rst:2672 msgid ":meth:`~.datetime.strptime` only accepts certain values for ``%Z``:" msgstr ":meth:`~.datetime.strptime` は ``%Z`` に特定の値のみを受け入れます:" -#: ../../library/datetime.rst:2670 +#: ../../library/datetime.rst:2674 msgid "any value in ``time.tzname`` for your machine's locale" msgstr "使用しているマシンのロケールによる ``time.tzname`` の任意の値" -#: ../../library/datetime.rst:2671 +#: ../../library/datetime.rst:2675 msgid "the hard-coded values ``UTC`` and ``GMT``" msgstr "ハードコードされた値 ``UTC`` または ``GMT``" -#: ../../library/datetime.rst:2673 +#: ../../library/datetime.rst:2677 msgid "" "So someone living in Japan may have ``JST``, ``UTC``, and ``GMT`` as valid " "values, but probably not ``EST``. It will raise ``ValueError`` for invalid " @@ -4869,7 +4875,7 @@ msgstr "" "り、 ``EST`` はおそらく無効な値となります。無効な値の場合は ``ValueError`` を" "送出します。" -#: ../../library/datetime.rst:2677 +#: ../../library/datetime.rst:2681 msgid "" "When the ``%z`` directive is provided to the :meth:`~.datetime.strptime` " "method, an aware :class:`.datetime` object will be produced. The ``tzinfo`` " @@ -4879,7 +4885,7 @@ msgstr "" "な :class:`.datetime` オブジェクトが作成されます。返り値の ``tzinfo`` は :" "class:`timezone` インスタンスになっています。" -#: ../../library/datetime.rst:2683 +#: ../../library/datetime.rst:2687 msgid "" "When used with the :meth:`~.datetime.strptime` method, ``%U`` and ``%W`` are " "only used in calculations when the day of the week and the calendar year " @@ -4888,7 +4894,7 @@ msgstr "" ":meth:`~.datetime.strptime` メソッドと共に使われた場合、 ``%U`` と ``%W`` 指" "定子は、曜日と年(``%Y``)が指定された場合の計算でのみ使われます。" -#: ../../library/datetime.rst:2688 +#: ../../library/datetime.rst:2692 msgid "" "Similar to ``%U`` and ``%W``, ``%V`` is only used in calculations when the " "day of the week and the ISO year (``%G``) are specified in a :meth:`~." @@ -4899,7 +4905,7 @@ msgstr "" "datetime.strptime` の書式文字列の中で指定された場合に計算でのみ使われます。\n" "``%G`` と ``%Y`` は互いに完全な互換性を持たないことにも注意してください。" -#: ../../library/datetime.rst:2694 +#: ../../library/datetime.rst:2698 msgid "" "When used with the :meth:`~.datetime.strptime` method, the leading zero is " "optional for formats ``%d``, ``%m``, ``%H``, ``%I``, ``%M``, ``%S``, " @@ -4911,7 +4917,7 @@ msgstr "" "任意です。\n" "書式 ``%y`` では先行ゼロは必須です。" -#: ../../library/datetime.rst:2699 +#: ../../library/datetime.rst:2703 msgid "" "When parsing a month and day using :meth:`~.datetime.strptime`, always " "include a year in the format. If the value you need to parse lacks a year, " @@ -4920,7 +4926,7 @@ msgid "" "parser is not a leap year. Users run into this bug every four years..." msgstr "" -#: ../../library/datetime.rst:2705 +#: ../../library/datetime.rst:2709 msgid "" ">>> month_day = \"02/29\"\n" ">>> datetime.strptime(f\"{month_day};1984\", \"%m/%d;%Y\") # No leap year " @@ -4928,7 +4934,7 @@ msgid "" "datetime.datetime(1984, 2, 29, 0, 0)" msgstr "" -#: ../../library/datetime.rst:2711 +#: ../../library/datetime.rst:2715 msgid "" ":meth:`~.datetime.strptime` calls using a format string containing a day of " "month without a year now emit a :exc:`DeprecationWarning`. In 3.15 or later " @@ -4936,15 +4942,15 @@ msgid "" "See :gh:`70647`." msgstr "" -#: ../../library/datetime.rst:2718 +#: ../../library/datetime.rst:2722 msgid "Footnotes" msgstr "脚注" -#: ../../library/datetime.rst:2719 +#: ../../library/datetime.rst:2723 msgid "If, that is, we ignore the effects of Relativity" msgstr "もし相対性理論の効果を無視するならば、ですが" -#: ../../library/datetime.rst:2721 +#: ../../library/datetime.rst:2725 msgid "" "This matches the definition of the \"proleptic Gregorian\" calendar in " "Dershowitz and Reingold's book *Calendrical Calculations*, where it's the " @@ -4958,7 +4964,7 @@ msgstr "" "先発グレゴリオ暦の序数とその他多くの暦法どうしの変換アルゴリズムについては、" "この書籍を参照してください。" -#: ../../library/datetime.rst:2727 +#: ../../library/datetime.rst:2731 msgid "" "See R. H. van Gent's `guide to the mathematics of the ISO 8601 calendar " "`_ を参照してください。" -#: ../../library/datetime.rst:2731 +#: ../../library/datetime.rst:2735 msgid "" "Passing ``datetime.strptime('Feb 29', '%b %d')`` will fail since 1900 is not " "a leap year." @@ -4976,10 +4982,10 @@ msgstr "" "1900は閏年ではないので ``datetime.strptime('Feb 29', '%b %d')`` を渡すと失敗" "します。" -#: ../../library/datetime.rst:2372 +#: ../../library/datetime.rst:2376 msgid "% (percent)" msgstr "% (パーセント)" -#: ../../library/datetime.rst:2372 +#: ../../library/datetime.rst:2376 msgid "datetime format" msgstr "" diff --git a/library/dbm.po b/library/dbm.po index aeb87f241..8bc7afb9a 100644 --- a/library/dbm.po +++ b/library/dbm.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:04+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -263,9 +263,9 @@ msgid "" "including the SQLite CLI." msgstr "" -#: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +#: ../../includes/wasm-mobile-notavail.rst:3 ../../includes/wasm-notavail.rst:3 +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" @@ -313,10 +313,6 @@ msgid "" "incompatible and can not be used interchangeably." msgstr "" -#: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." -msgstr "" - #: ../../includes/wasm-mobile-notavail.rst:5 msgid "" "This module is not supported on :ref:`mobile platforms `." msgstr "" -#: ../../library/dis.rst:1013 +#: ../../library/dis.rst:1014 msgid "" "Unpacks ``STACK[-1]`` into *count* individual values, which are put onto the " "stack right-to-left. Require there to be exactly *count* values.::" msgstr "" -#: ../../library/dis.rst:1016 +#: ../../library/dis.rst:1017 msgid "" "assert(len(STACK[-1]) == count)\n" "STACK.extend(STACK.pop()[:-count-1:-1])" msgstr "" -#: ../../library/dis.rst:1022 +#: ../../library/dis.rst:1023 msgid "" "Implements assignment with a starred target: Unpacks an iterable in " "``STACK[-1]`` into individual values, where the total number of values can " @@ -1183,11 +1185,11 @@ msgid "" "will be a list of all leftover items." msgstr "" -#: ../../library/dis.rst:1027 +#: ../../library/dis.rst:1028 msgid "The number of values before and after the list value is limited to 255." msgstr "" -#: ../../library/dis.rst:1029 +#: ../../library/dis.rst:1030 msgid "" "The number of values before the list value is encoded in the argument of the " "opcode. The number of values after the list if any is encoded using an " @@ -1196,67 +1198,67 @@ msgid "" "list value, the high byte of *counts* the number of values after it." msgstr "" -#: ../../library/dis.rst:1035 +#: ../../library/dis.rst:1036 msgid "" "The extracted values are put onto the stack right-to-left, i.e. ``a, *b, c = " "d`` will be stored after execution as ``STACK.extend((a, b, c))``." msgstr "" -#: ../../library/dis.rst:1043 +#: ../../library/dis.rst:1044 msgid "" "obj = STACK.pop()\n" "value = STACK.pop()\n" "obj.name = value" msgstr "" -#: ../../library/dis.rst:1047 +#: ../../library/dis.rst:1048 msgid "" "where *namei* is the index of name in :attr:`~codeobject.co_names` of the :" "ref:`code object `." msgstr "" -#: ../../library/dis.rst:1054 +#: ../../library/dis.rst:1055 msgid "" "obj = STACK.pop()\n" "del obj.name" msgstr "" -#: ../../library/dis.rst:1057 +#: ../../library/dis.rst:1058 msgid "" "where *namei* is the index of name into :attr:`~codeobject.co_names` of the :" "ref:`code object `." msgstr "" -#: ../../library/dis.rst:1063 +#: ../../library/dis.rst:1064 msgid "Works as :opcode:`STORE_NAME`, but stores the name as a global." msgstr "" ":opcode:`STORE_NAME` と同じように動作しますが、 name をグローバルとして保存し" "ます。" -#: ../../library/dis.rst:1068 +#: ../../library/dis.rst:1069 msgid "Works as :opcode:`DELETE_NAME`, but deletes a global name." msgstr "" ":opcode:`DELETE_NAME` と同じように動作しますが、グローバルの name を削除しま" "す。" -#: ../../library/dis.rst:1073 +#: ../../library/dis.rst:1074 msgid "Pushes ``co_consts[consti]`` onto the stack." msgstr "``co_consts[consti]`` をスタックにプッシュします。" -#: ../../library/dis.rst:1078 +#: ../../library/dis.rst:1079 msgid "" "Pushes the value associated with ``co_names[namei]`` onto the stack. The " "name is looked up within the locals, then the globals, then the builtins." msgstr "" -#: ../../library/dis.rst:1084 +#: ../../library/dis.rst:1085 msgid "" "Pushes a reference to the locals dictionary onto the stack. This is used to " "prepare namespace dictionaries for :opcode:`LOAD_FROM_DICT_OR_DEREF` and :" "opcode:`LOAD_FROM_DICT_OR_GLOBALS`." msgstr "" -#: ../../library/dis.rst:1093 +#: ../../library/dis.rst:1094 msgid "" "Pops a mapping off the stack and looks up the value for ``co_names[namei]``. " "If the name is not found there, looks it up in the globals and then the " @@ -1265,13 +1267,13 @@ msgid "" "bodies." msgstr "" -#: ../../library/dis.rst:1104 +#: ../../library/dis.rst:1105 msgid "" "Creates a tuple consuming *count* items from the stack, and pushes the " "resulting tuple onto the stack::" msgstr "" -#: ../../library/dis.rst:1107 +#: ../../library/dis.rst:1108 msgid "" "if count == 0:\n" " value = ()\n" @@ -1282,85 +1284,85 @@ msgid "" "STACK.append(value)" msgstr "" -#: ../../library/dis.rst:1118 +#: ../../library/dis.rst:1119 msgid "Works as :opcode:`BUILD_TUPLE`, but creates a list." msgstr "" ":opcode:`BUILD_TUPLE` と同じように動作しますが、この命令はリストを作り出しま" "す。" -#: ../../library/dis.rst:1123 +#: ../../library/dis.rst:1124 msgid "Works as :opcode:`BUILD_TUPLE`, but creates a set." msgstr "" ":opcode:`BUILD_TUPLE` と同じように動作しますが、この命令は set を作り出しま" "す。" -#: ../../library/dis.rst:1128 +#: ../../library/dis.rst:1129 msgid "" "Pushes a new dictionary object onto the stack. Pops ``2 * count`` items so " "that the dictionary holds *count* entries: ``{..., STACK[-4]: STACK[-3], " "STACK[-2]: STACK[-1]}``." msgstr "" -#: ../../library/dis.rst:1132 +#: ../../library/dis.rst:1133 msgid "" "The dictionary is created from stack items instead of creating an empty " "dictionary pre-sized to hold *count* items." msgstr "" -#: ../../library/dis.rst:1139 +#: ../../library/dis.rst:1140 msgid "" "The version of :opcode:`BUILD_MAP` specialized for constant keys. Pops the " "top element on the stack which contains a tuple of keys, then starting from " "``STACK[-2]``, pops *count* values to form values in the built dictionary." msgstr "" -#: ../../library/dis.rst:1148 +#: ../../library/dis.rst:1149 msgid "" "Concatenates *count* strings from the stack and pushes the resulting string " "onto the stack." msgstr "" -#: ../../library/dis.rst:1158 +#: ../../library/dis.rst:1159 msgid "" "seq = STACK.pop()\n" "list.extend(STACK[-i], seq)" msgstr "" -#: ../../library/dis.rst:1161 +#: ../../library/dis.rst:1162 msgid "Used to build lists." msgstr "" -#: ../../library/dis.rst:1170 +#: ../../library/dis.rst:1171 msgid "" "seq = STACK.pop()\n" "set.update(STACK[-i], seq)" msgstr "" -#: ../../library/dis.rst:1173 +#: ../../library/dis.rst:1174 msgid "Used to build sets." msgstr "" -#: ../../library/dis.rst:1182 +#: ../../library/dis.rst:1183 msgid "" "map = STACK.pop()\n" "dict.update(STACK[-i], map)" msgstr "" -#: ../../library/dis.rst:1185 +#: ../../library/dis.rst:1186 msgid "Used to build dicts." msgstr "" -#: ../../library/dis.rst:1192 +#: ../../library/dis.rst:1193 msgid "Like :opcode:`DICT_UPDATE` but raises an exception for duplicate keys." msgstr "" -#: ../../library/dis.rst:1199 +#: ../../library/dis.rst:1200 msgid "" "If the low bit of ``namei`` is not set, this replaces ``STACK[-1]`` with " "``getattr(STACK[-1], co_names[namei>>1])``." msgstr "" -#: ../../library/dis.rst:1202 +#: ../../library/dis.rst:1203 msgid "" "If the low bit of ``namei`` is set, this will attempt to load a method named " "``co_names[namei>>1]`` from the ``STACK[-1]`` object. ``STACK[-1]`` is " @@ -1372,76 +1374,76 @@ msgid "" "pushed." msgstr "" -#: ../../library/dis.rst:1211 +#: ../../library/dis.rst:1212 msgid "" "If the low bit of ``namei`` is set, then a ``NULL`` or ``self`` is pushed to " "the stack before the attribute or unbound method respectively." msgstr "" -#: ../../library/dis.rst:1218 +#: ../../library/dis.rst:1219 msgid "" "This opcode implements :func:`super`, both in its zero-argument and two-" "argument forms (e.g. ``super().method()``, ``super().attr`` and ``super(cls, " "self).method()``, ``super(cls, self).attr``)." msgstr "" -#: ../../library/dis.rst:1222 +#: ../../library/dis.rst:1223 msgid "It pops three values from the stack (from top of stack down):" msgstr "" -#: ../../library/dis.rst:1224 +#: ../../library/dis.rst:1225 msgid "``self``: the first argument to the current method" msgstr "" -#: ../../library/dis.rst:1225 +#: ../../library/dis.rst:1226 msgid "``cls``: the class within which the current method was defined" msgstr "" -#: ../../library/dis.rst:1226 +#: ../../library/dis.rst:1227 msgid "the global ``super``" msgstr "" -#: ../../library/dis.rst:1228 +#: ../../library/dis.rst:1229 msgid "" "With respect to its argument, it works similarly to :opcode:`LOAD_ATTR`, " "except that ``namei`` is shifted left by 2 bits instead of 1." msgstr "" -#: ../../library/dis.rst:1231 +#: ../../library/dis.rst:1232 msgid "" "The low bit of ``namei`` signals to attempt a method load, as with :opcode:" "`LOAD_ATTR`, which results in pushing ``NULL`` and the loaded method. When " "it is unset a single value is pushed to the stack." msgstr "" -#: ../../library/dis.rst:1235 +#: ../../library/dis.rst:1236 msgid "" "The second-low bit of ``namei``, if set, means that this was a two-argument " "call to :func:`super` (unset means zero-argument)." msgstr "" -#: ../../library/dis.rst:1243 +#: ../../library/dis.rst:1244 msgid "" "Performs a Boolean operation. The operation name can be found in " "``cmp_op[opname >> 5]``. If the fifth-lowest bit of ``opname`` is set " "(``opname & 16``), the result should be coerced to ``bool``." msgstr "" -#: ../../library/dis.rst:1247 +#: ../../library/dis.rst:1248 msgid "" "The fifth-lowest bit of the oparg now indicates a forced conversion to :" "class:`bool`." msgstr "" -#: ../../library/dis.rst:1254 +#: ../../library/dis.rst:1255 msgid "Performs ``is`` comparison, or ``is not`` if ``invert`` is 1." msgstr "" -#: ../../library/dis.rst:1261 +#: ../../library/dis.rst:1262 msgid "Performs ``in`` comparison, or ``not in`` if ``invert`` is 1." msgstr "" -#: ../../library/dis.rst:1268 +#: ../../library/dis.rst:1269 msgid "" "Imports the module ``co_names[namei]``. ``STACK[-1]`` and ``STACK[-2]`` are " "popped and provide the *fromlist* and *level* arguments of :func:" @@ -1450,68 +1452,68 @@ msgid "" "opcode:`STORE_FAST` instruction modifies the namespace." msgstr "" -#: ../../library/dis.rst:1276 +#: ../../library/dis.rst:1277 msgid "" "Loads the attribute ``co_names[namei]`` from the module found in " "``STACK[-1]``. The resulting object is pushed onto the stack, to be " "subsequently stored by a :opcode:`STORE_FAST` instruction." msgstr "" -#: ../../library/dis.rst:1283 +#: ../../library/dis.rst:1284 msgid "Increments bytecode counter by *delta*." msgstr "バイトコードカウンタを *delta* だけ増加させます。" -#: ../../library/dis.rst:1288 +#: ../../library/dis.rst:1289 msgid "Decrements bytecode counter by *delta*. Checks for interrupts." msgstr "" -#: ../../library/dis.rst:1295 +#: ../../library/dis.rst:1296 msgid "Decrements bytecode counter by *delta*. Does not check for interrupts." msgstr "" -#: ../../library/dis.rst:1302 +#: ../../library/dis.rst:1303 msgid "" "If ``STACK[-1]`` is true, increments the bytecode counter by *delta*. " "``STACK[-1]`` is popped." msgstr "" -#: ../../library/dis.rst:1305 ../../library/dis.rst:1321 +#: ../../library/dis.rst:1306 ../../library/dis.rst:1322 msgid "" "The oparg is now a relative delta rather than an absolute target. This " "opcode is a pseudo-instruction, replaced in final bytecode by the directed " "versions (forward/backward)." msgstr "" -#: ../../library/dis.rst:1310 ../../library/dis.rst:1326 -#: ../../library/dis.rst:1342 ../../library/dis.rst:1356 +#: ../../library/dis.rst:1311 ../../library/dis.rst:1327 +#: ../../library/dis.rst:1343 ../../library/dis.rst:1357 msgid "This is no longer a pseudo-instruction." msgstr "" -#: ../../library/dis.rst:1318 +#: ../../library/dis.rst:1319 msgid "" "If ``STACK[-1]`` is false, increments the bytecode counter by *delta*. " "``STACK[-1]`` is popped." msgstr "" -#: ../../library/dis.rst:1334 +#: ../../library/dis.rst:1335 msgid "" "If ``STACK[-1]`` is not ``None``, increments the bytecode counter by " "*delta*. ``STACK[-1]`` is popped." msgstr "" -#: ../../library/dis.rst:1337 ../../library/dis.rst:1351 +#: ../../library/dis.rst:1338 ../../library/dis.rst:1352 msgid "" "This opcode is a pseudo-instruction, replaced in final bytecode by the " "directed versions (forward/backward)." msgstr "" -#: ../../library/dis.rst:1348 +#: ../../library/dis.rst:1349 msgid "" "If ``STACK[-1]`` is ``None``, increments the bytecode counter by *delta*. " "``STACK[-1]`` is popped." msgstr "" -#: ../../library/dis.rst:1361 +#: ../../library/dis.rst:1362 msgid "" "``STACK[-1]`` is an :term:`iterator`. Call its :meth:`~iterator.__next__` " "method. If this yields a new value, push it on the stack (leaving the " @@ -1519,188 +1521,190 @@ msgid "" "code counter is incremented by *delta*." msgstr "" -#: ../../library/dis.rst:1366 +#: ../../library/dis.rst:1367 msgid "Up until 3.11 the iterator was popped when it was exhausted." msgstr "" -#: ../../library/dis.rst:1371 +#: ../../library/dis.rst:1372 msgid "Loads the global named ``co_names[namei>>1]`` onto the stack." msgstr "" "``co_names[namei>>1]`` という名前のグローバルをスタック上にロードします。" -#: ../../library/dis.rst:1373 +#: ../../library/dis.rst:1374 msgid "" "If the low bit of ``namei`` is set, then a ``NULL`` is pushed to the stack " "before the global variable." msgstr "" -#: ../../library/dis.rst:1379 +#: ../../library/dis.rst:1380 msgid "" "Pushes a reference to the local ``co_varnames[var_num]`` onto the stack." msgstr "" "ローカルな ``co_varnames[var_num]`` への参照をスタックにプッシュします。" -#: ../../library/dis.rst:1381 +#: ../../library/dis.rst:1382 msgid "" "This opcode is now only used in situations where the local variable is " "guaranteed to be initialized. It cannot raise :exc:`UnboundLocalError`." msgstr "" -#: ../../library/dis.rst:1387 +#: ../../library/dis.rst:1388 msgid "" "Pushes a reference to the local ``co_varnames[var_num]`` onto the stack, " "raising an :exc:`UnboundLocalError` if the local variable has not been " "initialized." msgstr "" -#: ../../library/dis.rst:1395 +#: ../../library/dis.rst:1396 msgid "" "Pushes a reference to the local ``co_varnames[var_num]`` onto the stack (or " "pushes ``NULL`` onto the stack if the local variable has not been " "initialized) and sets ``co_varnames[var_num]`` to ``NULL``." msgstr "" -#: ../../library/dis.rst:1403 +#: ../../library/dis.rst:1404 msgid "Stores ``STACK.pop()`` into the local ``co_varnames[var_num]``." msgstr "" -#: ../../library/dis.rst:1408 +#: ../../library/dis.rst:1409 msgid "Deletes local ``co_varnames[var_num]``." msgstr "ローカルな ``co_varnames[var_num]`` を削除します。" -#: ../../library/dis.rst:1413 +#: ../../library/dis.rst:1414 msgid "" "Creates a new cell in slot ``i``. If that slot is nonempty then that value " "is stored into the new cell." msgstr "" -#: ../../library/dis.rst:1421 +#: ../../library/dis.rst:1422 msgid "" "Loads the cell contained in slot ``i`` of the \"fast locals\" storage. " "Pushes a reference to the object the cell contains on the stack." msgstr "" -#: ../../library/dis.rst:1424 ../../library/dis.rst:1446 -#: ../../library/dis.rst:1457 +#: ../../library/dis.rst:1425 ../../library/dis.rst:1447 +#: ../../library/dis.rst:1458 msgid "" "``i`` is no longer offset by the length of :attr:`~codeobject.co_varnames`." msgstr "" -#: ../../library/dis.rst:1430 +#: ../../library/dis.rst:1431 msgid "" "Pops a mapping off the stack and looks up the name associated with slot " "``i`` of the \"fast locals\" storage in this mapping. If the name is not " "found there, loads it from the cell contained in slot ``i``, similar to :" -"opcode:`LOAD_DEREF`. This is used for loading free variables in class bodies " -"(which previously used :opcode:`!LOAD_CLASSDEREF`) and in :ref:`annotation " -"scopes ` within class bodies." +"opcode:`LOAD_DEREF`. This is used for loading :term:`closure variables " +"` in class bodies (which previously used :opcode:`!" +"LOAD_CLASSDEREF`) and in :ref:`annotation scopes ` within " +"class bodies." msgstr "" -#: ../../library/dis.rst:1443 +#: ../../library/dis.rst:1444 msgid "" "Stores ``STACK.pop()`` into the cell contained in slot ``i`` of the \"fast " "locals\" storage." msgstr "" -#: ../../library/dis.rst:1452 +#: ../../library/dis.rst:1453 msgid "" "Empties the cell contained in slot ``i`` of the \"fast locals\" storage. " "Used by the :keyword:`del` statement." msgstr "" -#: ../../library/dis.rst:1463 +#: ../../library/dis.rst:1464 msgid "" -"Copies the ``n`` free variables from the closure into the frame. Removes the " -"need for special code on the caller's side when calling closures." +"Copies the ``n`` :term:`free (closure) variables ` from " +"the closure into the frame. Removes the need for special code on the " +"caller's side when calling closures." msgstr "" -#: ../../library/dis.rst:1472 +#: ../../library/dis.rst:1473 msgid "" "Raises an exception using one of the 3 forms of the ``raise`` statement, " "depending on the value of *argc*:" msgstr "" -#: ../../library/dis.rst:1475 +#: ../../library/dis.rst:1476 msgid "0: ``raise`` (re-raise previous exception)" msgstr "" -#: ../../library/dis.rst:1476 +#: ../../library/dis.rst:1477 msgid "" "1: ``raise STACK[-1]`` (raise exception instance or type at ``STACK[-1]``)" msgstr "" -#: ../../library/dis.rst:1477 +#: ../../library/dis.rst:1478 msgid "" "2: ``raise STACK[-2] from STACK[-1]`` (raise exception instance or type at " "``STACK[-2]`` with ``__cause__`` set to ``STACK[-1]``)" msgstr "" -#: ../../library/dis.rst:1483 +#: ../../library/dis.rst:1484 msgid "" "Calls a callable object with the number of arguments specified by ``argc``. " "On the stack are (in ascending order):" msgstr "" -#: ../../library/dis.rst:1486 ../../library/dis.rst:1510 +#: ../../library/dis.rst:1487 ../../library/dis.rst:1511 msgid "The callable" msgstr "" -#: ../../library/dis.rst:1487 ../../library/dis.rst:1511 +#: ../../library/dis.rst:1488 ../../library/dis.rst:1512 msgid "``self`` or ``NULL``" msgstr "" -#: ../../library/dis.rst:1488 ../../library/dis.rst:1512 +#: ../../library/dis.rst:1489 ../../library/dis.rst:1513 msgid "The remaining positional arguments" msgstr "" -#: ../../library/dis.rst:1490 +#: ../../library/dis.rst:1491 msgid "``argc`` is the total of the positional arguments, excluding ``self``." msgstr "" -#: ../../library/dis.rst:1492 +#: ../../library/dis.rst:1493 msgid "" "``CALL`` pops all arguments and the callable object off the stack, calls the " "callable object with those arguments, and pushes the return value returned " "by the callable object." msgstr "" -#: ../../library/dis.rst:1498 +#: ../../library/dis.rst:1499 msgid "The callable now always appears at the same position on the stack." msgstr "" -#: ../../library/dis.rst:1501 +#: ../../library/dis.rst:1502 msgid "Calls with keyword arguments are now handled by :opcode:`CALL_KW`." msgstr "" -#: ../../library/dis.rst:1507 +#: ../../library/dis.rst:1508 msgid "" "Calls a callable object with the number of arguments specified by ``argc``, " "including one or more named arguments. On the stack are (in ascending order):" msgstr "" -#: ../../library/dis.rst:1513 +#: ../../library/dis.rst:1514 msgid "The named arguments" msgstr "" -#: ../../library/dis.rst:1514 +#: ../../library/dis.rst:1515 msgid "A :class:`tuple` of keyword argument names" msgstr "" -#: ../../library/dis.rst:1516 +#: ../../library/dis.rst:1517 msgid "" "``argc`` is the total of the positional and named arguments, excluding " "``self``. The length of the tuple of keyword argument names is the number of " "named arguments." msgstr "" -#: ../../library/dis.rst:1519 +#: ../../library/dis.rst:1520 msgid "" "``CALL_KW`` pops all arguments, the keyword names, and the callable object " "off the stack, calls the callable object with those arguments, and pushes " "the return value returned by the callable object." msgstr "" -#: ../../library/dis.rst:1528 +#: ../../library/dis.rst:1529 msgid "" "Calls a callable object with variable set of positional and keyword " "arguments. If the lowest bit of *flags* is set, the top of the stack " @@ -1712,33 +1716,33 @@ msgid "" "arguments, and pushes the return value returned by the callable object." msgstr "" -#: ../../library/dis.rst:1543 +#: ../../library/dis.rst:1544 msgid "" "Pushes a ``NULL`` to the stack. Used in the call sequence to match the " "``NULL`` pushed by :opcode:`LOAD_METHOD` for non-method calls." msgstr "" -#: ../../library/dis.rst:1552 +#: ../../library/dis.rst:1553 msgid "" "Pushes a new function object on the stack built from the code object at " "``STACK[1]``." msgstr "" -#: ../../library/dis.rst:1554 +#: ../../library/dis.rst:1555 msgid "Flag value ``0x04`` is a tuple of strings instead of dictionary" msgstr "" -#: ../../library/dis.rst:1557 +#: ../../library/dis.rst:1558 msgid "Qualified name at ``STACK[-1]`` was removed." msgstr "" -#: ../../library/dis.rst:1560 +#: ../../library/dis.rst:1561 msgid "" "Extra function attributes on the stack, signaled by oparg flags, were " "removed. They now use :opcode:`SET_FUNCTION_ATTRIBUTE`." msgstr "" -#: ../../library/dis.rst:1567 +#: ../../library/dis.rst:1568 msgid "" "Sets an attribute on a function object. Expects the function at " "``STACK[-1]`` and the attribute value to set at ``STACK[-2]``; consumes both " @@ -1746,42 +1750,42 @@ msgid "" "attribute to set:" msgstr "" -#: ../../library/dis.rst:1571 +#: ../../library/dis.rst:1572 msgid "" "``0x01`` a tuple of default values for positional-only and positional-or-" "keyword parameters in positional order" msgstr "" -#: ../../library/dis.rst:1573 +#: ../../library/dis.rst:1574 msgid "``0x02`` a dictionary of keyword-only parameters' default values" msgstr "" -#: ../../library/dis.rst:1574 +#: ../../library/dis.rst:1575 msgid "``0x04`` a tuple of strings containing parameters' annotations" msgstr "" -#: ../../library/dis.rst:1575 +#: ../../library/dis.rst:1576 msgid "``0x08`` a tuple containing cells for free variables, making a closure" msgstr "" -#: ../../library/dis.rst:1584 +#: ../../library/dis.rst:1585 msgid "" "Pushes a slice object on the stack. *argc* must be 2 or 3. If it is 2, " "implements::" msgstr "" -#: ../../library/dis.rst:1586 +#: ../../library/dis.rst:1587 msgid "" "end = STACK.pop()\n" "start = STACK.pop()\n" "STACK.append(slice(start, end))" msgstr "" -#: ../../library/dis.rst:1590 +#: ../../library/dis.rst:1591 msgid "if it is 3, implements::" msgstr "" -#: ../../library/dis.rst:1592 +#: ../../library/dis.rst:1593 msgid "" "step = STACK.pop()\n" "end = STACK.pop()\n" @@ -1789,11 +1793,11 @@ msgid "" "STACK.append(slice(start, end, step))" msgstr "" -#: ../../library/dis.rst:1597 +#: ../../library/dis.rst:1598 msgid "See the :func:`slice` built-in function for more information." msgstr "" -#: ../../library/dis.rst:1602 +#: ../../library/dis.rst:1603 msgid "" "Prefixes any opcode which has an argument too big to fit into the default " "one byte. *ext* holds an additional byte which act as higher bits in the " @@ -1801,50 +1805,50 @@ msgid "" "allowed, forming an argument from two-byte to four-byte." msgstr "" -#: ../../library/dis.rst:1610 +#: ../../library/dis.rst:1611 msgid "Convert value to a string, depending on ``oparg``::" msgstr "" -#: ../../library/dis.rst:1612 +#: ../../library/dis.rst:1613 msgid "" "value = STACK.pop()\n" "result = func(value)\n" "STACK.append(result)" msgstr "" -#: ../../library/dis.rst:1616 +#: ../../library/dis.rst:1617 msgid "``oparg == 1``: call :func:`str` on *value*" msgstr "" -#: ../../library/dis.rst:1617 +#: ../../library/dis.rst:1618 msgid "``oparg == 2``: call :func:`repr` on *value*" msgstr "" -#: ../../library/dis.rst:1618 +#: ../../library/dis.rst:1619 msgid "``oparg == 3``: call :func:`ascii` on *value*" msgstr "" -#: ../../library/dis.rst:1620 ../../library/dis.rst:1633 -#: ../../library/dis.rst:1646 +#: ../../library/dis.rst:1621 ../../library/dis.rst:1634 +#: ../../library/dis.rst:1647 msgid "Used for implementing formatted literal strings (f-strings)." msgstr "" -#: ../../library/dis.rst:1627 +#: ../../library/dis.rst:1628 msgid "Formats the value on top of stack::" msgstr "" -#: ../../library/dis.rst:1629 +#: ../../library/dis.rst:1630 msgid "" "value = STACK.pop()\n" "result = value.__format__(\"\")\n" "STACK.append(result)" msgstr "" -#: ../../library/dis.rst:1639 +#: ../../library/dis.rst:1640 msgid "Formats the given value with the given format spec::" msgstr "" -#: ../../library/dis.rst:1641 +#: ../../library/dis.rst:1642 msgid "" "spec = STACK.pop()\n" "value = STACK.pop()\n" @@ -1852,14 +1856,14 @@ msgid "" "STACK.append(result)" msgstr "" -#: ../../library/dis.rst:1653 +#: ../../library/dis.rst:1654 msgid "" "``STACK[-1]`` is a tuple of keyword attribute names, ``STACK[-2]`` is the " "class being matched against, and ``STACK[-3]`` is the match subject. " "*count* is the number of positional sub-patterns." msgstr "" -#: ../../library/dis.rst:1657 +#: ../../library/dis.rst:1658 msgid "" "Pop ``STACK[-1]``, ``STACK[-2]``, and ``STACK[-3]``. If ``STACK[-3]`` is an " "instance of ``STACK[-2]`` and has the positional and keyword attributes " @@ -1867,219 +1871,219 @@ msgid "" "Otherwise, push ``None``." msgstr "" -#: ../../library/dis.rst:1671 +#: ../../library/dis.rst:1672 msgid "A no-op. Performs internal tracing, debugging and optimization checks." msgstr "" -#: ../../library/dis.rst:1673 +#: ../../library/dis.rst:1674 msgid "" "The ``context`` oparand consists of two parts. The lowest two bits indicate " "where the ``RESUME`` occurs:" msgstr "" -#: ../../library/dis.rst:1676 +#: ../../library/dis.rst:1677 msgid "" "``0`` The start of a function, which is neither a generator, coroutine nor " "an async generator" msgstr "" -#: ../../library/dis.rst:1678 +#: ../../library/dis.rst:1679 msgid "``1`` After a ``yield`` expression" msgstr "" -#: ../../library/dis.rst:1679 +#: ../../library/dis.rst:1680 msgid "``2`` After a ``yield from`` expression" msgstr "" -#: ../../library/dis.rst:1680 +#: ../../library/dis.rst:1681 msgid "``3`` After an ``await`` expression" msgstr "" -#: ../../library/dis.rst:1682 +#: ../../library/dis.rst:1683 msgid "" "The next bit is ``1`` if the RESUME is at except-depth ``1``, and ``0`` " "otherwise." msgstr "" -#: ../../library/dis.rst:1687 +#: ../../library/dis.rst:1688 msgid "The oparg value changed to include information about except-depth" msgstr "" -#: ../../library/dis.rst:1693 +#: ../../library/dis.rst:1694 msgid "" "Create a generator, coroutine, or async generator from the current frame. " "Used as first opcode of in code object for the above mentioned callables. " "Clear the current frame and return the newly created generator." msgstr "" -#: ../../library/dis.rst:1702 +#: ../../library/dis.rst:1703 msgid "" "Equivalent to ``STACK[-1] = STACK[-2].send(STACK[-1])``. Used in ``yield " "from`` and ``await`` statements." msgstr "" -#: ../../library/dis.rst:1705 +#: ../../library/dis.rst:1706 msgid "" "If the call raises :exc:`StopIteration`, pop the top value from the stack, " "push the exception's ``value`` attribute, and increment the bytecode counter " "by *delta*." msgstr "" -#: ../../library/dis.rst:1714 +#: ../../library/dis.rst:1715 msgid "" "This is not really an opcode. It identifies the dividing line between " "opcodes in the range [0,255] which don't use their argument and those that " "do (``< HAVE_ARGUMENT`` and ``>= HAVE_ARGUMENT``, respectively)." msgstr "" -#: ../../library/dis.rst:1718 +#: ../../library/dis.rst:1719 msgid "" "If your application uses pseudo instructions or specialized instructions, " "use the :data:`hasarg` collection instead." msgstr "" -#: ../../library/dis.rst:1721 +#: ../../library/dis.rst:1722 msgid "" "Now every instruction has an argument, but opcodes ``< HAVE_ARGUMENT`` " "ignore it. Before, only opcodes ``>= HAVE_ARGUMENT`` had an argument." msgstr "" -#: ../../library/dis.rst:1725 +#: ../../library/dis.rst:1726 msgid "" "Pseudo instructions were added to the :mod:`dis` module, and for them it is " "not true that comparison with ``HAVE_ARGUMENT`` indicates whether they use " "their arg." msgstr "" -#: ../../library/dis.rst:1730 +#: ../../library/dis.rst:1731 msgid "Use :data:`hasarg` instead." msgstr "" -#: ../../library/dis.rst:1735 +#: ../../library/dis.rst:1736 msgid "" "Calls an intrinsic function with one argument. Passes ``STACK[-1]`` as the " "argument and sets ``STACK[-1]`` to the result. Used to implement " "functionality that is not performance critical." msgstr "" -#: ../../library/dis.rst:1739 ../../library/dis.rst:1793 +#: ../../library/dis.rst:1740 ../../library/dis.rst:1794 msgid "The operand determines which intrinsic function is called:" msgstr "" -#: ../../library/dis.rst:1742 ../../library/dis.rst:1796 +#: ../../library/dis.rst:1743 ../../library/dis.rst:1797 msgid "Operand" msgstr "" -#: ../../library/dis.rst:1742 ../../library/dis.rst:1796 +#: ../../library/dis.rst:1743 ../../library/dis.rst:1797 msgid "Description" msgstr "説明" -#: ../../library/dis.rst:1744 +#: ../../library/dis.rst:1745 msgid "``INTRINSIC_1_INVALID``" msgstr "" -#: ../../library/dis.rst:1744 ../../library/dis.rst:1798 +#: ../../library/dis.rst:1745 ../../library/dis.rst:1799 msgid "Not valid" msgstr "" -#: ../../library/dis.rst:1746 +#: ../../library/dis.rst:1747 msgid "``INTRINSIC_PRINT``" msgstr "" -#: ../../library/dis.rst:1746 +#: ../../library/dis.rst:1747 msgid "Prints the argument to standard out. Used in the REPL." msgstr "" -#: ../../library/dis.rst:1749 +#: ../../library/dis.rst:1750 msgid "``INTRINSIC_IMPORT_STAR``" msgstr "" -#: ../../library/dis.rst:1749 +#: ../../library/dis.rst:1750 msgid "Performs ``import *`` for the named module." msgstr "" -#: ../../library/dis.rst:1752 +#: ../../library/dis.rst:1753 msgid "``INTRINSIC_STOPITERATION_ERROR``" msgstr "" -#: ../../library/dis.rst:1752 +#: ../../library/dis.rst:1753 msgid "Extracts the return value from a ``StopIteration`` exception." msgstr "" -#: ../../library/dis.rst:1755 +#: ../../library/dis.rst:1756 msgid "``INTRINSIC_ASYNC_GEN_WRAP``" msgstr "" -#: ../../library/dis.rst:1755 +#: ../../library/dis.rst:1756 msgid "Wraps an async generator value" msgstr "" -#: ../../library/dis.rst:1757 +#: ../../library/dis.rst:1758 msgid "``INTRINSIC_UNARY_POSITIVE``" msgstr "" -#: ../../library/dis.rst:1757 +#: ../../library/dis.rst:1758 msgid "Performs the unary ``+`` operation" msgstr "" -#: ../../library/dis.rst:1760 +#: ../../library/dis.rst:1761 msgid "``INTRINSIC_LIST_TO_TUPLE``" msgstr "" -#: ../../library/dis.rst:1760 +#: ../../library/dis.rst:1761 msgid "Converts a list to a tuple" msgstr "" -#: ../../library/dis.rst:1762 +#: ../../library/dis.rst:1763 msgid "``INTRINSIC_TYPEVAR``" msgstr "" -#: ../../library/dis.rst:1762 +#: ../../library/dis.rst:1763 msgid "Creates a :class:`typing.TypeVar`" msgstr "" -#: ../../library/dis.rst:1764 +#: ../../library/dis.rst:1765 msgid "``INTRINSIC_PARAMSPEC``" msgstr "" -#: ../../library/dis.rst:1764 +#: ../../library/dis.rst:1765 msgid "Creates a :class:`typing.ParamSpec`" msgstr "" -#: ../../library/dis.rst:1767 +#: ../../library/dis.rst:1768 msgid "``INTRINSIC_TYPEVARTUPLE``" msgstr "" -#: ../../library/dis.rst:1767 +#: ../../library/dis.rst:1768 msgid "Creates a :class:`typing.TypeVarTuple`" msgstr "" -#: ../../library/dis.rst:1770 +#: ../../library/dis.rst:1771 msgid "``INTRINSIC_SUBSCRIPT_GENERIC``" msgstr "" -#: ../../library/dis.rst:1770 +#: ../../library/dis.rst:1771 msgid "Returns :class:`typing.Generic` subscripted with the argument" msgstr "" -#: ../../library/dis.rst:1773 +#: ../../library/dis.rst:1774 msgid "``INTRINSIC_TYPEALIAS``" msgstr "" -#: ../../library/dis.rst:1773 +#: ../../library/dis.rst:1774 msgid "" "Creates a :class:`typing.TypeAliasType`; used in the :keyword:`type` " "statement. The argument is a tuple of the type alias's name, type " "parameters, and value." msgstr "" -#: ../../library/dis.rst:1785 +#: ../../library/dis.rst:1786 msgid "" "Calls an intrinsic function with two arguments. Used to implement " "functionality that is not performance critical::" msgstr "" -#: ../../library/dis.rst:1788 +#: ../../library/dis.rst:1789 msgid "" "arg2 = STACK.pop()\n" "arg1 = STACK.pop()\n" @@ -2087,61 +2091,61 @@ msgid "" "STACK.append(result)" msgstr "" -#: ../../library/dis.rst:1798 +#: ../../library/dis.rst:1799 msgid "``INTRINSIC_2_INVALID``" msgstr "" -#: ../../library/dis.rst:1800 +#: ../../library/dis.rst:1801 msgid "``INTRINSIC_PREP_RERAISE_STAR``" msgstr "" -#: ../../library/dis.rst:1800 +#: ../../library/dis.rst:1801 msgid "Calculates the :exc:`ExceptionGroup` to raise from a ``try-except*``." msgstr "" -#: ../../library/dis.rst:1804 +#: ../../library/dis.rst:1805 msgid "``INTRINSIC_TYPEVAR_WITH_BOUND``" msgstr "" -#: ../../library/dis.rst:1804 +#: ../../library/dis.rst:1805 msgid "Creates a :class:`typing.TypeVar` with a bound." msgstr "" -#: ../../library/dis.rst:1807 +#: ../../library/dis.rst:1808 msgid "``INTRINSIC_TYPEVAR_WITH_CONSTRAINTS``" msgstr "" -#: ../../library/dis.rst:1807 +#: ../../library/dis.rst:1808 msgid "Creates a :class:`typing.TypeVar` with constraints." msgstr "" -#: ../../library/dis.rst:1811 +#: ../../library/dis.rst:1812 msgid "``INTRINSIC_SET_FUNCTION_TYPE_PARAMS``" msgstr "" -#: ../../library/dis.rst:1811 +#: ../../library/dis.rst:1812 msgid "Sets the ``__type_params__`` attribute of a function." msgstr "" -#: ../../library/dis.rst:1818 +#: ../../library/dis.rst:1819 msgid "**Pseudo-instructions**" msgstr "" -#: ../../library/dis.rst:1820 +#: ../../library/dis.rst:1821 msgid "" "These opcodes do not appear in Python bytecode. They are used by the " "compiler but are replaced by real opcodes or removed before bytecode is " "generated." msgstr "" -#: ../../library/dis.rst:1825 +#: ../../library/dis.rst:1826 msgid "" "Set up an exception handler for the following code block. If an exception " "occurs, the value stack level is restored to its current state and control " "is transferred to the exception handler at ``target``." msgstr "" -#: ../../library/dis.rst:1832 +#: ../../library/dis.rst:1833 msgid "" "Like ``SETUP_FINALLY``, but in case of an exception also pushes the last " "instruction (``lasti``) to the stack so that ``RERAISE`` can restore it. If " @@ -2150,58 +2154,58 @@ msgid "" "exception handler at ``target``." msgstr "" -#: ../../library/dis.rst:1841 +#: ../../library/dis.rst:1842 msgid "" "Like ``SETUP_CLEANUP``, but in case of an exception one more item is popped " "from the stack before control is transferred to the exception handler at " "``target``." msgstr "" -#: ../../library/dis.rst:1845 +#: ../../library/dis.rst:1846 msgid "" "This variant is used in :keyword:`with` and :keyword:`async with` " "constructs, which push the return value of the context manager's :meth:" "`~object.__enter__` or :meth:`~object.__aenter__` to the stack." msgstr "" -#: ../../library/dis.rst:1852 +#: ../../library/dis.rst:1853 msgid "" "Marks the end of the code block associated with the last ``SETUP_FINALLY``, " "``SETUP_CLEANUP`` or ``SETUP_WITH``." msgstr "" -#: ../../library/dis.rst:1858 +#: ../../library/dis.rst:1859 msgid "" "Undirected relative jump instructions which are replaced by their directed " "(forward/backward) counterparts by the assembler." msgstr "" -#: ../../library/dis.rst:1863 +#: ../../library/dis.rst:1864 msgid "" "Pushes a reference to the cell contained in slot ``i`` of the \"fast " "locals\" storage." msgstr "" -#: ../../library/dis.rst:1866 +#: ../../library/dis.rst:1867 msgid "" "Note that ``LOAD_CLOSURE`` is replaced with ``LOAD_FAST`` in the assembler." msgstr "" -#: ../../library/dis.rst:1868 +#: ../../library/dis.rst:1869 msgid "This opcode is now a pseudo-instruction." msgstr "" -#: ../../library/dis.rst:1874 +#: ../../library/dis.rst:1875 msgid "" "Optimized unbound method lookup. Emitted as a ``LOAD_ATTR`` opcode with a " "flag set in the arg." msgstr "" -#: ../../library/dis.rst:1881 +#: ../../library/dis.rst:1882 msgid "Opcode collections" msgstr "命令コードコレクション" -#: ../../library/dis.rst:1883 +#: ../../library/dis.rst:1884 msgid "" "These collections are provided for automatic introspection of bytecode " "instructions:" @@ -2209,83 +2213,84 @@ msgstr "" "これらのコレクションは、自動でバイトコード命令を解析するために提供されていま" "す:" -#: ../../library/dis.rst:1886 +#: ../../library/dis.rst:1887 msgid "" "The collections now contain pseudo instructions and instrumented " "instructions as well. These are opcodes with values ``>= MIN_PSEUDO_OPCODE`` " "and ``>= MIN_INSTRUMENTED_OPCODE``." msgstr "" -#: ../../library/dis.rst:1893 +#: ../../library/dis.rst:1894 msgid "Sequence of operation names, indexable using the bytecode." msgstr "" "命令コード名のリスト。\n" "バイトコードをインデックスに使って参照できます。" -#: ../../library/dis.rst:1898 +#: ../../library/dis.rst:1899 msgid "Dictionary mapping operation names to bytecodes." msgstr "命令コード名をバイトコードに対応づける辞書。" -#: ../../library/dis.rst:1903 +#: ../../library/dis.rst:1904 msgid "Sequence of all compare operation names." msgstr "すべての比較命令の名前のリスト。" -#: ../../library/dis.rst:1908 +#: ../../library/dis.rst:1909 msgid "Sequence of bytecodes that use their argument." msgstr "" -#: ../../library/dis.rst:1915 +#: ../../library/dis.rst:1916 msgid "Sequence of bytecodes that access a constant." msgstr "定数にアクセスするバイトコードのリスト。" -#: ../../library/dis.rst:1920 +#: ../../library/dis.rst:1921 msgid "" -"Sequence of bytecodes that access a free variable. 'free' in this context " -"refers to names in the current scope that are referenced by inner scopes or " -"names in outer scopes that are referenced from this scope. It does *not* " -"include references to global or builtin scopes." +"Sequence of bytecodes that access a :term:`free (closure) variable `. 'free' in this context refers to names in the current scope that " +"are referenced by inner scopes or names in outer scopes that are referenced " +"from this scope. It does *not* include references to global or builtin " +"scopes." msgstr "" -#: ../../library/dis.rst:1928 +#: ../../library/dis.rst:1929 msgid "Sequence of bytecodes that access an attribute by name." msgstr "名前によって属性にアクセスするバイトコードのリスト。" -#: ../../library/dis.rst:1933 +#: ../../library/dis.rst:1934 msgid "Sequence of bytecodes that have a jump target. All jumps are relative." msgstr "" -#: ../../library/dis.rst:1940 +#: ../../library/dis.rst:1941 msgid "Sequence of bytecodes that access a local variable." msgstr "ローカル変数にアクセスするバイトコードのリスト。" -#: ../../library/dis.rst:1945 +#: ../../library/dis.rst:1946 msgid "Sequence of bytecodes of Boolean operations." msgstr "ブール命令のバイトコードのリスト。" -#: ../../library/dis.rst:1949 +#: ../../library/dis.rst:1950 msgid "Sequence of bytecodes that set an exception handler." msgstr "" -#: ../../library/dis.rst:1956 +#: ../../library/dis.rst:1957 msgid "Sequence of bytecodes that have a relative jump target." msgstr "相対ジャンプ先を持つバイトコードのリスト。" -#: ../../library/dis.rst:1958 +#: ../../library/dis.rst:1959 msgid "All jumps are now relative. Use :data:`hasjump`." msgstr "" -#: ../../library/dis.rst:1964 +#: ../../library/dis.rst:1965 msgid "Sequence of bytecodes that have an absolute jump target." msgstr "絶対ジャンプ先を持つバイトコードのリスト。" -#: ../../library/dis.rst:1966 +#: ../../library/dis.rst:1967 msgid "All jumps are now relative. This list is empty." msgstr "" -#: ../../library/dis.rst:1582 +#: ../../library/dis.rst:1583 msgid "built-in function" msgstr "組み込み関数" -#: ../../library/dis.rst:1582 +#: ../../library/dis.rst:1583 msgid "slice" msgstr "slice" diff --git a/library/ensurepip.po b/library/ensurepip.po index e31aed0e8..844d345c0 100644 --- a/library/ensurepip.po +++ b/library/ensurepip.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:05+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -85,7 +85,7 @@ msgid "The original rationale and specification for this module." msgstr "このモジュールのもともとの論拠と仕様。" #: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." +msgid "Availability" msgstr "" #: ../../includes/wasm-mobile-notavail.rst:5 diff --git a/library/errno.po b/library/errno.po index 2ac13fa9f..2e27165af 100644 --- a/library/errno.po +++ b/library/errno.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:05+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -633,8 +633,8 @@ msgid "" msgstr "" #: ../../library/errno.rst:673 -msgid ":ref:`Availability `: WASI, FreeBSD" -msgstr ":ref:`利用可能な環境 `: WASI, FreeBSD" +msgid "Availability" +msgstr "" #: ../../library/errno.rst:680 msgid "Operation canceled" diff --git a/library/fcntl.po b/library/fcntl.po index e79a281d5..d5f596be4 100644 --- a/library/fcntl.po +++ b/library/fcntl.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:06+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -38,8 +38,8 @@ msgid "" msgstr "" #: ../../library/fcntl.rst:21 -msgid ":ref:`Availability `: Unix, not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外の Unix 。" +msgid "Availability" +msgstr "" #: ../../library/fcntl.rst:23 msgid "" diff --git a/library/ftplib.po b/library/ftplib.po index eab53662b..26f2900ff 100644 --- a/library/ftplib.po +++ b/library/ftplib.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:06+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -57,8 +57,8 @@ msgid "The default encoding is UTF-8, following :rfc:`2640`." msgstr "" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/functions.po b/library/functions.po index 4cff31398..304d73670 100644 --- a/library/functions.po +++ b/library/functions.po @@ -27,7 +27,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:06+0000\n" "Last-Translator: TENMYO Masakazu, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -542,8 +542,8 @@ msgstr "" "先頭に \"0b\" が付いて欲しい、もしくは付いて欲しくない場合には、次の方法のど" "ちらでも使えます。" -#: ../../library/functions.rst:141 ../../library/functions.rst:931 -#: ../../library/functions.rst:1311 +#: ../../library/functions.rst:141 ../../library/functions.rst:932 +#: ../../library/functions.rst:1312 msgid "See also :func:`format` for more information." msgstr "より詳しいことは :func:`format` も参照してください。" @@ -564,7 +564,7 @@ msgstr "" "せん。このクラスのインスタンスは ``False`` と ``True`` のみです (:ref:" "`typebool` を参照してください)。" -#: ../../library/functions.rst:156 ../../library/functions.rst:796 +#: ../../library/functions.rst:156 ../../library/functions.rst:797 msgid "The parameter is now positional-only." msgstr "引数は位置専用になりました。" @@ -994,8 +994,8 @@ msgstr "" "単一の文字列や数値を複素数に変換する、あるいは実部と虚部から複素数を作成しま" "す。" -#: ../../library/functions.rst:384 ../../library/functions.rst:741 -#: ../../library/functions.rst:987 +#: ../../library/functions.rst:384 ../../library/functions.rst:742 +#: ../../library/functions.rst:988 msgid "Examples:" msgstr "例:" @@ -1099,8 +1099,8 @@ msgstr "引数がすべて省略された場合は、 ``0j`` を返します。" msgid "The complex type is described in :ref:`typesnumeric`." msgstr "複素数型については :ref:`typesnumeric` に説明があります。" -#: ../../library/functions.rst:447 ../../library/functions.rst:793 -#: ../../library/functions.rst:1036 +#: ../../library/functions.rst:447 ../../library/functions.rst:794 +#: ../../library/functions.rst:1037 msgid "Grouping digits with underscores as in code literals is allowed." msgstr "コードリテラル中で桁をグループ化するのにアンダースコアを利用できます。" @@ -1393,7 +1393,7 @@ msgstr "" "literal_eval` も参照してください。" #: ../../library/functions.rst:629 ../../library/functions.rst:631 -#: ../../library/functions.rst:685 ../../library/functions.rst:687 +#: ../../library/functions.rst:686 ../../library/functions.rst:688 msgid "" "Raises an :ref:`auditing event ` ``exec`` with the code object as " "the argument. Code compilation events may also be raised." @@ -1401,11 +1401,11 @@ msgstr "" "コードオブジェクトを引数として :ref:`監査イベント ` ``exec`` を送出" "します。コードコンパイルのイベントも送出されることがあります。" -#: ../../library/functions.rst:636 ../../library/functions.rst:707 +#: ../../library/functions.rst:636 ../../library/functions.rst:708 msgid "The *globals* and *locals* arguments can now be passed as keywords." msgstr "*globals* と *locals* 引数 はキーワードとして渡せるようになった。" -#: ../../library/functions.rst:640 ../../library/functions.rst:711 +#: ../../library/functions.rst:640 ../../library/functions.rst:712 msgid "" "The semantics of the default *locals* namespace have been adjusted as " "described for the :func:`locals` builtin." @@ -1484,16 +1484,12 @@ msgstr "" #: ../../library/functions.rst:680 msgid "" "The *closure* argument specifies a closure--a tuple of cellvars. It's only " -"valid when the *object* is a code object containing free variables. The " -"length of the tuple must exactly match the number of free variables " -"referenced by the code object." +"valid when the *object* is a code object containing :term:`free (closure) " +"variables `. The length of the tuple must exactly match " +"the length of the code object'S :attr:`~codeobject.co_freevars` attribute." msgstr "" -"引数 *closure* はクロージャ、すなわちセル変数のタプルを指定します。この引数" -"は *object* が自由変数を含むコードオブジェクトである場合のみ有効です。タプル" -"の長さはコードオブジェクトから参照されている自由変数の数と厳密に一致しなけれ" -"ばなりません。" -#: ../../library/functions.rst:692 +#: ../../library/functions.rst:693 msgid "" "The built-in functions :func:`globals` and :func:`locals` return the current " "global and local namespace, respectively, which may be useful to pass around " @@ -1503,7 +1499,7 @@ msgstr "" "ルおよびローカルの名前空間を返すので、それらを :func:`exec` の第二、第三引数" "にそのまま渡して使うと便利なことがあります。" -#: ../../library/functions.rst:698 +#: ../../library/functions.rst:699 msgid "" "The default *locals* act as described for function :func:`locals` below. " "Pass an explicit *locals* dictionary if you need to see effects of the code " @@ -1513,11 +1509,11 @@ msgstr "" "`exec` の呼び出しが返る時にコードが *locals* に与える影響を知りたいなら、明示" "的に *locals* 辞書を渡してください。" -#: ../../library/functions.rst:702 +#: ../../library/functions.rst:703 msgid "Added the *closure* parameter." msgstr "*closure* パラメータが追加されました。" -#: ../../library/functions.rst:717 +#: ../../library/functions.rst:718 msgid "" "Construct an iterator from those elements of *iterable* for which *function* " "is true. *iterable* may be either a sequence, a container which supports " @@ -1529,7 +1525,7 @@ msgstr "" "テレータを渡せます。 *function* が ``None`` のときは恒等関数が指定されたもの" "として扱われ、 *iterable* のうち偽であるものがすべて取り除かれます。" -#: ../../library/functions.rst:723 +#: ../../library/functions.rst:724 msgid "" "Note that ``filter(function, iterable)`` is equivalent to the generator " "expression ``(item for item in iterable if function(item))`` if function is " @@ -1540,7 +1536,7 @@ msgstr "" "タ式 ``(item for item in iterable if function(item))`` と同等で、関数が " "``None`` なら ``(item for item in iterable if item)`` と同等です。" -#: ../../library/functions.rst:728 +#: ../../library/functions.rst:729 msgid "" "See :func:`itertools.filterfalse` for the complementary function that " "returns elements of *iterable* for which *function* is false." @@ -1548,11 +1544,11 @@ msgstr "" "逆の働きをする関数については、 :func:`itertools.filterfalse` を参照してくださ" "い。 *iterable* の要素のうち、 *function* が偽であるものを返します。" -#: ../../library/functions.rst:739 +#: ../../library/functions.rst:740 msgid "Return a floating-point number constructed from a number or a string." msgstr "数または文字列から生成された浮動小数点数を返します。" -#: ../../library/functions.rst:743 +#: ../../library/functions.rst:744 msgid "" ">>> float('+1.23')\n" "1.23\n" @@ -1576,7 +1572,7 @@ msgstr "" ">>> float('-Infinity')\n" "-inf" -#: ../../library/functions.rst:756 +#: ../../library/functions.rst:757 msgid "" "If the argument is a string, it should contain a decimal number, optionally " "preceded by a sign, and optionally embedded in whitespace. The optional " @@ -1593,7 +1589,7 @@ msgstr "" "尾の空白文字を除き、以下に示す :token:`~float:floatvalue` の生成規則に従う必" "要があります:" -#: ../../library/functions.rst:777 +#: ../../library/functions.rst:778 msgid "" "Case is not significant, so, for example, \"inf\", \"Inf\", \"INFINITY\", " "and \"iNfINity\" are all acceptable spellings for positive infinity." @@ -1601,7 +1597,7 @@ msgstr "" "大文字と小文字は重要ではないので、例えば、 \"inf\", \"Inf\", \"INFINITY\", " "\"iNfINity\" はすべて正の無限大を表す綴りとして受け入れられます。" -#: ../../library/functions.rst:780 +#: ../../library/functions.rst:781 msgid "" "Otherwise, if the argument is an integer or a floating-point number, a " "floating-point number with the same value (within Python's floating-point " @@ -1612,7 +1608,7 @@ msgstr "" "値の浮動小数点数が返されます。 引数が Python の浮動小数点数の範囲外なら、 :" "exc:`OverflowError` が送出されます。" -#: ../../library/functions.rst:785 +#: ../../library/functions.rst:786 msgid "" "For a general Python object ``x``, ``float(x)`` delegates to ``x." "__float__()``. If :meth:`~object.__float__` is not defined then it falls " @@ -1622,15 +1618,15 @@ msgstr "" "に委譲します。 :meth:`~object.__float__()` が定義されていない場合、:meth:" "`~object.__index__` へフォールバックします。" -#: ../../library/functions.rst:789 +#: ../../library/functions.rst:790 msgid "If no argument is given, ``0.0`` is returned." msgstr "引数が与えられなければ、``0.0`` が返されます。" -#: ../../library/functions.rst:791 +#: ../../library/functions.rst:792 msgid "The float type is described in :ref:`typesnumeric`." msgstr "浮動小数点数型については、 :ref:`typesnumeric` も参照してください。" -#: ../../library/functions.rst:799 +#: ../../library/functions.rst:800 msgid "" "Falls back to :meth:`~object.__index__` if :meth:`~object.__float__` is not " "defined." @@ -1638,7 +1634,7 @@ msgstr "" ":meth:`~object.__float__` が定義されていない場合、 :meth:`~object.__index__` " "へフォールバックします。" -#: ../../library/functions.rst:809 +#: ../../library/functions.rst:810 msgid "" "Convert a *value* to a \"formatted\" representation, as controlled by " "*format_spec*. The interpretation of *format_spec* will depend on the type " @@ -1649,7 +1645,7 @@ msgstr "" "す。 *format_spec* の解釈は *value* 引数の型に依存しますが、ほとんどの組み込" "み型で使われる標準的な構文が存在します: :ref:`formatspec`。" -#: ../../library/functions.rst:814 +#: ../../library/functions.rst:815 msgid "" "The default *format_spec* is an empty string which usually gives the same " "effect as calling :func:`str(value) `." @@ -1657,7 +1653,7 @@ msgstr "" "デフォルトの *format_spec* は空の文字列です。それは通常 :func:`str(value) " "` の呼び出しと同じ結果になります。" -#: ../../library/functions.rst:817 +#: ../../library/functions.rst:818 msgid "" "A call to ``format(value, format_spec)`` is translated to ``type(value)." "__format__(value, format_spec)`` which bypasses the instance dictionary when " @@ -1673,7 +1669,7 @@ msgstr "" "り、 *format_spec* や返り値が文字列でなかったりした場合、 :exc:`TypeError` が" "送出されます。" -#: ../../library/functions.rst:824 +#: ../../library/functions.rst:825 msgid "" "``object().__format__(format_spec)`` raises :exc:`TypeError` if " "*format_spec* is not an empty string." @@ -1681,7 +1677,7 @@ msgstr "" "*format_spec* が空の文字列でない場合 ``object().__format__(format_spec)`` " "は :exc:`TypeError` を送出します。" -#: ../../library/functions.rst:833 +#: ../../library/functions.rst:834 msgid "" "Return a new :class:`frozenset` object, optionally with elements taken from " "*iterable*. ``frozenset`` is a built-in class. See :class:`frozenset` and :" @@ -1692,7 +1688,7 @@ msgstr "" "関するドキュメントは :class:`frozenset` と :ref:`types-set` を参照してくださ" "い。" -#: ../../library/functions.rst:837 +#: ../../library/functions.rst:838 msgid "" "For other containers see the built-in :class:`set`, :class:`list`, :class:" "`tuple`, and :class:`dict` classes, as well as the :mod:`collections` module." @@ -1700,7 +1696,7 @@ msgstr "" "他のコンテナについては、ビルトインクラス :class:`set`, :class:`list`, :class:" "`tuple`, :class:`dict` や :mod:`collections` モジュールを見てください。" -#: ../../library/functions.rst:845 +#: ../../library/functions.rst:846 msgid "" "Return the value of the named attribute of *object*. *name* must be a " "string. If the string is the name of one of the object's attributes, the " @@ -1717,7 +1713,7 @@ msgstr "" "れます。 *name* は Python 識別子である必要はありません (:func:`setattr` を参" "照してください)。" -#: ../../library/functions.rst:854 +#: ../../library/functions.rst:855 msgid "" "Since :ref:`private name mangling ` happens at " "compilation time, one must manually mangle a private attribute's (attributes " @@ -1729,7 +1725,7 @@ msgstr "" "名前を持つ属性) の値を :func:`getattr` で取り出すためには、属性名を手動でマン" "グリングする必要があります。" -#: ../../library/functions.rst:862 +#: ../../library/functions.rst:863 msgid "" "Return the dictionary implementing the current module namespace. For code " "within functions, this is set when the function is defined and remains the " @@ -1739,7 +1735,7 @@ msgstr "" "は、関数が定義されるときに辞書が設定され、その関数がどこから呼ばれたかにかか" "わらず同じ内容になります。" -#: ../../library/functions.rst:869 +#: ../../library/functions.rst:870 msgid "" "The arguments are an object and a string. The result is ``True`` if the " "string is the name of one of the object's attributes, ``False`` if not. " @@ -1751,7 +1747,7 @@ msgstr "" "``getattr(object, name)`` を呼び出して :exc:`AttributeError` を送出するかどう" "かを見ることで実装されています。)" -#: ../../library/functions.rst:877 +#: ../../library/functions.rst:878 msgid "" "Return the hash value of the object (if it has one). Hash values are " "integers. They are used to quickly compare dictionary keys during a " @@ -1763,7 +1759,7 @@ msgstr "" "なる数値は等しいハッシュ値を持ちます (1 と 1.0 のように型が異なっていてもで" "す)。" -#: ../../library/functions.rst:884 +#: ../../library/functions.rst:885 msgid "" "For objects with custom :meth:`~object.__hash__` methods, note that :func:" "`hash` truncates the return value based on the bit width of the host machine." @@ -1772,7 +1768,7 @@ msgstr "" "func:`hash` が実行するマシンのビット幅に合わせて戻り値を切り捨てることに注意" "してください。" -#: ../../library/functions.rst:891 +#: ../../library/functions.rst:892 msgid "" "Invoke the built-in help system. (This function is intended for interactive " "use.) If no argument is given, the interactive help system starts on the " @@ -1788,7 +1784,7 @@ msgstr "" "コンソール上に印字されます。引数がその他のオブジェクトの場合、そのオブジェク" "トに関するヘルプページが生成されます。" -#: ../../library/functions.rst:898 +#: ../../library/functions.rst:899 msgid "" "Note that if a slash(/) appears in the parameter list of a function when " "invoking :func:`help`, it means that the parameters prior to the slash are " @@ -1800,13 +1796,13 @@ msgstr "" "さい。より詳しい情報は、 :ref:`位置専用引数についての FAQ の項目 ` を参照してください。" -#: ../../library/functions.rst:903 +#: ../../library/functions.rst:904 msgid "" "This function is added to the built-in namespace by the :mod:`site` module." msgstr "" "この関数は、 :mod:`site` モジュールから、組み込みの名前空間に移されました。" -#: ../../library/functions.rst:905 +#: ../../library/functions.rst:906 msgid "" "Changes to :mod:`pydoc` and :mod:`inspect` mean that the reported signatures " "for callables are now more comprehensive and consistent." @@ -1814,7 +1810,7 @@ msgstr "" ":mod:`pydoc` と :mod:`inspect` への変更により、呼び出し可能オブジェクトの報告" "されたシグニチャがより包括的で一貫性のあるものになりました。" -#: ../../library/functions.rst:912 +#: ../../library/functions.rst:913 msgid "" "Convert an integer number to a lowercase hexadecimal string prefixed with " "\"0x\". If *x* is not a Python :class:`int` object, it has to define an :" @@ -1825,7 +1821,7 @@ msgstr "" "`~object.__index__` メソッドが定義されていなければなりません。\n" "いくつかの例を示します:" -#: ../../library/functions.rst:921 +#: ../../library/functions.rst:922 msgid "" "If you want to convert an integer number to an uppercase or lower " "hexadecimal string with prefix or not, you can use either of the following " @@ -1834,14 +1830,14 @@ msgstr "" "整数を大文字の 16 進文字列や小文字の 16 進文字列、先頭の \"0x\" 付きや " "\"0x\" 無しに変換したい場合は、次に挙げる方法が使えます:" -#: ../../library/functions.rst:933 +#: ../../library/functions.rst:934 msgid "" "See also :func:`int` for converting a hexadecimal string to an integer using " "a base of 16." msgstr "" "16を底として16進数文字列を整数に変換するには :func:`int` も参照してください。" -#: ../../library/functions.rst:938 +#: ../../library/functions.rst:939 msgid "" "To obtain a hexadecimal string representation for a float, use the :meth:" "`float.hex` method." @@ -1849,7 +1845,7 @@ msgstr "" "浮動小数点数の16進文字列表記を得たい場合には、 :meth:`float.hex` メソッドを" "使って下さい。" -#: ../../library/functions.rst:944 +#: ../../library/functions.rst:945 msgid "" "Return the \"identity\" of an object. This is an integer which is " "guaranteed to be unique and constant for this object during its lifetime. " @@ -1860,11 +1856,11 @@ msgstr "" "期間中は一意かつ定数であることが保証されています。有効期間が重ならない 2 つの" "オブジェクトは同じ :func:`id` 値を持つかもしれません。" -#: ../../library/functions.rst:949 +#: ../../library/functions.rst:950 msgid "This is the address of the object in memory." msgstr "これはオブジェクトのメモリアドレスです。" -#: ../../library/functions.rst:951 +#: ../../library/functions.rst:952 msgid "" "Raises an :ref:`auditing event ` ``builtins.id`` with argument " "``id``." @@ -1872,7 +1868,7 @@ msgstr "" "引数 ``id`` を指定して :ref:`監査イベント ` ``builtins.id`` を送出" "します。 " -#: ../../library/functions.rst:957 +#: ../../library/functions.rst:958 msgid "" "If the *prompt* argument is present, it is written to standard output " "without a trailing newline. The function then reads a line from input, " @@ -1884,7 +1880,7 @@ msgstr "" "いて) 返します。 EOF が読み込まれたとき、 :exc:`EOFError` が送出されます。" "例::" -#: ../../library/functions.rst:962 +#: ../../library/functions.rst:963 msgid "" ">>> s = input('--> ') \n" "--> Monty Python's Flying Circus\n" @@ -1896,7 +1892,7 @@ msgstr "" ">>> s \n" "\"Monty Python's Flying Circus\"" -#: ../../library/functions.rst:967 +#: ../../library/functions.rst:968 msgid "" "If the :mod:`readline` module was loaded, then :func:`input` will use it to " "provide elaborate line editing and history features." @@ -1904,7 +1900,7 @@ msgstr "" ":mod:`readline` モジュールが読み込まれていれば、 :func:`input` はそれを使って" "精緻な行編集やヒストリ機能を提供します。" -#: ../../library/functions.rst:970 ../../library/functions.rst:972 +#: ../../library/functions.rst:971 ../../library/functions.rst:973 msgid "" "Raises an :ref:`auditing event ` ``builtins.input`` with argument " "``prompt`` before reading input" @@ -1912,7 +1908,7 @@ msgstr "" "入力を読み込む前に、引数 ``prompt`` 付きで :ref:`監査イベント ` " "``builtins.input`` を送出します。" -#: ../../library/functions.rst:975 ../../library/functions.rst:977 +#: ../../library/functions.rst:976 ../../library/functions.rst:978 msgid "" "Raises an :ref:`auditing event ` ``builtins.input/result`` with " "the result after successfully reading input." @@ -1920,7 +1916,7 @@ msgstr "" "入力の読み込みに成功した後に、その結果付きで :ref:`監査イベント ` " "``builtins.input/result`` を送出します。" -#: ../../library/functions.rst:984 +#: ../../library/functions.rst:985 msgid "" "Return an integer object constructed from a number or a string, or return " "``0`` if no arguments are given." @@ -1928,7 +1924,7 @@ msgstr "" "数または文字列から生成された整数オブジェクトを返します。引数が指定されない場" "合は ``0`` を返します。" -#: ../../library/functions.rst:989 +#: ../../library/functions.rst:990 msgid "" ">>> int(123.45)\n" "123\n" @@ -1956,7 +1952,7 @@ msgstr "" ">>> int('01110011', base=2)\n" "115" -#: ../../library/functions.rst:1004 +#: ../../library/functions.rst:1005 msgid "" "If the argument defines :meth:`~object.__int__`, ``int(x)`` returns ``x." "__int__()``. If the argument defines :meth:`~object.__index__`, it returns " @@ -1970,7 +1966,7 @@ msgstr "" "れている場合は、 ``x.__trunc__()`` を返します。浮動小数点数については、これ" "は 0 に近い側へ切り捨てます。" -#: ../../library/functions.rst:1010 +#: ../../library/functions.rst:1011 msgid "" "If the argument is not a number or if *base* is given, then it must be a " "string, :class:`bytes`, or :class:`bytearray` instance representing an " @@ -1985,7 +1981,7 @@ msgstr "" "の先頭に任意の数のゼロを付けたり、前後に空白文字を付けたり、各桁を単一の下線" "で区切ったりしても有効です。" -#: ../../library/functions.rst:1016 +#: ../../library/functions.rst:1017 msgid "" "A base-n integer string contains digits, each representing a value from 0 to " "n-1. The values 0--9 can be represented by any Unicode decimal digit. The " @@ -2010,11 +2006,11 @@ msgstr "" "ち ``int('010', 0)`` は基数を0に指定しているため不正ですが、 ``int('010')`` " "や ``int('010', 8)`` は有効です。" -#: ../../library/functions.rst:1027 +#: ../../library/functions.rst:1028 msgid "The integer type is described in :ref:`typesnumeric`." msgstr "整数型については、 :ref:`typesnumeric` も参照してください。" -#: ../../library/functions.rst:1029 +#: ../../library/functions.rst:1030 msgid "" "If *base* is not an instance of :class:`int` and the *base* object has a :" "meth:`base.__index__ ` method, that method is called to " @@ -2027,11 +2023,11 @@ msgstr "" "__index__ ` ではなく :meth:`base.__int__ ` " "を使用していました。" -#: ../../library/functions.rst:1039 +#: ../../library/functions.rst:1040 msgid "The first parameter is now positional-only." msgstr "第1引数は位置専用になりました。" -#: ../../library/functions.rst:1042 +#: ../../library/functions.rst:1043 msgid "" "Falls back to :meth:`~object.__index__` if :meth:`~object.__int__` is not " "defined." @@ -2039,11 +2035,11 @@ msgstr "" ":meth:`~object.__int__` が定義されていない場合、 :meth:`~object.__index__` へ" "フォールバックします。" -#: ../../library/functions.rst:1045 +#: ../../library/functions.rst:1046 msgid "The delegation to :meth:`~object.__trunc__` is deprecated." msgstr ":meth:`~object.__trunc__` への処理の委譲は非推奨になりました。" -#: ../../library/functions.rst:1048 +#: ../../library/functions.rst:1049 msgid "" ":class:`int` string inputs and string representations can be limited to help " "avoid denial of service attacks. A :exc:`ValueError` is raised when the " @@ -2058,7 +2054,7 @@ msgstr "" "`ValueError` が送出されます。詳しくは :ref:`整数文字列の変換における長さ制限 " "` を参照してください。" -#: ../../library/functions.rst:1058 +#: ../../library/functions.rst:1059 msgid "" "Return ``True`` if the *object* argument is an instance of the *classinfo* " "argument, or of a (direct, indirect, or :term:`virtual `) of *classinfo*. A class is considered a " @@ -2102,7 +2098,7 @@ msgstr "" "ば ``True`` を返します。上記以外の値が指定された場合、 :exc:`TypeError` 例外" "が送出されます。" -#: ../../library/functions.rst:1090 +#: ../../library/functions.rst:1091 msgid "" "Return an :term:`iterator` object. The first argument is interpreted very " "differently depending on the presence of the second argument. Without a " @@ -2129,11 +2125,11 @@ msgstr "" "*object* を呼び出します; 戻り値が *sentinel* と等しければ、 :exc:" "`StopIteration` が送出されます。それ以外の場合は戻り値がそのまま返されます。" -#: ../../library/functions.rst:1104 +#: ../../library/functions.rst:1105 msgid "See also :ref:`typeiter`." msgstr ":ref:`typeiter` も見てください。" -#: ../../library/functions.rst:1106 +#: ../../library/functions.rst:1107 msgid "" "One useful application of the second form of :func:`iter` is to build a " "block-reader. For example, reading fixed-width blocks from a binary database " @@ -2144,7 +2140,7 @@ msgstr "" "例えば、バイナリのデータベースファイルから固定幅のブロックをファイルの終端に" "到達するまで読み出すには次のようにします::" -#: ../../library/functions.rst:1110 +#: ../../library/functions.rst:1111 msgid "" "from functools import partial\n" "with open('mydata.db', 'rb') as f:\n" @@ -2156,7 +2152,7 @@ msgstr "" " for block in iter(partial(f.read, 64), b''):\n" " process_block(block)" -#: ../../library/functions.rst:1118 +#: ../../library/functions.rst:1119 msgid "" "Return the length (the number of items) of an object. The argument may be a " "sequence (such as a string, bytes, tuple, list, or range) or a collection " @@ -2165,7 +2161,7 @@ msgstr "" "オブジェクトの長さ (要素の数) を返します。引数はシーケンス (文字列、バイト" "列、タプル、リスト、range 等) かコレクション (辞書、集合、凍結集合等) です。" -#: ../../library/functions.rst:1124 +#: ../../library/functions.rst:1125 msgid "" "``len`` raises :exc:`OverflowError` on lengths larger than :data:`sys." "maxsize`, such as :class:`range(2 ** 100) `." @@ -2173,7 +2169,7 @@ msgstr "" "``len`` は、例えば :class:`range(2 ** 100) ` のような、 :data:`sys." "maxsize` を超える長さに対して :exc:`OverflowError` を送出します。" -#: ../../library/functions.rst:1133 +#: ../../library/functions.rst:1134 msgid "" "Rather than being a function, :class:`list` is actually a mutable sequence " "type, as documented in :ref:`typesseq-list` and :ref:`typesseq`." @@ -2181,7 +2177,7 @@ msgstr "" ":class:`list` は、実際には関数ではなくミュータブルなシーケンス型で、 :ref:" "`typesseq-list` と :ref:`typesseq` にドキュメント化されています。" -#: ../../library/functions.rst:1139 +#: ../../library/functions.rst:1140 msgid "" "Return a mapping object representing the current local symbol table, with " "variable names as the keys, and their currently bound references as the " @@ -2190,7 +2186,7 @@ msgstr "" "現在のローカル シンボル テーブルを表すマッピング オブジェクトを返します。これ" "は変数名をキーとし、現在バインドされている参照を値とします。" -#: ../../library/functions.rst:1143 +#: ../../library/functions.rst:1144 msgid "" "At module scope, as well as when using :func:`exec` or :func:`eval` with a " "single namespace, this function returns the same namespace as :func:" @@ -2199,14 +2195,14 @@ msgstr "" "モジュール スコープでは、単一の名前空間で :func:`exec` や :func:`eval` を使う" "場合と同じく、この関数は :func:`globals` と同じ名前空間を返します。" -#: ../../library/functions.rst:1147 +#: ../../library/functions.rst:1148 msgid "" "At class scope, it returns the namespace that will be passed to the " "metaclass constructor." msgstr "" "クラス スコープでは、メタクラス コンストラクタに渡された名前空間を返します。" -#: ../../library/functions.rst:1150 +#: ../../library/functions.rst:1151 msgid "" "When using ``exec()`` or ``eval()`` with separate local and global " "arguments, it returns the local namespace passed in to the function call." @@ -2214,7 +2210,7 @@ msgstr "" "``exec()`` や ``eval()`` が引数 local と global が分けて使われてる場合では、" "関数の呼び出しで渡されたローカル名前空間を返します。" -#: ../../library/functions.rst:1153 +#: ../../library/functions.rst:1154 msgid "" "In all of the above cases, each call to ``locals()`` in a given frame of " "execution will return the *same* mapping object. Changes made through the " @@ -2229,7 +2225,7 @@ msgstr "" "化されます。そしてローカル変数の代入、再代入、または削除は、返されたマッピン" "グ オブジェクトの内容へ直ちに反映されます。" -#: ../../library/functions.rst:1160 +#: ../../library/functions.rst:1161 msgid "" "In an :term:`optimized scope` (including functions, generators, and " "coroutines), each call to ``locals()`` instead returns a fresh dictionary " @@ -2247,7 +2243,7 @@ msgstr "" "れません* 。また、ローカル変数や非ローカル セル参照へ代入、再代入、削除を行っ" "ても、以前に返された辞書の内容には *影響しません* 。" -#: ../../library/functions.rst:1169 +#: ../../library/functions.rst:1170 msgid "" "Calling ``locals()`` as part of a comprehension in a function, generator, or " "coroutine is equivalent to calling it in the containing scope, except that " @@ -2260,7 +2256,7 @@ msgstr "" "れた反復変数が含まれます。他のスコープでは、内包表記がネストされた関数として" "実行されているかのように振舞います。" -#: ../../library/functions.rst:1175 +#: ../../library/functions.rst:1176 msgid "" "Calling ``locals()`` as part of a generator expression is equivalent to " "calling it in a nested generator function." @@ -2268,7 +2264,7 @@ msgstr "" "``locals()`` 呼び出しがジェネレータ式の一部であれば、ネストされたジェネレータ" "関数内の呼び出しと同等です。" -#: ../../library/functions.rst:1178 +#: ../../library/functions.rst:1179 msgid "" "The behaviour of ``locals()`` in a comprehension has been updated as " "described in :pep:`709`." @@ -2276,7 +2272,7 @@ msgstr "" "内包表記における ``locals()`` の振る舞い は、 :pep:`709` で説明されているよう" "に更新されました。" -#: ../../library/functions.rst:1182 +#: ../../library/functions.rst:1183 msgid "" "As part of :pep:`667`, the semantics of mutating the mapping objects " "returned from this function are now defined. The behavior in :term:" @@ -2289,7 +2285,7 @@ msgstr "" "の振る舞いは上記のようになりました。定義されただけで、その他のスコープの振る" "舞いは以前のバージョンのままです。" -#: ../../library/functions.rst:1192 +#: ../../library/functions.rst:1193 msgid "" "Return an iterator that applies *function* to every item of *iterable*, " "yielding the results. If additional *iterables* arguments are passed, " @@ -2306,14 +2302,14 @@ msgstr "" "数タプルとして単一のイテラブルの形で整理されている場合は、 :func:`itertools." "starmap` を参照してください。" -#: ../../library/functions.rst:1204 +#: ../../library/functions.rst:1205 msgid "" "Return the largest item in an iterable or the largest of two or more " "arguments." msgstr "" "iterable の中で最大の要素、または2つ以上の引数の中で最大のものを返します。" -#: ../../library/functions.rst:1207 +#: ../../library/functions.rst:1208 msgid "" "If one positional argument is provided, it should be an :term:`iterable`. " "The largest item in the iterable is returned. If two or more positional " @@ -2323,7 +2319,7 @@ msgstr "" "けません。その iterable の最大の要素が返されます。2 つ以上のキーワード無しの" "位置引数が与えられた場合、その位置引数の中で最大のものが返されます。" -#: ../../library/functions.rst:1212 ../../library/functions.rst:1250 +#: ../../library/functions.rst:1213 ../../library/functions.rst:1251 msgid "" "There are two optional keyword-only arguments. The *key* argument specifies " "a one-argument ordering function like that used for :meth:`list.sort`. The " @@ -2339,7 +2335,7 @@ msgstr "" "イテラブルが空で *default* が与えられていない場合 :exc:`ValueError` が送出さ" "れます。" -#: ../../library/functions.rst:1218 +#: ../../library/functions.rst:1219 msgid "" "If multiple items are maximal, the function returns the first one " "encountered. This is consistent with other sort-stability preserving tools " @@ -2351,15 +2347,15 @@ msgstr "" "nlargest(1, iterable, key=keyfunc)`` のような、他のソート安定性を維持するツー" "ルと両立します。" -#: ../../library/functions.rst:1223 ../../library/functions.rst:1261 +#: ../../library/functions.rst:1224 ../../library/functions.rst:1262 msgid "Added the *default* keyword-only parameter." msgstr "キーワード専用引数 *default* が追加されました。" -#: ../../library/functions.rst:1226 ../../library/functions.rst:1264 +#: ../../library/functions.rst:1227 ../../library/functions.rst:1265 msgid "The *key* can be ``None``." msgstr "*key* 引数が ``None`` であることを許容します。" -#: ../../library/functions.rst:1234 +#: ../../library/functions.rst:1235 msgid "" "Return a \"memory view\" object created from the given argument. See :ref:" "`typememoryview` for more information." @@ -2367,14 +2363,14 @@ msgstr "" "与えられたオブジェクトから作られた \"メモリビュー\" オブジェクトを返します。" "詳しくは :ref:`typememoryview` を参照してください。" -#: ../../library/functions.rst:1242 +#: ../../library/functions.rst:1243 msgid "" "Return the smallest item in an iterable or the smallest of two or more " "arguments." msgstr "" "iterable の中で最小の要素、または2つ以上の引数の中で最小のものを返します。" -#: ../../library/functions.rst:1245 +#: ../../library/functions.rst:1246 msgid "" "If one positional argument is provided, it should be an :term:`iterable`. " "The smallest item in the iterable is returned. If two or more positional " @@ -2384,7 +2380,7 @@ msgstr "" "けません。その iterable の最小の要素が返されます。2 つ以上のキーワード無しの" "位置引数が与えられた場合、その位置引数の中で最小のものが返されます。" -#: ../../library/functions.rst:1256 +#: ../../library/functions.rst:1257 msgid "" "If multiple items are minimal, the function returns the first one " "encountered. This is consistent with other sort-stability preserving tools " @@ -2395,7 +2391,7 @@ msgstr "" "は、``sorted(iterable, key=keyfunc)[0]`` や ``heapq.nsmallest(1, iterable, " "key=keyfunc)`` のような、他のソート安定性を維持するツールと両立します。" -#: ../../library/functions.rst:1271 +#: ../../library/functions.rst:1272 msgid "" "Retrieve the next item from the :term:`iterator` by calling its :meth:" "`~iterator.__next__` method. If *default* is given, it is returned if the " @@ -2406,7 +2402,7 @@ msgstr "" "いればその値が返されます。そうでない場合は :exc:`StopIteration` が送出されま" "す。" -#: ../../library/functions.rst:1278 +#: ../../library/functions.rst:1279 msgid "" "Return a new featureless object. :class:`object` is a base for all classes. " "It has methods that are common to all instances of Python classes. This " @@ -2416,13 +2412,13 @@ msgstr "" "スの基底クラスです。これは、全ての Python クラスのインスタンスに共通のメソッ" "ド群を持ちます。この関数はいかなる引数も受け付けません。" -#: ../../library/functions.rst:1284 +#: ../../library/functions.rst:1285 msgid "" ":class:`object` instances do *not* have :attr:`~object.__dict__` attributes, " "so you can't assign arbitrary attributes to an instance of :class:`object`." msgstr "" -#: ../../library/functions.rst:1291 +#: ../../library/functions.rst:1292 msgid "" "Convert an integer number to an octal string prefixed with \"0o\". The " "result is a valid Python expression. If *x* is not a Python :class:`int` " @@ -2435,7 +2431,7 @@ msgstr "" "`~object.__index__` メソッドが定義されていなければなりません。\n" "例えば、次のようになります:" -#: ../../library/functions.rst:1301 +#: ../../library/functions.rst:1302 msgid "" "If you want to convert an integer number to an octal string either with the " "prefix \"0o\" or not, you can use either of the following ways." @@ -2443,7 +2439,7 @@ msgstr "" "整数を接頭辞 \"0o\" 付きや \"0o\" 無しの 8 進文字列に変換したい場合は、次に挙" "げる方法のいずれかを使ってください。" -#: ../../library/functions.rst:1318 +#: ../../library/functions.rst:1319 msgid "" "Open *file* and return a corresponding :term:`file object`. If the file " "cannot be opened, an :exc:`OSError` is raised. See :ref:`tut-files` for more " @@ -2453,7 +2449,7 @@ msgstr "" "す。ファイルを開くことができなければ、:exc:`OSError` が送出されます。\n" "この関数の利用例について、 :ref:`tut-files` を参照してください。" -#: ../../library/functions.rst:1322 +#: ../../library/functions.rst:1323 msgid "" "*file* is a :term:`path-like object` giving the pathname (absolute or " "relative to the current working directory) of the file to be opened or an " @@ -2467,7 +2463,7 @@ msgstr "" "が ``False`` に設定されていないかぎり、この関数が返す I/O オブジェクトがク" "ローズされるときにファイルデスクリプタもクローズされます。)" -#: ../../library/functions.rst:1328 +#: ../../library/functions.rst:1329 msgid "" "*mode* is an optional string that specifies the mode in which the file is " "opened. It defaults to ``'r'`` which means open for reading in text mode. " @@ -2491,71 +2487,71 @@ msgstr "" "ます。 (生のバイトデータを読み書きする際にはバイナリモードを使い、 " "*encoding* は指定しません。) 指定できるモードは以下の通りです:" -#: ../../library/functions.rst:1345 +#: ../../library/functions.rst:1346 msgid "Character" msgstr "文字" -#: ../../library/functions.rst:1345 +#: ../../library/functions.rst:1346 msgid "Meaning" msgstr "意味" -#: ../../library/functions.rst:1347 +#: ../../library/functions.rst:1348 msgid "``'r'``" msgstr "``'r'``" -#: ../../library/functions.rst:1347 +#: ../../library/functions.rst:1348 msgid "open for reading (default)" msgstr "読み込み用に開く (デフォルト)" -#: ../../library/functions.rst:1348 +#: ../../library/functions.rst:1349 msgid "``'w'``" msgstr "``'w'``" -#: ../../library/functions.rst:1348 +#: ../../library/functions.rst:1349 msgid "open for writing, truncating the file first" msgstr "書き込み用に開き、まずファイルを切り詰める" -#: ../../library/functions.rst:1349 +#: ../../library/functions.rst:1350 msgid "``'x'``" msgstr "``'x'``" -#: ../../library/functions.rst:1349 +#: ../../library/functions.rst:1350 msgid "open for exclusive creation, failing if the file already exists" msgstr "排他的な生成に開き、ファイルが存在する場合は失敗する" -#: ../../library/functions.rst:1350 +#: ../../library/functions.rst:1351 msgid "``'a'``" msgstr "``'a'``" -#: ../../library/functions.rst:1350 +#: ../../library/functions.rst:1351 msgid "open for writing, appending to the end of file if it exists" msgstr "書き込み用に開き、ファイルが存在する場合には末尾に追記する" -#: ../../library/functions.rst:1351 +#: ../../library/functions.rst:1352 msgid "``'b'``" msgstr "``'b'``" -#: ../../library/functions.rst:1351 ../../library/functions.rst:1495 +#: ../../library/functions.rst:1352 ../../library/functions.rst:1496 msgid "binary mode" msgstr "バイナリモード" -#: ../../library/functions.rst:1352 +#: ../../library/functions.rst:1353 msgid "``'t'``" msgstr "``'t'``" -#: ../../library/functions.rst:1352 +#: ../../library/functions.rst:1353 msgid "text mode (default)" msgstr "テキストモード (デフォルト)" -#: ../../library/functions.rst:1353 +#: ../../library/functions.rst:1354 msgid "``'+'``" msgstr "``'+'``" -#: ../../library/functions.rst:1353 +#: ../../library/functions.rst:1354 msgid "open for updating (reading and writing)" msgstr "更新用に開く (読み込み・書き込み用)" -#: ../../library/functions.rst:1356 +#: ../../library/functions.rst:1357 msgid "" "The default mode is ``'r'`` (open for reading text, a synonym of ``'rt'``). " "Modes ``'w+'`` and ``'w+b'`` open and truncate the file. Modes ``'r+'`` and " @@ -2565,7 +2561,7 @@ msgstr "" "です。 ``'w+'`` と ``'w+b'`` はファイルを開いて上書きします。 ``'r+'`` と " "``'r+b'`` はファイルを上書きせずに開きます。" -#: ../../library/functions.rst:1360 +#: ../../library/functions.rst:1361 msgid "" "As mentioned in the :ref:`io-overview`, Python distinguishes between binary " "and text I/O. Files opened in binary mode (including ``'b'`` in the *mode* " @@ -2583,7 +2579,7 @@ msgstr "" "ラットフォーム依存のエンコーディングか、*encoding* が指定された場合は指定され" "たエンコーディングを使ってデコードされます。" -#: ../../library/functions.rst:1370 +#: ../../library/functions.rst:1371 msgid "" "Python doesn't depend on the underlying operating system's notion of text " "files; all the processing is done by Python itself, and is therefore " @@ -2593,7 +2589,7 @@ msgstr "" "は依存しません; すべての処理は Python 自身で行われ、よってプラットフォーム非" "依存です。" -#: ../../library/functions.rst:1374 +#: ../../library/functions.rst:1375 msgid "" "*buffering* is an optional integer used to set the buffering policy. Pass 0 " "to switch buffering off (only allowed in binary mode), 1 to select line " @@ -2618,7 +2614,7 @@ msgstr "" "討してください。 *buffering* 引数が与えられなかった場合、デフォルトのバッファ" "リングポリシーは以下のように動作します:" -#: ../../library/functions.rst:1384 +#: ../../library/functions.rst:1385 msgid "" "Binary files are buffered in fixed-size chunks; the size of the buffer is " "chosen using a heuristic trying to determine the underlying device's \"block " @@ -2630,7 +2626,7 @@ msgstr "" "選択され、それが不可能な場合は代わりに :const:`io.DEFAULT_BUFFER_SIZE` が使わ" "れます。多くのシステムでは、バッファサイズは通常 4096 か 8192 バイト長です。" -#: ../../library/functions.rst:1389 +#: ../../library/functions.rst:1390 msgid "" "\"Interactive\" text files (files for which :meth:`~io.IOBase.isatty` " "returns ``True``) use line buffering. Other text files use the policy " @@ -2640,7 +2636,7 @@ msgstr "" "ファイル) は行バッファリングを使用します。 その他のテキストファイルは、上で説" "明したバイナリファイル用の方針を使用します。" -#: ../../library/functions.rst:1393 +#: ../../library/functions.rst:1394 msgid "" "*encoding* is the name of the encoding used to decode or encode the file. " "This should only be used in text mode. The default encoding is platform " @@ -2655,7 +2651,7 @@ msgstr "" "しくは :mod:`codecs` モジュール内のサポートしているエンコーディングのリストを" "参照してください。" -#: ../../library/functions.rst:1399 +#: ../../library/functions.rst:1400 msgid "" "*errors* is an optional string that specifies how encoding and decoding " "errors are to be handled—this cannot be used in binary mode. A variety of " @@ -2669,7 +2665,7 @@ msgstr "" "`codecs.register_error` に登録されているエラー処理の名前も使用可能です。標準" "のエラーハンドラの名前には、以下のようなものがあります:" -#: ../../library/functions.rst:1407 +#: ../../library/functions.rst:1408 msgid "" "``'strict'`` to raise a :exc:`ValueError` exception if there is an encoding " "error. The default value of ``None`` has the same effect." @@ -2677,7 +2673,7 @@ msgstr "" "``'strict'`` はエンコーディングエラーがあると例外 :exc:`ValueError` を発生さ" "せます。デフォルト値である ``None`` も同じ効果です。" -#: ../../library/functions.rst:1411 +#: ../../library/functions.rst:1412 msgid "" "``'ignore'`` ignores errors. Note that ignoring encoding errors can lead to " "data loss." @@ -2685,7 +2681,7 @@ msgstr "" "``'ignore'`` はエラーを無視します。エンコーディングエラーを無視することで、" "データが失われる可能性があることに注意してください。" -#: ../../library/functions.rst:1414 +#: ../../library/functions.rst:1415 msgid "" "``'replace'`` causes a replacement marker (such as ``'?'``) to be inserted " "where there is malformed data." @@ -2693,7 +2689,7 @@ msgstr "" "``'replace'`` は、不正な形式のデータが存在した場所に(``'?'`` のような) 置換" "マーカーを挿入します。" -#: ../../library/functions.rst:1417 +#: ../../library/functions.rst:1418 msgid "" "``'surrogateescape'`` will represent any incorrect bytes as low surrogate " "code units ranging from U+DC80 to U+DCFF. These surrogate code units will " @@ -2707,7 +2703,7 @@ msgstr "" "ドユニットは元と同じバイト列に変換されます。これはエンコーディングが不明な" "ファイルを処理するのに便利です。" -#: ../../library/functions.rst:1424 +#: ../../library/functions.rst:1425 msgid "" "``'xmlcharrefreplace'`` is only supported when writing to a file. Characters " "not supported by the encoding are replaced with the appropriate XML " @@ -2717,7 +2713,7 @@ msgstr "" "ンコーディングでサポートされない文字は、:samp:`&#{nnn};` 形式の適切な XML 文" "字参照で置換されます。" -#: ../../library/functions.rst:1428 +#: ../../library/functions.rst:1429 msgid "" "``'backslashreplace'`` replaces malformed data by Python's backslashed " "escape sequences." @@ -2725,7 +2721,7 @@ msgstr "" "``'backslashreplace'`` は不正なデータを Python のバックスラッシュ付きのエス" "ケープシーケンスで置換します。" -#: ../../library/functions.rst:1431 +#: ../../library/functions.rst:1432 msgid "" "``'namereplace'`` (also only supported when writing) replaces unsupported " "characters with ``\\N{...}`` escape sequences." @@ -2733,7 +2729,7 @@ msgstr "" "``'namereplace'`` (書き込み時のみサポートされています) はサポートされていない" "文字を ``\\N{...}`` エスケープシーケンスで置換します。" -#: ../../library/functions.rst:1439 +#: ../../library/functions.rst:1440 msgid "" "*newline* determines how to parse newline characters from the stream. It can " "be ``None``, ``''``, ``'\\n'``, ``'\\r'``, and ``'\\r\\n'``. It works as " @@ -2743,7 +2739,7 @@ msgstr "" "ます。 ``None``, ``''``, ``'\\n'``, ``'\\r'``, または ``'\\r\\n'`` のいずれか" "を指定できます。これは以下のように動作します:" -#: ../../library/functions.rst:1443 +#: ../../library/functions.rst:1444 msgid "" "When reading input from the stream, if *newline* is ``None``, universal " "newlines mode is enabled. Lines in the input can end in ``'\\n'``, " @@ -2760,7 +2756,7 @@ msgstr "" "び出し元に返されます。その他の正当な値の場合、入力行は与えられた文字列でのみ" "終わり、行末は変換されずに呼び出し元に返されます。" -#: ../../library/functions.rst:1451 +#: ../../library/functions.rst:1452 msgid "" "When writing output to the stream, if *newline* is ``None``, any ``'\\n'`` " "characters written are translated to the system default line separator, :" @@ -2774,7 +2770,7 @@ msgstr "" "*newline* がその他の正当な値の場合、全ての ``'\\n'`` 文字は与えられた文字列に" "変換されます。" -#: ../../library/functions.rst:1457 +#: ../../library/functions.rst:1458 msgid "" "If *closefd* is ``False`` and a file descriptor rather than a filename was " "given, the underlying file descriptor will be kept open when the file is " @@ -2787,7 +2783,7 @@ msgstr "" "りません。\n" "そうでない場合エラーが送出されます。" -#: ../../library/functions.rst:1462 +#: ../../library/functions.rst:1463 msgid "" "A custom opener can be used by passing a callable as *opener*. The " "underlying file descriptor for the file object is then obtained by calling " @@ -2801,11 +2797,11 @@ msgstr "" "さなければなりません。 (:mod:`os.open` を *opener* として渡すと、``None`` を" "渡したのと同様の機能になります)。" -#: ../../library/functions.rst:1468 +#: ../../library/functions.rst:1469 msgid "The newly created file is :ref:`non-inheritable `." msgstr "新たに作成されたファイルは :ref:`継承不可 ` です。" -#: ../../library/functions.rst:1470 +#: ../../library/functions.rst:1471 msgid "" "The following example uses the :ref:`dir_fd ` parameter of the :func:" "`os.open` function to open a file relative to a given directory::" @@ -2813,7 +2809,7 @@ msgstr "" "次の例は :func:`os.open` 関数の :ref:`dir_fd ` 引数を使い、与えられた" "ディレクトリからの相対パスで指定されたファイルを開きます::" -#: ../../library/functions.rst:1473 +#: ../../library/functions.rst:1474 msgid "" ">>> import os\n" ">>> dir_fd = os.open('somedir', os.O_RDONLY)\n" @@ -2835,7 +2831,7 @@ msgstr "" "...\n" ">>> os.close(dir_fd) # ファイル記述子の解放漏れがないように" -#: ../../library/functions.rst:1483 +#: ../../library/functions.rst:1484 msgid "" "The type of :term:`file object` returned by the :func:`open` function " "depends on the mode. When :func:`open` is used to open a file in a text " @@ -2863,7 +2859,7 @@ msgstr "" "バッファリングが無効なときはrawストリーム、すなわち :class:`io.RawIOBase` の" "サブクラスである :class:`io.FileIO` を返します。" -#: ../../library/functions.rst:1504 +#: ../../library/functions.rst:1505 msgid "" "See also the file handling modules, such as :mod:`fileinput`, :mod:`io` " "(where :func:`open` is declared), :mod:`os`, :mod:`os.path`, :mod:" @@ -2873,7 +2869,7 @@ msgstr "" "`os` 、 :mod:`os.path` 、 :mod:`tempfile` 、 :mod:`shutil` などの、ファイル操" "作モジュールも参照してください。" -#: ../../library/functions.rst:1508 +#: ../../library/functions.rst:1509 msgid "" "Raises an :ref:`auditing event ` ``open`` with arguments ``path``, " "``mode``, ``flags``." @@ -2881,7 +2877,7 @@ msgstr "" "引数 ``path``, ``mode``, ``flags`` を指定して :ref:`監査イベント ` " "``open`` を送出します。 " -#: ../../library/functions.rst:1510 +#: ../../library/functions.rst:1511 msgid "" "The ``mode`` and ``flags`` arguments may have been modified or inferred from " "the original call." @@ -2889,21 +2885,21 @@ msgstr "" "``mode`` と ``flags`` の2つの引数は呼び出し時の値から修正されたり、推量により" "設定されたりする可能性があります。" -#: ../../library/functions.rst:1515 +#: ../../library/functions.rst:1516 msgid "The *opener* parameter was added." msgstr "*opener* 引数を追加しました。" -#: ../../library/functions.rst:1516 +#: ../../library/functions.rst:1517 msgid "The ``'x'`` mode was added." msgstr "``'x'`` モードを追加しました。" -#: ../../library/functions.rst:1517 +#: ../../library/functions.rst:1518 msgid ":exc:`IOError` used to be raised, it is now an alias of :exc:`OSError`." msgstr "" "以前は :exc:`IOError` が送出されました; それは現在 :exc:`OSError` のエイリア" "スです。" -#: ../../library/functions.rst:1518 +#: ../../library/functions.rst:1519 msgid "" ":exc:`FileExistsError` is now raised if the file opened in exclusive " "creation mode (``'x'``) already exists." @@ -2911,11 +2907,11 @@ msgstr "" "既存のファイルを 排他的生成モード(``'x'``)で開いた場合、 :exc:" "`FileExistsError` を送出するようになりました。" -#: ../../library/functions.rst:1523 +#: ../../library/functions.rst:1524 msgid "The file is now non-inheritable." msgstr "ファイルが継承不可になりました。" -#: ../../library/functions.rst:1527 +#: ../../library/functions.rst:1528 msgid "" "If the system call is interrupted and the signal handler does not raise an " "exception, the function now retries the system call instead of raising an :" @@ -2925,16 +2921,16 @@ msgstr "" "は :exc:`InterruptedError` 例外を送出する代わりにシステムコールを再試行するよ" "うになりました (論拠については :pep:`475` を参照してください)。" -#: ../../library/functions.rst:1530 +#: ../../library/functions.rst:1531 msgid "The ``'namereplace'`` error handler was added." msgstr "``'namereplace'`` エラーハンドラが追加されました。" -#: ../../library/functions.rst:1534 +#: ../../library/functions.rst:1535 msgid "Support added to accept objects implementing :class:`os.PathLike`." msgstr "" ":class:`os.PathLike` を実装したオブジェクトを受け入れるようになりました。" -#: ../../library/functions.rst:1535 +#: ../../library/functions.rst:1536 msgid "" "On Windows, opening a console buffer may return a subclass of :class:`io." "RawIOBase` other than :class:`io.FileIO`." @@ -2942,11 +2938,11 @@ msgstr "" "Windowsでは、コンソールバッファのオープンは、:class:`io.FileIO` ではなく、:" "class:`io.RawIOBase` のサブクラスを返すでしょう。" -#: ../../library/functions.rst:1538 +#: ../../library/functions.rst:1539 msgid "The ``'U'`` mode has been removed." msgstr "``'U'`` モードは削除されました。" -#: ../../library/functions.rst:1543 +#: ../../library/functions.rst:1544 msgid "" "Given a string representing one Unicode character, return an integer " "representing the Unicode code point of that character. For example, " @@ -2958,7 +2954,7 @@ msgstr "" "``ord('€')`` (ユーロ記号) は ``8364`` を返します。これは :func:`chr` の逆で" "す。" -#: ../../library/functions.rst:1551 +#: ../../library/functions.rst:1552 msgid "" "Return *base* to the power *exp*; if *mod* is present, return *base* to the " "power *exp*, modulo *mod* (computed more efficiently than ``pow(base, exp) % " @@ -2970,7 +2966,7 @@ msgstr "" "二引数の形式 ``pow(base, exp)`` は、冪乗演算子を使った ``base**exp`` と等価で" "す。" -#: ../../library/functions.rst:1556 +#: ../../library/functions.rst:1557 msgid "" "The arguments must have numeric types. With mixed operand types, the " "coercion rules for binary arithmetic operators apply. For :class:`int` " @@ -2995,7 +2991,7 @@ msgstr "" "数が整数の場合、浮動小数点数の結果が返されます。例えば、``pow(-9, 2.0)`` は " "``81.0`` を返します。" -#: ../../library/functions.rst:1568 +#: ../../library/functions.rst:1569 msgid "" "For :class:`int` operands *base* and *exp*, if *mod* is present, *mod* must " "also be of integer type and *mod* must be nonzero. If *mod* is present and " @@ -3010,11 +3006,11 @@ msgstr "" "ラ逆数 (*base* と *inv_base* の積を *mod* で割った余りが1になるような数) とし" "て、 ``pow(inv_base, -exp, mod)`` が返されます。" -#: ../../library/functions.rst:1574 +#: ../../library/functions.rst:1575 msgid "Here's an example of computing an inverse for ``38`` modulo ``97``::" msgstr "以下は ``97`` を法とする ``38`` のモジュラ逆数の計算例です::" -#: ../../library/functions.rst:1576 +#: ../../library/functions.rst:1577 msgid "" ">>> pow(38, -1, mod=97)\n" "23\n" @@ -3026,7 +3022,7 @@ msgstr "" ">>> 23 * 38 % 97 == 1\n" "True" -#: ../../library/functions.rst:1581 +#: ../../library/functions.rst:1582 msgid "" "For :class:`int` operands, the three-argument form of ``pow`` now allows the " "second argument to be negative, permitting computation of modular inverses." @@ -3035,14 +3031,14 @@ msgstr "" "ることができるようになりました。これによりモジュラ逆数の計算が可能になりま" "す。" -#: ../../library/functions.rst:1586 +#: ../../library/functions.rst:1587 msgid "" "Allow keyword arguments. Formerly, only positional arguments were supported." msgstr "" "キーワード引数を取ることができるようになりました。以前は位置引数だけがサポー" "トされていました。" -#: ../../library/functions.rst:1593 +#: ../../library/functions.rst:1594 msgid "" "Print *objects* to the text stream *file*, separated by *sep* and followed " "by *end*. *sep*, *end*, *file*, and *flush*, if present, must be given as " @@ -3052,7 +3048,7 @@ msgstr "" "*end* を表示します。*sep* 、 *end* 、 *file* 、 *flush* を与える場合、キー" "ワード引数として与える必要があります。" -#: ../../library/functions.rst:1597 +#: ../../library/functions.rst:1598 msgid "" "All non-keyword arguments are converted to strings like :func:`str` does and " "written to the stream, separated by *sep* and followed by *end*. Both *sep* " @@ -3066,7 +3062,7 @@ msgstr "" "ると、デフォルトの値が使われます。 *objects* が与えられなければ、 :func:" "`print` は *end* だけを書き出します。" -#: ../../library/functions.rst:1603 +#: ../../library/functions.rst:1604 msgid "" "The *file* argument must be an object with a ``write(string)`` method; if it " "is not present or ``None``, :data:`sys.stdout` will be used. Since printed " @@ -3079,7 +3075,7 @@ msgstr "" "イナリモードファイルオブジェクトには使用できません。代わりに ``file." "write(...)`` を使ってください。" -#: ../../library/functions.rst:1608 +#: ../../library/functions.rst:1609 msgid "" "Output buffering is usually determined by *file*. However, if *flush* is " "true, the stream is forcibly flushed." @@ -3087,15 +3083,15 @@ msgstr "" "出力がバッファ化されるかどうかは通常 *file* で決まりますが、*flush* キーワー" "ド引数が真ならストリームは強制的にフラッシュされます。" -#: ../../library/functions.rst:1612 +#: ../../library/functions.rst:1613 msgid "Added the *flush* keyword argument." msgstr "キーワード引数 *flush* が追加されました。" -#: ../../library/functions.rst:1618 +#: ../../library/functions.rst:1619 msgid "Return a property attribute." msgstr "property 属性を返します。" -#: ../../library/functions.rst:1620 +#: ../../library/functions.rst:1621 msgid "" "*fget* is a function for getting an attribute value. *fset* is a function " "for setting an attribute value. *fdel* is a function for deleting an " @@ -3105,11 +3101,11 @@ msgstr "" "です。*fdel* は属性値を削除するための関数です。*doc* は属性の docstring を作" "成します。" -#: ../../library/functions.rst:1624 +#: ../../library/functions.rst:1625 msgid "A typical use is to define a managed attribute ``x``::" msgstr "典型的な使用法は、属性 ``x`` の処理の定義です::" -#: ../../library/functions.rst:1626 +#: ../../library/functions.rst:1627 msgid "" "class C:\n" " def __init__(self):\n" @@ -3141,7 +3137,7 @@ msgstr "" "\n" " x = property(getx, setx, delx, \"I'm the 'x' property.\")" -#: ../../library/functions.rst:1641 +#: ../../library/functions.rst:1642 msgid "" "If *c* is an instance of *C*, ``c.x`` will invoke the getter, ``c.x = " "value`` will invoke the setter, and ``del c.x`` the deleter." @@ -3149,7 +3145,7 @@ msgstr "" "*c* が *C* のインスタンスならば、``c.x`` は getter を呼び出し、``c.x = " "value`` は setter を、``del c.x`` は deleter を呼び出します。" -#: ../../library/functions.rst:1644 +#: ../../library/functions.rst:1645 msgid "" "If given, *doc* will be the docstring of the property attribute. Otherwise, " "the property will copy *fget*'s docstring (if it exists). This makes it " @@ -3162,7 +3158,7 @@ msgstr "" "そのため :func:`property` を :term:`デコレータ ` として使えば、読" "み出し専用 property を作るのは容易です::" -#: ../../library/functions.rst:1648 +#: ../../library/functions.rst:1649 msgid "" "class Parrot:\n" " def __init__(self):\n" @@ -3182,7 +3178,7 @@ msgstr "" " \"\"\"Get the current voltage.\"\"\"\n" " return self._voltage" -#: ../../library/functions.rst:1657 +#: ../../library/functions.rst:1658 msgid "" "The ``@property`` decorator turns the :meth:`!voltage` method into a " "\"getter\" for a read-only attribute with the same name, and it sets the " @@ -3192,7 +3188,7 @@ msgstr "" "の \"getter\" にし、*voltage* のドキュメント文字列を \"Get the current " "voltage.\" に設定します。" -#: ../../library/functions.rst:1665 +#: ../../library/functions.rst:1666 msgid "" "A property object has ``getter``, ``setter``, and ``deleter`` methods usable " "as decorators that create a copy of the property with the corresponding " @@ -3204,7 +3200,7 @@ msgstr "" "レートされた関数に設定された、 property のコピーを作成できます。 これを一番" "分かりやすく説明する例があります:" -#: ../../library/functions.rst:1670 +#: ../../library/functions.rst:1671 msgid "" "class C:\n" " def __init__(self):\n" @@ -3240,7 +3236,7 @@ msgstr "" " def x(self):\n" " del self._x" -#: ../../library/functions.rst:1689 +#: ../../library/functions.rst:1690 msgid "" "This code is exactly equivalent to the first example. Be sure to give the " "additional functions the same name as the original property (``x`` in this " @@ -3249,7 +3245,7 @@ msgstr "" "このコードは最初の例と等価です。追加の関数には、必ず元の property と同じ名前 " "(この例では ``x``) を与えて下さい。" -#: ../../library/functions.rst:1693 +#: ../../library/functions.rst:1694 msgid "" "The returned property object also has the attributes ``fget``, ``fset``, and " "``fdel`` corresponding to the constructor arguments." @@ -3257,17 +3253,17 @@ msgstr "" "返される property オブジェクトも、コンストラクタの引数に対応した ``fget``, " "``fset``, および ``fdel`` 属性を持ちます。" -#: ../../library/functions.rst:1696 +#: ../../library/functions.rst:1697 msgid "The docstrings of property objects are now writeable." msgstr "属性オブジェクトのドックストリングが書き込み可能になりました。" -#: ../../library/functions.rst:1701 +#: ../../library/functions.rst:1702 msgid "" "Attribute holding the name of the property. The name of the property can be " "changed at runtime." msgstr "プロパティ名を保持する属性。プロパティ名は実行時に変更できます。" -#: ../../library/functions.rst:1712 +#: ../../library/functions.rst:1713 msgid "" "Rather than being a function, :class:`range` is actually an immutable " "sequence type, as documented in :ref:`typesseq-range` and :ref:`typesseq`." @@ -3275,7 +3271,7 @@ msgstr "" ":class:`range` は、実際には関数ではなくイミュータブルなシーケンス型で、 :ref:" "`typesseq-range` と :ref:`typesseq` にドキュメント化されています。" -#: ../../library/functions.rst:1718 +#: ../../library/functions.rst:1719 msgid "" "Return a string containing a printable representation of an object. For " "many types, this function makes an attempt to return a string that would " @@ -3296,11 +3292,11 @@ msgstr "" "displayhook` にアクセスできない場合、この関数は :exc:`RuntimeError` を送出し" "ます。" -#: ../../library/functions.rst:1729 +#: ../../library/functions.rst:1730 msgid "This class has a custom representation that can be evaluated::" msgstr "このクラスは、eval 評価可能な独自の representation を持ちます::" -#: ../../library/functions.rst:1731 +#: ../../library/functions.rst:1732 msgid "" "class Person:\n" " def __init__(self, name, age):\n" @@ -3318,7 +3314,7 @@ msgstr "" " def __repr__(self):\n" " return f\"Person('{self.name}', {self.age})\"" -#: ../../library/functions.rst:1742 +#: ../../library/functions.rst:1743 msgid "" "Return a reverse :term:`iterator`. *seq* must be an object which has a :" "meth:`~object.__reversed__` method or supports the sequence protocol (the :" @@ -3331,7 +3327,7 @@ msgstr "" "`~object.__getitem__` メソッド) をサポートするオブジェクトでなければなりませ" "ん。" -#: ../../library/functions.rst:1750 +#: ../../library/functions.rst:1751 msgid "" "Return *number* rounded to *ndigits* precision after the decimal point. If " "*ndigits* is omitted or is ``None``, it returns the nearest integer to its " @@ -3340,7 +3336,7 @@ msgstr "" "*number* を小数点以下 *ndigits* 桁の精度で丸めた値を返します。*ndigits* が省" "略されたり、``None`` だった場合、入力値に最も近い整数を返します。" -#: ../../library/functions.rst:1754 +#: ../../library/functions.rst:1755 msgid "" "For the built-in types supporting :func:`round`, values are rounded to the " "closest multiple of 10 to the power minus *ndigits*; if two multiples are " @@ -3358,7 +3354,7 @@ msgstr "" "返り値は *ndigits* が指定されていないか ``None`` の場合は整数、そうでなければ" "返り値は *number* と同じ型です。" -#: ../../library/functions.rst:1763 +#: ../../library/functions.rst:1764 msgid "" "For a general Python object ``number``, ``round`` delegates to ``number." "__round__``." @@ -3366,7 +3362,7 @@ msgstr "" "一般的な Python オブジェクト ``number`` に対して、``round`` は処理を `number." "__round__` に移譲します。" -#: ../../library/functions.rst:1768 +#: ../../library/functions.rst:1769 msgid "" "The behavior of :func:`round` for floats can be surprising: for example, " "``round(2.675, 2)`` gives ``2.67`` instead of the expected ``2.68``. This is " @@ -3379,7 +3375,7 @@ msgstr "" "これはバグではありません: これはほとんどの小数が浮動小数点数で正確に表せない" "ことの結果です。詳しくは :ref:`tut-fp-issues` を参照してください。" -#: ../../library/functions.rst:1780 +#: ../../library/functions.rst:1781 msgid "" "Return a new :class:`set` object, optionally with elements taken from " "*iterable*. ``set`` is a built-in class. See :class:`set` and :ref:`types-" @@ -3389,7 +3385,7 @@ msgstr "" "ます。 ``set`` は組み込みクラスです。このクラスについて詳しい情報は :class:" "`set` や :ref:`types-set` を参照してください。" -#: ../../library/functions.rst:1784 +#: ../../library/functions.rst:1785 msgid "" "For other containers see the built-in :class:`frozenset`, :class:`list`, :" "class:`tuple`, and :class:`dict` classes, as well as the :mod:`collections` " @@ -3399,7 +3395,7 @@ msgstr "" "`frozenset` 、 :class:`list` 、 :class:`tuple` 、 :class:`dict` クラスを参照" "してください。" -#: ../../library/functions.rst:1791 +#: ../../library/functions.rst:1792 msgid "" "This is the counterpart of :func:`getattr`. The arguments are an object, a " "string, and an arbitrary value. The string may name an existing attribute " @@ -3412,7 +3408,7 @@ msgstr "" "ブジェクトが許せば、値を属性に関連付けます。例えば、 ``setattr(x, 'foobar', " "123)`` は ``x.foobar = 123`` と等価です。" -#: ../../library/functions.rst:1797 +#: ../../library/functions.rst:1798 msgid "" "*name* need not be a Python identifier as defined in :ref:`identifiers` " "unless the object chooses to enforce that, for example in a custom :meth:" @@ -3426,7 +3422,7 @@ msgstr "" "ドットを使った属性へのアクセスはできませんが、 :func:`getattr` などを通じてア" "クセス可能です。" -#: ../../library/functions.rst:1805 +#: ../../library/functions.rst:1806 msgid "" "Since :ref:`private name mangling ` happens at " "compilation time, one must manually mangle a private attribute's (attributes " @@ -3437,7 +3433,7 @@ msgstr "" "名前を持つ属性) の値を :func:`setattr` でセットするためには、属性名を手動でマ" "ングリングする必要があります。" -#: ../../library/functions.rst:1814 +#: ../../library/functions.rst:1815 msgid "" "Return a :term:`slice` object representing the set of indices specified by " "``range(start, stop, step)``. The *start* and *step* arguments default to " @@ -3447,7 +3443,7 @@ msgstr "" "`slice` オブジェクトを返します。 引数 *start* と *step* のデフォルトは " "``None`` です。" -#: ../../library/functions.rst:1822 +#: ../../library/functions.rst:1823 msgid "" "Slice objects have read-only data attributes :attr:`!start`, :attr:`!stop`, " "and :attr:`!step` which merely return the argument values (or their " @@ -3459,7 +3455,7 @@ msgstr "" "返します。 スライスオブジェクトは特に他の機能を持ちませんが、 NumPy や他の" "サードパーティパッケージで使われています。" -#: ../../library/functions.rst:1827 +#: ../../library/functions.rst:1828 msgid "" "Slice objects are also generated when extended indexing syntax is used. For " "example: ``a[start:stop:step]`` or ``a[start:stop, i]``. See :func:" @@ -3469,7 +3465,7 @@ msgstr "" "例: ``a[start:stop:step]`` や ``a[start:stop, i]`` 。 :term:`iterator` を返" "す代替バージョンについては :func:`itertools.islice` を参照して下さい。" -#: ../../library/functions.rst:1832 +#: ../../library/functions.rst:1833 msgid "" "Slice objects are now :term:`hashable` (provided :attr:`~slice.start`, :attr:" "`~slice.stop`, and :attr:`~slice.step` are hashable)." @@ -3478,18 +3474,18 @@ msgstr "" "属性 :attr:`~slice.start` 、 :attr:`~slice.stop` 、 :attr:`~slice.step` がす" "べてハッシュ可能である場合に限ります)。" -#: ../../library/functions.rst:1838 +#: ../../library/functions.rst:1839 msgid "Return a new sorted list from the items in *iterable*." msgstr "*iterable* の要素を並べ替えた新たなリストを返します。" -#: ../../library/functions.rst:1840 +#: ../../library/functions.rst:1841 msgid "" "Has two optional arguments which must be specified as keyword arguments." msgstr "" "2 つのオプション引数があり、これらはキーワード引数として指定されなければなり" "ません。" -#: ../../library/functions.rst:1842 +#: ../../library/functions.rst:1843 msgid "" "*key* specifies a function of one argument that is used to extract a " "comparison key from each element in *iterable* (for example, ``key=str." @@ -3499,7 +3495,7 @@ msgstr "" "開するのに使われます (例えば、 ``key=str.lower`` のように指定します)。\n" "デフォルト値は ``None`` です (要素を直接比較します)。" -#: ../../library/functions.rst:1846 +#: ../../library/functions.rst:1847 msgid "" "*reverse* is a boolean value. If set to ``True``, then the list elements " "are sorted as if each comparison were reversed." @@ -3507,7 +3503,7 @@ msgstr "" "*reverse* は真偽値です。 ``True`` がセットされた場合、リストの要素は個々の比" "較が反転したものとして並び替えられます。" -#: ../../library/functions.rst:1849 +#: ../../library/functions.rst:1850 msgid "" "Use :func:`functools.cmp_to_key` to convert an old-style *cmp* function to a " "*key* function." @@ -3515,7 +3511,7 @@ msgstr "" "旧式の *cmp* 関数を *key* 関数に変換するには :func:`functools.cmp_to_key` を" "使用してください。" -#: ../../library/functions.rst:1852 +#: ../../library/functions.rst:1853 msgid "" "The built-in :func:`sorted` function is guaranteed to be stable. A sort is " "stable if it guarantees not to change the relative order of elements that " @@ -3527,7 +3523,7 @@ msgstr "" "でソートを行なうのに役立ちます(例えば部署でソートしてから給与の等級でソート" "する場合)。" -#: ../../library/functions.rst:1857 +#: ../../library/functions.rst:1858 msgid "" "The sort algorithm uses only ``<`` comparisons between items. While " "defining an :meth:`~object.__lt__` method will suffice for sorting, :PEP:`8` " @@ -3547,17 +3543,17 @@ msgstr "" "meth:`~object.__gt__` メソッドを呼び出す可能性のある型混合の比較での混乱を避" "けることにも役立ちます。 " -#: ../../library/functions.rst:1866 +#: ../../library/functions.rst:1867 msgid "" "For sorting examples and a brief sorting tutorial, see :ref:`sortinghowto`." msgstr "" "ソートの例と簡単なチュートリアルは :ref:`sortinghowto` を参照して下さい。" -#: ../../library/functions.rst:1870 +#: ../../library/functions.rst:1871 msgid "Transform a method into a static method." msgstr "メソッドを静的メソッドへ変換します。" -#: ../../library/functions.rst:1872 +#: ../../library/functions.rst:1873 msgid "" "A static method does not receive an implicit first argument. To declare a " "static method, use this idiom::" @@ -3565,7 +3561,7 @@ msgstr "" "静的メソッドは暗黙の第一引数を受け取りません。静的メソッドを宣言するには、こ" "のイディオムを使ってください::" -#: ../../library/functions.rst:1875 +#: ../../library/functions.rst:1876 msgid "" "class C:\n" " @staticmethod\n" @@ -3575,7 +3571,7 @@ msgstr "" " @staticmethod\n" " def f(arg1, arg2, argN): ..." -#: ../../library/functions.rst:1879 +#: ../../library/functions.rst:1880 msgid "" "The ``@staticmethod`` form is a function :term:`decorator` -- see :ref:" "`function` for details." @@ -3583,7 +3579,7 @@ msgstr "" "``@staticmethod`` 形式は関数 :term:`デコレータ ` です。詳しくは :" "ref:`function` を参照してください。" -#: ../../library/functions.rst:1882 +#: ../../library/functions.rst:1883 msgid "" "A static method can be called either on the class (such as ``C.f()``) or on " "an instance (such as ``C().f()``). Moreover, the static method :term:" @@ -3595,7 +3591,7 @@ msgstr "" "ソッド :term:`descriptor` は呼び出し可能でもあるため、(``f()`` のように) クラ" "ス定義の中でも使用できます。" -#: ../../library/functions.rst:1887 +#: ../../library/functions.rst:1888 msgid "" "Static methods in Python are similar to those found in Java or C++. Also, " "see :func:`classmethod` for a variant that is useful for creating alternate " @@ -3605,7 +3601,7 @@ msgstr "" "す。クラスコンストラクタの代替を生成するのに役立つ変種、 :func:`classmethod` " "も参照してください。" -#: ../../library/functions.rst:1891 +#: ../../library/functions.rst:1892 msgid "" "Like all decorators, it is also possible to call ``staticmethod`` as a " "regular function and do something with its result. This is needed in some " @@ -3619,7 +3615,7 @@ msgstr "" "ドに自動変換されるのを避けたいケースで必要になります。\n" "そのようなケースでは、このイディオムが使えます::" -#: ../../library/functions.rst:1897 +#: ../../library/functions.rst:1898 msgid "" "def regular_function():\n" " ...\n" @@ -3633,11 +3629,11 @@ msgstr "" "class C:\n" " method = staticmethod(regular_function)" -#: ../../library/functions.rst:1903 +#: ../../library/functions.rst:1904 msgid "For more information on static methods, see :ref:`types`." msgstr "静的メソッドについて詳しい情報は :ref:`types` を参照してください。" -#: ../../library/functions.rst:1905 +#: ../../library/functions.rst:1906 msgid "" "Static methods now inherit the method attributes (:attr:`~function." "__module__`, :attr:`~function.__name__`, :attr:`~function.__qualname__`, :" @@ -3645,14 +3641,14 @@ msgid "" "``__wrapped__`` attribute, and are now callable as regular functions." msgstr "" -#: ../../library/functions.rst:1921 +#: ../../library/functions.rst:1922 msgid "" "Return a :class:`str` version of *object*. See :func:`str` for details." msgstr "" "*object* の :class:`str` 版を返します。詳細は :func:`str` を参照してくださ" "い。" -#: ../../library/functions.rst:1923 +#: ../../library/functions.rst:1924 msgid "" "``str`` is the built-in string :term:`class`. For general information about " "strings, see :ref:`textseq`." @@ -3660,7 +3656,7 @@ msgstr "" "``str`` は組み込みの文字列 :term:`クラス` です。文字列に関する一般的な" "情報は、:ref:`textseq` を参照してください。" -#: ../../library/functions.rst:1929 +#: ../../library/functions.rst:1930 msgid "" "Sums *start* and the items of an *iterable* from left to right and returns " "the total. The *iterable*'s items are normally numbers, and the start value " @@ -3669,7 +3665,7 @@ msgstr "" "*start* と *iterable* の要素を左から右へ合計し、総和を返します。 *iterable* " "の要素は通常は数値で、start の値は文字列であってはなりません。" -#: ../../library/functions.rst:1933 +#: ../../library/functions.rst:1934 msgid "" "For some use cases, there are good alternatives to :func:`sum`. The " "preferred, fast way to concatenate a sequence of strings is by calling ``''." @@ -3683,13 +3679,13 @@ msgstr "" "てください。一連のイテラブルを連結するには、 :func:`itertools.chain` の使用を" "考えてください。" -#: ../../library/functions.rst:1939 +#: ../../library/functions.rst:1940 msgid "The *start* parameter can be specified as a keyword argument." msgstr "" "*start* パラメータをキーワード引数として指定することができるようになりまし" "た。" -#: ../../library/functions.rst:1942 +#: ../../library/functions.rst:1943 msgid "" "Summation of floats switched to an algorithm that gives higher accuracy and " "better commutativity on most builds." @@ -3697,7 +3693,7 @@ msgstr "" "浮動小数点数の総和を計算するとき、ほとんどの環境でより高精度な結果とより良い" "互換性が得られるアルゴリズムを使用するようになりました。" -#: ../../library/functions.rst:1949 +#: ../../library/functions.rst:1950 msgid "" "Return a proxy object that delegates method calls to a parent or sibling " "class of *type*. This is useful for accessing inherited methods that have " @@ -3707,7 +3703,7 @@ msgstr "" "トを返します。これはクラスの中でオーバーライドされた継承メソッドにアクセスす" "るのに便利です。" -#: ../../library/functions.rst:1953 +#: ../../library/functions.rst:1954 msgid "" "The *object_or_type* determines the :term:`method resolution order` to be " "searched. The search starts from the class right after the *type*." @@ -3715,14 +3711,14 @@ msgstr "" "*object_or_type* はメソッドの検索のための :term:`method resolution order` (メ" "ソッド解決順序) を決定します。検索は *type* 直後のクラスから開始します。" -#: ../../library/functions.rst:1957 +#: ../../library/functions.rst:1958 msgid "" "For example, if :attr:`~type.__mro__` of *object_or_type* is ``D -> B -> C -" "> A -> object`` and the value of *type* is ``B``, then :func:`super` " "searches ``C -> A -> object``." msgstr "" -#: ../../library/functions.rst:1961 +#: ../../library/functions.rst:1962 msgid "" "The :attr:`~type.__mro__` attribute of the class corresponding to " "*object_or_type* lists the method resolution search order used by both :func:" @@ -3730,7 +3726,7 @@ msgid "" "whenever the inheritance hierarchy is updated." msgstr "" -#: ../../library/functions.rst:1966 +#: ../../library/functions.rst:1967 msgid "" "If the second argument is omitted, the super object returned is unbound. If " "the second argument is an object, ``isinstance(obj, type)`` must be true. " @@ -3742,7 +3738,7 @@ msgstr "" "ん。第 2 引数が型であれば、 ``issubclass(type2, type)`` は真でなければなりま" "せん (これはクラスメソッドに役に立つでしょう)。" -#: ../../library/functions.rst:1971 +#: ../../library/functions.rst:1972 msgid "" "When called directly within an ordinary method of a class, both arguments " "may be omitted (\"zero-argument :func:`!super`\"). In this case, *type* will " @@ -3757,7 +3753,7 @@ msgstr "" "り、ゼロ引数 :func:`!super` は、ネストされた関数では期待どおりに動作しませ" "ん。これには 暗にネストされた関数を作るジェネレータ式も含まれます)" -#: ../../library/functions.rst:1978 +#: ../../library/functions.rst:1979 msgid "" "There are two typical use cases for *super*. In a class hierarchy with " "single inheritance, *super* can be used to refer to parent classes without " @@ -3769,7 +3765,7 @@ msgstr "" "メンテナンスしやすくなります。この用途は他のプログラミング言語で見られる " "*super* の用途によく似ています。" -#: ../../library/functions.rst:1983 +#: ../../library/functions.rst:1984 msgid "" "The second use case is to support cooperative multiple inheritance in a " "dynamic execution environment. This use case is unique to Python and is not " @@ -3790,12 +3786,12 @@ msgstr "" "決定されること、呼び出し順序はクラス階層構造の変化に順応すること、そして呼び" "出し順序が実行時まで未知の兄弟クラスが含まれる場合があることです)。" -#: ../../library/functions.rst:1993 +#: ../../library/functions.rst:1994 msgid "For both use cases, a typical superclass call looks like this::" msgstr "" "両方の用途において、典型的なスーパークラスの呼び出しは次のようになります::" -#: ../../library/functions.rst:1995 +#: ../../library/functions.rst:1996 msgid "" "class C(B):\n" " def method(self, arg):\n" @@ -3807,7 +3803,7 @@ msgstr "" " super().method(arg) # これは次と同じことを行います:\n" " # super(C, self).method(arg)" -#: ../../library/functions.rst:2000 +#: ../../library/functions.rst:2001 msgid "" "In addition to method lookups, :func:`super` also works for attribute " "lookups. One possible use case for this is calling :term:`descriptors " @@ -3817,7 +3813,7 @@ msgstr "" "同様に動作します。考えうる用途のひとつは親クラスや兄弟クラスの :term:" "`descriptors ` (デスクリプタ) を呼び出すことです。" -#: ../../library/functions.rst:2004 +#: ../../library/functions.rst:2005 msgid "" "Note that :func:`super` is implemented as part of the binding process for " "explicit dotted attribute lookups such as ``super().__getitem__(name)``. It " @@ -3833,7 +3829,7 @@ msgstr "" "文や ``super()[name]`` のような演算子を使った暗黙の探索向けには定義されていま" "せん。" -#: ../../library/functions.rst:2012 +#: ../../library/functions.rst:2013 msgid "" "Also note that, aside from the zero argument form, :func:`super` is not " "limited to use inside methods. The two argument form specifies the " @@ -3848,7 +3844,7 @@ msgstr "" "クラスを取り出すのに必要な詳細を、通常の方法で現在のインスタンスにアクセスす" "るようにコンパイラが埋めるのではたらきます。" -#: ../../library/functions.rst:2019 +#: ../../library/functions.rst:2020 msgid "" "For practical suggestions on how to design cooperative classes using :func:" "`super`, see `guide to using super() `_ を参照してください。" -#: ../../library/functions.rst:2029 +#: ../../library/functions.rst:2030 msgid "" "Rather than being a function, :class:`tuple` is actually an immutable " "sequence type, as documented in :ref:`typesseq-tuple` and :ref:`typesseq`." @@ -3866,14 +3862,14 @@ msgstr "" ":class:`tuple` は、実際は関数ではなくイミュータブルなシーケンス型で、:ref:" "`typesseq-tuple` と :ref:`typesseq` にドキュメント化されています。" -#: ../../library/functions.rst:2038 +#: ../../library/functions.rst:2039 msgid "" "With one argument, return the type of an *object*. The return value is a " "type object and generally the same object as returned by :attr:`object." "__class__`." msgstr "" -#: ../../library/functions.rst:2042 +#: ../../library/functions.rst:2043 msgid "" "The :func:`isinstance` built-in function is recommended for testing the type " "of an object, because it takes subclasses into account." @@ -3881,7 +3877,7 @@ msgstr "" "オブジェクトの型の判定には、 :func:`isinstance` 組み込み関数を使うことが推奨" "されます。これはサブクラスを考慮するからです。" -#: ../../library/functions.rst:2045 +#: ../../library/functions.rst:2046 msgid "" "With three arguments, return a new type object. This is essentially a " "dynamic form of the :keyword:`class` statement. The *name* string is the " @@ -3894,21 +3890,21 @@ msgid "" "type` objects:" msgstr "" -#: ../../library/functions.rst:2060 +#: ../../library/functions.rst:2061 msgid "See also:" msgstr "" -#: ../../library/functions.rst:2062 +#: ../../library/functions.rst:2063 msgid "" ":ref:`Documentation on attributes and methods on classes `." msgstr "" -#: ../../library/functions.rst:2063 +#: ../../library/functions.rst:2064 msgid ":ref:`bltin-type-objects`" msgstr "" -#: ../../library/functions.rst:2065 +#: ../../library/functions.rst:2066 msgid "" "Keyword arguments provided to the three argument form are passed to the " "appropriate metaclass machinery (usually :meth:`~object.__init_subclass__`) " @@ -3919,23 +3915,23 @@ msgstr "" "定義におけるキーワード引数と同様に、適切なメタクラスの機構 (通常は :meth:" "`~object.__init_subclass__`) に渡されます。" -#: ../../library/functions.rst:2070 +#: ../../library/functions.rst:2071 msgid "See also :ref:`class-customization`." msgstr ":ref:`class-customization` も参照してください。" -#: ../../library/functions.rst:2072 +#: ../../library/functions.rst:2073 msgid "" "Subclasses of :class:`!type` which don't override ``type.__new__`` may no " "longer use the one-argument form to get the type of an object." msgstr "" -#: ../../library/functions.rst:2079 +#: ../../library/functions.rst:2080 msgid "" "Return the :attr:`~object.__dict__` attribute for a module, class, instance, " "or any other object with a :attr:`!__dict__` attribute." msgstr "" -#: ../../library/functions.rst:2082 +#: ../../library/functions.rst:2083 msgid "" "Objects such as modules and instances have an updateable :attr:`~object." "__dict__` attribute; however, other objects may have write restrictions on " @@ -3943,11 +3939,11 @@ msgid "" "MappingProxyType` to prevent direct dictionary updates)." msgstr "" -#: ../../library/functions.rst:2087 +#: ../../library/functions.rst:2088 msgid "Without an argument, :func:`vars` acts like :func:`locals`." msgstr "引数がない場合 :func:`vars` は :func:`locals` のように動作します。" -#: ../../library/functions.rst:2089 +#: ../../library/functions.rst:2090 msgid "" "A :exc:`TypeError` exception is raised if an object is specified but it " "doesn't have a :attr:`~object.__dict__` attribute (for example, if its class " @@ -3957,7 +3953,7 @@ msgstr "" "のクラスが :attr:`~object.__slots__` 属性を定義している場合)、 :exc:" "`TypeError` 例外が送出されます。" -#: ../../library/functions.rst:2095 +#: ../../library/functions.rst:2096 msgid "" "The result of calling this function without an argument has been updated as " "described for the :func:`locals` builtin." @@ -3965,7 +3961,7 @@ msgstr "" "この関数を引数なしで呼び出したときの返り値は、 :func:`locals` 組み込み関数で" "の説明に更新されました。" -#: ../../library/functions.rst:2101 +#: ../../library/functions.rst:2102 msgid "" "Iterate over several iterables in parallel, producing tuples with an item " "from each one." @@ -3973,11 +3969,11 @@ msgstr "" "複数のイテラブルを並行に反復処理し、各イテラブルの要素からなるタプルを生成し" "ます。" -#: ../../library/functions.rst:2104 +#: ../../library/functions.rst:2105 msgid "Example::" msgstr "以下はプログラム例です::" -#: ../../library/functions.rst:2106 +#: ../../library/functions.rst:2107 msgid "" ">>> for item in zip([1, 2, 3], ['sugar', 'spice', 'everything nice']):\n" "... print(item)\n" @@ -3993,7 +3989,7 @@ msgstr "" "(2, 'spice')\n" "(3, 'everything nice')" -#: ../../library/functions.rst:2113 +#: ../../library/functions.rst:2114 msgid "" "More formally: :func:`zip` returns an iterator of tuples, where the *i*-th " "tuple contains the *i*-th element from each of the argument iterables." @@ -4001,7 +3997,7 @@ msgstr "" "より正式な定義: :func:`zip` は、 *i* 番目のタプルが 引数に与えた各イテラブル" "の *i* 番目の要素を含むような、タプルのイテレータを返します。" -#: ../../library/functions.rst:2116 +#: ../../library/functions.rst:2117 msgid "" "Another way to think of :func:`zip` is that it turns rows into columns, and " "columns into rows. This is similar to `transposing a matrix `_ " "とよく似ています。" -#: ../../library/functions.rst:2120 +#: ../../library/functions.rst:2121 msgid "" ":func:`zip` is lazy: The elements won't be processed until the iterable is " "iterated on, e.g. by a :keyword:`!for` loop or by wrapping in a :class:" @@ -4021,7 +4017,7 @@ msgstr "" "り、 :class:`list` でラップされたりするなどして反復処理されるまで、要素が実際" "に処理されることはありません。" -#: ../../library/functions.rst:2124 +#: ../../library/functions.rst:2125 msgid "" "One thing to consider is that the iterables passed to :func:`zip` could have " "different lengths; sometimes by design, and sometimes because of a bug in " @@ -4033,7 +4029,7 @@ msgstr "" "備するコードにおけるバグのこともあるでしょう。 Python はこの問題に対して3つの" "異なるアプローチを提供します:" -#: ../../library/functions.rst:2129 +#: ../../library/functions.rst:2130 msgid "" "By default, :func:`zip` stops when the shortest iterable is exhausted. It " "will ignore the remaining items in the longer iterables, cutting off the " @@ -4043,7 +4039,7 @@ msgstr "" "す。より繰り返し数の長いイテラブルの残りの要素は無視して、結果を最も短いイテ" "ラブルの長さに切り詰めます::" -#: ../../library/functions.rst:2133 +#: ../../library/functions.rst:2134 msgid "" ">>> list(zip(range(3), ['fee', 'fi', 'fo', 'fum']))\n" "[(0, 'fee'), (1, 'fi'), (2, 'fo')]" @@ -4051,7 +4047,7 @@ msgstr "" ">>> list(zip(range(3), ['fee', 'fi', 'fo', 'fum']))\n" "[(0, 'fee'), (1, 'fi'), (2, 'fo')]" -#: ../../library/functions.rst:2136 +#: ../../library/functions.rst:2137 msgid "" ":func:`zip` is often used in cases where the iterables are assumed to be of " "equal length. In such cases, it's recommended to use the ``strict=True`` " @@ -4061,7 +4057,7 @@ msgstr "" "下で使われます。そのような場合、 ``strict=True`` オプションの利用が推奨されま" "す。その出力は通常の :func:`zip` と同じです::" -#: ../../library/functions.rst:2140 +#: ../../library/functions.rst:2141 msgid "" ">>> list(zip(('a', 'b', 'c'), (1, 2, 3), strict=True))\n" "[('a', 1), ('b', 2), ('c', 3)]" @@ -4069,7 +4065,7 @@ msgstr "" ">>> list(zip(('a', 'b', 'c'), (1, 2, 3), strict=True))\n" "[('a', 1), ('b', 2), ('c', 3)]" -#: ../../library/functions.rst:2143 +#: ../../library/functions.rst:2144 msgid "" "Unlike the default behavior, it raises a :exc:`ValueError` if one iterable " "is exhausted before the others:" @@ -4077,7 +4073,7 @@ msgstr "" "しかし、デフォルトの動作と異なり、あるイテラブルが他のイテラブルよりも先に消" "費しきった場合に :exc:`ValueError` 例外を送出します:" -#: ../../library/functions.rst:2161 +#: ../../library/functions.rst:2162 msgid "" "Without the ``strict=True`` argument, any bug that results in iterables of " "different lengths will be silenced, possibly manifesting as a hard-to-find " @@ -4087,7 +4083,7 @@ msgstr "" "なるバグも、この時点では問題なく処理されます。そして代わりにプログラムの別の" "場所で、原因を特定しにくいバグとして検出されることになるでしょう。" -#: ../../library/functions.rst:2165 +#: ../../library/functions.rst:2166 msgid "" "Shorter iterables can be padded with a constant value to make all the " "iterables have the same length. This is done by :func:`itertools." @@ -4097,7 +4093,7 @@ msgstr "" "にすることもできます。この機能は :func:`itertools.zip_longest` で提供されま" "す。" -#: ../../library/functions.rst:2169 +#: ../../library/functions.rst:2170 msgid "" "Edge cases: With a single iterable argument, :func:`zip` returns an iterator " "of 1-tuples. With no arguments, it returns an empty iterator." @@ -4105,11 +4101,11 @@ msgstr "" "エッジケース: 引数としてイテラブルをひとつだけ渡した場合、 :func:`zip` は 1 " "タプルのイテレータを返します。引数なしの場合は空のイテレータを返します。" -#: ../../library/functions.rst:2172 +#: ../../library/functions.rst:2173 msgid "Tips and tricks:" msgstr "ヒントとコツ:" -#: ../../library/functions.rst:2174 +#: ../../library/functions.rst:2175 msgid "" "The left-to-right evaluation order of the iterables is guaranteed. This " "makes possible an idiom for clustering a data series into n-length groups " @@ -4123,14 +4119,14 @@ msgstr "" "``n`` 回呼び出した結果となるよう、 *同じ* イテレータを ``n`` 回繰り返します。" "これは入力を長さ n のチャンクに分割する効果があります。" -#: ../../library/functions.rst:2180 +#: ../../library/functions.rst:2181 msgid "" ":func:`zip` in conjunction with the ``*`` operator can be used to unzip a " "list::" msgstr "" ":func:`zip` に続けて ``*`` 演算子を使うと、zip したリストを元に戻せます::" -#: ../../library/functions.rst:2183 +#: ../../library/functions.rst:2184 msgid "" ">>> x = [1, 2, 3]\n" ">>> y = [4, 5, 6]\n" @@ -4148,11 +4144,11 @@ msgstr "" ">>> x == list(x2) and y == list(y2)\n" "True" -#: ../../library/functions.rst:2191 +#: ../../library/functions.rst:2192 msgid "Added the ``strict`` argument." msgstr "``strict`` 引数が追加されました。" -#: ../../library/functions.rst:2203 +#: ../../library/functions.rst:2204 msgid "" "This is an advanced function that is not needed in everyday Python " "programming, unlike :func:`importlib.import_module`." @@ -4160,7 +4156,7 @@ msgstr "" "これは :func:`importlib.import_module` とは違い、日常の Python プログラミング" "では必要ない高等な関数です。" -#: ../../library/functions.rst:2206 +#: ../../library/functions.rst:2207 msgid "" "This function is invoked by the :keyword:`import` statement. It can be " "replaced (by importing the :mod:`builtins` module and assigning to " @@ -4180,7 +4176,7 @@ msgstr "" "`__import__` を直接使用することも推奨されず、 :func:`importlib." "import_module` の方が好まれます。" -#: ../../library/functions.rst:2215 +#: ../../library/functions.rst:2216 msgid "" "The function imports the module *name*, potentially using the given " "*globals* and *locals* to determine how to interpret the name in a package " @@ -4196,7 +4192,7 @@ msgstr "" "使われず、 *globals* は :keyword:`import` 文のパッケージコンテキストを決定す" "るためにのみ使われます。" -#: ../../library/functions.rst:2222 +#: ../../library/functions.rst:2223 msgid "" "*level* specifies whether to use absolute or relative imports. ``0`` (the " "default) means only perform absolute imports. Positive values for *level* " @@ -4209,7 +4205,7 @@ msgstr "" "を呼び出したディレクトリから検索対象となる親ディレクトリの数を示します (詳細" "は :pep:`328` を参照してください)。" -#: ../../library/functions.rst:2228 +#: ../../library/functions.rst:2229 msgid "" "When the *name* variable is of the form ``package.module``, normally, the " "top-level package (the name up till the first dot) is returned, *not* the " @@ -4221,26 +4217,26 @@ msgstr "" "す。しかしながら、空でない *fromlist* 引数が与えられると、 *name* で指名され" "たモジュールが返されます。" -#: ../../library/functions.rst:2233 +#: ../../library/functions.rst:2234 msgid "" "For example, the statement ``import spam`` results in bytecode resembling " "the following code::" msgstr "" "例えば、文 ``import spam`` は、以下のコードのようなバイトコードに帰結します::" -#: ../../library/functions.rst:2236 +#: ../../library/functions.rst:2237 msgid "spam = __import__('spam', globals(), locals(), [], 0)" msgstr "spam = __import__('spam', globals(), locals(), [], 0)" -#: ../../library/functions.rst:2238 +#: ../../library/functions.rst:2239 msgid "The statement ``import spam.ham`` results in this call::" msgstr "文 ``import spam.ham`` は、この呼び出しになります::" -#: ../../library/functions.rst:2240 +#: ../../library/functions.rst:2241 msgid "spam = __import__('spam.ham', globals(), locals(), [], 0)" msgstr "spam = __import__('spam.ham', globals(), locals(), [], 0)" -#: ../../library/functions.rst:2242 +#: ../../library/functions.rst:2243 msgid "" "Note how :func:`__import__` returns the toplevel module here because this is " "the object that is bound to a name by the :keyword:`import` statement." @@ -4249,7 +4245,7 @@ msgstr "" "て下さい。 :keyword:`import` 文により名前が束縛されたオブジェクトになっていま" "す。" -#: ../../library/functions.rst:2245 +#: ../../library/functions.rst:2246 msgid "" "On the other hand, the statement ``from spam.ham import eggs, sausage as " "saus`` results in ::" @@ -4257,7 +4253,7 @@ msgstr "" "一方で、文 ``from spam.ham import eggs, sausage as saus`` は、以下となりま" "す ::" -#: ../../library/functions.rst:2248 +#: ../../library/functions.rst:2249 msgid "" "_temp = __import__('spam.ham', globals(), locals(), ['eggs', 'sausage'], 0)\n" "eggs = _temp.eggs\n" @@ -4267,7 +4263,7 @@ msgstr "" "eggs = _temp.eggs\n" "saus = _temp.sausage" -#: ../../library/functions.rst:2252 +#: ../../library/functions.rst:2253 msgid "" "Here, the ``spam.ham`` module is returned from :func:`__import__`. From " "this object, the names to import are retrieved and assigned to their " @@ -4277,7 +4273,7 @@ msgstr "" "ジェクトから、インポートされる名前が取り出され、それぞれの名前として代入され" "ます。" -#: ../../library/functions.rst:2256 +#: ../../library/functions.rst:2257 msgid "" "If you simply want to import a module (potentially within a package) by " "name, use :func:`importlib.import_module`." @@ -4285,7 +4281,7 @@ msgstr "" "単純に名前からモジュール (パッケージの範囲内であるかも知れません) をインポー" "トしたいなら、 :func:`importlib.import_module` を使ってください。" -#: ../../library/functions.rst:2259 +#: ../../library/functions.rst:2260 msgid "" "Negative values for *level* are no longer supported (which also changes the " "default value to 0)." @@ -4293,7 +4289,7 @@ msgstr "" "負の *level* の値はサポートされなくなりました (デフォルト値の 0 に変更されま" "す)。" -#: ../../library/functions.rst:2263 +#: ../../library/functions.rst:2264 msgid "" "When the command line options :option:`-E` or :option:`-I` are being used, " "the environment variable :envvar:`PYTHONCASEOK` is now ignored." @@ -4301,11 +4297,11 @@ msgstr "" "コマンドラインオプション :option:`-E` or :option:`-I` が指定された場合、環境" "変数 :envvar:`PYTHONCASEOK` は無視されるようになりました。" -#: ../../library/functions.rst:2268 +#: ../../library/functions.rst:2269 msgid "Footnotes" msgstr "脚注" -#: ../../library/functions.rst:2269 +#: ../../library/functions.rst:2270 msgid "" "Note that the parser only accepts the Unix-style end of line convention. If " "you are reading the code from a file, make sure to use newline conversion " @@ -4319,7 +4315,7 @@ msgstr "" msgid "Boolean" msgstr "Boolean" -#: ../../library/functions.rst:154 ../../library/functions.rst:2036 +#: ../../library/functions.rst:154 ../../library/functions.rst:2037 msgid "type" msgstr "type" @@ -4331,94 +4327,94 @@ msgstr "組み込み関数" msgid "exec" msgstr "exec" -#: ../../library/functions.rst:735 +#: ../../library/functions.rst:736 msgid "NaN" msgstr "NaN" -#: ../../library/functions.rst:735 +#: ../../library/functions.rst:736 msgid "Infinity" msgstr "Infinity" -#: ../../library/functions.rst:803 +#: ../../library/functions.rst:804 msgid "__format__" msgstr "__format__" -#: ../../library/functions.rst:803 ../../library/functions.rst:1913 +#: ../../library/functions.rst:804 ../../library/functions.rst:1914 msgid "string" msgstr "string" -#: ../../library/functions.rst:803 +#: ../../library/functions.rst:804 msgid "format() (built-in function)" msgstr "format() (組み込み関数)" -#: ../../library/functions.rst:1313 +#: ../../library/functions.rst:1314 msgid "file object" msgstr "file object" -#: ../../library/functions.rst:1313 ../../library/functions.rst:1434 +#: ../../library/functions.rst:1314 ../../library/functions.rst:1435 msgid "open() built-in function" msgstr "open() built-in function" -#: ../../library/functions.rst:1341 +#: ../../library/functions.rst:1342 msgid "file" msgstr "ファイル" -#: ../../library/functions.rst:1341 +#: ../../library/functions.rst:1342 msgid "modes" msgstr "modes" -#: ../../library/functions.rst:1434 +#: ../../library/functions.rst:1435 msgid "universal newlines" msgstr "universal newlines" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "line-buffered I/O" msgstr "line-buffered I/O" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "unbuffered I/O" msgstr "unbuffered I/O" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "buffer size, I/O" msgstr "buffer size, I/O" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "I/O control" msgstr "I/O control" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "buffering" msgstr "buffering" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "text mode" msgstr "text mode" -#: ../../library/functions.rst:1495 ../../library/functions.rst:2197 +#: ../../library/functions.rst:1496 ../../library/functions.rst:2198 msgid "module" msgstr "module" -#: ../../library/functions.rst:1495 +#: ../../library/functions.rst:1496 msgid "sys" msgstr "sys" -#: ../../library/functions.rst:1913 +#: ../../library/functions.rst:1914 msgid "str() (built-in function)" msgstr "str() (built-in function)" -#: ../../library/functions.rst:2036 +#: ../../library/functions.rst:2037 msgid "object" msgstr "object" -#: ../../library/functions.rst:2197 +#: ../../library/functions.rst:2198 msgid "statement" msgstr "statement" -#: ../../library/functions.rst:2197 +#: ../../library/functions.rst:2198 msgid "import" msgstr "import" -#: ../../library/functions.rst:2197 +#: ../../library/functions.rst:2198 msgid "builtins" msgstr "builtins" diff --git a/library/getpass.po b/library/getpass.po index b7ea4cce4..11d569af3 100644 --- a/library/getpass.po +++ b/library/getpass.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:06+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -32,8 +32,8 @@ msgid "**Source code:** :source:`Lib/getpass.py`" msgstr "**ソースコード:** :source:`Lib/getpass.py`" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/grp.po b/library/grp.po index 375bb2372..1458014ef 100644 --- a/library/grp.po +++ b/library/grp.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:07+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -38,8 +38,7 @@ msgstr "" "ます。全ての Unix バージョンで利用可能です。" #: ../../library/grp.rst:13 -msgid "" -":ref:`Availability `: Unix, not WASI, not Android, not iOS." +msgid "Availability" msgstr "" #: ../../library/grp.rst:15 diff --git a/library/http.client.po b/library/http.client.po index e9be575f3..ce247a240 100644 --- a/library/http.client.po +++ b/library/http.client.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:07+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -64,8 +64,8 @@ msgstr "" "み利用できます (:mod:`ssl` モジュールによって)。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/http.server.po b/library/http.server.po index d3c17d60a..aa02c7ce4 100644 --- a/library/http.server.po +++ b/library/http.server.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:07+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -48,8 +48,8 @@ msgstr "" "キュリティチェック ` のみを実装します。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/imaplib.po b/library/imaplib.po index e6cbfa8bc..4050025dc 100644 --- a/library/imaplib.po +++ b/library/imaplib.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:07+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -49,8 +49,8 @@ msgstr "" "ていないので注意してください。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/importlib.metadata.po b/library/importlib.metadata.po index 45d4b6e7a..35840cce0 100644 --- a/library/importlib.metadata.po +++ b/library/importlib.metadata.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:08+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -198,108 +198,137 @@ msgstr "" "` をリストアップし、配布物の :ref:`requirements` のリストを取得するこ" "とができます。" -#: ../../library/importlib.metadata.rst:104 +#: ../../library/importlib.metadata.rst:105 +msgid "" +"Subclass of :class:`ModuleNotFoundError` raised by several functions in this " +"module when queried for a distribution package which is not installed in the " +"current Python environment." +msgstr "" + +#: ../../library/importlib.metadata.rst:111 msgid "Functional API" msgstr "機能 API" -#: ../../library/importlib.metadata.rst:106 +#: ../../library/importlib.metadata.rst:113 msgid "This package provides the following functionality via its public API." msgstr "本パッケージは、公開APIを通じて以下の機能を提供します。" -#: ../../library/importlib.metadata.rst:112 +#: ../../library/importlib.metadata.rst:119 msgid "Entry points" msgstr "エントリポイント" -#: ../../library/importlib.metadata.rst:114 +#: ../../library/importlib.metadata.rst:123 +msgid "" +"Returns a :class:`EntryPoints` instance describing entry points for the " +"current environment. Any given keyword parameters are passed to the :meth:`!" +"select` method for comparison to the attributes of the individual entry " +"point definitions." +msgstr "" + +#: ../../library/importlib.metadata.rst:128 +msgid "" +"Note: it is not currently possible to query for entry points based on their :" +"attr:`!EntryPoint.dist` attribute (as different :class:`!Distribution` " +"instances do not currently compare equal, even if they have the same " +"attributes)" +msgstr "" + +#: ../../library/importlib.metadata.rst:134 +msgid "Details of a collection of installed entry points." +msgstr "" + +#: ../../library/importlib.metadata.rst:136 +msgid "" +"Also provides a ``.groups`` attribute that reports all identifed entry point " +"groups, and a ``.names`` attribute that reports all identified entry point " +"names." +msgstr "" + +#: ../../library/importlib.metadata.rst:142 +msgid "Details of an installed entry point." +msgstr "" + +#: ../../library/importlib.metadata.rst:144 msgid "" -"The ``entry_points()`` function returns a collection of entry points. Entry " -"points are represented by ``EntryPoint`` instances; each ``EntryPoint`` has " -"a ``.name``, ``.group``, and ``.value`` attributes and a ``.load()`` method " -"to resolve the value. There are also ``.module``, ``.attr``, and ``." -"extras`` attributes for getting the components of the ``.value`` attribute." +"Each :class:`!EntryPoint` instance has ``.name``, ``.group``, and ``.value`` " +"attributes and a ``.load()`` method to resolve the value. There are also ``." +"module``, ``.attr``, and ``.extras`` attributes for getting the components " +"of the ``.value`` attribute, and ``.dist`` for obtaining information " +"regarding the distribution package that provides the entry point." msgstr "" -"``entry_points()`` 関数は、エントリポイントの集合を返します。各 " -"``EntryPoint`` は ``.name``, ``.group``, ``.value`` 属性と値を解決する ``." -"load()`` メソッドを持っています。 また、 ``.value`` 属性の構成要素を取得する" -"ための ``.module``, ``.attr``, ``.extras`` 属性が存在します。" -#: ../../library/importlib.metadata.rst:121 +#: ../../library/importlib.metadata.rst:150 msgid "Query all entry points::" msgstr "すべてのエントリポイントに問い合わせる::" -#: ../../library/importlib.metadata.rst:123 +#: ../../library/importlib.metadata.rst:152 msgid ">>> eps = entry_points() " msgstr "" -#: ../../library/importlib.metadata.rst:125 +#: ../../library/importlib.metadata.rst:154 msgid "" -"The ``entry_points()`` function returns an ``EntryPoints`` object, a " -"collection of all ``EntryPoint`` objects with ``names`` and ``groups`` " +"The :func:`!entry_points` function returns a :class:`!EntryPoints` object, a " +"collection of all :class:`!EntryPoint` objects with ``names`` and ``groups`` " "attributes for convenience::" msgstr "" -"``entry_points()`` 関数は、すべての ``EntryPoint`` オブジェクトを集めた " -"``EntryPoints`` オブジェクトを、便宜上 ``names`` と ``groups`` 属性を付けて返" -"します。" -#: ../../library/importlib.metadata.rst:129 +#: ../../library/importlib.metadata.rst:158 msgid "" ">>> sorted(eps.groups) \n" "['console_scripts', 'distutils.commands', 'distutils.setup_keywords', " "'egg_info.writers', 'setuptools.installation']" msgstr "" -#: ../../library/importlib.metadata.rst:132 +#: ../../library/importlib.metadata.rst:161 msgid "" -"``EntryPoints`` has a ``select`` method to select entry points matching " -"specific properties. Select entry points in the ``console_scripts`` group::" +":class:`!EntryPoints` has a :meth:`!select` method to select entry points " +"matching specific properties. Select entry points in the ``console_scripts`` " +"group::" msgstr "" -"``EntryPoints`` には、特定のプロパティに一致するエントリポイントを選択するた" -"めの ``select`` メソッドがあります。``console_scripts`` グループ内のエントリ" -"ポイントを選択する::" -#: ../../library/importlib.metadata.rst:136 +#: ../../library/importlib.metadata.rst:165 msgid ">>> scripts = eps.select(group='console_scripts') " msgstr "" -#: ../../library/importlib.metadata.rst:138 +#: ../../library/importlib.metadata.rst:167 msgid "" -"Equivalently, since ``entry_points`` passes keyword arguments through to " -"select::" +"Equivalently, since :func:`!entry_points` passes keyword arguments through " +"to select::" msgstr "" -#: ../../library/importlib.metadata.rst:141 +#: ../../library/importlib.metadata.rst:170 msgid ">>> scripts = entry_points(group='console_scripts') " msgstr "" -#: ../../library/importlib.metadata.rst:143 +#: ../../library/importlib.metadata.rst:172 msgid "" "Pick out a specific script named \"wheel\" (found in the wheel project)::" msgstr "" "\"wheel\" という名前の特定のスクリプトを選択します。(wheelプロジェクトにあり" "ます)::" -#: ../../library/importlib.metadata.rst:145 +#: ../../library/importlib.metadata.rst:174 msgid "" ">>> 'wheel' in scripts.names \n" "True\n" ">>> wheel = scripts['wheel'] " msgstr "" -#: ../../library/importlib.metadata.rst:149 +#: ../../library/importlib.metadata.rst:178 msgid "Equivalently, query for that entry point during selection::" msgstr "同様に、選択時にそのエントリポイントを問い合わせます::" -#: ../../library/importlib.metadata.rst:151 +#: ../../library/importlib.metadata.rst:180 msgid "" ">>> (wheel,) = entry_points(group='console_scripts', name='wheel') \n" ">>> (wheel,) = entry_points().select(group='console_scripts', name='wheel') " msgstr "" -#: ../../library/importlib.metadata.rst:154 +#: ../../library/importlib.metadata.rst:183 msgid "Inspect the resolved entry point::" msgstr "解決したエントリポイントを検証する::" -#: ../../library/importlib.metadata.rst:156 +#: ../../library/importlib.metadata.rst:185 msgid "" ">>> wheel \n" "EntryPoint(name='wheel', value='wheel.cli:main', group='console_scripts')\n" @@ -314,7 +343,7 @@ msgid "" "" msgstr "" -#: ../../library/importlib.metadata.rst:168 +#: ../../library/importlib.metadata.rst:197 msgid "" "The ``group`` and ``name`` are arbitrary values defined by the package " "author and usually a client will wish to resolve all entry points for a " @@ -328,7 +357,7 @@ msgstr "" "ト `_ を参照" "してください。" -#: ../../library/importlib.metadata.rst:174 +#: ../../library/importlib.metadata.rst:203 msgid "" "The \"selectable\" entry points were introduced in ``importlib_metadata`` " "3.6 and Python 3.10. Prior to those changes, ``entry_points`` accepted no " @@ -338,72 +367,92 @@ msgid "" "entry_points_selectable` for compatibility options." msgstr "" -#: ../../library/importlib.metadata.rst:183 +#: ../../library/importlib.metadata.rst:212 msgid "" "``EntryPoint`` objects no longer present a tuple-like interface (:meth:" "`~object.__getitem__`)." msgstr "" -#: ../../library/importlib.metadata.rst:190 +#: ../../library/importlib.metadata.rst:219 msgid "Distribution metadata" msgstr "配布物メタデータ" -#: ../../library/importlib.metadata.rst:192 +#: ../../library/importlib.metadata.rst:223 +msgid "" +"Return the distribution metadata corresponding to the named distribution " +"package as a :class:`PackageMetadata` instance." +msgstr "" + +#: ../../library/importlib.metadata.rst:226 +#: ../../library/importlib.metadata.rst:274 +#: ../../library/importlib.metadata.rst:295 +#: ../../library/importlib.metadata.rst:358 +#: ../../library/importlib.metadata.rst:409 +msgid "" +"Raises :exc:`PackageNotFoundError` if the named distribution package is not " +"installed in the current Python environment." +msgstr "" + +#: ../../library/importlib.metadata.rst:231 +msgid "A concrete implementation of the" +msgstr "" + +#: ../../library/importlib.metadata.rst:232 +msgid "" +"`PackageMetadata protocol `_." +msgstr "" + +#: ../../library/importlib.metadata.rst:234 +msgid "" +"In addition to providing the defined protocol methods and attributes, " +"subscripting the instance is equivalent to calling the :meth:`!get` method." +msgstr "" + +#: ../../library/importlib.metadata.rst:237 msgid "" "Every `Distribution Package `_ includes some metadata, which you can extract " -"using the ``metadata()`` function::" +"using the :func:`!metadata` function::" msgstr "" -"すべての `配布パッケージ `_ にはメタデータが含まれており、 ``metadata()`` " -"関数を使って取得することができます::" -#: ../../library/importlib.metadata.rst:196 +#: ../../library/importlib.metadata.rst:240 msgid ">>> wheel_metadata = metadata('wheel') " msgstr "" -#: ../../library/importlib.metadata.rst:198 +#: ../../library/importlib.metadata.rst:242 msgid "" -"The keys of the returned data structure, a ``PackageMetadata``, name the " -"metadata keywords, and the values are returned unparsed from the " -"distribution metadata::" +"The keys of the returned data structure name the metadata keywords, and the " +"values are returned unparsed from the distribution metadata::" msgstr "" -"返されたデータ構造である ``PackageMetadata`` のキーはメタデータのキーワードを" -"表し、値は配布パッケージのメタデータから解析されずに返されます::" -#: ../../library/importlib.metadata.rst:202 +#: ../../library/importlib.metadata.rst:245 msgid "" ">>> wheel_metadata['Requires-Python'] \n" "'>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*'" msgstr "" -#: ../../library/importlib.metadata.rst:205 +#: ../../library/importlib.metadata.rst:248 msgid "" -"``PackageMetadata`` also presents a ``json`` attribute that returns all the " -"metadata in a JSON-compatible form per :PEP:`566`::" +":class:`PackageMetadata` also presents a :attr:`!json` attribute that " +"returns all the metadata in a JSON-compatible form per :PEP:`566`::" msgstr "" -"``PackageMetadata`` には ``json`` 属性があり、 :PEP:`566` に従ってすべてのメ" -"タデータをJSON互換の形式で返します::" -#: ../../library/importlib.metadata.rst:208 +#: ../../library/importlib.metadata.rst:251 msgid "" ">>> wheel_metadata.json['requires_python']\n" "'>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*'" msgstr "" -#: ../../library/importlib.metadata.rst:213 +#: ../../library/importlib.metadata.rst:254 +#: ../../library/importlib.metadata.rst:452 msgid "" -"The actual type of the object returned by ``metadata()`` is an " -"implementation detail and should be accessed only through the interface " -"described by the `PackageMetadata protocol `_." +"The full set of available metadata is not described here. See the PyPA `Core " +"metadata specification `_ for additional details." msgstr "" -"``metadata()`` が返すオブジェクトの実際の型は実装の詳細であり、 " -"`PackageMetadataプロトコル `_ が示すインターフェース" -"を通じてのみアクセスすることができます。" -#: ../../library/importlib.metadata.rst:218 +#: ../../library/importlib.metadata.rst:257 msgid "" "The ``Description`` is now included in the metadata when presented through " "the payload. Line continuation characters have been removed." @@ -411,53 +460,65 @@ msgstr "" "ペイロードを通して提示されるとき、 ``Description`` がメタデータに含まれるよう" "になりました。行の継続文字は削除されました。" -#: ../../library/importlib.metadata.rst:222 +#: ../../library/importlib.metadata.rst:261 msgid "The ``json`` attribute was added." msgstr "``json`` 属性が追加されました。" -#: ../../library/importlib.metadata.rst:228 +#: ../../library/importlib.metadata.rst:267 msgid "Distribution versions" msgstr "配布物バージョン" -#: ../../library/importlib.metadata.rst:230 +#: ../../library/importlib.metadata.rst:271 msgid "" -"The ``version()`` function is the quickest way to get a `Distribution " +"Return the installed distribution package version for the named distribution " +"package." +msgstr "" + +#: ../../library/importlib.metadata.rst:277 +msgid "" +"The :func:`!version` function is the quickest way to get a `Distribution " "Package `_'s version number, as a string::" msgstr "" -"``version()`` 関数は `配布パッケージ `_ のバージョン番号を文字列で取得するもっ" -"とも簡単な方法です。::" -#: ../../library/importlib.metadata.rst:234 +#: ../../library/importlib.metadata.rst:281 msgid "" ">>> version('wheel') \n" "'0.32.3'" msgstr "" -#: ../../library/importlib.metadata.rst:241 +#: ../../library/importlib.metadata.rst:288 msgid "Distribution files" msgstr "配布物ファイル" -#: ../../library/importlib.metadata.rst:243 +#: ../../library/importlib.metadata.rst:292 msgid "" -"You can also get the full set of files contained within a distribution. The " -"``files()`` function takes a `Distribution Package `_ name and returns all of " -"the files installed by this distribution. Each file object returned is a " -"``PackagePath``, a :class:`pathlib.PurePath` derived object with additional " -"``dist``, ``size``, and ``hash`` properties as indicated by the metadata. " -"For example::" +"Return the full set of files contained within the named distribution package." msgstr "" -"また、配布パッケージに含まれるファイルのフルセットを取得することもできます。" -"``files()`` 関数は `配布パッケージ `_ 名を受け取り、この配布パッケージにイン" -"ストールされているすべてのファイルを返します。返される各ファイルオブジェクト" -"は ``PackagePath`` で、 :class:`pathlib.PurePath` から派生したオブジェクト" -"に、メタデータで示された ``dist``, ``size``, ``hash`` プロパティを追加してい" -"ます。 例えば::" -#: ../../library/importlib.metadata.rst:250 +#: ../../library/importlib.metadata.rst:298 +msgid "" +"Returns :const:`None` if the distribution is found but the installation " +"database records reporting the files associated with the distribuion package " +"are missing." +msgstr "" + +#: ../../library/importlib.metadata.rst:304 +msgid "" +"A :class:`pathlib.PurePath` derived object with additional ``dist``, " +"``size``, and ``hash`` properties corresponding to the distribution " +"package's installation metadata for that file." +msgstr "" + +#: ../../library/importlib.metadata.rst:308 +msgid "" +"The :func:`!files` function takes a `Distribution Package `_ name and returns " +"all of the files installed by this distribution. Each file is reported as a :" +"class:`PackagePath` instance. For example::" +msgstr "" + +#: ../../library/importlib.metadata.rst:313 msgid "" ">>> util = [p for p in files('wheel') if 'util.py' in str(p)][0] \n" ">>> util \n" @@ -470,11 +531,11 @@ msgid "" "" msgstr "" -#: ../../library/importlib.metadata.rst:260 +#: ../../library/importlib.metadata.rst:323 msgid "Once you have the file, you can also read its contents::" msgstr "ファイルを取得したら、その内容を読むこともできます::" -#: ../../library/importlib.metadata.rst:262 +#: ../../library/importlib.metadata.rst:325 msgid "" ">>> print(util.read_text()) \n" "import base64\n" @@ -486,55 +547,69 @@ msgid "" " return s" msgstr "" -#: ../../library/importlib.metadata.rst:271 +#: ../../library/importlib.metadata.rst:334 msgid "" -"You can also use the ``locate`` method to get a the absolute path to the " +"You can also use the :meth:`!locate` method to get the absolute path to the " "file::" msgstr "" -"また、 ``locate`` メソッドを使用すると、ファイルへの絶対パスを取得することが" -"できます::" -#: ../../library/importlib.metadata.rst:274 +#: ../../library/importlib.metadata.rst:337 msgid "" ">>> util.locate() \n" "PosixPath('/home/gustav/example/lib/site-packages/wheel/util.py')" msgstr "" -#: ../../library/importlib.metadata.rst:277 +#: ../../library/importlib.metadata.rst:340 msgid "" -"In the case where the metadata file listing files (RECORD or SOURCES.txt) is " -"missing, ``files()`` will return ``None``. The caller may wish to wrap calls " -"to ``files()`` in `always_iterable `_ or otherwise guard against " -"this condition if the target distribution is not known to have the metadata " -"present." +"In the case where the metadata file listing files (``RECORD`` or ``SOURCES." +"txt``) is missing, :func:`!files` will return :const:`None`. The caller may " +"wish to wrap calls to :func:`!files` in `always_iterable `_ or otherwise guard against this condition if the target " +"distribution is not known to have the metadata present." msgstr "" -#: ../../library/importlib.metadata.rst:288 +#: ../../library/importlib.metadata.rst:351 msgid "Distribution requirements" msgstr "配布物の要件" -#: ../../library/importlib.metadata.rst:290 +#: ../../library/importlib.metadata.rst:355 +msgid "" +"Return the declared dependency specifiers for the named distribution package." +msgstr "" + +#: ../../library/importlib.metadata.rst:361 msgid "" "To get the full set of requirements for a `Distribution Package `_, use " -"the ``requires()`` function::" +"the :func:`!requires` function::" msgstr "" -"`配布パッケージ `_ に必要なすべての要件を取得するには、 ``requires()`` " -"関数を使用します::" -#: ../../library/importlib.metadata.rst:294 +#: ../../library/importlib.metadata.rst:365 msgid "" ">>> requires('wheel') \n" "[\"pytest (>=3.0.0) ; extra == 'test'\", \"pytest-cov ; extra == 'test'\"]" msgstr "" -#: ../../library/importlib.metadata.rst:302 +#: ../../library/importlib.metadata.rst:373 msgid "Mapping import to distribution packages" msgstr "" -#: ../../library/importlib.metadata.rst:304 +#: ../../library/importlib.metadata.rst:377 +msgid "" +"Return a mapping from the top level module and import package names found " +"via :attr:`sys.meta_path` to the names of the distribution packages (if any) " +"that provide the corresponding files." +msgstr "" + +#: ../../library/importlib.metadata.rst:381 +msgid "" +"To allow for namespace packages (which may have members provided by multiple " +"distribution packages), each top level import name maps to a list of " +"distribution names rather than mapping directly to a single name." +msgstr "" + +#: ../../library/importlib.metadata.rst:385 msgid "" "A convenience method to resolve the `Distribution Package `_ name (or names, " @@ -548,67 +623,79 @@ msgstr "" "Distribution-Package>`_ 名(名前空間パッケージの場合はその名前)を解決する便利" "なメソッドです::" -#: ../../library/importlib.metadata.rst:309 +#: ../../library/importlib.metadata.rst:390 msgid "" ">>> packages_distributions()\n" "{'importlib_metadata': ['importlib-metadata'], 'yaml': ['PyYAML'], 'jaraco': " "['jaraco.classes', 'jaraco.functools'], ...}" msgstr "" -#: ../../library/importlib.metadata.rst:312 +#: ../../library/importlib.metadata.rst:393 msgid "" "Some editable installs, `do not supply top-level names `_, and thus this function is not " "reliable with such installs." msgstr "" -#: ../../library/importlib.metadata.rst:321 +#: ../../library/importlib.metadata.rst:402 msgid "Distributions" msgstr "" -#: ../../library/importlib.metadata.rst:323 +#: ../../library/importlib.metadata.rst:406 msgid "" -"While the above API is the most common and convenient usage, you can get all " -"of that information from the ``Distribution`` class. A ``Distribution`` is " -"an abstract object that represents the metadata for a Python `Distribution " -"Package `_. You can get the ``Distribution`` instance::" +"Return a :class:`Distribution` instance describing the named distribution " +"package." msgstr "" -"上記のAPIは最も一般的で便利な使い方ですが、 ``Distribution`` クラスからすべて" -"の情報を得ることができます。 ``Distribution`` はPython `配布パッケージ " -"`_ のメタデータを表す抽象オブジェクトです。 ``Distribution`` のインス" -"タンスを取得することができます。" -#: ../../library/importlib.metadata.rst:329 +#: ../../library/importlib.metadata.rst:414 +msgid "Details of an installed distribution package." +msgstr "" + +#: ../../library/importlib.metadata.rst:416 +msgid "" +"Note: different :class:`!Distribution` instances do not currently compare " +"equal, even if they relate to the same installed distribution and " +"accordingly have the same attributes." +msgstr "" + +#: ../../library/importlib.metadata.rst:420 +msgid "" +"While the module level API described above is the most common and convenient " +"usage, you can get all of that information from the :class:`!Distribution` " +"class. :class:`!Distribution` is an abstract object that represents the " +"metadata for a Python `Distribution Package `_. You can get the concreate :" +"class:`!Distribution` subclass instance for an installed distribution " +"package by calling the :func:`distribution` function::" +msgstr "" + +#: ../../library/importlib.metadata.rst:427 msgid "" ">>> from importlib.metadata import distribution \n" -">>> dist = distribution('wheel') " +">>> dist = distribution('wheel') \n" +">>> type(dist) \n" +"" msgstr "" -#: ../../library/importlib.metadata.rst:332 +#: ../../library/importlib.metadata.rst:432 msgid "" -"Thus, an alternative way to get the version number is through the " -"``Distribution`` instance::" +"Thus, an alternative way to get the version number is through the :class:`!" +"Distribution` instance::" msgstr "" -"したがって、バージョン情報を取得する別の方法として、 ``Distribution`` インス" -"タンスを使用します::" -#: ../../library/importlib.metadata.rst:335 +#: ../../library/importlib.metadata.rst:435 msgid "" ">>> dist.version \n" "'0.32.3'" msgstr "" -#: ../../library/importlib.metadata.rst:338 +#: ../../library/importlib.metadata.rst:438 msgid "" -"There are all kinds of additional metadata available on the ``Distribution`` " -"instance::" +"There are all kinds of additional metadata available on :class:`!" +"Distribution` instances::" msgstr "" -"``Distribution`` インスタンスには、あらゆる種類の追加メタデータが用意されてい" -"ます::" -#: ../../library/importlib.metadata.rst:341 +#: ../../library/importlib.metadata.rst:441 msgid "" ">>> dist.metadata['Requires-Python'] \n" "'>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*'\n" @@ -616,37 +703,27 @@ msgid "" "'MIT'" msgstr "" -#: ../../library/importlib.metadata.rst:346 +#: ../../library/importlib.metadata.rst:446 msgid "" "For editable packages, an ``origin`` property may present :pep:`610` " "metadata::" msgstr "" -#: ../../library/importlib.metadata.rst:349 +#: ../../library/importlib.metadata.rst:449 msgid "" ">>> dist.origin.url\n" "'file:///path/to/wheel-0.32.3.editable-py3-none-any.whl'" msgstr "" -#: ../../library/importlib.metadata.rst:352 -msgid "" -"The full set of available metadata is not described here. See the `Core " -"metadata specifications `_ for additional details." -msgstr "" -"利用可能なメタデータのフルセットは、ここでは説明しません。詳細は `コアとなる" -"メタデータの仕様 `_ を参照してください。" - -#: ../../library/importlib.metadata.rst:355 +#: ../../library/importlib.metadata.rst:455 msgid "The ``.origin`` property was added." msgstr "" -#: ../../library/importlib.metadata.rst:359 +#: ../../library/importlib.metadata.rst:459 msgid "Distribution Discovery" msgstr "" -#: ../../library/importlib.metadata.rst:361 +#: ../../library/importlib.metadata.rst:461 msgid "" "By default, this package provides built-in support for discovery of metadata " "for file system and zip file `Distribution Package `_ metadata is not available through :" @@ -690,14 +767,14 @@ msgid "" "on :data:`sys.meta_path`." msgstr "" -#: ../../library/importlib.metadata.rst:380 +#: ../../library/importlib.metadata.rst:480 msgid "" "By default ``importlib.metadata`` installs a finder for distribution " "packages found on the file system. This finder doesn't actually find any " "*distributions*, but it can find their metadata." msgstr "" -#: ../../library/importlib.metadata.rst:385 +#: ../../library/importlib.metadata.rst:485 msgid "" "The abstract class :py:class:`importlib.abc.MetaPathFinder` defines the " "interface expected of finders by Python's import system. ``importlib." @@ -713,7 +790,7 @@ msgstr "" "にし、この拡張インターフェースを ``DistributionFinder`` 抽象基底クラスとして" "提示し、この抽象メソッドを定義しています::" -#: ../../library/importlib.metadata.rst:393 +#: ../../library/importlib.metadata.rst:493 msgid "" "@abc.abstractmethod\n" "def find_distributions(context=DistributionFinder.Context()):\n" @@ -722,7 +799,7 @@ msgid "" " \"\"\"" msgstr "" -#: ../../library/importlib.metadata.rst:399 +#: ../../library/importlib.metadata.rst:499 msgid "" "The ``DistributionFinder.Context`` object provides ``.path`` and ``.name`` " "properties indicating the path to search and name to match and may supply " @@ -732,7 +809,7 @@ msgstr "" "す ``.path`` と ``.name`` のプロパティを提供し、その他の関連するコンテキスト" "を提供することもできます。" -#: ../../library/importlib.metadata.rst:403 +#: ../../library/importlib.metadata.rst:503 msgid "" "What this means in practice is that to support finding distribution package " "metadata in locations other than the file system, subclass ``Distribution`` " @@ -745,17 +822,17 @@ msgstr "" "カスタムファインダーから ``find_distributions()`` メソッドで、派生した " "``Distribution`` のインスタンスを返します。" -#: ../../library/importlib.metadata.rst:410 +#: ../../library/importlib.metadata.rst:510 msgid "Example" msgstr "使用例" -#: ../../library/importlib.metadata.rst:412 +#: ../../library/importlib.metadata.rst:512 msgid "" "Consider for example a custom finder that loads Python modules from a " "database::" msgstr "" -#: ../../library/importlib.metadata.rst:415 +#: ../../library/importlib.metadata.rst:515 msgid "" "class DatabaseImporter(importlib.abc.MetaPathFinder):\n" " def __init__(self, db):\n" @@ -767,14 +844,14 @@ msgid "" "sys.meta_path.append(DatabaseImporter(connect_db(...)))" msgstr "" -#: ../../library/importlib.metadata.rst:424 +#: ../../library/importlib.metadata.rst:524 msgid "" "That importer now presumably provides importable modules from a database, " "but it provides no metadata or entry points. For this custom importer to " "provide metadata, it would also need to implement ``DistributionFinder``::" msgstr "" -#: ../../library/importlib.metadata.rst:429 +#: ../../library/importlib.metadata.rst:529 msgid "" "from importlib.metadata import DistributionFinder\n" "\n" @@ -787,7 +864,7 @@ msgid "" " yield DatabaseDistribution(dist_record)" msgstr "" -#: ../../library/importlib.metadata.rst:439 +#: ../../library/importlib.metadata.rst:539 msgid "" "In this way, ``query_distributions`` would return records for each " "distribution served by the database matching the query. For example, if " @@ -796,7 +873,7 @@ msgid "" "``Context(name=None)``." msgstr "" -#: ../../library/importlib.metadata.rst:445 +#: ../../library/importlib.metadata.rst:545 msgid "" "For the sake of simplicity, this example ignores ``context.path``\\. The " "``path`` attribute defaults to ``sys.path`` and is the set of import paths " @@ -809,11 +886,11 @@ msgid "" "``context.path`` and only yield ``Distribution``\\ s pertinent to that path." msgstr "" -#: ../../library/importlib.metadata.rst:456 +#: ../../library/importlib.metadata.rst:556 msgid "``DatabaseDistribution``, then, would look something like::" msgstr "" -#: ../../library/importlib.metadata.rst:458 +#: ../../library/importlib.metadata.rst:558 msgid "" "class DatabaseDistribution(importlib.metadata.Distributon):\n" " def __init__(self, record):\n" @@ -836,14 +913,14 @@ msgid "" " raise RuntimeError(\"This distribution has no file system\")" msgstr "" -#: ../../library/importlib.metadata.rst:478 +#: ../../library/importlib.metadata.rst:578 msgid "" "This basic implementation should provide metadata and entry points for " "packages served by the ``DatabaseImporter``, assuming that the ``record`` " "supplies suitable ``.name``, ``.version``, and ``.entry_points`` attributes." msgstr "" -#: ../../library/importlib.metadata.rst:483 +#: ../../library/importlib.metadata.rst:583 msgid "" "The ``DatabaseDistribution`` may also provide other metadata files, like " "``RECORD`` (required for ``Distribution.files``) or override the " diff --git a/library/importlib.po b/library/importlib.po index f36f356c9..70c1ea0dd 100644 --- a/library/importlib.po +++ b/library/importlib.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:08+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -491,20 +491,12 @@ msgid "" "An abstract method for finding a :term:`spec ` for the " "specified module. If this is a top-level import, *path* will be ``None``. " "Otherwise, this is a search for a subpackage or module and *path* will be " -"the value of :attr:`__path__` from the parent package. If a spec cannot be " -"found, ``None`` is returned. When passed in, ``target`` is a module object " -"that the finder may use to make a more educated guess about what spec to " -"return. :func:`importlib.util.spec_from_loader` may be useful for " -"implementing concrete ``MetaPathFinders``." +"the value of :attr:`~module.__path__` from the parent package. If a spec " +"cannot be found, ``None`` is returned. When passed in, ``target`` is a " +"module object that the finder may use to make a more educated guess about " +"what spec to return. :func:`importlib.util.spec_from_loader` may be useful " +"for implementing concrete ``MetaPathFinders``." msgstr "" -"指定されたモジュールに対応する :term:`スペック ` を検索する抽象" -"メソッド。もしこれがトップレベルのインポートなら、 *path* は ``None`` です。" -"そうでなければ、これはサブパッケージまたはモジュールのための検索で、 *path* " -"は親パッケージの :attr:`__path__` の値です。スペックが見つからなければ " -"``None`` が返されます。 ``target`` は、渡されてきたならモジュールオブジェクト" -"です。これはファインダーがどのようなスペックを返せばよいか推測するために使用" -"します。具体的な ``MetaPathFinders`` を実装するためには :func:`importlib." -"util.spec_from_loader` が便利かもしれません。" #: ../../library/importlib.rst:263 msgid "" @@ -644,81 +636,42 @@ msgstr "" "属性には、モジュールがリロードされた際に変化するものがあります):" #: ../../library/importlib.rst:358 -msgid ":attr:`__name__`" -msgstr ":attr:`__name__`" +msgid ":attr:`module.__name__`" +msgstr "" #: ../../library/importlib.rst:359 -msgid "" -"The module's fully qualified name. It is ``'__main__'`` for an executed " -"module." +msgid ":attr:`module.__file__`" msgstr "" -#: ../../library/importlib.rst:362 -msgid ":attr:`__file__`" -msgstr ":attr:`__file__`" - -#: ../../library/importlib.rst:363 -msgid "" -"The location the :term:`loader` used to load the module. For example, for " -"modules loaded from a .py file this is the filename. It is not set on all " -"modules (e.g. built-in modules)." +#: ../../library/importlib.rst:360 +msgid ":attr:`module.__cached__` *(deprecated)*" msgstr "" -#: ../../library/importlib.rst:367 -msgid ":attr:`__cached__`" -msgstr ":attr:`__cached__`" - -#: ../../library/importlib.rst:368 -msgid "" -"The filename of a compiled version of the module's code. It is not set on " -"all modules (e.g. built-in modules)." +#: ../../library/importlib.rst:361 +msgid ":attr:`module.__path__`" msgstr "" -#: ../../library/importlib.rst:371 -msgid ":attr:`__path__`" -msgstr ":attr:`__path__`" - -#: ../../library/importlib.rst:372 -msgid "" -"The list of locations where the package's submodules will be found. Most of " -"the time this is a single directory. The import system passes this attribute " -"to ``__import__()`` and to finders in the same way as :data:`sys.path` but " -"just for the package. It is not set on non-package modules so it can be used " -"as an indicator that the module is a package." -msgstr "" - -#: ../../library/importlib.rst:379 -msgid ":attr:`__package__`" -msgstr ":attr:`__package__`" - -#: ../../library/importlib.rst:380 -msgid "" -"The fully qualified name of the package the module is in (or the empty " -"string for a top-level module). If the module is a package then this is the " -"same as :attr:`__name__`." +#: ../../library/importlib.rst:362 +msgid ":attr:`module.__package__` *(deprecated)*" msgstr "" -#: ../../library/importlib.rst:384 -msgid ":attr:`__loader__`" -msgstr ":attr:`__loader__`" - -#: ../../library/importlib.rst:385 -msgid "The :term:`loader` used to load the module." +#: ../../library/importlib.rst:363 +msgid ":attr:`module.__loader__` *(deprecated)*" msgstr "" -#: ../../library/importlib.rst:387 +#: ../../library/importlib.rst:365 msgid "" "When :meth:`exec_module` is available then backwards-compatible " "functionality is provided." msgstr ":meth:`exec_module` が利用可能な場合、後方互換な機能が提供されます。" -#: ../../library/importlib.rst:390 +#: ../../library/importlib.rst:368 msgid "" "Raise :exc:`ImportError` when called instead of :exc:`NotImplementedError`. " "Functionality provided when :meth:`exec_module` is available." msgstr "" -#: ../../library/importlib.rst:395 +#: ../../library/importlib.rst:373 msgid "" "The recommended API for loading a module is :meth:`exec_module` (and :meth:" "`create_module`). Loaders should implement it instead of :meth:" @@ -731,7 +684,7 @@ msgstr "" "装するべきです。 :meth:`exec_module` が実装されている場合、インポート機構は :" "meth:`load_module` の他のすべての責任を肩代わりします。" -#: ../../library/importlib.rst:405 +#: ../../library/importlib.rst:383 msgid "" "An abstract base class for a :term:`loader` which implements the optional :" "pep:`302` protocol for loading arbitrary resources from the storage back-end." @@ -739,33 +692,27 @@ msgstr "" ":term:`loader` の抽象基底クラスで、ストレージバックエンドから任意のリソースを" "ロードするオプションの :pep:`302` プロトコルを実装します。" -#: ../../library/importlib.rst:409 +#: ../../library/importlib.rst:387 msgid "" "This ABC is deprecated in favour of supporting resource loading through :" "class:`importlib.resources.abc.ResourceReader`." msgstr "" -#: ../../library/importlib.rst:415 +#: ../../library/importlib.rst:393 msgid "" "An abstract method to return the bytes for the data located at *path*. " "Loaders that have a file-like storage back-end that allows storing arbitrary " "data can implement this abstract method to give direct access to the data " "stored. :exc:`OSError` is to be raised if the *path* cannot be found. The " -"*path* is expected to be constructed using a module's :attr:`__file__` " -"attribute or an item from a package's :attr:`__path__`." +"*path* is expected to be constructed using a module's :attr:`~module." +"__file__` attribute or an item from a package's :attr:`~module.__path__`." msgstr "" -"*path* に割り当てられたデータのバイト列を返す抽象メソッドです。任意のデータを" -"保管できるファイル的なストレージバックエンドをもつローダーは、この抽象メソッ" -"ドを実装して、保管されたデータに直接アクセスさせるようにできます。 *path* が" -"見つからなければ :exc:`OSError` を送出する必要があります。 *path* は、モ" -"ジュールの :attr:`__file__` 属性を使って、またはパッケージの :attr:" -"`__path__` の要素を使って、構成されることが期待されます。" -#: ../../library/importlib.rst:423 +#: ../../library/importlib.rst:402 msgid "Raises :exc:`OSError` instead of :exc:`NotImplementedError`." msgstr ":exc:`NotImplementedError` の代わりに :exc:`OSError` を送出します。" -#: ../../library/importlib.rst:429 +#: ../../library/importlib.rst:408 msgid "" "An abstract base class for a :term:`loader` which implements the optional :" "pep:`302` protocol for loaders that inspect modules." @@ -773,7 +720,7 @@ msgstr "" ":term:`loader` の抽象基底クラスで、ローダーがモジュールを検査するためのオプ" "ションの :pep:`302` プロトコルを実装します。" -#: ../../library/importlib.rst:434 +#: ../../library/importlib.rst:413 msgid "" "Return the code object for a module, or ``None`` if the module does not have " "a code object (as would be the case, for example, for a built-in module). " @@ -784,7 +731,7 @@ msgstr "" "求されたモジュールをローダーが見つけられなかった場合は :exc:`ImportError` を" "送出します。" -#: ../../library/importlib.rst:440 +#: ../../library/importlib.rst:419 msgid "" "While the method has a default implementation, it is suggested that it be " "overridden if possible for performance." @@ -792,11 +739,11 @@ msgstr "" "このメソッドにはデフォルト実装がありますが、とはいえパフォーマンスのために、" "可能ならばオーバライドしたほうが良いです。" -#: ../../library/importlib.rst:446 +#: ../../library/importlib.rst:425 msgid "No longer abstract and a concrete implementation is provided." msgstr "このメソッドはもはや抽象メソッドではなく、具象実装が提供されます。" -#: ../../library/importlib.rst:451 +#: ../../library/importlib.rst:430 msgid "" "An abstract method to return the source of a module. It is returned as a " "text string using :term:`universal newlines`, translating all recognized " @@ -810,13 +757,13 @@ msgstr "" "``None`` を返します。指定されたモジュールが見つからなければ、 :exc:" "`ImportError` を送出します。" -#: ../../library/importlib.rst:457 ../../library/importlib.rst:466 -#: ../../library/importlib.rst:516 +#: ../../library/importlib.rst:436 ../../library/importlib.rst:445 +#: ../../library/importlib.rst:495 msgid "Raises :exc:`ImportError` instead of :exc:`NotImplementedError`." msgstr "" ":exc:`NotImplementedError` の代わりに :exc:`ImportError` を送出します。" -#: ../../library/importlib.rst:462 +#: ../../library/importlib.rst:441 msgid "" "An optional method to return a true value if the module is a package, a " "false value otherwise. :exc:`ImportError` is raised if the :term:`loader` " @@ -826,11 +773,11 @@ msgstr "" "ションのメソッドです。 :term:`ローダー ` がモジュールを見つけられな" "かったなら :exc:`ImportError` が送出されます。" -#: ../../library/importlib.rst:471 +#: ../../library/importlib.rst:450 msgid "Create a code object from Python source." msgstr "Python のソースからコードオブジェクトを作ります。" -#: ../../library/importlib.rst:473 +#: ../../library/importlib.rst:452 msgid "" "The *data* argument can be whatever the :func:`compile` function supports (i." "e. string or bytes). The *path* argument should be the \"path\" to where the " @@ -842,7 +789,7 @@ msgstr "" "でなければなりませんが、抽象概念 (例えば zip ファイル内の場所) でも構いませ" "ん。" -#: ../../library/importlib.rst:478 +#: ../../library/importlib.rst:457 msgid "" "With the subsequent code object one can execute it in a module by running " "``exec(code, module.__dict__)``." @@ -850,23 +797,23 @@ msgstr "" "結果のコードオブジェクトを使って、 ``exec(code, module.__dict__)`` を呼ぶこと" "でモジュール内でコードを実行できます。" -#: ../../library/importlib.rst:483 +#: ../../library/importlib.rst:462 msgid "Made the method static." msgstr "スタティックメソッドになりました。" -#: ../../library/importlib.rst:488 +#: ../../library/importlib.rst:467 msgid "Implementation of :meth:`Loader.exec_module`." msgstr ":meth:`Loader.exec_module` の実装です。" -#: ../../library/importlib.rst:494 +#: ../../library/importlib.rst:473 msgid "Implementation of :meth:`Loader.load_module`." msgstr ":meth:`Loader.load_module` の実装です。" -#: ../../library/importlib.rst:496 +#: ../../library/importlib.rst:475 msgid "use :meth:`exec_module` instead." msgstr "代わりに :meth:`exec_module` を使用してください。" -#: ../../library/importlib.rst:502 +#: ../../library/importlib.rst:481 msgid "" "An abstract base class which inherits from :class:`InspectLoader` that, when " "implemented, helps a module to be executed as a script. The ABC represents " @@ -876,15 +823,14 @@ msgstr "" "ジュールをスクリプトとして実行する助けになります。この抽象基底クラスはオプ" "ションの :pep:`302` プロトコルを表します。" -#: ../../library/importlib.rst:508 +#: ../../library/importlib.rst:487 msgid "" -"An abstract method that is to return the value of :attr:`__file__` for the " -"specified module. If no path is available, :exc:`ImportError` is raised." +"An abstract method that is to return the value of :attr:`~module.__file__` " +"for the specified module. If no path is available, :exc:`ImportError` is " +"raised." msgstr "" -"指定されたモジュールの :attr:`__file__` の値を返す抽象メソッドです。利用でき" -"るパスがなければ、 :exc:`ImportError` が送出されます。" -#: ../../library/importlib.rst:512 +#: ../../library/importlib.rst:491 msgid "" "If source code is available, then the method should return the path to the " "source file, regardless of whether a bytecode was used to load the module." @@ -893,7 +839,7 @@ msgstr "" "かにかかわらず、このメソッドはそのソースファイルへのパスを返す必要がありま" "す。" -#: ../../library/importlib.rst:522 +#: ../../library/importlib.rst:501 msgid "" "An abstract base class which inherits from :class:`ResourceLoader` and :" "class:`ExecutionLoader`, providing concrete implementations of :meth:" @@ -903,7 +849,7 @@ msgstr "" "ラスで、 :meth:`ResourceLoader.get_data` および :meth:`ExecutionLoader." "get_filename` の具象実装を提供します。" -#: ../../library/importlib.rst:526 +#: ../../library/importlib.rst:505 msgid "" "The *fullname* argument is a fully resolved name of the module the loader is " "to handle. The *path* argument is the path to the file for the module." @@ -911,31 +857,31 @@ msgstr "" "*fullname* 引数は、ローダーが解決しようとするモジュールの、完全に解決された名" "前です。*path* 引数は、モジュールのファイルへのパスです。" -#: ../../library/importlib.rst:533 +#: ../../library/importlib.rst:512 msgid "The name of the module the loader can handle." msgstr "ローダーが扱えるモジュールの名前です。" -#: ../../library/importlib.rst:537 +#: ../../library/importlib.rst:516 msgid "Path to the file of the module." msgstr "モジュールのファイルへのパスです。" -#: ../../library/importlib.rst:541 +#: ../../library/importlib.rst:520 msgid "Calls super's ``load_module()``." msgstr "親クラスの ``load_module()`` を呼び出します。" -#: ../../library/importlib.rst:543 +#: ../../library/importlib.rst:522 msgid "Use :meth:`Loader.exec_module` instead." msgstr "代わりに :meth:`Loader.exec_module` を使用してください。" -#: ../../library/importlib.rst:548 ../../library/importlib.rst:1143 +#: ../../library/importlib.rst:527 ../../library/importlib.rst:1122 msgid "Returns :attr:`path`." msgstr ":attr:`path` を返します。" -#: ../../library/importlib.rst:552 +#: ../../library/importlib.rst:531 msgid "Reads *path* as a binary file and returns the bytes from it." msgstr "*path* をバイナリファイルとして読み込み、そのバイト列を返します。" -#: ../../library/importlib.rst:557 +#: ../../library/importlib.rst:536 msgid "" "An abstract base class for implementing source (and optionally bytecode) " "file loading. The class inherits from both :class:`ResourceLoader` and :" @@ -945,15 +891,15 @@ msgstr "" "す。このクラスは、 :class:`ResourceLoader` と :class:`ExecutionLoader` の両方" "を継承し、以下の実装が必要です:" -#: ../../library/importlib.rst:561 +#: ../../library/importlib.rst:540 msgid ":meth:`ResourceLoader.get_data`" msgstr ":meth:`ResourceLoader.get_data`" -#: ../../library/importlib.rst:562 +#: ../../library/importlib.rst:541 msgid ":meth:`ExecutionLoader.get_filename`" msgstr ":meth:`ExecutionLoader.get_filename`" -#: ../../library/importlib.rst:563 +#: ../../library/importlib.rst:542 msgid "" "Should only return the path to the source file; sourceless loading is not " "supported." @@ -961,7 +907,7 @@ msgstr "" "ソースファイルへのパスのみを返す必要があります。ソースなしのロードはサポート" "されていません。" -#: ../../library/importlib.rst:566 +#: ../../library/importlib.rst:545 msgid "" "The abstract methods defined by this class are to add optional bytecode file " "support. Not implementing these optional methods (or causing them to raise :" @@ -981,7 +927,7 @@ msgstr "" "る解析の工程をなくして速度を上げる最適化です。ですから、バイトコード特有の " "API は公開されていません。" -#: ../../library/importlib.rst:577 +#: ../../library/importlib.rst:556 msgid "" "Optional abstract method which returns a :class:`dict` containing metadata " "about the specified path. Supported dictionary keys are:" @@ -989,18 +935,18 @@ msgstr "" "指定されたパスについてのメタデータを含む :class:`dict` を返す、オプションの抽" "象メソッドです。サポートされる辞書のキーは:" -#: ../../library/importlib.rst:580 +#: ../../library/importlib.rst:559 msgid "" "``'mtime'`` (mandatory): an integer or floating-point number representing " "the modification time of the source code;" msgstr "" "``'mtime'`` (必須): ソースコードの更新時刻を表す整数または浮動小数点数です。" -#: ../../library/importlib.rst:582 +#: ../../library/importlib.rst:561 msgid "``'size'`` (optional): the size in bytes of the source code." msgstr "``'size'`` (任意): バイト数で表したソースコードのサイズです。" -#: ../../library/importlib.rst:584 +#: ../../library/importlib.rst:563 msgid "" "Any other keys in the dictionary are ignored, to allow for future " "extensions. If the path cannot be handled, :exc:`OSError` is raised." @@ -1008,17 +954,17 @@ msgstr "" "未来の拡張のため、辞書内の他のキーは無視されます。パスが扱えなければ、 :exc:" "`OSError` が送出されます。" -#: ../../library/importlib.rst:589 ../../library/importlib.rst:602 +#: ../../library/importlib.rst:568 ../../library/importlib.rst:581 msgid "Raise :exc:`OSError` instead of :exc:`NotImplementedError`." msgstr ":exc:`NotImplementedError` の代わりに :exc:`OSError` を送出します。" -#: ../../library/importlib.rst:594 +#: ../../library/importlib.rst:573 msgid "" "Optional abstract method which returns the modification time for the " "specified path." msgstr "指定されたパスの更新時刻を返す、オプションの抽象メソッドです。" -#: ../../library/importlib.rst:597 +#: ../../library/importlib.rst:576 msgid "" "This method is deprecated in favour of :meth:`path_stats`. You don't have " "to implement it, but it is still available for compatibility purposes. " @@ -1028,7 +974,7 @@ msgstr "" "実装する必要はありませんが、互換性のため現在も利用できます。パスが扱えなけれ" "ば、 :exc:`OSError` が送出されます。" -#: ../../library/importlib.rst:607 +#: ../../library/importlib.rst:586 msgid "" "Optional abstract method which writes the specified bytes to a file path. " "Any intermediate directories which do not exist are to be created " @@ -1037,38 +983,38 @@ msgstr "" "ファイルパスに指定されたバイト列を書き込むオプションの抽象メソッドです。存在" "しない中間ディレクトリがあれば、自動で作成されます。" -#: ../../library/importlib.rst:611 +#: ../../library/importlib.rst:590 msgid "" "When writing to the path fails because the path is read-only (:const:`errno." "EACCES`/:exc:`PermissionError`), do not propagate the exception." msgstr "" -#: ../../library/importlib.rst:615 +#: ../../library/importlib.rst:594 msgid "No longer raises :exc:`NotImplementedError` when called." msgstr "" "呼ばれたときに :exc:`NotImplementedError` を送出することは最早ありません。" -#: ../../library/importlib.rst:620 +#: ../../library/importlib.rst:599 msgid "Concrete implementation of :meth:`InspectLoader.get_code`." msgstr ":meth:`InspectLoader.get_code` の具象実装です。" -#: ../../library/importlib.rst:624 +#: ../../library/importlib.rst:603 msgid "Concrete implementation of :meth:`Loader.exec_module`." msgstr ":meth:`Loader.exec_module` の具象実装です。" -#: ../../library/importlib.rst:630 +#: ../../library/importlib.rst:609 msgid "Concrete implementation of :meth:`Loader.load_module`." msgstr ":meth:`Loader.load_module` の具象実装です。" -#: ../../library/importlib.rst:632 +#: ../../library/importlib.rst:611 msgid "Use :meth:`exec_module` instead." msgstr "代わりに :meth:`exec_module` を使用してください。" -#: ../../library/importlib.rst:637 +#: ../../library/importlib.rst:616 msgid "Concrete implementation of :meth:`InspectLoader.get_source`." msgstr ":meth:`InspectLoader.get_source` の具象実装です。" -#: ../../library/importlib.rst:641 +#: ../../library/importlib.rst:620 msgid "" "Concrete implementation of :meth:`InspectLoader.is_package`. A module is " "determined to be a package if its file path (as provided by :meth:" @@ -1082,18 +1028,18 @@ msgstr "" "除くと ``__init__`` という名のファイルであること。モジュール名自体が " "``__init__`` で終わらないこと。" -#: ../../library/importlib.rst:650 +#: ../../library/importlib.rst:629 msgid "*Superseded by TraversableResources*" msgstr "*TraversableResources に取って代わられました*" -#: ../../library/importlib.rst:652 +#: ../../library/importlib.rst:631 msgid "" "An :term:`abstract base class` to provide the ability to read *resources*." msgstr "" "*resources* の読み出し機能を提供する :term:`抽象基底クラス (abstract base " "class, ABC) ` です。" -#: ../../library/importlib.rst:655 +#: ../../library/importlib.rst:634 msgid "" "From the perspective of this ABC, a *resource* is a binary artifact that is " "shipped within a package. Typically this is something like a data file that " @@ -1103,7 +1049,7 @@ msgid "" "file versus on the file system." msgstr "" -#: ../../library/importlib.rst:663 +#: ../../library/importlib.rst:642 msgid "" "For any of methods of this class, a *resource* argument is expected to be a :" "term:`path-like object` which represents conceptually just a file name. This " @@ -1115,7 +1061,7 @@ msgid "" "potentially representing multiple packages or a module)." msgstr "" -#: ../../library/importlib.rst:674 +#: ../../library/importlib.rst:653 msgid "" "Loaders that wish to support resource reading are expected to provide a " "method called ``get_resource_reader(fullname)`` which returns an object " @@ -1124,26 +1070,26 @@ msgid "" "with this ABC should only be returned when the specified module is a package." msgstr "" -#: ../../library/importlib.rst:683 ../../library/importlib.rst:793 +#: ../../library/importlib.rst:662 ../../library/importlib.rst:772 msgid "Use :class:`importlib.resources.abc.TraversableResources` instead." msgstr "" -#: ../../library/importlib.rst:688 +#: ../../library/importlib.rst:667 msgid "" "Returns an opened, :term:`file-like object` for binary reading of the " "*resource*." msgstr "" -#: ../../library/importlib.rst:691 +#: ../../library/importlib.rst:670 msgid "If the resource cannot be found, :exc:`FileNotFoundError` is raised." msgstr "" "リソースが見付からない場合は、 :exc:`FileNotFoundError` が送出されます。" -#: ../../library/importlib.rst:696 +#: ../../library/importlib.rst:675 msgid "Returns the file system path to the *resource*." msgstr "*resource* へのファイルシステムパスを返します。" -#: ../../library/importlib.rst:698 +#: ../../library/importlib.rst:677 msgid "" "If the resource does not concretely exist on the file system, raise :exc:" "`FileNotFoundError`." @@ -1151,7 +1097,7 @@ msgstr "" "リソースの実体がファイルシステムに存在しない場合、 :exc:`FileNotFoundError` " "が送出されます。" -#: ../../library/importlib.rst:703 +#: ../../library/importlib.rst:682 msgid "" "Returns ``True`` if the named *name* is considered a resource. :exc:" "`FileNotFoundError` is raised if *name* does not exist." @@ -1159,7 +1105,7 @@ msgstr "" "*name* という名前がリソースだと見なせるなら ``True`` を返します。\n" "*name* が存在しない場合は :exc:`FileNotFoundError` が送出されます。" -#: ../../library/importlib.rst:708 +#: ../../library/importlib.rst:687 msgid "" "Returns an :term:`iterable` of strings over the contents of the package. Do " "note that it is not required that all names returned by the iterator be " @@ -1167,7 +1113,7 @@ msgid "" "`is_resource` would be false." msgstr "" -#: ../../library/importlib.rst:714 +#: ../../library/importlib.rst:693 msgid "" "Allowing non-resource names to be returned is to allow for situations where " "how a package and its resources are stored are known a priori and the non-" @@ -1176,71 +1122,71 @@ msgid "" "stored on the file system then those subdirectory names can be used directly." msgstr "" -#: ../../library/importlib.rst:722 +#: ../../library/importlib.rst:701 msgid "The abstract method returns an iterable of no items." msgstr "" -#: ../../library/importlib.rst:727 +#: ../../library/importlib.rst:706 msgid "" "An object with a subset of :class:`pathlib.Path` methods suitable for " "traversing directories and opening files." msgstr "" -#: ../../library/importlib.rst:730 +#: ../../library/importlib.rst:709 msgid "" "For a representation of the object on the file-system, use :meth:`importlib." "resources.as_file`." msgstr "" -#: ../../library/importlib.rst:735 +#: ../../library/importlib.rst:714 msgid "Use :class:`importlib.resources.abc.Traversable` instead." msgstr "" -#: ../../library/importlib.rst:740 +#: ../../library/importlib.rst:719 msgid "Abstract. The base name of this object without any parent references." msgstr "" -#: ../../library/importlib.rst:744 +#: ../../library/importlib.rst:723 msgid "Yield ``Traversable`` objects in ``self``." msgstr "" -#: ../../library/importlib.rst:748 +#: ../../library/importlib.rst:727 msgid "Return ``True`` if ``self`` is a directory." msgstr "" -#: ../../library/importlib.rst:752 +#: ../../library/importlib.rst:731 msgid "Return ``True`` if ``self`` is a file." msgstr "" -#: ../../library/importlib.rst:756 +#: ../../library/importlib.rst:735 msgid "Return Traversable child in ``self``." msgstr "" -#: ../../library/importlib.rst:760 +#: ../../library/importlib.rst:739 msgid "Return ``Traversable`` child in ``self``." msgstr "" -#: ../../library/importlib.rst:764 +#: ../../library/importlib.rst:743 msgid "" "*mode* may be 'r' or 'rb' to open as text or binary. Return a handle " "suitable for reading (same as :attr:`pathlib.Path.open`)." msgstr "" -#: ../../library/importlib.rst:767 +#: ../../library/importlib.rst:746 msgid "" "When opening as text, accepts encoding parameters such as those accepted by :" "attr:`io.TextIOWrapper`." msgstr "" -#: ../../library/importlib.rst:772 +#: ../../library/importlib.rst:751 msgid "Read contents of ``self`` as bytes." msgstr "" -#: ../../library/importlib.rst:776 +#: ../../library/importlib.rst:755 msgid "Read contents of ``self`` as text." msgstr "" -#: ../../library/importlib.rst:781 +#: ../../library/importlib.rst:760 msgid "" "An abstract base class for resource readers capable of serving the :meth:" "`importlib.resources.files` interface. Subclasses :class:`importlib." @@ -1250,27 +1196,27 @@ msgid "" "also supplies ResourceReader." msgstr "" -#: ../../library/importlib.rst:788 +#: ../../library/importlib.rst:767 msgid "" "Loaders that wish to support resource reading are expected to implement this " "interface." msgstr "" -#: ../../library/importlib.rst:798 +#: ../../library/importlib.rst:777 msgid "" "Returns a :class:`importlib.resources.abc.Traversable` object for the loaded " "package." msgstr "" -#: ../../library/importlib.rst:804 +#: ../../library/importlib.rst:783 msgid ":mod:`importlib.machinery` -- Importers and path hooks" msgstr ":mod:`importlib.machinery` -- インポータおよびパスフック" -#: ../../library/importlib.rst:809 +#: ../../library/importlib.rst:788 msgid "**Source code:** :source:`Lib/importlib/machinery.py`" msgstr "**ソースコード:** :source:`Lib/importlib/machinery.py`" -#: ../../library/importlib.rst:813 +#: ../../library/importlib.rst:792 msgid "" "This module contains the various objects that help :keyword:`import` find " "and load modules." @@ -1278,14 +1224,14 @@ msgstr "" "このモジュールには、 :keyword:`import` がモジュールを検索してロードするのに役" "立つ様々なオブジェクトがあります。" -#: ../../library/importlib.rst:818 +#: ../../library/importlib.rst:797 msgid "" "A list of strings representing the recognized file suffixes for source " "modules." msgstr "" "認識されているソースモジュールのファイル接尾辞を表す文字列のリストです。" -#: ../../library/importlib.rst:825 +#: ../../library/importlib.rst:804 msgid "" "A list of strings representing the file suffixes for non-optimized bytecode " "modules." @@ -1293,18 +1239,18 @@ msgstr "" "最適化されていないバイトコードモジュールのファイル接尾辞を表す文字列のリスト" "です。" -#: ../../library/importlib.rst:830 ../../library/importlib.rst:840 +#: ../../library/importlib.rst:809 ../../library/importlib.rst:819 msgid "Use :attr:`BYTECODE_SUFFIXES` instead." msgstr "代わりに :attr:`BYTECODE_SUFFIXES` を使ってください。" -#: ../../library/importlib.rst:835 +#: ../../library/importlib.rst:814 msgid "" "A list of strings representing the file suffixes for optimized bytecode " "modules." msgstr "" "最適化されたバイトコードモジュールのファイル接尾辞を表す文字列のリストです。" -#: ../../library/importlib.rst:845 +#: ../../library/importlib.rst:824 msgid "" "A list of strings representing the recognized file suffixes for bytecode " "modules (including the leading dot)." @@ -1312,11 +1258,11 @@ msgstr "" "認識されているバイトコードモジュールのファイル接尾辞を表す文字列のリストです " "(先頭のドットを含みます)。" -#: ../../library/importlib.rst:850 +#: ../../library/importlib.rst:829 msgid "The value is no longer dependent on ``__debug__``." msgstr "この値は ``__debug__`` に依存しなくなりました。" -#: ../../library/importlib.rst:855 +#: ../../library/importlib.rst:834 msgid "" "A list of strings representing the recognized file suffixes for extension " "modules." @@ -1324,7 +1270,7 @@ msgstr "" "認識されている最適化された拡張モジュールのファイル接尾辞を表す文字列のリスト" "です。" -#: ../../library/importlib.rst:862 +#: ../../library/importlib.rst:841 msgid "" "Returns a combined list of strings representing all file suffixes for " "modules recognized by the standard import machinery. This is a helper for " @@ -1337,7 +1283,7 @@ msgstr "" "スがモジュールを参照する可能性があるかだけを知りたくて、そのモジュールの種類" "を詳しく知る必要はないコード (例えば :func:`inspect.getmodulename`) です。" -#: ../../library/importlib.rst:873 +#: ../../library/importlib.rst:852 msgid "" "An :term:`importer` for built-in modules. All known built-in modules are " "listed in :data:`sys.builtin_module_names`. This class implements the :class:" @@ -1348,8 +1294,8 @@ msgstr "" "`importlib.abc.MetaPathFinder` および :class:`importlib.abc.InspectLoader` 抽" "象基底クラスを実装します。" -#: ../../library/importlib.rst:878 ../../library/importlib.rst:892 -#: ../../library/importlib.rst:905 ../../library/importlib.rst:920 +#: ../../library/importlib.rst:857 ../../library/importlib.rst:871 +#: ../../library/importlib.rst:884 ../../library/importlib.rst:899 msgid "" "Only class methods are defined by this class to alleviate the need for " "instantiation." @@ -1357,7 +1303,7 @@ msgstr "" "インスタンス化の必要性を軽減するため、このクラスにはクラスメソッドだけが定義" "されています。" -#: ../../library/importlib.rst:881 +#: ../../library/importlib.rst:860 msgid "" "As part of :pep:`489`, the builtin importer now implements :meth:`Loader." "create_module` and :meth:`Loader.exec_module`" @@ -1365,7 +1311,7 @@ msgstr "" ":pep:`489` の一環として、ビルトインインポーターは :meth:`Loader." "create_module` と :meth:`Loader.exec_module` を実装しています。" -#: ../../library/importlib.rst:888 +#: ../../library/importlib.rst:867 msgid "" "An :term:`importer` for frozen modules. This class implements the :class:" "`importlib.abc.MetaPathFinder` and :class:`importlib.abc.InspectLoader` ABCs." @@ -1374,12 +1320,12 @@ msgstr "" "は :class:`importlib.abc.MetaPathFinder` および :class:`importlib.abc." "InspectLoader` 抽象基底クラスを実装します。" -#: ../../library/importlib.rst:895 +#: ../../library/importlib.rst:874 msgid "" "Gained :meth:`~Loader.create_module` and :meth:`~Loader.exec_module` methods." msgstr "" -#: ../../library/importlib.rst:902 +#: ../../library/importlib.rst:881 msgid "" ":term:`Finder ` for modules declared in the Windows registry. This " "class implements the :class:`importlib.abc.MetaPathFinder` ABC." @@ -1387,7 +1333,7 @@ msgstr "" "Windows レジストリで宣言されたモジュールの :term:`finder ` です。この" "クラスは :class:`importlib.abc.MetaPathFinder` 抽象基底クラスを実装します。" -#: ../../library/importlib.rst:910 +#: ../../library/importlib.rst:889 msgid "" "Use :mod:`site` configuration instead. Future versions of Python may not " "enable this finder by default." @@ -1396,7 +1342,7 @@ msgstr "" "Python の将来のバージョンでは、デフォルトでこのファインダーが使えなくなるかも" "しれません。" -#: ../../library/importlib.rst:917 +#: ../../library/importlib.rst:896 msgid "" "A :term:`Finder ` for :data:`sys.path` and package ``__path__`` " "attributes. This class implements the :class:`importlib.abc.MetaPathFinder` " @@ -1406,7 +1352,7 @@ msgstr "" "` です。このクラスは :class:`importlib.abc.MetaPathFinder` 抽象基底ク" "ラスを実装します。" -#: ../../library/importlib.rst:925 +#: ../../library/importlib.rst:904 msgid "" "Class method that attempts to find a :term:`spec ` for the " "module specified by *fullname* on :data:`sys.path` or, if defined, on " @@ -1430,7 +1376,7 @@ msgstr "" "ジュールについて問い合わせられます。それでもファインダーが見つからなければ " "``None`` が保管され、また返されます。" -#: ../../library/importlib.rst:939 +#: ../../library/importlib.rst:918 msgid "" "If the current working directory -- represented by an empty string -- is no " "longer valid then ``None`` is returned but no value is cached in :data:`sys." @@ -1440,18 +1386,18 @@ msgstr "" "でに有効でなければ、 ``None`` が返されますが値は :data:`sys." "path_importer_cache` にキャッシュされません。" -#: ../../library/importlib.rst:946 +#: ../../library/importlib.rst:925 msgid "" "Calls :meth:`importlib.abc.PathEntryFinder.invalidate_caches` on all finders " "stored in :data:`sys.path_importer_cache` that define the method. Otherwise " "entries in :data:`sys.path_importer_cache` set to ``None`` are deleted." msgstr "" -#: ../../library/importlib.rst:951 +#: ../../library/importlib.rst:930 msgid "Entries of ``None`` in :data:`sys.path_importer_cache` are deleted." msgstr "" -#: ../../library/importlib.rst:954 +#: ../../library/importlib.rst:933 msgid "" "Calls objects in :data:`sys.path_hooks` with the current working directory " "for ``''`` (i.e. the empty string)." @@ -1459,7 +1405,7 @@ msgstr "" "``''`` (すなわち空の文字列) に対してはカレントワーキングディレクトリととも" "に :data:`sys.path_hooks` のオブジェクトを呼び出します。" -#: ../../library/importlib.rst:961 +#: ../../library/importlib.rst:940 msgid "" "A concrete implementation of :class:`importlib.abc.PathEntryFinder` which " "caches results from the file system." @@ -1467,13 +1413,13 @@ msgstr "" "ファイルシステムからの結果をキャッシュする :class:`importlib.abc." "PathEntryFinder` の具象実装です。" -#: ../../library/importlib.rst:964 +#: ../../library/importlib.rst:943 msgid "" "The *path* argument is the directory for which the finder is in charge of " "searching." msgstr "*path* 引数は検索を担当するファインダーのディレクトリです。" -#: ../../library/importlib.rst:967 +#: ../../library/importlib.rst:946 msgid "" "The *loader_details* argument is a variable number of 2-item tuples each " "containing a loader and a sequence of file suffixes the loader recognizes. " @@ -1485,7 +1431,7 @@ msgstr "" "能でモジュール名と見つかったファイルのパスとの 2 引数を受け付けることを期待さ" "れます。" -#: ../../library/importlib.rst:972 +#: ../../library/importlib.rst:951 msgid "" "The finder will cache the directory contents as necessary, making stat calls " "for each module search to verify the cache is not outdated. Because cache " @@ -1506,26 +1452,26 @@ msgstr "" "検索が失敗します。これを防ぐためには、モジュールを動的に作成する際に、必ず :" "func:`importlib.invalidate_caches` を呼び出してください。" -#: ../../library/importlib.rst:986 +#: ../../library/importlib.rst:965 msgid "The path the finder will search in." msgstr "ファインダーが検索されるパスです。" -#: ../../library/importlib.rst:990 +#: ../../library/importlib.rst:969 msgid "Attempt to find the spec to handle *fullname* within :attr:`path`." msgstr ":attr:`path` 内で *fullname* を扱うスペックの探索を試みます。" -#: ../../library/importlib.rst:996 +#: ../../library/importlib.rst:975 msgid "Clear out the internal cache." msgstr "内部キャッシュを完全に消去します。" -#: ../../library/importlib.rst:1000 +#: ../../library/importlib.rst:979 msgid "" "A class method which returns a closure for use on :data:`sys.path_hooks`. An " "instance of :class:`FileFinder` is returned by the closure using the path " "argument given to the closure directly and *loader_details* indirectly." msgstr "" -#: ../../library/importlib.rst:1005 +#: ../../library/importlib.rst:984 msgid "" "If the argument to the closure is not an existing directory, :exc:" "`ImportError` is raised." @@ -1533,7 +1479,7 @@ msgstr "" "クロージャへの引数が存在するディレクトリでなければ、 :exc:`ImportError` が送" "出されます。" -#: ../../library/importlib.rst:1011 +#: ../../library/importlib.rst:990 msgid "" "A concrete implementation of :class:`importlib.abc.SourceLoader` by " "subclassing :class:`importlib.abc.FileLoader` and providing some concrete " @@ -1542,28 +1488,28 @@ msgstr "" ":class:`importlib.abc.FileLoader` を継承し、その他いくつかのメソッドの具象実" "装を提供する、 :class:`importlib.abc.SourceLoader` の具象実装です。" -#: ../../library/importlib.rst:1019 +#: ../../library/importlib.rst:998 msgid "The name of the module that this loader will handle." msgstr "このローダーが扱うモジュールの名前です。" -#: ../../library/importlib.rst:1023 +#: ../../library/importlib.rst:1002 msgid "The path to the source file." msgstr "ソースファイルへのパスです。" -#: ../../library/importlib.rst:1027 +#: ../../library/importlib.rst:1006 msgid "Return ``True`` if :attr:`path` appears to be for a package." msgstr ":attr:`path` がパッケージを表すとき ``True`` を返します。" -#: ../../library/importlib.rst:1031 +#: ../../library/importlib.rst:1010 msgid "" "Concrete implementation of :meth:`importlib.abc.SourceLoader.path_stats`." msgstr ":meth:`importlib.abc.SourceLoader.path_stats` の具象実装です。" -#: ../../library/importlib.rst:1035 +#: ../../library/importlib.rst:1014 msgid "Concrete implementation of :meth:`importlib.abc.SourceLoader.set_data`." msgstr ":meth:`importlib.abc.SourceLoader.set_data` の具象実装です。" -#: ../../library/importlib.rst:1039 ../../library/importlib.rst:1082 +#: ../../library/importlib.rst:1018 ../../library/importlib.rst:1061 msgid "" "Concrete implementation of :meth:`importlib.abc.Loader.load_module` where " "specifying the name of the module to load is optional." @@ -1571,11 +1517,11 @@ msgstr "" "ロードするモジュールの名前指定がオプションの、 :meth:`importlib.abc.Loader." "load_module` の具象実装です。" -#: ../../library/importlib.rst:1044 ../../library/importlib.rst:1087 +#: ../../library/importlib.rst:1023 ../../library/importlib.rst:1066 msgid "Use :meth:`importlib.abc.Loader.exec_module` instead." msgstr "代わりに :meth:`importlib.abc.Loader.exec_module` を使用してください。" -#: ../../library/importlib.rst:1049 +#: ../../library/importlib.rst:1028 msgid "" "A concrete implementation of :class:`importlib.abc.FileLoader` which can " "import bytecode files (i.e. no source code files exist)." @@ -1583,7 +1529,7 @@ msgstr "" "バイトコードファイル (すなわちソースコードファイルが存在しない) をインポート" "できる :class:`importlib.abc.FileLoader` の具象実装です。" -#: ../../library/importlib.rst:1052 +#: ../../library/importlib.rst:1031 msgid "" "Please note that direct use of bytecode files (and thus not source code " "files) inhibits your modules from being usable by all Python implementations " @@ -1593,32 +1539,32 @@ msgstr "" "のモジュールはすべての Python 実装では使用できないし、新しいバージョンの " "Python ではバイトコードフォーマットが変更されていたら使用できません。" -#: ../../library/importlib.rst:1061 +#: ../../library/importlib.rst:1040 msgid "The name of the module the loader will handle." msgstr "ローダーが扱うモジュールの名前です。" -#: ../../library/importlib.rst:1065 +#: ../../library/importlib.rst:1044 msgid "The path to the bytecode file." msgstr "バイトコードファイルへのパスです。" -#: ../../library/importlib.rst:1069 +#: ../../library/importlib.rst:1048 msgid "Determines if the module is a package based on :attr:`path`." msgstr "" "そのモジュールがパッケージであるかを :attr:`path` に基づいて決定します。" -#: ../../library/importlib.rst:1073 +#: ../../library/importlib.rst:1052 msgid "Returns the code object for :attr:`name` created from :attr:`path`." msgstr "" ":attr:`path` から作成された :attr:`name` のコードオブジェクトを返します。" -#: ../../library/importlib.rst:1077 +#: ../../library/importlib.rst:1056 msgid "" "Returns ``None`` as bytecode files have no source when this loader is used." msgstr "" "このローダーが使われたとき、バイトコードファイルのソースがなければ ``None`` " "を返します。" -#: ../../library/importlib.rst:1092 +#: ../../library/importlib.rst:1071 msgid "" "A concrete implementation of :class:`importlib.abc.ExecutionLoader` for " "extension modules." @@ -1626,7 +1572,7 @@ msgstr "" "拡張モジュールのための :class:`importlib.abc.ExecutionLoader` の具象実装で" "す。" -#: ../../library/importlib.rst:1095 +#: ../../library/importlib.rst:1074 msgid "" "The *fullname* argument specifies the name of the module the loader is to " "support. The *path* argument is the path to the extension module's file." @@ -1634,26 +1580,26 @@ msgstr "" "*fullname* 引数はローダーがサポートするモジュールの名前を指定します。*path* " "引数は拡張モジュールのファイルへのパスです。" -#: ../../library/importlib.rst:1098 +#: ../../library/importlib.rst:1077 msgid "" "Note that, by default, importing an extension module will fail in " "subinterpreters if it doesn't implement multi-phase init (see :pep:`489`), " "even if it would otherwise import successfully." msgstr "" -#: ../../library/importlib.rst:1104 +#: ../../library/importlib.rst:1083 msgid "Multi-phase init is now required for use in subinterpreters." msgstr "" -#: ../../library/importlib.rst:1109 ../../library/importlib.rst:1293 +#: ../../library/importlib.rst:1088 ../../library/importlib.rst:1274 msgid "Name of the module the loader supports." msgstr "ローダーがサポートするモジュールの名前です。" -#: ../../library/importlib.rst:1113 +#: ../../library/importlib.rst:1092 msgid "Path to the extension module." msgstr "拡張モジュールへのパスです。" -#: ../../library/importlib.rst:1117 +#: ../../library/importlib.rst:1096 msgid "" "Creates the module object from the given specification in accordance with :" "pep:`489`." @@ -1661,11 +1607,11 @@ msgstr "" "与えられたスペックから :pep:`489` に従ってモジュールオブジェクトを作成しま" "す。" -#: ../../library/importlib.rst:1124 +#: ../../library/importlib.rst:1103 msgid "Initializes the given module object in accordance with :pep:`489`." msgstr "与えられたモジュールオブジェクトを :pep:`489` に従って初期化します。" -#: ../../library/importlib.rst:1130 +#: ../../library/importlib.rst:1109 msgid "" "Returns ``True`` if the file path points to a package's ``__init__`` module " "based on :attr:`EXTENSION_SUFFIXES`." @@ -1673,22 +1619,22 @@ msgstr "" ":attr:`EXTENSION_SUFFIXES` に基づいて、ファイルパスがパッケージの " "``__init__`` モジュールを指していれば ``True`` を返します。" -#: ../../library/importlib.rst:1135 +#: ../../library/importlib.rst:1114 msgid "Returns ``None`` as extension modules lack a code object." msgstr "拡張モジュールにコードオブジェクトがなければ ``None`` を返します。" -#: ../../library/importlib.rst:1139 +#: ../../library/importlib.rst:1118 msgid "Returns ``None`` as extension modules do not have source code." msgstr "拡張モジュールにソースコードがなければ ``None`` を返します。" -#: ../../library/importlib.rst:1150 +#: ../../library/importlib.rst:1129 msgid "" "A concrete implementation of :class:`importlib.abc.InspectLoader` for " "namespace packages. This is an alias for a private class and is only made " "public for introspecting the ``__loader__`` attribute on namespace packages::" msgstr "" -#: ../../library/importlib.rst:1155 +#: ../../library/importlib.rst:1134 msgid "" ">>> from importlib.machinery import NamespaceLoader\n" ">>> import my_namespace\n" @@ -1699,82 +1645,84 @@ msgid "" "True" msgstr "" -#: ../../library/importlib.rst:1168 +#: ../../library/importlib.rst:1147 msgid "" "A specification for a module's import-system-related state. This is " -"typically exposed as the module's :attr:`__spec__` attribute. Many of these " -"attributes are also available directly on a module: for example, ``module." -"__spec__.origin == module.__file__``. Note, however, that while the " -"*values* are usually equivalent, they can differ since there is no " +"typically exposed as the module's :attr:`~module.__spec__` attribute. Many " +"of these attributes are also available directly on a module: for example, " +"``module.__spec__.origin == module.__file__``. Note, however, that while " +"the *values* are usually equivalent, they can differ since there is no " "synchronization between the two objects. For example, it is possible to " -"update the module's :attr:`__file__` at runtime and this will not be " -"automatically reflected in the module's :attr:`__spec__.origin`, and vice " -"versa." +"update the module's :attr:`~module.__file__` at runtime and this will not be " +"automatically reflected in the module's :attr:`__spec__.origin `, and vice versa." msgstr "" -#: ../../library/importlib.rst:1181 +#: ../../library/importlib.rst:1161 msgid "" -"The module's fully qualified name (see :attr:`__name__` attributes on " -"modules). The :term:`finder` should always set this attribute to a non-empty " -"string." +"The module's fully qualified name (see :attr:`module.__name__`). The :term:" +"`finder` should always set this attribute to a non-empty string." msgstr "" -#: ../../library/importlib.rst:1187 +#: ../../library/importlib.rst:1166 msgid "" -"The :term:`loader` used to load the module (see :attr:`__loader__` " -"attributes on modules). The :term:`finder` should always set this attribute." +"The :term:`loader` used to load the module (see :attr:`module.__loader__`). " +"The :term:`finder` should always set this attribute." msgstr "" -#: ../../library/importlib.rst:1193 +#: ../../library/importlib.rst:1171 msgid "" "The location the :term:`loader` should use to load the module (see :attr:" -"`__file__` attributes on modules). For example, for modules loaded from a ." -"py file this is the filename. The :term:`finder` should always set this " -"attribute to a meaningful value for the :term:`loader` to use. In the " -"uncommon case that there is not one (like for namespace packages), it should " -"be set to ``None``." +"`module.__file__`). For example, for modules loaded from a ``.py`` file this " +"is the filename. The :term:`finder` should always set this attribute to a " +"meaningful value for the :term:`loader` to use. In the uncommon case that " +"there is not one (like for namespace packages), it should be set to ``None``." +msgstr "" + +#: ../../library/importlib.rst:1180 +msgid "" +"A (possibly empty) :term:`sequence` of strings enumerating the locations in " +"which a package's submodules will be found (see :attr:`module.__path__`). " +"Most of the time there will only be a single directory in this list." msgstr "" -#: ../../library/importlib.rst:1202 +#: ../../library/importlib.rst:1185 msgid "" -"The list of locations where the package's submodules will be found (see :" -"attr:`__path__` attributes on modules). Most of the time this is a single " -"directory. The :term:`finder` should set this attribute to a list, even an " -"empty one, to indicate to the import system that the module is a package. " -"It should be set to ``None`` for non-package modules. It is set " -"automatically later to a special object for namespace packages." +"The :term:`finder` should set this attribute to a sequence, even an empty " +"one, to indicate to the import system that the module is a package. It " +"should be set to ``None`` for non-package modules. It is set automatically " +"later to a special object for namespace packages." msgstr "" -#: ../../library/importlib.rst:1212 +#: ../../library/importlib.rst:1193 msgid "" "The :term:`finder` may set this attribute to an object containing " "additional, module-specific data to use when loading the module. Otherwise " "it should be set to ``None``." msgstr "" -#: ../../library/importlib.rst:1218 +#: ../../library/importlib.rst:1199 msgid "" -"The filename of a compiled version of the module's code (see :attr:" -"`__cached__` attributes on modules). The :term:`finder` should always set " -"this attribute but it may be ``None`` for modules that do not need compiled " -"code stored." +"The filename of a compiled version of the module's code (see :attr:`module." +"__cached__`). The :term:`finder` should always set this attribute but it may " +"be ``None`` for modules that do not need compiled code stored." msgstr "" -#: ../../library/importlib.rst:1225 +#: ../../library/importlib.rst:1206 msgid "" "(Read-only) The fully qualified name of the package the module is in (or the " -"empty string for a top-level module). See :attr:`__package__` attributes on " -"modules. If the module is a package then this is the same as :attr:`name`." +"empty string for a top-level module). See :attr:`module.__package__`. If the " +"module is a package then this is the same as :attr:`name`." msgstr "" -#: ../../library/importlib.rst:1232 +#: ../../library/importlib.rst:1213 msgid "" "``True`` if the spec's :attr:`origin` refers to a loadable location, " -"``False`` otherwise. This value impacts how :attr:`origin` is interpreted " -"and how the module's :attr:`__file__` is populated." +"``False`` otherwise. This value impacts how :attr:`!origin` is interpreted " +"and how the module's :attr:`~module.__file__` is populated." msgstr "" -#: ../../library/importlib.rst:1239 +#: ../../library/importlib.rst:1220 msgid "" "A specialization of :class:`importlib.machinery.ExtensionFileLoader` that is " "able to load extension modules in Framework format." @@ -1782,7 +1730,7 @@ msgstr "" "フレームワーク形式の拡張モジュールを読み込み事ができる、特殊な :class:" "`importlib.machinery.ExtensionFileLoader` です。" -#: ../../library/importlib.rst:1242 +#: ../../library/importlib.rst:1223 msgid "" "For compatibility with the iOS App Store, *all* binary modules in an iOS app " "must be dynamic libraries, contained in a framework with appropriate " @@ -1796,7 +1744,7 @@ msgstr "" "レームワークごとにバイナリは一つだけで、 Frameworks フォルダーの外に実行可能" "バイナリデータを設置することはできません。" -#: ../../library/importlib.rst:1248 +#: ../../library/importlib.rst:1229 msgid "" "To accommodate this requirement, when running on iOS, extension module " "binaries are *not* packaged as ``.so`` files on ``sys.path``, but as " @@ -1810,7 +1758,7 @@ msgid "" "fwork`` file, relative to the app bundle." msgstr "" -#: ../../library/importlib.rst:1259 +#: ../../library/importlib.rst:1240 msgid "" "For example, consider the case of an import ``from foo.bar import _whiz``, " "where ``_whiz`` is implemented with the binary module ``sources/foo/bar/" @@ -1838,7 +1786,7 @@ msgstr "" "む ``Frameworks/foo.bar._whiz.framework/foo.bar._whiz.origin`` も含まなければ" "なりません。" -#: ../../library/importlib.rst:1273 +#: ../../library/importlib.rst:1254 msgid "" "When a module is loaded with this loader, the ``__file__`` for the module " "will report as the location of the ``.fwork`` file. This allows code to use " @@ -1852,7 +1800,7 @@ msgstr "" "spec origin は、 ``.framework`` フォルダー下のバイナリの *実際の* 場所を参照" "します。" -#: ../../library/importlib.rst:1279 +#: ../../library/importlib.rst:1260 msgid "" "The Xcode project building the app is responsible for converting any ``.so`` " "files from wherever they exist in the ``PYTHONPATH`` into frameworks in the " @@ -1863,23 +1811,23 @@ msgid "" "details on how to construct this build step." msgstr "" -#: ../../library/importlib.rst:1289 -msgid ":ref:`Availability `: iOS." -msgstr ":ref:`利用可能な環境 `: iOS" +#: ../../library/importlib.rst:1270 +msgid "Availability" +msgstr "" -#: ../../library/importlib.rst:1297 +#: ../../library/importlib.rst:1278 msgid "Path to the ``.fwork`` file for the extension module." msgstr "拡張モジュールの ``.fwork`` ファイルへのパス。" -#: ../../library/importlib.rst:1301 +#: ../../library/importlib.rst:1282 msgid ":mod:`importlib.util` -- Utility code for importers" msgstr ":mod:`importlib.util` -- インポータのためのユーティリティコード" -#: ../../library/importlib.rst:1307 +#: ../../library/importlib.rst:1288 msgid "**Source code:** :source:`Lib/importlib/util.py`" msgstr "**ソースコード:** :source:`Lib/importlib/util.py`" -#: ../../library/importlib.rst:1311 +#: ../../library/importlib.rst:1292 msgid "" "This module contains the various objects that help in the construction of " "an :term:`importer`." @@ -1887,7 +1835,7 @@ msgstr "" "このモジュールには、 :term:`インポーター ` の構築を助ける様々なオブ" "ジェクトがあります。" -#: ../../library/importlib.rst:1316 +#: ../../library/importlib.rst:1297 msgid "" "The bytes which represent the bytecode version number. If you need help with " "loading/writing bytecode then consider :class:`importlib.abc.SourceLoader`." @@ -1896,7 +1844,7 @@ msgstr "" "みについてヘルプが必要なら :class:`importlib.abc.SourceLoader` を参照してくだ" "さい。" -#: ../../library/importlib.rst:1323 +#: ../../library/importlib.rst:1304 msgid "" "Return the :pep:`3147`/:pep:`488` path to the byte-compiled file associated " "with the source *path*. For example, if *path* is ``/foo/bar/baz.py`` the " @@ -1912,7 +1860,7 @@ msgstr "" "ジックタグについては :func:`get_tag` を参照; :attr:`sys.implementation." "cache_tag` が未定義なら :exc:`NotImplementedError` が送出されます。)" -#: ../../library/importlib.rst:1330 +#: ../../library/importlib.rst:1311 msgid "" "The *optimization* parameter is used to specify the optimization level of " "the bytecode file. An empty string represents no optimization, so ``/foo/bar/" @@ -1934,7 +1882,7 @@ msgstr "" "コードパスが返ります。 *optimization* の文字列表現は英数字だけが可能で、そう" "でなければ :exc:`ValueError` が上げられます。" -#: ../../library/importlib.rst:1340 +#: ../../library/importlib.rst:1321 msgid "" "The *debug_override* parameter is deprecated and can be used to override the " "system's value for ``__debug__``. A ``True`` value is the equivalent of " @@ -1948,7 +1896,7 @@ msgstr "" "のと同等です。もし *debug_override* と *optimization* のどちらも ``None`` 以" "外であれば :exc:`TypeError` が上げられます。" -#: ../../library/importlib.rst:1348 +#: ../../library/importlib.rst:1329 msgid "" "The *optimization* parameter was added and the *debug_override* parameter " "was deprecated." @@ -1956,12 +1904,12 @@ msgstr "" "*optimization* パラメータが追加され、 *debug_override* パラメータは " "deprecated になりました。" -#: ../../library/importlib.rst:1352 ../../library/importlib.rst:1368 -#: ../../library/importlib.rst:1457 +#: ../../library/importlib.rst:1333 ../../library/importlib.rst:1349 +#: ../../library/importlib.rst:1438 msgid "Accepts a :term:`path-like object`." msgstr ":term:`path-like object` を受け入れるようになりました。" -#: ../../library/importlib.rst:1358 +#: ../../library/importlib.rst:1339 msgid "" "Given the *path* to a :pep:`3147` file name, return the associated source " "code file path. For example, if *path* is ``/foo/bar/__pycache__/baz." @@ -1977,7 +1925,7 @@ msgstr "" "合は :exc:`ValueError` が送出されます。 :attr:`sys.implementation.cache_tag` " "が定義されていない場合、 :exc:`NotImplementedError` が送出されます。" -#: ../../library/importlib.rst:1373 +#: ../../library/importlib.rst:1354 msgid "" "Decode the given bytes representing source code and return it as a string " "with universal newlines (as required by :meth:`importlib.abc.InspectLoader." @@ -1987,11 +1935,11 @@ msgstr "" "な改行形式 (universal newlines) で返します (:meth:`importlib.abc." "InspectLoader.get_source` で要求されるように)。" -#: ../../library/importlib.rst:1381 +#: ../../library/importlib.rst:1362 msgid "Resolve a relative module name to an absolute one." msgstr "相対的なモジュール名を解決して絶対的なものにします。" -#: ../../library/importlib.rst:1383 +#: ../../library/importlib.rst:1364 msgid "" "If **name** has no leading dots, then **name** is simply returned. This " "allows for usage such as ``importlib.util.resolve_name('sys', __spec__." @@ -2001,7 +1949,7 @@ msgstr "" "えば ``importlib.util.resolve_name('sys', __spec__.parent)`` を使うときに " "**package** 変数が必要かどうかを確認する必要がなくなります。" -#: ../../library/importlib.rst:1388 +#: ../../library/importlib.rst:1369 msgid "" ":exc:`ImportError` is raised if **name** is a relative module name but " "**package** is a false value (e.g. ``None`` or the empty string). :exc:" @@ -2013,13 +1961,13 @@ msgstr "" "名前がそれを含むパッケージから抜け出る (例えば ``spam`` パッケージ内から ``.." "bacon`` を要求する) 場合にも :exc:`ImportError` が送出されます。" -#: ../../library/importlib.rst:1396 +#: ../../library/importlib.rst:1377 msgid "" "To improve consistency with import statements, raise :exc:`ImportError` " "instead of :exc:`ValueError` for invalid relative import attempts." msgstr "" -#: ../../library/importlib.rst:1403 +#: ../../library/importlib.rst:1384 msgid "" "Find the :term:`spec ` for a module, optionally relative to the " "specified **package** name. If the module is in :data:`sys.modules`, then " @@ -2029,7 +1977,7 @@ msgid "" "if no spec is found." msgstr "" -#: ../../library/importlib.rst:1410 +#: ../../library/importlib.rst:1391 msgid "" "If **name** is for a submodule (contains a dot), the parent module is " "automatically imported." @@ -2037,20 +1985,20 @@ msgstr "" "**name** がサブモジュールを示している (ドットを含む) 場合、親モジュールは自" "動的にインポートされます。" -#: ../../library/importlib.rst:1413 +#: ../../library/importlib.rst:1394 msgid "**name** and **package** work the same as for :func:`import_module`." msgstr "" "**name** と **package** は :func:`import_module` に対するものと同じように機能" "します。" -#: ../../library/importlib.rst:1417 +#: ../../library/importlib.rst:1398 msgid "" "Raises :exc:`ModuleNotFoundError` instead of :exc:`AttributeError` if " -"**package** is in fact not a package (i.e. lacks a :attr:`__path__` " +"**package** is in fact not a package (i.e. lacks a :attr:`~module.__path__` " "attribute)." msgstr "" -#: ../../library/importlib.rst:1424 +#: ../../library/importlib.rst:1405 msgid "" "Create a new module based on **spec** and :meth:`spec.loader.create_module " "`." @@ -2058,7 +2006,7 @@ msgstr "" "**spec** と :meth:`spec.loader.create_module ` に基づいて新しいモジュールを作ります。" -#: ../../library/importlib.rst:1427 +#: ../../library/importlib.rst:1408 msgid "" "If :meth:`spec.loader.create_module ` " "does not return ``None``, then any pre-existing attributes will not be " @@ -2070,7 +2018,7 @@ msgstr "" "**spec** にアクセスしたり属性をモジュールに設定したりする際に :exc:" "`AttributeError` 例外が起きても例外は送出されません。" -#: ../../library/importlib.rst:1432 +#: ../../library/importlib.rst:1413 msgid "" "This function is preferred over using :class:`types.ModuleType` to create a " "new module as **spec** is used to set as many import-controlled attributes " @@ -2080,7 +2028,7 @@ msgstr "" "推奨されます。なぜなら、できるだけ多くのインポートコントロールされた属性をモ" "ジュールに設定するために **spec** が使用されるからです。" -#: ../../library/importlib.rst:1440 +#: ../../library/importlib.rst:1421 msgid "" "A factory function for creating a :class:`~importlib.machinery.ModuleSpec` " "instance based on a loader. The parameters have the same meaning as they do " @@ -2091,7 +2039,7 @@ msgstr "" "この関数は、スペックに不足している情報を埋めるために :class:`~importlib." "machinery.ModuleSpec` のような利用可能な :term:`loader` API を使います。" -#: ../../library/importlib.rst:1450 +#: ../../library/importlib.rst:1431 msgid "" "A factory function for creating a :class:`~importlib.machinery.ModuleSpec` " "instance based on the path to a file. Missing information will be filled in " @@ -2103,14 +2051,14 @@ msgstr "" "用してスペックから得られる情報と、モジュールがファイルベースであるという暗黙" "的な情報によって埋められます。" -#: ../../library/importlib.rst:1462 +#: ../../library/importlib.rst:1443 msgid "" "Return the hash of *source_bytes* as bytes. A hash-based ``.pyc`` file " "embeds the :func:`source_hash` of the corresponding source file's contents " "in its header." msgstr "" -#: ../../library/importlib.rst:1470 +#: ../../library/importlib.rst:1451 msgid "" "A context manager that can temporarily skip the compatibility check for " "extension modules. By default the check is enabled and will fail when a " @@ -2119,27 +2067,27 @@ msgid "" "interpreter GIL, when imported in an interpreter with its own GIL." msgstr "" -#: ../../library/importlib.rst:1477 +#: ../../library/importlib.rst:1458 msgid "" "Note that this function is meant to accommodate an unusual case; one which " "is likely to eventually go away. There's is a pretty good chance this is " "not what you were looking for." msgstr "" -#: ../../library/importlib.rst:1481 +#: ../../library/importlib.rst:1462 msgid "" "You can get the same effect as this function by implementing the basic " "interface of multi-phase init (:pep:`489`) and lying about support for " "multiple interpreters (or per-interpreter GIL)." msgstr "" -#: ../../library/importlib.rst:1486 +#: ../../library/importlib.rst:1467 msgid "" "Using this function to disable the check can lead to unexpected behavior and " "even crashes. It should only be used during extension module development." msgstr "" -#: ../../library/importlib.rst:1494 +#: ../../library/importlib.rst:1475 msgid "" "A class which postpones the execution of the loader of a module until the " "module has an attribute accessed." @@ -2147,7 +2095,7 @@ msgstr "" "モジュールが属性アクセスできるようになるまで、モジュールのローダーの実行を遅" "延するクラス。" -#: ../../library/importlib.rst:1497 +#: ../../library/importlib.rst:1478 msgid "" "This class **only** works with loaders that define :meth:`~importlib.abc." "Loader.exec_module` as control over what module type is used for the module " @@ -2160,7 +2108,7 @@ msgid "" "raised if such a substitution is detected." msgstr "" -#: ../../library/importlib.rst:1508 +#: ../../library/importlib.rst:1489 msgid "" "For projects where startup time is critical, this class allows for " "potentially minimizing the cost of loading a module if it is never used. For " @@ -2174,14 +2122,14 @@ msgstr "" "文脈の外で起こるエラーメッセージのため、このクラスの使用は **著しく** 推奨さ" "れません。" -#: ../../library/importlib.rst:1516 +#: ../../library/importlib.rst:1497 msgid "" "Began calling :meth:`~importlib.abc.Loader.create_module`, removing the " "compatibility warning for :class:`importlib.machinery.BuiltinImporter` and :" "class:`importlib.machinery.ExtensionFileLoader`." msgstr "" -#: ../../library/importlib.rst:1523 +#: ../../library/importlib.rst:1504 msgid "" "A class method which returns a callable that creates a lazy loader. This is " "meant to be used in situations where the loader is passed by class instead " @@ -2191,7 +2139,7 @@ msgstr "" "タンスとしてではなくクラスとして渡すような状況において使われることを意図して" "います。 ::" -#: ../../library/importlib.rst:1528 +#: ../../library/importlib.rst:1509 msgid "" "suffixes = importlib.machinery.SOURCE_SUFFIXES\n" "loader = importlib.machinery.SourceFileLoader\n" @@ -2199,33 +2147,33 @@ msgid "" "finder = importlib.machinery.FileFinder(path, (lazy_loader, suffixes))" msgstr "" -#: ../../library/importlib.rst:1536 +#: ../../library/importlib.rst:1517 msgid "Examples" msgstr "使用例" -#: ../../library/importlib.rst:1539 +#: ../../library/importlib.rst:1520 msgid "Importing programmatically" msgstr "プログラムからのインポート" -#: ../../library/importlib.rst:1541 +#: ../../library/importlib.rst:1522 msgid "" "To programmatically import a module, use :func:`importlib.import_module`. ::" msgstr "" "プログラムからモジュールをインポートするには、 :func:`importlib." "import_module` を使ってください。 ::" -#: ../../library/importlib.rst:1544 +#: ../../library/importlib.rst:1525 msgid "" "import importlib\n" "\n" "itertools = importlib.import_module('itertools')" msgstr "" -#: ../../library/importlib.rst:1550 +#: ../../library/importlib.rst:1531 msgid "Checking if a module can be imported" msgstr "モジュールがインポートできるか確認する" -#: ../../library/importlib.rst:1552 +#: ../../library/importlib.rst:1533 msgid "" "If you need to find out if a module can be imported without actually doing " "the import, then you should use :func:`importlib.util.find_spec`." @@ -2233,13 +2181,13 @@ msgstr "" "インポートを実際に行わずに、あるモジュールがインポートできるかを知る必要があ" "る場合は、 :func:`importlib.util.find_spec` を使ってください。" -#: ../../library/importlib.rst:1555 +#: ../../library/importlib.rst:1536 msgid "" "Note that if ``name`` is a submodule (contains a dot), :func:`importlib.util." "find_spec` will import the parent module. ::" msgstr "" -#: ../../library/importlib.rst:1559 +#: ../../library/importlib.rst:1540 msgid "" "import importlib.util\n" "import sys\n" @@ -2259,11 +2207,11 @@ msgid "" " print(f\"can't find the {name!r} module\")" msgstr "" -#: ../../library/importlib.rst:1578 +#: ../../library/importlib.rst:1559 msgid "Importing a source file directly" msgstr "ソースファイルから直接インポートする" -#: ../../library/importlib.rst:1580 +#: ../../library/importlib.rst:1561 msgid "" "This recipe should be used with caution: it is an approximation of an import " "statement where the file path is specified directly, rather than :data:`sys." @@ -2273,13 +2221,13 @@ msgid "" "file is appropriate." msgstr "" -#: ../../library/importlib.rst:1587 +#: ../../library/importlib.rst:1568 msgid "" "To import a Python source file directly from a path, use the following " "recipe::" msgstr "" -#: ../../library/importlib.rst:1589 +#: ../../library/importlib.rst:1570 msgid "" "import importlib.util\n" "import sys\n" @@ -2302,15 +2250,15 @@ msgid "" "json = import_from_path(module_name, file_path)" msgstr "" -#: ../../library/importlib.rst:1611 +#: ../../library/importlib.rst:1592 msgid "Implementing lazy imports" msgstr "" -#: ../../library/importlib.rst:1613 +#: ../../library/importlib.rst:1594 msgid "The example below shows how to implement lazy imports::" msgstr "" -#: ../../library/importlib.rst:1615 +#: ../../library/importlib.rst:1596 msgid "" ">>> import importlib.util\n" ">>> import sys\n" @@ -2330,11 +2278,11 @@ msgid "" "False" msgstr "" -#: ../../library/importlib.rst:1634 +#: ../../library/importlib.rst:1615 msgid "Setting up an importer" msgstr "インポーターのセットアップ" -#: ../../library/importlib.rst:1636 +#: ../../library/importlib.rst:1617 msgid "" "For deep customizations of import, you typically want to implement an :term:" "`importer`. This means managing both the :term:`finder` and :term:`loader` " @@ -2348,7 +2296,7 @@ msgid "" "for the appropriate classes defined within this package)::" msgstr "" -#: ../../library/importlib.rst:1647 +#: ../../library/importlib.rst:1628 msgid "" "import importlib.machinery\n" "import sys\n" @@ -2372,11 +2320,11 @@ msgid "" "sys.path_hooks.append(SpamPathEntryFinder.path_hook(loader_details))" msgstr "" -#: ../../library/importlib.rst:1668 +#: ../../library/importlib.rst:1649 msgid "Approximating :func:`importlib.import_module`" msgstr "" -#: ../../library/importlib.rst:1670 +#: ../../library/importlib.rst:1651 msgid "" "Import itself is implemented in Python code, making it possible to expose " "most of the import machinery through importlib. The following helps " @@ -2384,7 +2332,7 @@ msgid "" "approximate implementation of :func:`importlib.import_module`::" msgstr "" -#: ../../library/importlib.rst:1676 +#: ../../library/importlib.rst:1657 msgid "" "import importlib.util\n" "import sys\n" @@ -2417,10 +2365,10 @@ msgid "" " return module" msgstr "" -#: ../../library/importlib.rst:443 +#: ../../library/importlib.rst:422 msgid "universal newlines" msgstr "universal newlines" -#: ../../library/importlib.rst:443 +#: ../../library/importlib.rst:422 msgid "importlib.abc.InspectLoader.get_source method" msgstr "importlib.abc.InspectLoader.get_source メソッド" diff --git a/library/itertools.po b/library/itertools.po index 8a245b783..7c4a6b2e0 100644 --- a/library/itertools.po +++ b/library/itertools.po @@ -18,7 +18,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:08+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -271,6 +271,10 @@ msgstr "iterable[, key]" msgid "sub-iterators grouped by value of key(v)" msgstr "key(v) の値でグループ化したサブイテレータ" +#: ../../library/itertools.rst:61 +msgid "``groupby(['A','B','DEF'], len) → (1, A B) (3, DEF)``" +msgstr "" + #: ../../library/itertools.rst:62 msgid ":func:`islice`" msgstr ":func:`islice`" @@ -441,13 +445,10 @@ msgstr "Itertool関数" #: ../../library/itertools.rst:96 msgid "" -"The following module functions all construct and return iterators. Some " -"provide streams of infinite length, so they should only be accessed by " -"functions or loops that truncate the stream." +"The following functions all construct and return iterators. Some provide " +"streams of infinite length, so they should only be accessed by functions or " +"loops that truncate the stream." msgstr "" -"以下の関数は全て、イテレータを作成して返します。無限長のストリームのイテレー" -"タを返す関数もあり、この場合にはストリームを中断するような関数かループ処理か" -"ら使用しなければなりません。" #: ../../library/itertools.rst:103 msgid "" @@ -467,11 +468,11 @@ msgid "" "value and the output will have one more element than the input iterable." msgstr "" -#: ../../library/itertools.rst:113 ../../library/itertools.rst:185 -#: ../../library/itertools.rst:244 ../../library/itertools.rst:287 -#: ../../library/itertools.rst:484 ../../library/itertools.rst:515 -#: ../../library/itertools.rst:550 ../../library/itertools.rst:623 -#: ../../library/itertools.rst:684 ../../library/itertools.rst:726 +#: ../../library/itertools.rst:113 ../../library/itertools.rst:186 +#: ../../library/itertools.rst:245 ../../library/itertools.rst:288 +#: ../../library/itertools.rst:489 ../../library/itertools.rst:524 +#: ../../library/itertools.rst:561 ../../library/itertools.rst:637 +#: ../../library/itertools.rst:698 ../../library/itertools.rst:779 msgid "Roughly equivalent to::" msgstr "およそ次と等価です::" @@ -499,14 +500,14 @@ msgstr "" #: ../../library/itertools.rst:134 msgid "" -"The *function* argument can be set to :func:`min` for a running minimum, :" -"func:`max` for a running maximum, or :func:`operator.mul` for a running " -"product. `Amortization tables `_ can be built by accumulating interest and applying " -"payments:" +"To compute a running minimum, set *function* to :func:`min`. For a running " +"maximum, set *function* to :func:`max`. Or for a running product, set " +"*function* to :func:`operator.mul`. To build an `amortization table `_, accumulate the " +"interest and apply payments:" msgstr "" -#: ../../library/itertools.rst:140 +#: ../../library/itertools.rst:141 msgid "" ">>> data = [3, 4, 6, 2, 1, 9, 0, 7, 5, 8]\n" ">>> list(accumulate(data, max)) # running maximum\n" @@ -520,7 +521,7 @@ msgid "" "[1000, 960, 918, 874, 828, 779, 728, 674, 618, 559, 497]" msgstr "" -#: ../../library/itertools.rst:153 +#: ../../library/itertools.rst:154 msgid "" "See :func:`functools.reduce` for a similar function that returns only the " "final accumulated value." @@ -528,15 +529,15 @@ msgstr "" "最終的な累積値だけを返す類似の関数については :func:`functools.reduce` を見て" "ください。" -#: ../../library/itertools.rst:158 +#: ../../library/itertools.rst:159 msgid "Added the optional *function* parameter." msgstr "" -#: ../../library/itertools.rst:161 +#: ../../library/itertools.rst:162 msgid "Added the optional *initial* parameter." msgstr "オプションの *initial* パラメータが追加されました。" -#: ../../library/itertools.rst:167 +#: ../../library/itertools.rst:168 msgid "" "Batch data from the *iterable* into tuples of length *n*. The last batch may " "be shorter than *n*." @@ -544,13 +545,13 @@ msgstr "" "*iterable* から得られるデータを *n* 個ごとに一つのタプルにまとめます。\n" "一番最後のバッチは *n* 個より少なくなる可能性があります。" -#: ../../library/itertools.rst:170 +#: ../../library/itertools.rst:171 msgid "" "If *strict* is true, will raise a :exc:`ValueError` if the final batch is " "shorter than *n*." msgstr "" -#: ../../library/itertools.rst:173 +#: ../../library/itertools.rst:174 msgid "" "Loops over the input iterable and accumulates data into tuples up to size " "*n*. The input is consumed lazily, just enough to fill a batch. The result " @@ -564,7 +565,7 @@ msgstr "" "タプルは、個数が *n* に到達するか、入力の iterable が尽きるとすぐに出力されま" "す:" -#: ../../library/itertools.rst:178 +#: ../../library/itertools.rst:179 msgid "" ">>> flattened_data = ['roses', 'red', 'violets', 'blue', 'sugar', 'sweet']\n" ">>> unflattened = list(batched(flattened_data, 2))\n" @@ -572,7 +573,7 @@ msgid "" "[('roses', 'red'), ('violets', 'blue'), ('sugar', 'sweet')]" msgstr "" -#: ../../library/itertools.rst:187 +#: ../../library/itertools.rst:188 msgid "" "def batched(iterable, n, *, strict=False):\n" " # batched('ABCDEFG', 3) → ABC DEF G\n" @@ -585,22 +586,19 @@ msgid "" " yield batch" msgstr "" -#: ../../library/itertools.rst:199 +#: ../../library/itertools.rst:200 msgid "Added the *strict* option." msgstr "" -#: ../../library/itertools.rst:205 +#: ../../library/itertools.rst:206 msgid "" "Make an iterator that returns elements from the first iterable until it is " "exhausted, then proceeds to the next iterable, until all of the iterables " -"are exhausted. Used for treating consecutive sequences as a single " -"sequence. Roughly equivalent to::" +"are exhausted. This combines multiple data sources into a single iterator. " +"Roughly equivalent to::" msgstr "" -"先頭の iterable の全要素を返し、次に2番目の iterable の全要素を返し、と全 " -"iterable の要素を返すイテレータを作成します。連続したシーケンスを一つのシーケ" -"ンスとして扱う場合に使用します。およそ次と等価です::" -#: ../../library/itertools.rst:210 +#: ../../library/itertools.rst:211 msgid "" "def chain(*iterables):\n" " # chain('ABC', 'DEF') → A B C D E F\n" @@ -608,7 +606,7 @@ msgid "" " yield from iterable" msgstr "" -#: ../../library/itertools.rst:218 +#: ../../library/itertools.rst:219 msgid "" "Alternate constructor for :func:`chain`. Gets chained inputs from a single " "iterable argument that is evaluated lazily. Roughly equivalent to::" @@ -617,7 +615,7 @@ msgstr "" "引数一つから連鎖した入力を受け取ります。この関数は、以下のコードとほぼ等価で" "す::" -#: ../../library/itertools.rst:221 +#: ../../library/itertools.rst:222 msgid "" "def from_iterable(iterables):\n" " # chain.from_iterable(['ABC', 'DEF']) → A B C D E F\n" @@ -625,11 +623,11 @@ msgid "" " yield from iterable" msgstr "" -#: ../../library/itertools.rst:229 +#: ../../library/itertools.rst:230 msgid "Return *r* length subsequences of elements from the input *iterable*." msgstr "入力 *iterable* の要素からなる長さ *r* の部分列を返します。" -#: ../../library/itertools.rst:231 +#: ../../library/itertools.rst:232 msgid "" "The output is a subsequence of :func:`product` keeping only entries that are " "subsequences of the *iterable*. The length of the output is given by :func:" @@ -637,21 +635,21 @@ msgid "" "when ``r > n``." msgstr "" -#: ../../library/itertools.rst:236 +#: ../../library/itertools.rst:237 msgid "" "The combination tuples are emitted in lexicographic order according to the " "order of the input *iterable*. If the input *iterable* is sorted, the output " "tuples will be produced in sorted order." msgstr "" -#: ../../library/itertools.rst:240 +#: ../../library/itertools.rst:241 msgid "" "Elements are treated as unique based on their position, not on their value. " "If the input elements are unique, there will be no repeated values within " "each combination." msgstr "" -#: ../../library/itertools.rst:246 +#: ../../library/itertools.rst:247 msgid "" "def combinations(iterable, r):\n" " # combinations('ABCD', 2) → AB AC AD BC BD CD\n" @@ -676,7 +674,7 @@ msgid "" " yield tuple(pool[i] for i in indices)" msgstr "" -#: ../../library/itertools.rst:271 +#: ../../library/itertools.rst:272 msgid "" "Return *r* length subsequences of elements from the input *iterable* " "allowing individual elements to be repeated more than once." @@ -684,7 +682,7 @@ msgstr "" "入力 *iterable* から、それぞれの要素が複数回現れることを許して、長さ *r* の要" "素の部分列を返します。" -#: ../../library/itertools.rst:274 +#: ../../library/itertools.rst:275 msgid "" "The output is a subsequence of :func:`product` that keeps only entries that " "are subsequences (with possible repeated elements) of the *iterable*. The " @@ -692,21 +690,21 @@ msgid "" "> 0``." msgstr "" -#: ../../library/itertools.rst:279 +#: ../../library/itertools.rst:280 msgid "" "The combination tuples are emitted in lexicographic order according to the " "order of the input *iterable*. if the input *iterable* is sorted, the output " "tuples will be produced in sorted order." msgstr "" -#: ../../library/itertools.rst:283 +#: ../../library/itertools.rst:284 msgid "" "Elements are treated as unique based on their position, not on their value. " "If the input elements are unique, the generated combinations will also be " "unique." msgstr "" -#: ../../library/itertools.rst:289 +#: ../../library/itertools.rst:290 msgid "" "def combinations_with_replacement(iterable, r):\n" " # combinations_with_replacement('ABC', 2) → AA AB AC BB BC CC\n" @@ -728,28 +726,28 @@ msgid "" " yield tuple(pool[i] for i in indices)" msgstr "" -#: ../../library/itertools.rst:313 +#: ../../library/itertools.rst:314 msgid "" "Make an iterator that returns elements from *data* where the corresponding " "element in *selectors* is true. Stops when either the *data* or *selectors* " "iterables have been exhausted. Roughly equivalent to::" msgstr "" -#: ../../library/itertools.rst:318 +#: ../../library/itertools.rst:319 msgid "" "def compress(data, selectors):\n" " # compress('ABCDEF', [1,0,1,0,1,1]) → A C E F\n" " return (datum for datum, selector in zip(data, selectors) if selector)" msgstr "" -#: ../../library/itertools.rst:327 +#: ../../library/itertools.rst:328 msgid "" "Make an iterator that returns evenly spaced values beginning with *start*. " "Can be used with :func:`map` to generate consecutive data points or with :" "func:`zip` to add sequence numbers. Roughly equivalent to::" msgstr "" -#: ../../library/itertools.rst:332 +#: ../../library/itertools.rst:333 msgid "" "def count(start=0, step=1):\n" " # count(10) → 10 11 12 13 14 ...\n" @@ -760,51 +758,53 @@ msgid "" " n += step" msgstr "" -#: ../../library/itertools.rst:340 +#: ../../library/itertools.rst:341 msgid "" "When counting with floating-point numbers, better accuracy can sometimes be " "achieved by substituting multiplicative code such as: ``(start + step * i " "for i in count())``." msgstr "" -#: ../../library/itertools.rst:344 +#: ../../library/itertools.rst:345 msgid "Added *step* argument and allowed non-integer arguments." msgstr "*step* 引数が追加され、非整数の引数が許されるようになりました。" -#: ../../library/itertools.rst:350 +#: ../../library/itertools.rst:351 msgid "" "Make an iterator returning elements from the *iterable* and saving a copy of " "each. When the iterable is exhausted, return elements from the saved copy. " "Repeats indefinitely. Roughly equivalent to::" msgstr "" -#: ../../library/itertools.rst:354 +#: ../../library/itertools.rst:355 msgid "" "def cycle(iterable):\n" " # cycle('ABCD') → A B C D A B C D A B C D ...\n" +"\n" " saved = []\n" " for element in iterable:\n" " yield element\n" " saved.append(element)\n" +"\n" " while saved:\n" " for element in saved:\n" " yield element" msgstr "" -#: ../../library/itertools.rst:364 +#: ../../library/itertools.rst:367 msgid "" "This itertool may require significant auxiliary storage (depending on the " "length of the iterable)." msgstr "" -#: ../../library/itertools.rst:370 +#: ../../library/itertools.rst:373 msgid "" "Make an iterator that drops elements from the *iterable* while the " "*predicate* is true and afterwards returns every element. Roughly " "equivalent to::" msgstr "" -#: ../../library/itertools.rst:374 +#: ../../library/itertools.rst:377 msgid "" "def dropwhile(predicate, iterable):\n" " # dropwhile(lambda x: x<5, [1,4,6,3,8]) → 6 3 8\n" @@ -819,31 +819,33 @@ msgid "" " yield x" msgstr "" -#: ../../library/itertools.rst:386 +#: ../../library/itertools.rst:389 msgid "" "Note this does not produce *any* output until the predicate first becomes " "false, so this itertool may have a lengthy start-up time." msgstr "" -#: ../../library/itertools.rst:392 +#: ../../library/itertools.rst:395 msgid "" "Make an iterator that filters elements from the *iterable* returning only " "those for which the *predicate* returns a false value. If *predicate* is " "``None``, returns the items that are false. Roughly equivalent to::" msgstr "" -#: ../../library/itertools.rst:397 +#: ../../library/itertools.rst:400 msgid "" "def filterfalse(predicate, iterable):\n" " # filterfalse(lambda x: x<5, [1,4,6,3,8]) → 6 8\n" +"\n" " if predicate is None:\n" " predicate = bool\n" +"\n" " for x in iterable:\n" " if not predicate(x):\n" " yield x" msgstr "" -#: ../../library/itertools.rst:408 +#: ../../library/itertools.rst:413 msgid "" "Make an iterator that returns consecutive keys and groups from the " "*iterable*. The *key* is a function computing a key value for each element. " @@ -857,7 +859,7 @@ msgstr "" "ルトは恒等関数になり要素をそのまま返します。通常、*iterable* は同じキー関数で" "ソート済みである必要があります。" -#: ../../library/itertools.rst:414 +#: ../../library/itertools.rst:419 msgid "" "The operation of :func:`groupby` is similar to the ``uniq`` filter in Unix. " "It generates a break or new group every time the value of the key function " @@ -870,7 +872,7 @@ msgstr "" "関数でソートしておく必要があるのです)。この動作は SQL の入力順に関係なく共通" "の要素を集約する GROUP BY とは違います。" -#: ../../library/itertools.rst:420 +#: ../../library/itertools.rst:425 msgid "" "The returned group is itself an iterator that shares the underlying iterable " "with :func:`groupby`. Because the source is shared, when the :func:" @@ -883,7 +885,7 @@ msgstr "" "なってしまいます。従って、データが後で必要な場合にはリストの形で保存しておく" "必要があります::" -#: ../../library/itertools.rst:425 +#: ../../library/itertools.rst:430 msgid "" "groups = []\n" "uniquekeys = []\n" @@ -893,11 +895,11 @@ msgid "" " uniquekeys.append(k)" msgstr "" -#: ../../library/itertools.rst:432 +#: ../../library/itertools.rst:437 msgid ":func:`groupby` is roughly equivalent to::" msgstr ":func:`groupby` はおよそ次と等価です::" -#: ../../library/itertools.rst:434 +#: ../../library/itertools.rst:439 msgid "" "def groupby(iterable, key=None):\n" " # [k for k, g in groupby('AAAABBBCCDAABBB')] → A B C D A B\n" @@ -932,33 +934,33 @@ msgid "" " pass" msgstr "" -#: ../../library/itertools.rst:470 +#: ../../library/itertools.rst:475 msgid "" "Make an iterator that returns selected elements from the iterable. Works " "like sequence slicing but does not support negative values for *start*, " "*stop*, or *step*." msgstr "" -#: ../../library/itertools.rst:474 +#: ../../library/itertools.rst:479 msgid "" "If *start* is zero or ``None``, iteration starts at zero. Otherwise, " "elements from the iterable are skipped until *start* is reached." msgstr "" -#: ../../library/itertools.rst:477 +#: ../../library/itertools.rst:482 msgid "" -"If *stop* is ``None``, iteration continues until the iterator is exhausted, " -"if at all. Otherwise, it stops at the specified position." +"If *stop* is ``None``, iteration continues until the input is exhausted, if " +"at all. Otherwise, it stops at the specified position." msgstr "" -#: ../../library/itertools.rst:480 +#: ../../library/itertools.rst:485 msgid "" "If *step* is ``None``, the step defaults to one. Elements are returned " "consecutively unless *step* is set higher than one which results in items " "being skipped." msgstr "" -#: ../../library/itertools.rst:486 +#: ../../library/itertools.rst:491 msgid "" "def islice(iterable, *args):\n" " # islice('ABCDEFG', 2) → A B\n" @@ -981,35 +983,43 @@ msgid "" " next_i += step" msgstr "" -#: ../../library/itertools.rst:509 +#: ../../library/itertools.rst:511 +msgid "" +"If the input is an iterator, then fully consuming the *islice* advances the " +"input iterator by ``max(start, stop)`` steps regardless of the *step* value." +msgstr "" + +#: ../../library/itertools.rst:518 msgid "Return successive overlapping pairs taken from the input *iterable*." msgstr "" -#: ../../library/itertools.rst:511 +#: ../../library/itertools.rst:520 msgid "" "The number of 2-tuples in the output iterator will be one fewer than the " "number of inputs. It will be empty if the input iterable has fewer than two " "values." msgstr "" -#: ../../library/itertools.rst:517 +#: ../../library/itertools.rst:526 msgid "" "def pairwise(iterable):\n" " # pairwise('ABCDEFG') → AB BC CD DE EF FG\n" +"\n" " iterator = iter(iterable)\n" " a = next(iterator, None)\n" +"\n" " for b in iterator:\n" " yield a, b\n" " a = b" msgstr "" -#: ../../library/itertools.rst:530 +#: ../../library/itertools.rst:541 msgid "" "Return successive *r* length `permutations of elements `_ from the *iterable*." msgstr "" -#: ../../library/itertools.rst:533 +#: ../../library/itertools.rst:544 msgid "" "If *r* is not specified or is ``None``, then *r* defaults to the length of " "the *iterable* and all possible full-length permutations are generated." @@ -1017,7 +1027,7 @@ msgstr "" "*r* が指定されない場合や ``None`` の場合、*r* はデフォルトで *iterable* の長" "さとなり、可能な最長の順列の全てが生成されます。" -#: ../../library/itertools.rst:537 +#: ../../library/itertools.rst:548 msgid "" "The output is a subsequence of :func:`product` where entries with repeated " "elements have been filtered out. The length of the output is given by :func:" @@ -1025,21 +1035,21 @@ msgid "" "``r > n``." msgstr "" -#: ../../library/itertools.rst:542 +#: ../../library/itertools.rst:553 msgid "" "The permutation tuples are emitted in lexicographic order according to the " "order of the input *iterable*. If the input *iterable* is sorted, the " "output tuples will be produced in sorted order." msgstr "" -#: ../../library/itertools.rst:546 +#: ../../library/itertools.rst:557 msgid "" "Elements are treated as unique based on their position, not on their value. " "If the input elements are unique, there will be no repeated values within a " "permutation." msgstr "" -#: ../../library/itertools.rst:552 +#: ../../library/itertools.rst:563 msgid "" "def permutations(iterable, r=None):\n" " # permutations('ABCD', 2) → AB AC AD BA BC BD CA CB CD DA DB DC\n" @@ -1070,11 +1080,13 @@ msgid "" " return" msgstr "" -#: ../../library/itertools.rst:583 -msgid "Cartesian product of input iterables." -msgstr "入力イテラブルのデカルト積です。" +#: ../../library/itertools.rst:594 +msgid "" +"`Cartesian product `_ of " +"the input iterables." +msgstr "" -#: ../../library/itertools.rst:585 +#: ../../library/itertools.rst:597 msgid "" "Roughly equivalent to nested for-loops in a generator expression. For " "example, ``product(A, B)`` returns the same as ``((x,y) for x in A for y in " @@ -1083,7 +1095,7 @@ msgstr "" "ジェネレータ式の入れ子になった for ループとおよそ等価です。たとえば " "``product(A, B)`` は ``((x,y) for x in A for y in B)`` と同じものを返します。" -#: ../../library/itertools.rst:588 +#: ../../library/itertools.rst:600 msgid "" "The nested loops cycle like an odometer with the rightmost element advancing " "on every iteration. This pattern creates a lexicographic ordering so that " @@ -1094,7 +1106,7 @@ msgstr "" "ていきます。このパターンは辞書式順序を作り出し、入力のイテレート可能オブジェ" "クトたちがソートされていれば、直積タプルもソートされた順に出てきます。" -#: ../../library/itertools.rst:593 +#: ../../library/itertools.rst:605 msgid "" "To compute the product of an iterable with itself, specify the number of " "repetitions with the optional *repeat* keyword argument. For example, " @@ -1104,7 +1116,7 @@ msgstr "" "数に繰り返し回数を指定します。たとえば ``product(A, repeat=4)`` は " "``product(A, A, A, A)`` と同じ意味です。" -#: ../../library/itertools.rst:597 +#: ../../library/itertools.rst:609 msgid "" "This function is roughly equivalent to the following code, except that the " "actual implementation does not build up intermediate results in memory::" @@ -1112,12 +1124,14 @@ msgstr "" "この関数は以下のコードとおよそ等価ですが、実際の実装ではメモリ中に中間結果を" "作りません::" -#: ../../library/itertools.rst:600 +#: ../../library/itertools.rst:612 msgid "" "def product(*iterables, repeat=1):\n" " # product('ABCD', 'xy') → Ax Ay Bx By Cx Cy Dx Dy\n" " # product(range(2), repeat=3) → 000 001 010 011 100 101 110 111\n" "\n" +" if repeat < 0:\n" +" raise ValueError('repeat argument cannot be negative')\n" " pools = [tuple(pool) for pool in iterables] * repeat\n" "\n" " result = [[]]\n" @@ -1128,7 +1142,7 @@ msgid "" " yield tuple(prod)" msgstr "" -#: ../../library/itertools.rst:613 +#: ../../library/itertools.rst:627 msgid "" "Before :func:`product` runs, it completely consumes the input iterables, " "keeping pools of values in memory to generate the products. Accordingly, it " @@ -1138,13 +1152,13 @@ msgstr "" "するためにメモリ内に値を蓄えます。したがって、入力が有限の場合に限り有用で" "す。" -#: ../../library/itertools.rst:620 +#: ../../library/itertools.rst:634 msgid "" "Make an iterator that returns *object* over and over again. Runs " "indefinitely unless the *times* argument is specified." msgstr "" -#: ../../library/itertools.rst:625 +#: ../../library/itertools.rst:639 msgid "" "def repeat(object, times=None):\n" " # repeat(10, 3) → 10 10 10\n" @@ -1156,34 +1170,34 @@ msgid "" " yield object" msgstr "" -#: ../../library/itertools.rst:634 +#: ../../library/itertools.rst:648 msgid "" "A common use for *repeat* is to supply a stream of constant values to *map* " "or *zip*:" msgstr "" "*repeat* は *map* や *zip* に定数のストリームを与えるためによく利用されます:" -#: ../../library/itertools.rst:637 +#: ../../library/itertools.rst:651 msgid "" ">>> list(map(pow, range(10), repeat(2)))\n" "[0, 1, 4, 9, 16, 25, 36, 49, 64, 81]" msgstr "" -#: ../../library/itertools.rst:645 +#: ../../library/itertools.rst:659 msgid "" "Make an iterator that computes the *function* using arguments obtained from " "the *iterable*. Used instead of :func:`map` when argument parameters have " "already been \"pre-zipped\" into tuples." msgstr "" -#: ../../library/itertools.rst:649 +#: ../../library/itertools.rst:663 msgid "" "The difference between :func:`map` and :func:`starmap` parallels the " "distinction between ``function(a,b)`` and ``function(*c)``. Roughly " "equivalent to::" msgstr "" -#: ../../library/itertools.rst:653 +#: ../../library/itertools.rst:667 msgid "" "def starmap(function, iterable):\n" " # starmap(pow, [(2,5), (3,2), (10,3)]) → 32 9 1000\n" @@ -1191,13 +1205,13 @@ msgid "" " yield function(*args)" msgstr "" -#: ../../library/itertools.rst:661 +#: ../../library/itertools.rst:675 msgid "" "Make an iterator that returns elements from the *iterable* as long as the " "*predicate* is true. Roughly equivalent to::" msgstr "" -#: ../../library/itertools.rst:664 +#: ../../library/itertools.rst:678 msgid "" "def takewhile(predicate, iterable):\n" " # takewhile(lambda x: x<5, [1,4,6,3,8]) → 1 4\n" @@ -1207,7 +1221,7 @@ msgid "" " yield x" msgstr "" -#: ../../library/itertools.rst:671 +#: ../../library/itertools.rst:685 msgid "" "Note, the element that first fails the predicate condition is consumed from " "the input iterator and there is no way to access it. This could be an issue " @@ -1217,47 +1231,87 @@ msgid "" "readthedocs.io/en/stable/api.html#more_itertools.before_and_after>`_ instead." msgstr "" -#: ../../library/itertools.rst:682 +#: ../../library/itertools.rst:696 msgid "Return *n* independent iterators from a single iterable." msgstr "一つの iterable から *n* 個の独立したイテレータを返します。" -#: ../../library/itertools.rst:686 +#: ../../library/itertools.rst:700 msgid "" "def tee(iterable, n=2):\n" -" iterator = iter(iterable)\n" -" shared_link = [None, None]\n" -" return tuple(_tee(iterator, shared_link) for _ in range(n))\n" +" if n < 0:\n" +" raise ValueError\n" +" if n == 0:\n" +" return ()\n" +" iterator = _tee(iterable)\n" +" result = [iterator]\n" +" for _ in range(n - 1):\n" +" result.append(_tee(iterator))\n" +" return tuple(result)\n" "\n" -"def _tee(iterator, link):\n" -" try:\n" -" while True:\n" -" if link[1] is None:\n" -" link[0] = next(iterator)\n" -" link[1] = [None, None]\n" -" value, link = link\n" -" yield value\n" -" except StopIteration:\n" -" return" +"class _tee:\n" +"\n" +" def __init__(self, iterable):\n" +" it = iter(iterable)\n" +" if isinstance(it, _tee):\n" +" self.iterator = it.iterator\n" +" self.link = it.link\n" +" else:\n" +" self.iterator = it\n" +" self.link = [None, None]\n" +"\n" +" def __iter__(self):\n" +" return self\n" +"\n" +" def __next__(self):\n" +" link = self.link\n" +" if link[1] is None:\n" +" link[0] = next(self.iterator)\n" +" link[1] = [None, None]\n" +" value, self.link = link\n" +" return value" +msgstr "" + +#: ../../library/itertools.rst:733 +msgid "" +"When the input *iterable* is already a tee iterator object, all members of " +"the return tuple are constructed as if they had been produced by the " +"upstream :func:`tee` call. This \"flattening step\" allows nested :func:" +"`tee` calls to share the same underlying data chain and to have a single " +"update step rather than a chain of calls." +msgstr "" + +#: ../../library/itertools.rst:739 +msgid "The flattening property makes tee iterators efficiently peekable:" msgstr "" -#: ../../library/itertools.rst:702 +#: ../../library/itertools.rst:741 msgid "" -"Once a :func:`tee` has been created, the original *iterable* should not be " -"used anywhere else; otherwise, the *iterable* could get advanced without the " -"tee objects being informed." +"def lookahead(tee_iterator):\n" +" \"Return the next value without moving the input forward\"\n" +" [forked_iterator] = tee(tee_iterator, 1)\n" +" return next(forked_iterator)" msgstr "" -"一度 :func:`tee` が生成されたら、もとの *iterable* を他で使ってはいけません。" -"さもなければ、 :func:`tee` オブジェクトの知らない間に *iterable* が先の要素に" -"進んでしまうことになります。" -#: ../../library/itertools.rst:706 +#: ../../library/itertools.rst:748 +msgid "" +">>> iterator = iter('abcdef')\n" +">>> [iterator] = tee(iterator, 1) # Make the input peekable\n" +">>> next(iterator) # Move the iterator forward\n" +"'a'\n" +">>> lookahead(iterator) # Check next value\n" +"'b'\n" +">>> next(iterator) # Continue moving forward\n" +"'b'" +msgstr "" + +#: ../../library/itertools.rst:759 msgid "" "``tee`` iterators are not threadsafe. A :exc:`RuntimeError` may be raised " "when simultaneously using iterators returned by the same :func:`tee` call, " "even if the original *iterable* is threadsafe." msgstr "" -#: ../../library/itertools.rst:710 +#: ../../library/itertools.rst:763 msgid "" "This itertool may require significant auxiliary storage (depending on how " "much temporary data needs to be stored). In general, if one iterator uses " @@ -1269,21 +1323,21 @@ msgstr "" "よりも先にほとんどまたは全ての要素を消費するような場合には、 :func:`tee` より" "も :func:`list` を使った方が高速です。" -#: ../../library/itertools.rst:718 +#: ../../library/itertools.rst:771 msgid "Make an iterator that aggregates elements from each of the *iterables*." msgstr "" -#: ../../library/itertools.rst:721 +#: ../../library/itertools.rst:774 msgid "" "If the iterables are of uneven length, missing values are filled-in with " "*fillvalue*. If not specified, *fillvalue* defaults to ``None``." msgstr "" -#: ../../library/itertools.rst:724 +#: ../../library/itertools.rst:777 msgid "Iteration continues until the longest iterable is exhausted." msgstr "" -#: ../../library/itertools.rst:728 +#: ../../library/itertools.rst:781 msgid "" "def zip_longest(*iterables, fillvalue=None):\n" " # zip_longest('ABCD', 'xy', fillvalue='-') → Ax By C- D-\n" @@ -1308,18 +1362,18 @@ msgid "" " yield tuple(values)" msgstr "" -#: ../../library/itertools.rst:750 +#: ../../library/itertools.rst:803 msgid "" "If one of the iterables is potentially infinite, then the :func:" "`zip_longest` function should be wrapped with something that limits the " "number of calls (for example :func:`islice` or :func:`takewhile`)." msgstr "" -#: ../../library/itertools.rst:758 +#: ../../library/itertools.rst:811 msgid "Itertools Recipes" msgstr "Itertools レシピ" -#: ../../library/itertools.rst:760 +#: ../../library/itertools.rst:813 msgid "" "This section shows recipes for creating an extended toolset using the " "existing itertools as building blocks." @@ -1327,7 +1381,7 @@ msgstr "" "この節では、既存の itertools を素材としてツールセットを拡張するためのレシピを" "示します。" -#: ../../library/itertools.rst:763 +#: ../../library/itertools.rst:816 msgid "" "The primary purpose of the itertools recipes is educational. The recipes " "show various ways of thinking about individual tools — for example, that " @@ -1339,7 +1393,7 @@ msgid "" "``map()``, ``filter()``, ``reversed()``, and ``enumerate()``." msgstr "" -#: ../../library/itertools.rst:772 +#: ../../library/itertools.rst:825 msgid "" "A secondary purpose of the recipes is to serve as an incubator. The " "``accumulate()``, ``compress()``, and ``pairwise()`` itertools started out " @@ -1347,17 +1401,17 @@ msgid "" "``sieve()`` recipes are being tested to see whether they prove their worth." msgstr "" -#: ../../library/itertools.rst:777 +#: ../../library/itertools.rst:830 msgid "" "Substantially all of these recipes and many, many others can be installed " "from the :pypi:`more-itertools` project found on the Python Package Index::" msgstr "" -#: ../../library/itertools.rst:781 +#: ../../library/itertools.rst:834 msgid "python -m pip install more-itertools" msgstr "" -#: ../../library/itertools.rst:783 +#: ../../library/itertools.rst:836 msgid "" "Many of the recipes offer the same high performance as the underlying " "toolset. Superior memory performance is kept by processing elements one at a " @@ -1369,7 +1423,7 @@ msgid "" "overhead." msgstr "" -#: ../../library/itertools.rst:791 +#: ../../library/itertools.rst:844 msgid "" "import collections\n" "import contextlib\n" @@ -1505,16 +1559,6 @@ msgid "" " iterators = cycle(islice(iterators, num_active))\n" " yield from map(next, iterators)\n" "\n" -"def partition(predicate, iterable):\n" -" \"\"\"Partition entries into false entries and true entries.\n" -"\n" -" If *predicate* is slow, consider wrapping it with functools." -"lru_cache().\n" -" \"\"\"\n" -" # partition(is_odd, range(10)) → 0 2 4 6 8 and 1 3 5 7 9\n" -" t1, t2 = tee(iterable)\n" -" return filterfalse(predicate, t1), filter(predicate, t2)\n" -"\n" "def subslices(seq):\n" " \"Return all contiguous non-empty subslices of a sequence.\"\n" " # subslices('ABCD') → A AB ABC ABCD B BC BCD C CD D\n" @@ -1548,11 +1592,11 @@ msgid "" " yield func()" msgstr "" -#: ../../library/itertools.rst:964 +#: ../../library/itertools.rst:1008 msgid "The following recipes have a more mathematical flavor:" msgstr "" -#: ../../library/itertools.rst:966 +#: ../../library/itertools.rst:1010 msgid "" "def powerset(iterable):\n" " \"powerset([1,2,3]) → () (1,) (2,) (3,) (1,2) (1,3) (2,3) (1,2,3)\"\n" diff --git a/library/locale.po b/library/locale.po index 19338cb90..4bef67f01 100644 --- a/library/locale.po +++ b/library/locale.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:08+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -373,17 +373,14 @@ msgstr "" #: ../../library/locale.rst:161 msgid "" -"Return some locale-specific information as a string. This function is not " -"available on all systems, and the set of possible options might also vary " -"across platforms. The possible argument values are numbers, for which " -"symbolic constants are available in the locale module." +"Return some locale-specific information as a string (or a tuple for " +"``ALT_DIGITS``). This function is not available on all systems, and the set " +"of possible options might also vary across platforms. The possible argument " +"values are numbers, for which symbolic constants are available in the locale " +"module." msgstr "" -"ロケール特有の情報を文字列として返します。この関数は全てのシステムで利用可能" -"なわけではなく、指定できる *option* もプラットフォーム間で大きく異なります。" -"引数として使えるのは、locale モジュールで利用可能なシンボル定数を表す数字で" -"す。" -#: ../../library/locale.rst:166 +#: ../../library/locale.rst:167 msgid "" "The :func:`nl_langinfo` function accepts one of the following keys. Most " "descriptions are taken from the corresponding description in the GNU C " @@ -392,7 +389,7 @@ msgstr "" "関数 :func:`nl_langinfo` は以下のキーのうち一つを受理します。ほとんどの記述" "は GNU C ライブラリ中の対応する説明から引用されています。" -#: ../../library/locale.rst:172 +#: ../../library/locale.rst:173 msgid "" "Get a string with the name of the character encoding used in the selected " "locale." @@ -400,7 +397,7 @@ msgstr "" "選択されたロケールで用いられている文字エンコーディングの名前を文字列で取得し" "ます。" -#: ../../library/locale.rst:177 +#: ../../library/locale.rst:178 msgid "" "Get a string that can be used as a format string for :func:`time.strftime` " "to represent date and time in a locale-specific way." @@ -408,7 +405,7 @@ msgstr "" "日付と時刻をロケール特有の方法で表現するために、 :func:`time.strftime` の書式" "文字列として用いることのできる文字列を取得します。" -#: ../../library/locale.rst:182 +#: ../../library/locale.rst:183 msgid "" "Get a string that can be used as a format string for :func:`time.strftime` " "to represent a date in a locale-specific way." @@ -416,7 +413,7 @@ msgstr "" "日付をロケール特有の方法で表現するために、 :func:`time.strftime` の書式文字列" "として用いることのできる文字列を取得します。" -#: ../../library/locale.rst:187 +#: ../../library/locale.rst:188 msgid "" "Get a string that can be used as a format string for :func:`time.strftime` " "to represent a time in a locale-specific way." @@ -424,7 +421,7 @@ msgstr "" "時刻をロケール特有の方法で表現するために、 :func:`time.strftime` の書式文字列" "として用いることのできる文字列を取得します。" -#: ../../library/locale.rst:192 +#: ../../library/locale.rst:193 msgid "" "Get a format string for :func:`time.strftime` to represent time in the am/pm " "format." @@ -432,11 +429,11 @@ msgstr "" "時刻を午前/午後の書式で表現するために、 :func:`time.strftime` の書式文字列と" "して用いることのできる文字列を取得します。" -#: ../../library/locale.rst:203 +#: ../../library/locale.rst:204 msgid "Get the name of the n-th day of the week." msgstr "1 週間中の n 番目の曜日名を取得します。" -#: ../../library/locale.rst:207 +#: ../../library/locale.rst:208 msgid "" "This follows the US convention of :const:`DAY_1` being Sunday, not the " "international convention (ISO 8601) that Monday is the first day of the week." @@ -444,27 +441,27 @@ msgstr "" "ロケール US における、 :const:`DAY_1` を日曜日とする慣行に従っています。国際" "的な (ISO 8601) 月曜日を週の初めとする慣行ではありません。" -#: ../../library/locale.rst:219 +#: ../../library/locale.rst:220 msgid "Get the abbreviated name of the n-th day of the week." msgstr "1 週間中の n 番目の曜日名を略式表記で取得します。" -#: ../../library/locale.rst:234 +#: ../../library/locale.rst:235 msgid "Get the name of the n-th month." msgstr "n 番目の月の名前を取得します。" -#: ../../library/locale.rst:249 +#: ../../library/locale.rst:250 msgid "Get the abbreviated name of the n-th month." msgstr "n 番目の月の名前を略式表記で取得します。" -#: ../../library/locale.rst:253 +#: ../../library/locale.rst:254 msgid "Get the radix character (decimal dot, decimal comma, etc.)." msgstr "基数点 (小数点ドット、あるいは小数点コンマ、等) を取得します。" -#: ../../library/locale.rst:257 +#: ../../library/locale.rst:258 msgid "Get the separator character for thousands (groups of three digits)." msgstr "1000 単位桁区切り (3 桁ごとのグループ化) の区切り文字を取得します。" -#: ../../library/locale.rst:261 +#: ../../library/locale.rst:262 msgid "" "Get a regular expression that can be used with the regex function to " "recognize a positive response to a yes/no question." @@ -472,20 +469,20 @@ msgstr "" "肯定/否定で答える質問に対する肯定回答を正規表現関数で認識するために利用でき" "る正規表現を取得します。" -#: ../../library/locale.rst:266 +#: ../../library/locale.rst:267 msgid "" "Get a regular expression that can be used with the ``regex(3)`` function to " "recognize a negative response to a yes/no question." msgstr "" -#: ../../library/locale.rst:271 +#: ../../library/locale.rst:272 msgid "" "The regular expressions for :const:`YESEXPR` and :const:`NOEXPR` use syntax " "suitable for the ``regex`` function from the C library, which might differ " "from the syntax used in :mod:`re`." msgstr "" -#: ../../library/locale.rst:278 +#: ../../library/locale.rst:279 msgid "" "Get the currency symbol, preceded by \"-\" if the symbol should appear " "before the value, \"+\" if the symbol should appear after the value, or \"." @@ -495,11 +492,11 @@ msgstr "" "ろに表示させる場合には \"+\"、シンボルを基数点と置き換える場合には \".\" を前" "につけます。" -#: ../../library/locale.rst:284 +#: ../../library/locale.rst:285 msgid "Get a string that represents the era used in the current locale." msgstr "現在のロケールで使われている年代を表現する値を取得します。" -#: ../../library/locale.rst:286 +#: ../../library/locale.rst:287 msgid "" "Most locales do not define this value. An example of a locale which does " "define this value is the Japanese one. In Japan, the traditional " @@ -510,7 +507,7 @@ msgstr "" "の例は Japanese です。日本には日付の伝統的な表示法として、時の天皇に対応する" "元号名があります。" -#: ../../library/locale.rst:291 +#: ../../library/locale.rst:292 msgid "" "Normally it should not be necessary to use this value directly. Specifying " "the ``E`` modifier in their format strings causes the :func:`time.strftime` " @@ -523,7 +520,7 @@ msgstr "" "の様式は決められていないので、異なるシステム間で様式に関する同じ知識が使える" "と期待してはいけません。" -#: ../../library/locale.rst:299 +#: ../../library/locale.rst:300 msgid "" "Get a format string for :func:`time.strftime` to represent date and time in " "a locale-specific era-based way." @@ -531,7 +528,7 @@ msgstr "" "日付および時間をロケール固有の年代に基づいた方法で表現するために、 :func:" "`time.strftime` の書式文字列として用いることのできる文字列を取得します。" -#: ../../library/locale.rst:304 +#: ../../library/locale.rst:305 msgid "" "Get a format string for :func:`time.strftime` to represent a date in a " "locale-specific era-based way." @@ -539,7 +536,7 @@ msgstr "" "日付をロケール固有の年代に基づいた方法で表現するために、 :func:`time." "strftime` の書式文字列として用いることのできる文字列を取得します。" -#: ../../library/locale.rst:309 +#: ../../library/locale.rst:310 msgid "" "Get a format string for :func:`time.strftime` to represent a time in a " "locale-specific era-based way." @@ -547,11 +544,9 @@ msgstr "" "時刻をロケール固有の年代に基づいた方法で表現するために、 :func:`time." "strftime` の書式文字列として用いることのできる文字列を取得します。" -#: ../../library/locale.rst:314 -msgid "" -"Get a representation of up to 100 values used to represent the values 0 to " -"99." -msgstr "返される値は 0 から 99 までの 100 個の値の表現です。" +#: ../../library/locale.rst:315 +msgid "Get a tuple of up to 100 strings used to represent the values 0 to 99." +msgstr "" #: ../../library/locale.rst:320 msgid "" diff --git a/library/logging.config.po b/library/logging.config.po index aeb8b1a52..27ecce1b2 100644 --- a/library/logging.config.po +++ b/library/logging.config.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:09+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -1335,59 +1335,59 @@ msgstr "" #: ../../library/logging.config.rst:756 msgid "" -"An object implementing the :class:`queue.Queue` public API. For instance, " -"this may be an actual instance of :class:`queue.Queue` or a subclass " -"thereof, or a proxy obtained by :meth:`multiprocessing.managers.SyncManager." -"Queue`." +"An object implementing the :meth:`Queue.put_nowait ` " +"and :meth:`Queue.get ` public API. For instance, this may " +"be an actual instance of :class:`queue.Queue` or a subclass thereof, or a " +"proxy obtained by :meth:`multiprocessing.managers.SyncManager.Queue`." msgstr "" -#: ../../library/logging.config.rst:760 +#: ../../library/logging.config.rst:761 msgid "" "This is of course only possible if you are constructing or modifying the " "configuration dictionary in code." msgstr "" -#: ../../library/logging.config.rst:763 +#: ../../library/logging.config.rst:764 msgid "" "A string that resolves to a callable which, when called with no arguments, " -"returns the :class:`queue.Queue` instance to use. That callable could be a :" -"class:`queue.Queue` subclass or a function which returns a suitable queue " -"instance, such as ``my.module.queue_factory()``." +"returns the queue instance to use. That callable could be a :class:`queue." +"Queue` subclass or a function which returns a suitable queue instance, such " +"as ``my.module.queue_factory()``." msgstr "" -#: ../../library/logging.config.rst:768 +#: ../../library/logging.config.rst:769 msgid "" "A dict with a ``'()'`` key which is constructed in the usual way as " "discussed in :ref:`logging-config-dict-userdef`. The result of this " "construction should be a :class:`queue.Queue` instance." msgstr "" -#: ../../library/logging.config.rst:772 +#: ../../library/logging.config.rst:773 msgid "" "If the ``queue`` key is absent, a standard unbounded :class:`queue.Queue` " "instance is created and used." msgstr "" -#: ../../library/logging.config.rst:775 +#: ../../library/logging.config.rst:776 msgid "" "If the ``listener`` key is present, the corresponding value can be one of " "the following:" msgstr "" -#: ../../library/logging.config.rst:777 +#: ../../library/logging.config.rst:778 msgid "" "A subclass of :class:`logging.handlers.QueueListener`. This is of course " "only possible if you are constructing or modifying the configuration " "dictionary in code." msgstr "" -#: ../../library/logging.config.rst:781 +#: ../../library/logging.config.rst:782 msgid "" "A string which resolves to a class which is a subclass of ``QueueListener``, " "such as ``'my.package.CustomListener'``." msgstr "" -#: ../../library/logging.config.rst:784 +#: ../../library/logging.config.rst:785 msgid "" "A dict with a ``'()'`` key which is constructed in the usual way as " "discussed in :ref:`logging-config-dict-userdef`. The result of this " @@ -1395,31 +1395,31 @@ msgid "" "``QueueListener`` initializer." msgstr "" -#: ../../library/logging.config.rst:788 +#: ../../library/logging.config.rst:789 msgid "" "If the ``listener`` key is absent, :class:`logging.handlers.QueueListener` " "is used." msgstr "" -#: ../../library/logging.config.rst:790 +#: ../../library/logging.config.rst:791 msgid "" "The values under the ``handlers`` key are the names of other handlers in the " "configuration (not shown in the above snippet) which will be passed to the " "queue listener." msgstr "" -#: ../../library/logging.config.rst:794 +#: ../../library/logging.config.rst:795 msgid "" "Any custom queue handler and listener classes will need to be defined with " "the same initialization signatures as :class:`~logging.handlers." "QueueHandler` and :class:`~logging.handlers.QueueListener`." msgstr "" -#: ../../library/logging.config.rst:803 +#: ../../library/logging.config.rst:804 msgid "Configuration file format" msgstr "環境設定ファイルの書式" -#: ../../library/logging.config.rst:805 +#: ../../library/logging.config.rst:806 msgid "" "The configuration file format understood by :func:`fileConfig` is based on :" "mod:`configparser` functionality. The file must contain sections called " @@ -1449,7 +1449,7 @@ msgstr "" "ガーの設定は ``[logger_root]`` と呼ばれるセクションで指定されていなければなり" "ません。" -#: ../../library/logging.config.rst:820 +#: ../../library/logging.config.rst:821 msgid "" "The :func:`fileConfig` API is older than the :func:`dictConfig` API and does " "not provide functionality to cover certain aspects of logging. For example, " @@ -1470,11 +1470,11 @@ msgstr "" "行われることに注意してください。ですから、そうするのが便利であるときに新しい " "API に乗り換えるのは良い考えです。" -#: ../../library/logging.config.rst:830 +#: ../../library/logging.config.rst:831 msgid "Examples of these sections in the file are given below." msgstr "ファイルにおけるこれらのセクションの例を以下に示します。" -#: ../../library/logging.config.rst:832 +#: ../../library/logging.config.rst:833 msgid "" "[loggers]\n" "keys=root,log02,log03,log04,log05,log06,log07\n" @@ -1486,7 +1486,7 @@ msgid "" "keys=form01,form02,form03,form04,form05,form06,form07,form08,form09" msgstr "" -#: ../../library/logging.config.rst:843 +#: ../../library/logging.config.rst:844 msgid "" "The root logger must specify a level and a list of handlers. An example of a " "root logger section is given below." @@ -1494,14 +1494,14 @@ msgstr "" "ルートロガーでは、レベルとハンドラのリストを指定しなければなりません。ルート" "ロガーのセクションの例を以下に示します。" -#: ../../library/logging.config.rst:846 +#: ../../library/logging.config.rst:847 msgid "" "[logger_root]\n" "level=NOTSET\n" "handlers=hand01" msgstr "" -#: ../../library/logging.config.rst:852 +#: ../../library/logging.config.rst:853 msgid "" "The ``level`` entry can be one of ``DEBUG, INFO, WARNING, ERROR, CRITICAL`` " "or ``NOTSET``. For the root logger only, ``NOTSET`` means that all messages " @@ -1514,7 +1514,7 @@ msgstr "" "値は ``logging`` パッケージの名前空間のコンテキストで :ref:`評価 ` されます。" -#: ../../library/logging.config.rst:857 +#: ../../library/logging.config.rst:858 msgid "" "The ``handlers`` entry is a comma-separated list of handler names, which " "must appear in the ``[handlers]`` section. These names must appear in the " @@ -1525,7 +1525,7 @@ msgstr "" "``[handlers]`` セクションになくてはなりません。また、これらの各ハンドラの名前" "に対応するセクションが設定ファイルに存在しなければなりません。" -#: ../../library/logging.config.rst:862 +#: ../../library/logging.config.rst:863 msgid "" "For loggers other than the root logger, some additional information is " "required. This is illustrated by the following example." @@ -1533,7 +1533,7 @@ msgstr "" "ルートロガー以外のロガーでは、いくつか追加の情報が必要になります。これは以下" "の例のように表されます。" -#: ../../library/logging.config.rst:865 +#: ../../library/logging.config.rst:866 msgid "" "[logger_parser]\n" "level=DEBUG\n" @@ -1542,7 +1542,7 @@ msgid "" "qualname=compiler.parser" msgstr "" -#: ../../library/logging.config.rst:873 +#: ../../library/logging.config.rst:874 msgid "" "The ``level`` and ``handlers`` entries are interpreted as for the root " "logger, except that if a non-root logger's level is specified as ``NOTSET``, " @@ -1563,13 +1563,13 @@ msgstr "" "ガーのチャネル名を階層的に表したもの、すなわちアプリケーションがこのロガーを" "取得する際に使う名前になります。" -#: ../../library/logging.config.rst:882 +#: ../../library/logging.config.rst:883 msgid "" "Sections which specify handler configuration are exemplified by the " "following." msgstr "ハンドラの環境設定を指定しているセクションは以下の例のようになります。" -#: ../../library/logging.config.rst:884 +#: ../../library/logging.config.rst:885 msgid "" "[handler_hand01]\n" "class=StreamHandler\n" @@ -1578,7 +1578,7 @@ msgid "" "args=(sys.stdout,)" msgstr "" -#: ../../library/logging.config.rst:892 +#: ../../library/logging.config.rst:893 msgid "" "The ``class`` entry indicates the handler's class (as determined by :func:" "`eval` in the ``logging`` package's namespace). The ``level`` is interpreted " @@ -1589,7 +1589,7 @@ msgstr "" "うに解釈され、 ``NOTSET`` は \"すべてを記録する (log everything)\" と解釈され" "ます。" -#: ../../library/logging.config.rst:896 +#: ../../library/logging.config.rst:897 msgid "" "The ``formatter`` entry indicates the key name of the formatter for this " "handler. If blank, a default formatter (``logging._defaultFormatter``) is " @@ -1601,7 +1601,7 @@ msgstr "" "われます。名前が指定されている場合、その名前は ``[formatters]`` セクションに" "なくてはならず、対応するセクションが設定ファイル中になければなりません。" -#: ../../library/logging.config.rst:901 +#: ../../library/logging.config.rst:902 msgid "" "The ``args`` entry, when :ref:`evaluated ` in the context of the " "``logging`` package's namespace, is the list of arguments to the constructor " @@ -1615,7 +1615,7 @@ msgstr "" "のコンストラクタまたは下記の例を参照してください。指定されなければデフォルト" "は ``()`` になります。" -#: ../../library/logging.config.rst:907 +#: ../../library/logging.config.rst:908 msgid "" "The optional ``kwargs`` entry, when :ref:`evaluated ` in the " "context of the ``logging`` package's namespace, is the keyword argument dict " @@ -1627,7 +1627,7 @@ msgstr "" "ためのキーワード引数の辞書です。指定されなければデフォルトは ``{}`` になりま" "す。" -#: ../../library/logging.config.rst:911 +#: ../../library/logging.config.rst:912 msgid "" "[handler_hand02]\n" "class=FileHandler\n" @@ -1683,12 +1683,12 @@ msgid "" "kwargs={'secure': True}" msgstr "" -#: ../../library/logging.config.rst:964 +#: ../../library/logging.config.rst:965 msgid "" "Sections which specify formatter configuration are typified by the following." msgstr "フォーマッタの環境設定を指定しているセクションは以下のような形式です。" -#: ../../library/logging.config.rst:966 +#: ../../library/logging.config.rst:967 msgid "" "[formatter_form01]\n" "format=F1 %(asctime)s %(levelname)s %(message)s %(customfield)s\n" @@ -1699,7 +1699,7 @@ msgid "" "class=logging.Formatter" msgstr "" -#: ../../library/logging.config.rst:976 +#: ../../library/logging.config.rst:977 msgid "" "The arguments for the formatter configuration are the same as the keys in " "the dictionary schema :ref:`formatters section ` の辞" "書スキーマと同じキーを持つ、フォーマッター設定の引数です。" -#: ../../library/logging.config.rst:980 +#: ../../library/logging.config.rst:981 msgid "" "The ``defaults`` entry, when :ref:`evaluated ` in the context of " "the ``logging`` package's namespace, is a dictionary of default values for " "custom formatting fields. If not provided, it defaults to ``None``." msgstr "" -#: ../../library/logging.config.rst:987 +#: ../../library/logging.config.rst:988 msgid "" "Due to the use of :func:`eval` as described above, there are potential " "security risks which result from using the :func:`listen` to send and " @@ -1729,18 +1729,18 @@ msgstr "" "ドを実行する場合に制限されています; 詳細は :func:`listen` ドキュメンテーショ" "ンを参照してください。" -#: ../../library/logging.config.rst:995 +#: ../../library/logging.config.rst:996 msgid "Module :mod:`logging`" msgstr ":mod:`logging` モジュール" -#: ../../library/logging.config.rst:996 +#: ../../library/logging.config.rst:997 msgid "API reference for the logging module." msgstr "logging モジュールの API リファレンス。" -#: ../../library/logging.config.rst:998 +#: ../../library/logging.config.rst:999 msgid "Module :mod:`logging.handlers`" msgstr ":mod:`logging.handlers` モジュール" -#: ../../library/logging.config.rst:999 +#: ../../library/logging.config.rst:1000 msgid "Useful handlers included with the logging module." msgstr "logging モジュールに含まれる、便利なハンドラです。" diff --git a/library/mimetypes.po b/library/mimetypes.po index bc3bdf46a..29c1196e6 100644 --- a/library/mimetypes.po +++ b/library/mimetypes.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:09+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -454,8 +454,8 @@ msgid "Load MIME type information from the Windows registry." msgstr "MIME type 情報を Windows のレジストリから読み込みます。" #: ../../library/mimetypes.rst:292 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +msgid "Availability" +msgstr "" #: ../../library/mimetypes.rst:11 ../../library/mimetypes.rst:31 #: ../../library/mimetypes.rst:64 diff --git a/library/mmap.po b/library/mmap.po index 4e7af487f..338c2ed28 100644 --- a/library/mmap.po +++ b/library/mmap.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:09+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -31,8 +31,8 @@ msgid ":mod:`!mmap` --- Memory-mapped file support" msgstr ":mod:`!mmap` --- メモリマップファイルのサポート" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/multiprocessing.po b/library/multiprocessing.po index 214caad83..2e6ad6e63 100644 --- a/library/multiprocessing.po +++ b/library/multiprocessing.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:10+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -37,7 +37,7 @@ msgid "**Source code:** :source:`Lib/multiprocessing/`" msgstr "**ソースコード:** :source:`Lib/multiprocessing/`" #: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." +msgid "Availability" msgstr "" #: ../../includes/wasm-mobile-notavail.rst:5 diff --git a/library/os.path.po b/library/os.path.po index fe6a8e610..8e9705c6f 100644 --- a/library/os.path.po +++ b/library/os.path.po @@ -9,8 +9,8 @@ # mollinaca, 2021 # Takanori Suzuki , 2021 # Arihiro TAKASE, 2023 -# Masato HASHIMOTO , 2023 # tomo, 2023 +# Masato HASHIMOTO , 2023 # 石井明久, 2024 # Takeshi Nakazato, 2024 # @@ -19,7 +19,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:10+0000\n" "Last-Translator: Takeshi Nakazato, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -456,8 +456,8 @@ msgid "" msgstr "" #: ../../library/os.path.rst:348 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +msgid "Availability" +msgstr "" #: ../../library/os.path.rst:355 msgid "" diff --git a/library/os.po b/library/os.po index cb8a70efe..c5760ede4 100644 --- a/library/os.po +++ b/library/os.po @@ -20,7 +20,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:10+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -340,20 +340,62 @@ msgid "" "Return the filename corresponding to the controlling terminal of the process." msgstr "プロセスの制御端末に対応するファイル名を返します。" -#: ../../library/os.rst:181 ../../library/os.rst:358 ../../library/os.rst:367 -#: ../../library/os.rst:389 ../../library/os.rst:398 ../../library/os.rst:434 -#: ../../library/os.rst:442 ../../library/os.rst:480 ../../library/os.rst:491 -#: ../../library/os.rst:512 ../../library/os.rst:522 ../../library/os.rst:602 +#: ../../library/os.rst:181 ../../library/os.rst:322 ../../library/os.rst:337 +#: ../../library/os.rst:358 ../../library/os.rst:367 ../../library/os.rst:376 +#: ../../library/os.rst:389 ../../library/os.rst:398 ../../library/os.rst:426 +#: ../../library/os.rst:434 ../../library/os.rst:442 ../../library/os.rst:462 +#: ../../library/os.rst:480 ../../library/os.rst:491 ../../library/os.rst:503 +#: ../../library/os.rst:512 ../../library/os.rst:522 ../../library/os.rst:533 +#: ../../library/os.rst:545 ../../library/os.rst:579 ../../library/os.rst:586 +#: ../../library/os.rst:593 ../../library/os.rst:602 ../../library/os.rst:639 #: ../../library/os.rst:652 ../../library/os.rst:661 ../../library/os.rst:678 -#: ../../library/os.rst:719 ../../library/os.rst:726 ../../library/os.rst:1139 -#: ../../library/os.rst:1183 ../../library/os.rst:1367 -#: ../../library/os.rst:1393 ../../library/os.rst:1463 -#: ../../library/os.rst:1535 ../../library/os.rst:1662 -#: ../../library/os.rst:1682 ../../library/os.rst:1691 +#: ../../library/os.rst:687 ../../library/os.rst:694 ../../library/os.rst:703 +#: ../../library/os.rst:712 ../../library/os.rst:719 ../../library/os.rst:726 +#: ../../library/os.rst:735 ../../library/os.rst:792 ../../library/os.rst:831 +#: ../../library/os.rst:953 ../../library/os.rst:979 ../../library/os.rst:992 +#: ../../library/os.rst:1009 ../../library/os.rst:1027 +#: ../../library/os.rst:1038 ../../library/os.rst:1061 +#: ../../library/os.rst:1082 ../../library/os.rst:1094 +#: ../../library/os.rst:1105 ../../library/os.rst:1118 +#: ../../library/os.rst:1139 ../../library/os.rst:1160 +#: ../../library/os.rst:1172 ../../library/os.rst:1183 +#: ../../library/os.rst:1244 ../../library/os.rst:1367 +#: ../../library/os.rst:1379 ../../library/os.rst:1393 +#: ../../library/os.rst:1403 ../../library/os.rst:1418 +#: ../../library/os.rst:1433 ../../library/os.rst:1446 +#: ../../library/os.rst:1463 ../../library/os.rst:1489 +#: ../../library/os.rst:1506 ../../library/os.rst:1520 +#: ../../library/os.rst:1535 ../../library/os.rst:1547 +#: ../../library/os.rst:1574 ../../library/os.rst:1586 +#: ../../library/os.rst:1596 ../../library/os.rst:1610 +#: ../../library/os.rst:1662 ../../library/os.rst:1682 +#: ../../library/os.rst:1691 ../../library/os.rst:1703 +#: ../../library/os.rst:1738 ../../library/os.rst:1762 #: ../../library/os.rst:1772 ../../library/os.rst:1780 -#: ../../library/os.rst:1800 ../../library/os.rst:2087 -#: ../../library/os.rst:2221 ../../library/os.rst:2514 -#: ../../library/os.rst:2536 ../../library/os.rst:4330 +#: ../../library/os.rst:1789 ../../library/os.rst:1800 +#: ../../library/os.rst:1837 ../../library/os.rst:1864 +#: ../../library/os.rst:1915 ../../library/os.rst:1921 +#: ../../library/os.rst:2087 ../../library/os.rst:2164 +#: ../../library/os.rst:2181 ../../library/os.rst:2195 +#: ../../library/os.rst:2221 ../../library/os.rst:2239 +#: ../../library/os.rst:2255 ../../library/os.rst:2271 +#: ../../library/os.rst:2334 ../../library/os.rst:2358 +#: ../../library/os.rst:2378 ../../library/os.rst:2514 +#: ../../library/os.rst:2536 ../../library/os.rst:2580 +#: ../../library/os.rst:2592 ../../library/os.rst:2614 +#: ../../library/os.rst:3322 ../../library/os.rst:3456 +#: ../../library/os.rst:3479 ../../library/os.rst:3493 +#: ../../library/os.rst:3712 ../../library/os.rst:3737 +#: ../../library/os.rst:3762 ../../library/os.rst:3816 +#: ../../library/os.rst:3825 ../../library/os.rst:3834 +#: ../../library/os.rst:3842 ../../library/os.rst:3851 +#: ../../library/os.rst:3860 ../../library/os.rst:3932 +#: ../../library/os.rst:3995 ../../library/os.rst:4005 +#: ../../library/os.rst:4023 ../../library/os.rst:4032 +#: ../../library/os.rst:4042 ../../library/os.rst:4052 +#: ../../library/os.rst:4062 ../../library/os.rst:4073 +#: ../../library/os.rst:4218 ../../library/os.rst:4287 +#: ../../library/os.rst:4322 ../../library/os.rst:4330 #: ../../library/os.rst:4337 ../../library/os.rst:4344 #: ../../library/os.rst:4351 ../../library/os.rst:4358 #: ../../library/os.rst:4365 ../../library/os.rst:4372 @@ -361,9 +403,32 @@ msgstr "プロセスの制御端末に対応するファイル名を返します #: ../../library/os.rst:4395 ../../library/os.rst:4402 #: ../../library/os.rst:4411 ../../library/os.rst:4419 #: ../../library/os.rst:4427 ../../library/os.rst:4434 -#: ../../library/os.rst:4441 ../../library/os.rst:4564 -msgid ":ref:`Availability `: Unix, not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外の Unix 。" +#: ../../library/os.rst:4441 ../../library/os.rst:4490 +#: ../../library/os.rst:4517 ../../library/os.rst:4541 +#: ../../library/os.rst:4557 ../../library/os.rst:4564 +#: ../../library/os.rst:4575 ../../library/os.rst:4585 +#: ../../library/os.rst:4594 ../../library/os.rst:4626 +#: ../../library/os.rst:4734 ../../library/os.rst:4750 +#: ../../library/os.rst:4783 ../../library/os.rst:4852 +#: ../../library/os.rst:4871 ../../library/os.rst:4882 +#: ../../library/os.rst:4894 ../../library/os.rst:4939 +#: ../../library/os.rst:4976 ../../library/os.rst:4999 +#: ../../library/os.rst:5020 ../../library/os.rst:5054 +#: ../../library/os.rst:5095 ../../library/os.rst:5115 +#: ../../library/os.rst:5129 ../../library/os.rst:5146 +#: ../../library/os.rst:5161 ../../library/os.rst:5172 +#: ../../library/os.rst:5184 ../../library/os.rst:5197 +#: ../../library/os.rst:5206 ../../library/os.rst:5216 +#: ../../library/os.rst:5229 ../../library/os.rst:5264 +#: ../../library/os.rst:5280 ../../library/os.rst:5291 +#: ../../library/os.rst:5303 ../../library/os.rst:5310 +#: ../../library/os.rst:5319 ../../library/os.rst:5328 +#: ../../library/os.rst:5337 ../../library/os.rst:5346 +#: ../../library/os.rst:5496 ../../library/os.rst:5505 +#: ../../library/os.rst:5529 ../../library/os.rst:5556 +#: ../../library/os.rst:5565 ../../library/os.rst:5688 +msgid "Availability" +msgstr "" #: ../../library/os.rst:186 msgid "" @@ -563,17 +628,6 @@ msgstr "" "``'surrogateescape'`` でデコードされます。異なるエンコーディングを使用したい" "場合は :func:`os.getenvb` を使用します。" -#: ../../library/os.rst:322 ../../library/os.rst:1009 ../../library/os.rst:1094 -#: ../../library/os.rst:1105 ../../library/os.rst:1118 -#: ../../library/os.rst:1379 ../../library/os.rst:1703 -#: ../../library/os.rst:1864 ../../library/os.rst:2271 -#: ../../library/os.rst:2614 ../../library/os.rst:3456 -#: ../../library/os.rst:3493 ../../library/os.rst:4322 -#: ../../library/os.rst:4871 ../../library/os.rst:4882 -#: ../../library/os.rst:4999 -msgid ":ref:`Availability `: Unix, Windows." -msgstr ":ref:`Availability `: Unix, Windows。" - #: ../../library/os.rst:327 msgid "" "Return the value of the environment variable *key* as bytes if it exists, or " @@ -597,24 +651,6 @@ msgstr "" ":func:`getenvb` は :const:`supports_bytes_environ` が ``True`` の場合のみ利用" "可能です。" -#: ../../library/os.rst:337 ../../library/os.rst:376 ../../library/os.rst:533 -#: ../../library/os.rst:792 ../../library/os.rst:1027 ../../library/os.rst:1038 -#: ../../library/os.rst:1061 ../../library/os.rst:1082 -#: ../../library/os.rst:1160 ../../library/os.rst:1172 -#: ../../library/os.rst:1403 ../../library/os.rst:1418 -#: ../../library/os.rst:1433 ../../library/os.rst:1446 -#: ../../library/os.rst:1547 ../../library/os.rst:1762 -#: ../../library/os.rst:1789 ../../library/os.rst:1837 -#: ../../library/os.rst:2164 ../../library/os.rst:2195 -#: ../../library/os.rst:2255 ../../library/os.rst:2580 -#: ../../library/os.rst:2592 ../../library/os.rst:3322 -#: ../../library/os.rst:3479 ../../library/os.rst:3712 -#: ../../library/os.rst:5496 ../../library/os.rst:5505 -#: ../../library/os.rst:5529 ../../library/os.rst:5556 -#: ../../library/os.rst:5565 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" - #: ../../library/os.rst:344 msgid "" "Returns the list of directories that will be searched for a named " @@ -707,10 +743,6 @@ msgstr "" "`USERNAME` を調べ、さらには ``pwd.getpwuid(os.getuid())[0]`` まで調べに行くか" "らです。" -#: ../../library/os.rst:426 ../../library/os.rst:462 -msgid ":ref:`Availability `: Unix, Windows, not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外の Unix 及び Windows。" - #: ../../library/os.rst:431 msgid "" "Return the process group id of the process with process id *pid*. If *pid* " @@ -764,10 +796,6 @@ msgid "" "Parameters for the :func:`getpriority` and :func:`setpriority` functions." msgstr ":func:`getpriority` と :func:`setpriority` 用のパラメータです。" -#: ../../library/os.rst:503 -msgid ":ref:`Availability `: macOS" -msgstr ":ref:`利用可能な環境 `: macOS" - #: ../../library/os.rst:509 msgid "" "Return a tuple (ruid, euid, suid) denoting the current process's real, " @@ -797,13 +825,6 @@ msgstr "" "システムの initgroups() を呼び出し、指定された *username* がメンバーである全" "グループと *gid* で指定されたグループでグループアクセスリストを初期化します。" -#: ../../library/os.rst:545 ../../library/os.rst:579 ../../library/os.rst:586 -#: ../../library/os.rst:593 ../../library/os.rst:687 ../../library/os.rst:694 -#: ../../library/os.rst:703 ../../library/os.rst:712 ../../library/os.rst:735 -#: ../../library/os.rst:2181 -msgid ":ref:`Availability `: Unix, not WASI, not Android." -msgstr "" - #: ../../library/os.rst:554 msgid "" "Set the environment variable named *key* to the string *value*. Such " @@ -931,10 +952,6 @@ msgid "" "os.close(fd)" msgstr "" -#: ../../library/os.rst:639 -msgid ":ref:`Availability `: Linux >= 3.0 with glibc >= 2.14." -msgstr "" - #: ../../library/os.rst:645 msgid "The :func:`~os.unshare` function." msgstr "" @@ -1152,10 +1169,6 @@ msgid "" "are made to the calling process's execution context." msgstr "" -#: ../../library/os.rst:831 -msgid ":ref:`Availability `: Linux >= 2.6.16." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.16以上。" - #: ../../library/os.rst:837 msgid "The :func:`~os.setns` function." msgstr ":func:`~os.setns` 関数。" @@ -1309,10 +1322,6 @@ msgid "" "known Linux kernel issue." msgstr "" -#: ../../library/os.rst:953 -msgid ":ref:`Availability `: Linux >= 4.5 with glibc >= 2.27." -msgstr ":ref:`利用可能な環境 `: Linux >= 4.5 かつ glibc >= 2.27." - #: ../../library/os.rst:960 msgid "" "Return a string describing the encoding of the device associated with *fd* " @@ -1348,10 +1357,6 @@ msgstr "" "Windows では、標準ストリーム (0: 標準入力、1: 標準出力、2: 標準エラー出力) を" "複製する場合、新しいファイル記述子は :ref:`継承可能 ` です。" -#: ../../library/os.rst:979 ../../library/os.rst:992 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" - #: ../../library/os.rst:981 ../../library/os.rst:1266 msgid "The new file descriptor is now non-inheritable." msgstr "新しいファイル記述子が継承不可になりました。" @@ -1719,10 +1724,6 @@ msgstr "" msgid "These operations only make sense for filesystems that support them." msgstr "" -#: ../../library/os.rst:1244 -msgid ":ref:`Availability `: Linux >= 3.1, macOS, Unix" -msgstr "" - #: ../../library/os.rst:1251 msgid "" "Open the file *path* and set various flags according to *flags* and possibly " @@ -2025,12 +2026,6 @@ msgstr "" msgid "Combine the functionality of :func:`os.readv` and :func:`os.pread`." msgstr ":func:`os.readv` と :func:`os.pread` の機能を統合します。" -#: ../../library/os.rst:1489 ../../library/os.rst:1574 -msgid "" -":ref:`Availability `: Linux >= 2.6.30, FreeBSD >= 6.0, OpenBSD " -">= 2.7, AIX >= 7.1." -msgstr "" - #: ../../library/os.rst:1491 ../../library/os.rst:1576 msgid "Using flags requires Linux >= 4.6." msgstr "" @@ -2052,10 +2047,6 @@ msgid "" "EAGAIN`." msgstr "" -#: ../../library/os.rst:1506 -msgid ":ref:`Availability `: Linux >= 4.14." -msgstr ":ref:`利用可能な環境 `: Linux 4.14以上。" - #: ../../library/os.rst:1513 msgid "" "High priority read/write. Allows block-based filesystems to use polling of " @@ -2073,10 +2064,6 @@ msgstr "" "現状、Linuxでは、ファイル記述子を :data:`O_DIRECT` フラグを指定したオープンし" "た場合でのみ、この機能を利用できます。" -#: ../../library/os.rst:1520 -msgid ":ref:`Availability `: Linux >= 4.6." -msgstr ":ref:`利用可能な環境 `: Linux 4.6以上。" - #: ../../library/os.rst:1527 msgid "" "Return the name of the slave pseudo-terminal device associated with the " @@ -2141,10 +2128,6 @@ msgstr "" "グです。このフラグはシステムコールによって書き込まれたデータ範囲に対してのみ" "適用されます。" -#: ../../library/os.rst:1586 ../../library/os.rst:1596 -msgid ":ref:`Availability `: Linux >= 4.7." -msgstr ":ref:`利用可能な環境 `: Linux 4.7以上。" - #: ../../library/os.rst:1593 msgid "" "Provide a per-write equivalent of the :data:`O_SYNC` :func:`os.open` flag. " @@ -2164,10 +2147,6 @@ msgid "" "*offset* is updated." msgstr "" -#: ../../library/os.rst:1610 -msgid ":ref:`Availability `: Linux >= 4.16." -msgstr ":ref:`利用可能な環境 `: Linux 4.16以上。" - #: ../../library/os.rst:1617 msgid "Read at most *n* bytes from file descriptor *fd*." msgstr "ファイル記述子 *fd* から 最大 *n* バイトを読み込みます。" @@ -2324,10 +2303,6 @@ msgid "" "the pipe." msgstr "" -#: ../../library/os.rst:1738 -msgid ":ref:`Availability `: Linux >= 2.6.17 with glibc >= 2.5" -msgstr "" - #: ../../library/os.rst:1751 msgid "" "Read from a file descriptor *fd* into a number of mutable :term:`bytes-like " @@ -2523,12 +2498,6 @@ msgid "Get the \"inheritable\" flag of the specified handle (a boolean)." msgstr "" "指定したハンドルの「継承可能 (inheritable)」フラグを取得します (boolean)。" -#: ../../library/os.rst:1915 ../../library/os.rst:1921 -#: ../../library/os.rst:4218 ../../library/os.rst:4894 -#: ../../library/os.rst:4939 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" - #: ../../library/os.rst:1919 msgid "Set the \"inheritable\" flag of the specified handle." msgstr "指定したハンドルの「継承可能 (inheritable)」フラグをセットします。" @@ -3051,12 +3020,6 @@ msgid "" "changing the mode of symbolic links is supported." msgstr "" -#: ../../library/os.rst:2239 -msgid "" -":ref:`Availability `: Unix, Windows, not Linux, FreeBSD >= " -"1.3, NetBSD >= 1.3, not OpenBSD" -msgstr "" - #: ../../library/os.rst:2249 msgid "" "Change the owner and group id of *path* to the numeric *uid* and *gid*. " @@ -3189,11 +3152,6 @@ msgid "" "arguments." msgstr "" -#: ../../library/os.rst:2334 ../../library/os.rst:2358 -#: ../../library/os.rst:2378 -msgid ":ref:`Availability `: Windows" -msgstr ":ref:`利用可能な環境 `: Windows" - #: ../../library/os.rst:2341 msgid "" "Return a list containing the mount points for a volume on a Windows system." @@ -5106,18 +5064,10 @@ msgid "" "side effects." msgstr "" -#: ../../library/os.rst:3737 -msgid ":ref:`Availability `: Linux >= 3.17 with glibc >= 2.27." -msgstr "" - #: ../../library/os.rst:3760 msgid "These flags can be passed to :func:`memfd_create`." msgstr "" -#: ../../library/os.rst:3762 -msgid ":ref:`Availability `: Linux >= 3.17 with glibc >= 2.27" -msgstr "" - #: ../../library/os.rst:3764 msgid "The ``MFD_HUGE*`` flags are only available since Linux 4.14." msgstr "" @@ -5189,25 +5139,12 @@ msgid "" " os.close(fd)" msgstr "" -#: ../../library/os.rst:3816 ../../library/os.rst:3932 -#: ../../library/os.rst:3995 ../../library/os.rst:4005 -#: ../../library/os.rst:4023 ../../library/os.rst:4032 -#: ../../library/os.rst:4042 ../../library/os.rst:4052 -#: ../../library/os.rst:4062 ../../library/os.rst:4073 -msgid ":ref:`Availability `: Linux >= 2.6.27 with glibc >= 2.8" -msgstr "" - #: ../../library/os.rst:3822 msgid "" "Read value from an :func:`eventfd` file descriptor and return a 64 bit " "unsigned int. The function does not verify that *fd* is an :func:`eventfd`." msgstr "" -#: ../../library/os.rst:3825 ../../library/os.rst:3834 -#: ../../library/os.rst:3842 ../../library/os.rst:3851 -msgid ":ref:`Availability `: Linux >= 2.6.27" -msgstr "" - #: ../../library/os.rst:3831 msgid "" "Add value to an :func:`eventfd` file descriptor. *value* must be a 64 bit " @@ -5229,10 +5166,6 @@ msgid "" "descriptor. On read the internal counter is decremented by one." msgstr "" -#: ../../library/os.rst:3860 -msgid ":ref:`Availability `: Linux >= 2.6.30" -msgstr "" - #: ../../library/os.rst:3868 msgid "Timer File Descriptors" msgstr "" @@ -5806,14 +5739,6 @@ msgstr "" "引数 ``path``, ``args``, ``env`` を指定して :ref:`監査イベント ` " "``os.exec`` を送出します。 " -#: ../../library/os.rst:4287 ../../library/os.rst:4852 -#: ../../library/os.rst:4976 ../../library/os.rst:5095 -#: ../../library/os.rst:5264 -msgid "" -":ref:`Availability `: Unix, Windows, not WASI, not Android, " -"not iOS." -msgstr "" - #: ../../library/os.rst:4289 msgid "" "Added support for specifying *path* as an open file descriptor for :func:" @@ -6022,11 +5947,6 @@ msgid "" "this longstanding platform compatibility problem to developers." msgstr "" -#: ../../library/os.rst:4490 ../../library/os.rst:4750 -msgid "" -":ref:`Availability `: POSIX, not WASI, not Android, not iOS." -msgstr "" - #: ../../library/os.rst:4495 msgid "" "Fork a child process, using a new pseudo-terminal as the child's controlling " @@ -6060,22 +5980,6 @@ msgid "" "fork`." msgstr "" -#: ../../library/os.rst:4517 ../../library/os.rst:4734 -#: ../../library/os.rst:4783 ../../library/os.rst:5020 -#: ../../library/os.rst:5054 ../../library/os.rst:5115 -#: ../../library/os.rst:5129 ../../library/os.rst:5146 -#: ../../library/os.rst:5161 ../../library/os.rst:5172 -#: ../../library/os.rst:5184 ../../library/os.rst:5197 -#: ../../library/os.rst:5206 ../../library/os.rst:5216 -#: ../../library/os.rst:5229 ../../library/os.rst:5280 -#: ../../library/os.rst:5291 ../../library/os.rst:5303 -#: ../../library/os.rst:5310 ../../library/os.rst:5319 -#: ../../library/os.rst:5328 ../../library/os.rst:5337 -#: ../../library/os.rst:5346 -msgid "" -":ref:`Availability `: Unix, not WASI, not Android, not iOS." -msgstr "" - #: ../../library/os.rst:4526 msgid "" "Send signal *sig* to the process *pid*. Constants for the specific signals " @@ -6107,10 +6011,6 @@ msgstr "" "引数 ``pid``, ``sig`` を指定して :ref:`監査イベント ` ``os.kill`` " "を送出します。 " -#: ../../library/os.rst:4541 -msgid ":ref:`Availability `: Unix, Windows, not WASI, not iOS." -msgstr "" - #: ../../library/os.rst:4553 msgid "Send the signal *sig* to the process group *pgid*." msgstr "プロセスグループ *pgid* にシグナル *sig* を送ります。" @@ -6123,10 +6023,6 @@ msgstr "" "引数 ``pgid``, ``sig`` を指定して :ref:`監査イベント ` ``os." "killpg`` を送出します。 " -#: ../../library/os.rst:4557 ../../library/os.rst:4594 -msgid ":ref:`Availability `: Unix, not WASI, not iOS." -msgstr ":ref:`利用可能な環境 `: WASI 及び iOS 以外の Unix 。" - #: ../../library/os.rst:4562 msgid "" "Add *increment* to the process's \"niceness\". Return the new niceness." @@ -6144,12 +6040,6 @@ msgstr "" msgid "See the :manpage:`pidfd_open(2)` man page for more details." msgstr "" -#: ../../library/os.rst:4575 -msgid "" -":ref:`Availability `: Linux >= 5.3, Android >= :func:`build-" -"time ` API level 31" -msgstr "" - #: ../../library/os.rst:4580 msgid "" "This flag indicates that the file descriptor will be non-blocking. If the " @@ -6158,10 +6048,6 @@ msgid "" "immediately return the error :const:`~errno.EAGAIN` rather than blocking." msgstr "" -#: ../../library/os.rst:4585 -msgid ":ref:`Availability `: Linux >= 5.10" -msgstr "" - #: ../../library/os.rst:4591 msgid "" "Lock program segments into memory. The value of *op* (defined in ```: not WASI, not Android, not iOS." -msgstr "" - #: ../../library/os.rst:4629 msgid "" "The :ref:`Python UTF-8 Mode ` affects encodings used for *cmd* " @@ -7689,10 +7571,6 @@ msgstr "" "`Linux getrandom() manual page `_ も参照してください。 " -#: ../../library/os.rst:5688 -msgid ":ref:`Availability `: Linux >= 3.17." -msgstr ":ref:`利用可能な環境 `: Linux 3.17以上。" - #: ../../library/os.rst:5694 msgid "" "Return a bytestring of *size* random bytes suitable for cryptographic use." diff --git a/library/pkgutil.po b/library/pkgutil.po index f34083866..45b033368 100644 --- a/library/pkgutil.po +++ b/library/pkgutil.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:11+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -61,12 +61,12 @@ msgstr "" #: ../../library/pkgutil.rst:28 msgid "" "For each directory on :data:`sys.path` that has a subdirectory that matches " -"the package name, add the subdirectory to the package's :attr:`__path__`. " -"This is useful if one wants to distribute different parts of a single " -"logical package as multiple directories." +"the package name, add the subdirectory to the package's :attr:`~module." +"__path__`. This is useful if one wants to distribute different parts of a " +"single logical package as multiple directories." msgstr "" -#: ../../library/pkgutil.rst:33 +#: ../../library/pkgutil.rst:34 msgid "" "It also looks for :file:`\\*.pkg` files beginning where ``*`` matches the " "*name* argument. This feature is similar to :file:`\\*.pth` files (see the :" @@ -77,7 +77,7 @@ msgid "" "they exist on the filesystem (this is a feature)." msgstr "" -#: ../../library/pkgutil.rst:41 +#: ../../library/pkgutil.rst:42 msgid "" "If the input path is not a list (as is the case for frozen packages) it is " "returned unchanged. The input path is not modified; an extended copy is " @@ -87,7 +87,7 @@ msgstr "" "ンします。入力パスが変更されていなければ、アイテムを末尾に追加しただけのコ" "ピーを返します。" -#: ../../library/pkgutil.rst:45 +#: ../../library/pkgutil.rst:46 msgid "" "It is assumed that :data:`sys.path` is a sequence. Items of :data:`sys." "path` that are not strings referring to existing directories are ignored. " @@ -101,12 +101,12 @@ msgstr "" "Unicode要素がある場合、この関数(:func:`os.path.isdir` を実行している行) で例" "外が発生する可能性があります。" -#: ../../library/pkgutil.rst:53 +#: ../../library/pkgutil.rst:54 msgid "Retrieve a module :term:`loader` for the given *fullname*." msgstr "" "*fullname* に対するモジュール :term:`loader` オブジェクトを取得します。" -#: ../../library/pkgutil.rst:55 +#: ../../library/pkgutil.rst:56 msgid "" "This is a backwards compatibility wrapper around :func:`importlib.util." "find_spec` that converts most failures to :exc:`ImportError` and only " @@ -118,9 +118,9 @@ msgstr "" "class:`importlib.machinery.ModuleSpec` を返す代わりにローダのみを返していま" "す。" -#: ../../library/pkgutil.rst:60 ../../library/pkgutil.rst:81 -#: ../../library/pkgutil.rst:96 ../../library/pkgutil.rst:120 -#: ../../library/pkgutil.rst:141 ../../library/pkgutil.rst:180 +#: ../../library/pkgutil.rst:61 ../../library/pkgutil.rst:82 +#: ../../library/pkgutil.rst:97 ../../library/pkgutil.rst:121 +#: ../../library/pkgutil.rst:142 ../../library/pkgutil.rst:181 msgid "" "Updated to be based directly on :mod:`importlib` rather than relying on the " "package internal :pep:`302` import emulation." @@ -128,19 +128,19 @@ msgstr "" "パッケージ内部の :pep:`302` エミュレーションに依存するのではなく直接的に :" "mod:`importlib` に基くように更新されました。 " -#: ../../library/pkgutil.rst:64 ../../library/pkgutil.rst:100 +#: ../../library/pkgutil.rst:65 ../../library/pkgutil.rst:101 msgid "Updated to be based on :pep:`451`" msgstr ":pep:`451` ベースに更新されました。" -#: ../../library/pkgutil.rst:67 ../../library/pkgutil.rst:103 +#: ../../library/pkgutil.rst:68 ../../library/pkgutil.rst:104 msgid "Use :func:`importlib.util.find_spec` instead." msgstr "代わりに :func:`importlib.util.find_spec` を使用してください。" -#: ../../library/pkgutil.rst:73 +#: ../../library/pkgutil.rst:74 msgid "Retrieve a :term:`finder` for the given *path_item*." msgstr "指定された *path_item* に対する :term:`finder` を取得します。" -#: ../../library/pkgutil.rst:75 +#: ../../library/pkgutil.rst:76 msgid "" "The returned finder is cached in :data:`sys.path_importer_cache` if it was " "newly created by a path hook." @@ -148,7 +148,7 @@ msgstr "" "path hook により新しい finder が作成された場合は、それは :data:`sys." "path_importer_cache` にキャッシュされます。" -#: ../../library/pkgutil.rst:78 +#: ../../library/pkgutil.rst:79 msgid "" "The cache (or part of it) can be cleared manually if a rescan of :data:`sys." "path_hooks` is necessary." @@ -156,11 +156,11 @@ msgstr "" "キャッシュ (やその一部) は、 :data:`sys.path_hooks` のリスキャンが必要になっ" "た場合は手動でクリアすることができます。" -#: ../../library/pkgutil.rst:88 +#: ../../library/pkgutil.rst:89 msgid "Get a :term:`loader` object for *module_or_name*." msgstr "*module_or_name* に対する :term:`loader` オブジェクトを取得します。" -#: ../../library/pkgutil.rst:90 +#: ../../library/pkgutil.rst:91 msgid "" "If the module or package is accessible via the normal import mechanism, a " "wrapper around the relevant part of that machinery is returned. Returns " @@ -174,18 +174,18 @@ msgstr "" "ない場合、そのモジュールを含むパッケージが(あれば)そのパッケージの " "``__path__`` を確立するために import されます。" -#: ../../library/pkgutil.rst:109 +#: ../../library/pkgutil.rst:110 msgid "Yield :term:`finder` objects for the given module name." msgstr "" -#: ../../library/pkgutil.rst:111 +#: ../../library/pkgutil.rst:112 msgid "" "If fullname contains a ``'.'``, the finders will be for the package " "containing fullname, otherwise they will be all registered top level finders " "(i.e. those on both :data:`sys.meta_path` and :data:`sys.path_hooks`)." msgstr "" -#: ../../library/pkgutil.rst:115 +#: ../../library/pkgutil.rst:116 msgid "" "If the named module is in a package, that package is imported as a side " "effect of invoking this function." @@ -193,12 +193,12 @@ msgstr "" "その名前のついたモジュールがパッケージ内に含まれている場合、この関数を実行し" "た副作用としてそのパッケージが import されます。" -#: ../../library/pkgutil.rst:118 +#: ../../library/pkgutil.rst:119 msgid "If no module name is specified, all top level finders are produced." msgstr "" "モジュール名が指定されない場合は全てのトップレベルの finder が生成されます。" -#: ../../library/pkgutil.rst:127 +#: ../../library/pkgutil.rst:128 msgid "" "Yields :class:`ModuleInfo` for all submodules on *path*, or, if *path* is " "``None``, all top-level modules on :data:`sys.path`." @@ -207,19 +207,19 @@ msgstr "" "ら :data:`sys.path` のすべてのトップレベルモジュールに対して、:class:" "`ModuleInfo` を yield します。" -#: ../../library/pkgutil.rst:130 ../../library/pkgutil.rst:151 +#: ../../library/pkgutil.rst:131 ../../library/pkgutil.rst:152 msgid "" "*path* should be either ``None`` or a list of paths to look for modules in." msgstr "" "*path* は ``None`` か、モジュールを検索する path のリストのどちらかでなければ" "なりません。" -#: ../../library/pkgutil.rst:132 ../../library/pkgutil.rst:153 +#: ../../library/pkgutil.rst:133 ../../library/pkgutil.rst:154 msgid "" "*prefix* is a string to output on the front of every module name on output." msgstr "*prefix* は出力の全てのモジュール名の頭に出力する文字列です。" -#: ../../library/pkgutil.rst:136 ../../library/pkgutil.rst:175 +#: ../../library/pkgutil.rst:137 ../../library/pkgutil.rst:176 msgid "" "Only works for a :term:`finder` which defines an ``iter_modules()`` method. " "This interface is non-standard, so the module also provides implementations " @@ -231,7 +231,7 @@ msgstr "" "`importlib.machinery.FileFinder` と :class:`zipimport.zipimporter` の実装も提" "供します。" -#: ../../library/pkgutil.rst:148 +#: ../../library/pkgutil.rst:149 msgid "" "Yields :class:`ModuleInfo` for all modules recursively on *path*, or, if " "*path* is ``None``, all accessible modules." @@ -240,7 +240,7 @@ msgstr "" "``None`` ならばアクセスできるすべてのモジュールに対して、:class:`ModuleInfo` " "を yield します。" -#: ../../library/pkgutil.rst:155 +#: ../../library/pkgutil.rst:156 msgid "" "Note that this function must import all *packages* (*not* all modules!) on " "the given *path*, in order to access the ``__path__`` attribute to find " @@ -250,7 +250,7 @@ msgstr "" "い*) を、サブモジュールを検索するのに必要な ``__path__`` 属性にアクセスするた" "めに import します。" -#: ../../library/pkgutil.rst:159 +#: ../../library/pkgutil.rst:160 msgid "" "*onerror* is a function which gets called with one argument (the name of the " "package which was being imported) if any exception occurs while trying to " @@ -263,11 +263,11 @@ msgstr "" "す。 *onerror* 関数が提供されない場合、 :exc:`ImportError` は補足され無視され" "ます。それ以外の全ての例外は伝播し、検索を停止させます。" -#: ../../library/pkgutil.rst:165 +#: ../../library/pkgutil.rst:166 msgid "Examples::" msgstr "例::" -#: ../../library/pkgutil.rst:167 +#: ../../library/pkgutil.rst:168 msgid "" "# list all modules python can access\n" "walk_packages()\n" @@ -276,11 +276,11 @@ msgid "" "walk_packages(ctypes.__path__, ctypes.__name__ + '.')" msgstr "" -#: ../../library/pkgutil.rst:187 +#: ../../library/pkgutil.rst:188 msgid "Get a resource from a package." msgstr "パッケージからリソースを取得します。" -#: ../../library/pkgutil.rst:189 +#: ../../library/pkgutil.rst:190 msgid "" "This is a wrapper for the :term:`loader` :meth:`get_data ` API. The *package* argument should be the name of " @@ -295,13 +295,13 @@ msgstr "" "パス区切りに使った相対ファイル名の形式です。親ディレクトリを ``..`` とした" "り、ルートからの (``/`` で始まる) 名前を使うことはできません。" -#: ../../library/pkgutil.rst:196 +#: ../../library/pkgutil.rst:197 msgid "" "The function returns a binary string that is the contents of the specified " "resource." msgstr "この関数が返すのは指定されたリソースの内容であるバイナリ文字列です。" -#: ../../library/pkgutil.rst:199 +#: ../../library/pkgutil.rst:200 msgid "" "For packages located in the filesystem, which have already been imported, " "this is the rough equivalent of::" @@ -309,13 +309,13 @@ msgstr "" "ファイルシステム中に位置するパッケージで既にインポートされているものに対して" "は、次と大体同じです::" -#: ../../library/pkgutil.rst:202 +#: ../../library/pkgutil.rst:203 msgid "" "d = os.path.dirname(sys.modules[package].__file__)\n" "data = open(os.path.join(d, resource), 'rb').read()" msgstr "" -#: ../../library/pkgutil.rst:205 +#: ../../library/pkgutil.rst:206 msgid "" "If the package cannot be located or loaded, or it uses a :term:`loader` " "which does not support :meth:`get_data `." msgstr "" -#: ../../library/pkgutil.rst:214 +#: ../../library/pkgutil.rst:215 msgid "Resolve a name to an object." msgstr "" -#: ../../library/pkgutil.rst:216 +#: ../../library/pkgutil.rst:217 msgid "" "This functionality is used in numerous places in the standard library (see :" "issue:`12915`) - and equivalent functionality is also in widely used third-" "party packages such as setuptools, Django and Pyramid." msgstr "" -#: ../../library/pkgutil.rst:220 +#: ../../library/pkgutil.rst:221 msgid "" "It is expected that *name* will be a string in one of the following formats, " "where W is shorthand for a valid Python identifier and dot stands for a " "literal period in these pseudo-regexes:" msgstr "" -#: ../../library/pkgutil.rst:224 +#: ../../library/pkgutil.rst:225 msgid "``W(.W)*``" msgstr "" -#: ../../library/pkgutil.rst:225 +#: ../../library/pkgutil.rst:226 msgid "``W(.W)*:(W(.W)*)?``" msgstr "" -#: ../../library/pkgutil.rst:227 +#: ../../library/pkgutil.rst:228 msgid "" "The first form is intended for backward compatibility only. It assumes that " "some part of the dotted name is a package, and the rest is an object " @@ -360,7 +360,7 @@ msgid "" "form." msgstr "" -#: ../../library/pkgutil.rst:234 +#: ../../library/pkgutil.rst:235 msgid "" "In the second form, the caller makes the division point clear through the " "provision of a single colon: the dotted name to the left of the colon is a " @@ -369,21 +369,21 @@ msgid "" "ends with the colon, then a module object is returned." msgstr "" -#: ../../library/pkgutil.rst:240 +#: ../../library/pkgutil.rst:241 msgid "" "The function will return an object (which might be a module), or raise one " "of the following exceptions:" msgstr "" -#: ../../library/pkgutil.rst:243 +#: ../../library/pkgutil.rst:244 msgid ":exc:`ValueError` -- if *name* isn't in a recognised format." msgstr "" -#: ../../library/pkgutil.rst:245 +#: ../../library/pkgutil.rst:246 msgid ":exc:`ImportError` -- if an import failed when it shouldn't have." msgstr "" -#: ../../library/pkgutil.rst:247 +#: ../../library/pkgutil.rst:248 msgid "" ":exc:`AttributeError` -- If a failure occurred when traversing the object " "hierarchy within the imported package to get to the desired object." diff --git a/library/poplib.po b/library/poplib.po index c74050199..0535f3167 100644 --- a/library/poplib.po +++ b/library/poplib.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:11+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -75,8 +75,8 @@ msgstr "" "れている傾向があります。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/posix.po b/library/posix.po index c58070ec9..cb2feb8ad 100644 --- a/library/posix.po +++ b/library/posix.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:11+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -41,8 +41,8 @@ msgstr "" "に対するアクセス機構を提供します。" #: ../../library/posix.rst:14 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +msgid "Availability" +msgstr "" #: ../../library/posix.rst:18 msgid "" diff --git a/library/pty.po b/library/pty.po index 14f5db8aa..dd02717a5 100644 --- a/library/pty.po +++ b/library/pty.po @@ -4,7 +4,7 @@ # FIRST AUTHOR , YEAR. # # Translators: -# tomo, 2023 +# tomo, 2021 # 石井明久, 2024 # Arihiro TAKASE, 2024 # @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:11+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -42,8 +42,8 @@ msgstr "" "をプログラムで読み書きする)を制御する操作を定義しています。" #: ../../library/pty.rst:19 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +msgid "Availability" +msgstr "" #: ../../library/pty.rst:21 msgid "" diff --git a/library/pwd.po b/library/pwd.po index 4a0e6a10e..7343a2deb 100644 --- a/library/pwd.po +++ b/library/pwd.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:11+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -36,8 +36,8 @@ msgstr "" "スを提供します。全ての Unix 系 OS で利用できます。" #: ../../library/pwd.rst:13 -msgid ":ref:`Availability `: Unix, not WASI, not iOS." -msgstr ":ref:`利用可能な環境 `: WASI 及び iOS 以外の Unix 。" +msgid "Availability" +msgstr "" #: ../../library/pwd.rst:15 msgid "" diff --git a/library/readline.po b/library/readline.po index 9e41c7c7c..d2dda353a 100644 --- a/library/readline.po +++ b/library/readline.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:12+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -66,7 +66,7 @@ msgstr "" "形式や可能な構成、 Readline ライブラリ全体の機能を知ってください。" #: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." +msgid "Availability" msgstr "" #: ../../includes/wasm-mobile-notavail.rst:5 diff --git a/library/resource.po b/library/resource.po index 7ec159324..e2540c724 100644 --- a/library/resource.po +++ b/library/resource.po @@ -4,8 +4,8 @@ # FIRST AUTHOR , YEAR. # # Translators: +# Takanori Suzuki , 2021 # tomo, 2021 -# Takanori Suzuki , 2022 # yaakiyu, 2022 # 石井明久, 2024 # Arihiro TAKASE, 2024 @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:12+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -38,9 +38,14 @@ msgstr "" "このモジュールでは、プログラムによって使用されているシステムリソースを計測し" "たり制御するための基本的なメカニズムを提供します。" -#: ../../library/resource.rst:16 -msgid ":ref:`Availability `: Unix, not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外の Unix 。" +#: ../../library/resource.rst:16 ../../library/resource.rst:104 +#: ../../library/resource.rst:180 ../../library/resource.rst:192 +#: ../../library/resource.rst:201 ../../library/resource.rst:210 +#: ../../library/resource.rst:220 ../../library/resource.rst:229 +#: ../../library/resource.rst:239 ../../library/resource.rst:252 +#: ../../library/resource.rst:260 ../../library/resource.rst:268 +msgid "Availability" +msgstr "" #: ../../library/resource.rst:18 msgid "" @@ -204,11 +209,6 @@ msgstr "" "引数 ``pid``, ``dst`, ``limits`` を指定して :ref:`監査イベント ` " "``resource.prlimit`` を送出します。 " -#: ../../library/resource.rst:104 -msgid ":ref:`Availability `: Linux >= 2.6.36 with glibc >= 2.13." -msgstr "" -":ref:`利用可能な環境 `: Linux >= 2.6.36 かつ glibc >= 2.13." - #: ../../library/resource.rst:109 msgid "" "These symbols define resources whose consumption can be controlled using " @@ -298,10 +298,6 @@ msgstr "メモリ中でロックできる最大アドレス空間です。" msgid "The largest area of mapped memory which the process may occupy." msgstr "プロセスが占有できるマップメモリの最大領域です。" -#: ../../library/resource.rst:180 ../../library/resource.rst:268 -msgid ":ref:`Availability `: FreeBSD >= 11." -msgstr ":ref:`利用可能な環境 `: FreeBSD 11 以上。" - #: ../../library/resource.rst:185 msgid "" "The maximum area (in bytes) of address space which may be taken by the " @@ -312,18 +308,10 @@ msgstr "アドレス空間でプロセスが占有できる最大領域 (バイ msgid "The number of bytes that can be allocated for POSIX message queues." msgstr "POSIX メッセージキューに割り当てることの出来るバイト数です。" -#: ../../library/resource.rst:192 ../../library/resource.rst:229 -msgid ":ref:`Availability `: Linux >= 2.6.8." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.8以上。" - #: ../../library/resource.rst:199 msgid "The ceiling for the process's nice level (calculated as 20 - rlim_cur)." msgstr "プロセスの nice の上限です (20 - rlim_cur)。" -#: ../../library/resource.rst:201 ../../library/resource.rst:210 -msgid ":ref:`Availability `: Linux >= 2.6.12." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.12以上。" - #: ../../library/resource.rst:208 msgid "The ceiling of the real-time priority." msgstr "リアルタイム優先順位の上限です。" @@ -336,10 +324,6 @@ msgstr "" "リアルタイムスケジューリングにおいて、プロセスがブロッキングシステムコールを" "行わずに使用できるCPU時間の制限値(マイクロ秒単位)。" -#: ../../library/resource.rst:220 -msgid ":ref:`Availability `: Linux >= 2.6.25." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.25以上。" - #: ../../library/resource.rst:227 msgid "The number of signals which the process may queue." msgstr "プロセスがキュー出来るシグナルの数です。" @@ -353,11 +337,6 @@ msgstr "" "このユーザが使用するソケットバッファの最大サイズ(バイト単位)。これは、この" "ユーザが常に保持できるネットワークメモリの量、つまり mbuf の量を制限します。" -#: ../../library/resource.rst:239 ../../library/resource.rst:252 -#: ../../library/resource.rst:260 -msgid ":ref:`Availability `: FreeBSD." -msgstr ":ref:`利用可能な環境 `: FreeBSD。" - #: ../../library/resource.rst:245 msgid "" "The maximum size (in bytes) of the swap space that may be reserved or used " diff --git a/library/select.po b/library/select.po index 3265dcae4..d5595718f 100644 --- a/library/select.po +++ b/library/select.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:12+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -62,9 +62,9 @@ msgstr "" "OS レベルプリミティブを使用した正確な制御を求めない限り、代わりに :mod:" "`selectors` を使用することが推奨されます。" -#: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +#: ../../library/select.rst:177 ../../includes/wasm-notavail.rst:3 +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" @@ -310,10 +310,6 @@ msgstr "" msgid "This value is guaranteed by POSIX to be at least 512." msgstr "この値は POSIX により少なくとも512であることが保証されています。" -#: ../../library/select.rst:177 -msgid ":ref:`Availability `: Unix" -msgstr ":ref:`利用可能な環境 `: Unix" - #: ../../library/select.rst:185 msgid "``/dev/poll`` Polling Objects" msgstr "``/dev/poll`` ポーリングオブジェクト" diff --git a/library/selectors.po b/library/selectors.po index 49a733397..0517febfe 100644 --- a/library/selectors.po +++ b/library/selectors.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:12+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -93,8 +93,8 @@ msgid "Low-level I/O multiplexing module." msgstr "低水準の I/O 多重化モジュールです。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/shutil.po b/library/shutil.po index e953b74c7..e0c933027 100644 --- a/library/shutil.po +++ b/library/shutil.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -673,9 +673,9 @@ msgstr "" "Windowsにおいても *path* にディレクトリだけでなくファイルを指定できるようにな" "りました。" -#: ../../library/shutil.rst:422 -msgid ":ref:`Availability `: Unix, Windows." -msgstr ":ref:`Availability `: Unix, Windows。" +#: ../../library/shutil.rst:422 ../../library/shutil.rst:436 +msgid "Availability" +msgstr "" #: ../../library/shutil.rst:427 msgid "Change owner *user* and/or *group* of the given *path*." @@ -701,10 +701,6 @@ msgstr "" "引数 ``path``, ``user``, ``group`` を指定して :ref:`監査イベント ` " "``shutil.chown`` を送出します。 " -#: ../../library/shutil.rst:436 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" - #: ../../library/shutil.rst:440 msgid "Added *dir_fd* and *follow_symlinks* parameters." msgstr "" diff --git a/library/signal.po b/library/signal.po index 217983458..0bae2b8aa 100644 --- a/library/signal.po +++ b/library/signal.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -185,18 +185,21 @@ msgid "" msgstr "" #: ../../library/signal.rst:103 ../../library/signal.rst:136 -#: ../../library/signal.rst:148 ../../library/signal.rst:154 +#: ../../library/signal.rst:142 ../../library/signal.rst:148 +#: ../../library/signal.rst:154 ../../library/signal.rst:160 #: ../../library/signal.rst:166 ../../library/signal.rst:180 #: ../../library/signal.rst:198 ../../library/signal.rst:206 -#: ../../library/signal.rst:232 ../../library/signal.rst:238 -#: ../../library/signal.rst:244 ../../library/signal.rst:351 -#: ../../library/signal.rst:390 ../../library/signal.rst:437 +#: ../../library/signal.rst:217 ../../library/signal.rst:232 +#: ../../library/signal.rst:238 ../../library/signal.rst:244 +#: ../../library/signal.rst:262 ../../library/signal.rst:272 +#: ../../library/signal.rst:351 ../../library/signal.rst:390 +#: ../../library/signal.rst:414 ../../library/signal.rst:437 #: ../../library/signal.rst:471 ../../library/signal.rst:501 #: ../../library/signal.rst:508 ../../library/signal.rst:561 #: ../../library/signal.rst:603 ../../library/signal.rst:618 #: ../../library/signal.rst:644 ../../library/signal.rst:664 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +msgid "Availability" +msgstr "" #: ../../library/signal.rst:105 ../../library/signal.rst:473 msgid "" @@ -239,11 +242,6 @@ msgstr "" msgid "Interrupt from keyboard (CTRL + BREAK)." msgstr "" -#: ../../library/signal.rst:142 ../../library/signal.rst:262 -#: ../../library/signal.rst:272 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" - #: ../../library/signal.rst:146 msgid "Bus error (bad memory access)." msgstr "" @@ -256,10 +254,6 @@ msgstr "" msgid "Alias to :data:`SIGCHLD`." msgstr ":data:`SIGCHLD` のエイリアスです。" -#: ../../library/signal.rst:160 -msgid ":ref:`Availability `: not macOS." -msgstr "" - #: ../../library/signal.rst:164 msgid "Continue the process if it is currently stopped" msgstr "" @@ -317,10 +311,6 @@ msgid "" "can only be raised in user space." msgstr "" -#: ../../library/signal.rst:217 -msgid ":ref:`Availability `: Linux." -msgstr ":ref:`利用可能な環境 `: Linux。" - #: ../../library/signal.rst:219 msgid "" "On architectures where the signal is available. See the man page :manpage:" @@ -557,12 +547,6 @@ msgstr "" "さらに詳しい情報についてはオンラインマニュアルページ :manpage:" "`pidfd_send_signal(2)` を参照してください。" -#: ../../library/signal.rst:414 -msgid "" -":ref:`Availability `: Linux >= 5.1, Android >= :func:`build-" -"time ` API level 31" -msgstr "" - #: ../../library/signal.rst:420 msgid "" "Send the signal *signalnum* to the thread *thread_id*, another thread in the " diff --git a/library/smtplib.po b/library/smtplib.po index cb979bbe8..bf4fec3e7 100644 --- a/library/smtplib.po +++ b/library/smtplib.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -49,8 +49,8 @@ msgstr "" "Service Extensions)を調べてください。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/socket.po b/library/socket.po index 9867a16df..8b076871b 100644 --- a/library/socket.po +++ b/library/socket.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -52,17 +52,37 @@ msgstr "" "いくつかの挙動はプラットフォームに依存します。オペレーティングシステムのソ" "ケットAPIを呼び出しているためです。" -#: ../../library/socket.rst:709 ../../library/socket.rst:994 -#: ../../library/socket.rst:1010 ../../library/socket.rst:1023 -#: ../../library/socket.rst:1038 ../../library/socket.rst:1055 -#: ../../library/socket.rst:1066 ../../library/socket.rst:1077 -#: ../../library/socket.rst:1088 ../../library/socket.rst:1412 -#: ../../library/socket.rst:1459 ../../library/socket.rst:1473 -#: ../../library/socket.rst:1493 ../../library/socket.rst:1540 -#: ../../library/socket.rst:1585 ../../library/socket.rst:1969 -#: ../../library/socket.rst:1979 ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +#: ../../library/socket.rst:171 ../../library/socket.rst:181 +#: ../../library/socket.rst:209 ../../library/socket.rst:216 +#: ../../library/socket.rst:233 ../../library/socket.rst:383 +#: ../../library/socket.rst:461 ../../library/socket.rst:475 +#: ../../library/socket.rst:490 ../../library/socket.rst:501 +#: ../../library/socket.rst:510 ../../library/socket.rst:519 +#: ../../library/socket.rst:530 ../../library/socket.rst:542 +#: ../../library/socket.rst:553 ../../library/socket.rst:566 +#: ../../library/socket.rst:594 ../../library/socket.rst:606 +#: ../../library/socket.rst:612 ../../library/socket.rst:643 +#: ../../library/socket.rst:658 ../../library/socket.rst:667 +#: ../../library/socket.rst:684 ../../library/socket.rst:699 +#: ../../library/socket.rst:709 ../../library/socket.rst:898 +#: ../../library/socket.rst:994 ../../library/socket.rst:1010 +#: ../../library/socket.rst:1023 ../../library/socket.rst:1038 +#: ../../library/socket.rst:1055 ../../library/socket.rst:1066 +#: ../../library/socket.rst:1077 ../../library/socket.rst:1088 +#: ../../library/socket.rst:1177 ../../library/socket.rst:1197 +#: ../../library/socket.rst:1223 ../../library/socket.rst:1246 +#: ../../library/socket.rst:1275 ../../library/socket.rst:1286 +#: ../../library/socket.rst:1313 ../../library/socket.rst:1330 +#: ../../library/socket.rst:1347 ../../library/socket.rst:1361 +#: ../../library/socket.rst:1412 ../../library/socket.rst:1459 +#: ../../library/socket.rst:1473 ../../library/socket.rst:1493 +#: ../../library/socket.rst:1540 ../../library/socket.rst:1585 +#: ../../library/socket.rst:1715 ../../library/socket.rst:1759 +#: ../../library/socket.rst:1867 ../../library/socket.rst:1885 +#: ../../library/socket.rst:1969 ../../library/socket.rst:1979 +#: ../../library/socket.rst:1991 ../../includes/wasm-notavail.rst:3 +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" @@ -396,11 +416,6 @@ msgstr "" msgid "*feat* and *mask* are unsigned 32bit integers." msgstr "*feat* と *mask* は、符号を持たない 32 ビットの整数です。" -#: ../../library/socket.rst:171 ../../library/socket.rst:594 -#: ../../library/socket.rst:1885 -msgid ":ref:`Availability `: Linux >= 2.6.38." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.38以上。" - #: ../../library/socket.rst:173 msgid "Some algorithm types require more recent Kernels." msgstr "一部のアルゴリズムタイプでは、さらに新しいカーネルが必要です。" @@ -412,10 +427,6 @@ msgid "" "context ID or CID and port are integers." msgstr "" -#: ../../library/socket.rst:181 ../../library/socket.rst:667 -msgid ":ref:`Availability `: Linux >= 3.9" -msgstr ":ref:`利用可能な環境 `: Linux 3.9以上。" - #: ../../library/socket.rst:183 msgid "See :manpage:`vsock(7)`" msgstr "" @@ -477,10 +488,6 @@ msgid "" "address, whose interpretation depends on the device." msgstr "" -#: ../../library/socket.rst:209 ../../library/socket.rst:542 -msgid ":ref:`Availability `: Linux >= 2.2." -msgstr ":ref:`利用可能な環境 `: Linux 2.2以上。" - #: ../../library/socket.rst:211 msgid "" ":const:`AF_QIPCRTR` is a Linux-only socket based interface for communicating " @@ -489,10 +496,6 @@ msgid "" "*port* are non-negative integers." msgstr "" -#: ../../library/socket.rst:216 ../../library/socket.rst:643 -msgid ":ref:`Availability `: Linux >= 4.7." -msgstr ":ref:`利用可能な環境 `: Linux 4.7以上。" - #: ../../library/socket.rst:220 msgid "" ":const:`IPPROTO_UDPLITE` is a variant of UDP which allows you to specify " @@ -511,10 +514,6 @@ msgid "" "IPPROTO_UDPLITE)`` for IPv6." msgstr "" -#: ../../library/socket.rst:233 -msgid ":ref:`Availability `: Linux >= 2.6.20, FreeBSD >= 10.1" -msgstr "" - #: ../../library/socket.rst:237 msgid "" ":const:`AF_HYPERV` is a Windows-only socket based interface for " @@ -727,10 +726,6 @@ msgstr "" "より完全な説明は `Secure File Descriptor Handling `_ を参照してください。" -#: ../../library/socket.rst:383 -msgid ":ref:`Availability `: Linux >= 2.6.27." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.27以上。" - #: ../../library/socket.rst:404 msgid "" "Many constants of these forms, documented in the Unix documentation on " @@ -813,10 +808,6 @@ msgstr "" "Linux ドキュメントにあるこの形式の定数は socket モジュールでも定義されていま" "す。" -#: ../../library/socket.rst:461 -msgid ":ref:`Availability `: Linux >= 2.6.25, NetBSD >= 8." -msgstr "" - #: ../../library/socket.rst:465 msgid "NetBSD support was added." msgstr "NetBSD サポートが追加されました。" @@ -831,10 +822,6 @@ msgstr "" "ルです。Linuxドキュメントにあるこの形式の定数は、socketモジュールでも定義され" "ています。" -#: ../../library/socket.rst:475 ../../library/socket.rst:510 -msgid ":ref:`Availability `: Linux >= 2.6.25." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.25以上。" - #: ../../library/socket.rst:478 msgid "" "The :data:`CAN_BCM_CAN_FD_FRAME` flag is only available on Linux >= 4.8." @@ -855,20 +842,12 @@ msgstr "" msgid "This constant is documented in the Linux documentation." msgstr "この定数は、 Linux のドキュメンテーションで説明されています。" -#: ../../library/socket.rst:490 -msgid ":ref:`Availability `: Linux >= 3.6." -msgstr ":ref:`利用可能な環境 `: Linux 3.6以上。" - #: ../../library/socket.rst:496 msgid "" "Joins the applied CAN filters such that only CAN frames that match all given " "CAN filters are passed to user space." msgstr "" -#: ../../library/socket.rst:501 -msgid ":ref:`Availability `: Linux >= 4.1." -msgstr ":ref:`利用可能な環境 `: Linux 4.1以上。" - #: ../../library/socket.rst:507 msgid "" "CAN_ISOTP, in the CAN protocol family, is the ISO-TP (ISO 15765-2) protocol. " @@ -881,20 +860,12 @@ msgid "" "constants, documented in the Linux documentation." msgstr "" -#: ../../library/socket.rst:519 -msgid ":ref:`Availability `: Linux >= 5.4." -msgstr ":ref:`利用可能な環境 `: Linux 5.4以上。" - #: ../../library/socket.rst:527 msgid "" "These two constants, documented in the FreeBSD divert(4) manual page, are " "also defined in the socket module." msgstr "" -#: ../../library/socket.rst:530 -msgid ":ref:`Availability `: FreeBSD >= 14.0." -msgstr "" - #: ../../library/socket.rst:547 msgid "" ":data:`!ETH_P_ALL` can be used in the :class:`~socket.socket` constructor as " @@ -906,14 +877,6 @@ msgstr "" msgid "For more information, see the :manpage:`packet(7)` manpage." msgstr "" -#: ../../library/socket.rst:553 -msgid ":ref:`Availability `: Linux." -msgstr ":ref:`利用可能な環境 `: Linux。" - -#: ../../library/socket.rst:566 -msgid ":ref:`Availability `: Linux >= 2.6.30." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.30以上。" - #: ../../library/socket.rst:576 msgid "" "Constants for Windows' WSAIoctl(). The constants are used as arguments to " @@ -942,14 +905,6 @@ msgstr "Linux カーネル暗号用の定数です。" msgid "Constants for Linux host/guest communication." msgstr "" -#: ../../library/socket.rst:606 -msgid ":ref:`Availability `: Linux >= 4.8." -msgstr ":ref:`利用可能な環境 `: Linux 4.8以上。" - -#: ../../library/socket.rst:612 -msgid ":ref:`Availability `: BSD, macOS." -msgstr ":ref:`利用可能な環境 `: BSD, macOS。" - #: ../../library/socket.rst:618 msgid "" "This constant contains a boolean value which indicates if IPv6 is supported " @@ -991,10 +946,6 @@ msgid "" "message type." msgstr "" -#: ../../library/socket.rst:658 -msgid ":ref:`Availability `: FreeBSD." -msgstr ":ref:`利用可能な環境 `: FreeBSD。" - #: ../../library/socket.rst:662 msgid "" "Constant to optimize CPU locality, to be used in conjunction with :data:" @@ -1005,21 +956,12 @@ msgstr "" msgid "Constants for Windows Hyper-V sockets for host/guest communications." msgstr "" -#: ../../library/socket.rst:684 ../../library/socket.rst:898 -#: ../../library/socket.rst:1991 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" - #: ../../library/socket.rst:695 msgid "" "`IEEE 802.3 protocol number `_. constants." msgstr "" -#: ../../library/socket.rst:699 -msgid ":ref:`Availability `: Linux, FreeBSD, macOS." -msgstr "" - #: ../../library/socket.rst:707 msgid "" "These constants are used by the :meth:`~socket.socket.shutdown` method of " @@ -1696,10 +1638,6 @@ msgstr "" "`OSError` が発生します。有効な *ip_string* は、 *address_family* と :c:func:" "`inet_pton` の実装によって異なります。" -#: ../../library/socket.rst:1177 ../../library/socket.rst:1197 -msgid ":ref:`Availability `: Unix, Windows." -msgstr ":ref:`Availability `: Unix, Windows。" - #: ../../library/socket.rst:1179 ../../library/socket.rst:1199 msgid "Windows support added" msgstr "Windowsで利用可能になりました" @@ -1749,11 +1687,6 @@ msgstr "" "使用した移植可能なアプリケーションが必要です。通常 *length* は定数であり、許" "容範囲外の値が指定された場合は :exc:`OverflowError` 例外が送出されます。" -#: ../../library/socket.rst:1223 ../../library/socket.rst:1246 -#: ../../library/socket.rst:1867 -msgid ":ref:`Availability `: Unix, not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外の Unix 。" - #: ../../library/socket.rst:1225 ../../library/socket.rst:1717 #: ../../library/socket.rst:1761 ../../library/socket.rst:1869 msgid "Most Unix platforms." @@ -1827,10 +1760,6 @@ msgstr "" "引数 ``name`` を指定して :ref:`監査イベント ` ``socket." "sethostname`` を送出します。" -#: ../../library/socket.rst:1275 -msgid ":ref:`Availability `: Unix, not Android." -msgstr "" - #: ../../library/socket.rst:1282 msgid "" "Return a list of network interface information (index int, name string) " @@ -1839,12 +1768,6 @@ msgstr "" "ネットワークインターフェース情報 (index int, name string)のタプルを返します。" "システムコールが失敗した場合、 :exc:`OSError` 例外を送出します。" -#: ../../library/socket.rst:1286 ../../library/socket.rst:1313 -#: ../../library/socket.rst:1330 ../../library/socket.rst:1347 -#: ../../library/socket.rst:1361 -msgid ":ref:`Availability `: Unix, Windows, not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外の Unix 及び Windows。" - #: ../../library/socket.rst:1290 ../../library/socket.rst:1317 #: ../../library/socket.rst:1334 msgid "Windows support was added." @@ -2417,10 +2340,6 @@ msgid "" " return msg, list(fds)" msgstr "" -#: ../../library/socket.rst:1715 ../../library/socket.rst:1759 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" - #: ../../library/socket.rst:1729 msgid "" "Receive normal data and ancillary data from the socket, behaving as :meth:" diff --git a/library/socketserver.po b/library/socketserver.po index e379f1fd3..2aed27981 100644 --- a/library/socketserver.po +++ b/library/socketserver.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -43,8 +43,8 @@ msgstr "" "ます。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/ssl.po b/library/ssl.po index 3b2250d48..c3955b3c9 100644 --- a/library/ssl.po +++ b/library/ssl.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -69,9 +69,10 @@ msgstr "" "フォルト設定はアプリケーションに十分ではないので、読まない場合はセキュリティ" "に誤った意識を持ってしまうかもしれません。" +#: ../../library/ssl.rst:454 ../../library/ssl.rst:469 #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" @@ -700,10 +701,6 @@ msgid "" " (b'data...', 'x509_asn', True)]" msgstr "" -#: ../../library/ssl.rst:454 ../../library/ssl.rst:469 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" - #: ../../library/ssl.rst:460 msgid "" "Retrieve CRLs from Windows' system cert store. *store_name* may be one of " diff --git a/library/stat.po b/library/stat.po index e6b0aea6e..ab4961945 100644 --- a/library/stat.po +++ b/library/stat.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:13+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -493,8 +493,8 @@ msgid "All super-user supported flags" msgstr "" #: ../../library/stat.rst:409 ../../library/stat.rst:417 -msgid ":ref:`Availability `: macOS" -msgstr ":ref:`利用可能な環境 `: macOS" +msgid "Availability" +msgstr "" #: ../../library/stat.rst:415 msgid "All super-user read-only synthetic flags" diff --git a/library/subprocess.po b/library/subprocess.po index c8d4ffcb2..86ad217be 100644 --- a/library/subprocess.po +++ b/library/subprocess.po @@ -19,7 +19,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:14+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -66,8 +66,12 @@ msgstr "" msgid ":pep:`324` -- PEP proposing the subprocess module" msgstr ":pep:`324` -- subprocess モジュールを提案している PEP" +#: ../../library/subprocess.rst:598 ../../library/subprocess.rst:605 +#: ../../library/subprocess.rst:615 ../../library/subprocess.rst:624 +#: ../../library/subprocess.rst:633 ../../library/subprocess.rst:639 +#: ../../library/subprocess.rst:1560 ../../library/subprocess.rst:1582 #: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." +msgid "Availability" msgstr "" #: ../../includes/wasm-mobile-notavail.rst:5 @@ -952,12 +956,6 @@ msgid "" "the child process prior to the execution of the subprocess." msgstr "" -#: ../../library/subprocess.rst:598 ../../library/subprocess.rst:605 -#: ../../library/subprocess.rst:615 ../../library/subprocess.rst:624 -#: ../../library/subprocess.rst:633 ../../library/subprocess.rst:639 -msgid ":ref:`Availability `: POSIX" -msgstr ":ref:`利用可能な環境 `: POSIX" - #: ../../library/subprocess.rst:599 msgid "*start_new_session* was added." msgstr "*start_new_session* が追加されました。" @@ -2262,10 +2260,6 @@ msgid "" "(-15, '')" msgstr "" -#: ../../library/subprocess.rst:1560 ../../library/subprocess.rst:1582 -msgid ":ref:`Availability `: Unix, Windows." -msgstr ":ref:`Availability `: Unix, Windows。" - #: ../../library/subprocess.rst:1562 msgid "Windows support was added." msgstr "Windows のサポートが追加されました。" diff --git a/library/symtable.po b/library/symtable.po index 989eaa4fe..59b9bfc29 100644 --- a/library/symtable.po +++ b/library/symtable.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:14+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -210,46 +210,50 @@ msgid "Return a tuple containing names of globals in this function." msgstr "この関数のグローバル変数の名前からなるタプルを返します。" #: ../../library/symtable.rst:170 -msgid "Return a tuple containing names of nonlocals in this function." -msgstr "この関数の非ローカル変数の名前からなるタプルを返します。" +msgid "" +"Return a tuple containing names of explicitly declared nonlocals in this " +"function." +msgstr "" #: ../../library/symtable.rst:174 -msgid "Return a tuple containing names of free variables in this function." -msgstr "この関数の自由変数の名前からなるタプルを返します。" +msgid "" +"Return a tuple containing names of :term:`free (closure) variables ` in this function." +msgstr "" -#: ../../library/symtable.rst:179 +#: ../../library/symtable.rst:180 msgid "A namespace of a class. This class inherits from :class:`SymbolTable`." msgstr "" -#: ../../library/symtable.rst:183 +#: ../../library/symtable.rst:184 msgid "" "Return a tuple containing the names of method-like functions declared in the " "class." msgstr "" -#: ../../library/symtable.rst:186 +#: ../../library/symtable.rst:187 msgid "" "Here, the term 'method' designates *any* function defined in the class body " "via :keyword:`def` or :keyword:`async def`." msgstr "" -#: ../../library/symtable.rst:189 +#: ../../library/symtable.rst:190 msgid "" "Functions defined in a deeper scope (e.g., in an inner class) are not picked " "up by :meth:`get_methods`." msgstr "" -#: ../../library/symtable.rst:192 +#: ../../library/symtable.rst:193 msgid "For example:" msgstr "例えば:" -#: ../../library/symtable.rst:214 +#: ../../library/symtable.rst:215 msgid "" "Although ``A().f()`` raises :exc:`TypeError` at runtime, ``A.f`` is still " "considered as a method-like function." msgstr "" -#: ../../library/symtable.rst:219 +#: ../../library/symtable.rst:220 msgid "" "An entry in a :class:`SymbolTable` corresponding to an identifier in the " "source. The constructor is not public." @@ -257,46 +261,46 @@ msgstr "" ":class:`SymbolTable` のエントリーでソースの識別子に対応するものです。コンスト" "ラクタはパブリックではありません。" -#: ../../library/symtable.rst:224 +#: ../../library/symtable.rst:225 msgid "Return the symbol's name." msgstr "記号の名前を返します。" -#: ../../library/symtable.rst:228 +#: ../../library/symtable.rst:229 msgid "Return ``True`` if the symbol is used in its block." msgstr "記号がそのブロックの中で使われていれば ``True`` を返します。" -#: ../../library/symtable.rst:232 +#: ../../library/symtable.rst:233 msgid "Return ``True`` if the symbol is created from an import statement." msgstr "記号が import 文で作られたものならば ``True`` を返します。" -#: ../../library/symtable.rst:236 +#: ../../library/symtable.rst:237 msgid "Return ``True`` if the symbol is a parameter." msgstr "記号がパラメータならば ``True`` を返します。" -#: ../../library/symtable.rst:240 +#: ../../library/symtable.rst:241 msgid "Return ``True`` if the symbol is global." msgstr "記号がグローバルならば ``True`` を返します。" -#: ../../library/symtable.rst:244 +#: ../../library/symtable.rst:245 msgid "Return ``True`` if the symbol is nonlocal." msgstr "記号が非ローカルならば ``True`` を返します。" -#: ../../library/symtable.rst:248 +#: ../../library/symtable.rst:249 msgid "" "Return ``True`` if the symbol is declared global with a global statement." msgstr "" "記号が global 文によってグローバルであると宣言されているなら ``True`` を返し" "ます。" -#: ../../library/symtable.rst:252 +#: ../../library/symtable.rst:253 msgid "Return ``True`` if the symbol is local to its block." msgstr "記号がそのブロックに対してローカルならば ``True`` を返します。" -#: ../../library/symtable.rst:256 +#: ../../library/symtable.rst:257 msgid "Return ``True`` if the symbol is annotated." msgstr "記号が注釈付きならば ``True`` を返します。" -#: ../../library/symtable.rst:262 +#: ../../library/symtable.rst:263 msgid "" "Return ``True`` if the symbol is referenced in its block, but not assigned " "to." @@ -304,25 +308,25 @@ msgstr "" "記号がそのブロックの中で参照されていて、しかし代入は行われないならば " "``True`` を返します。" -#: ../../library/symtable.rst:267 +#: ../../library/symtable.rst:268 msgid "Return ``True`` if the symbol is assigned to in its block." msgstr "記号がそのブロックの中で代入されているならば ``True`` を返します。" -#: ../../library/symtable.rst:271 +#: ../../library/symtable.rst:272 msgid "Return ``True`` if name binding introduces new namespace." msgstr "名前の束縛が新たな名前空間を導入するならば ``True`` を返します。" -#: ../../library/symtable.rst:273 +#: ../../library/symtable.rst:274 msgid "" "If the name is used as the target of a function or class statement, this " "will be true." msgstr "名前が関数または class 文のターゲットとして使われるならば、真です。" -#: ../../library/symtable.rst:276 +#: ../../library/symtable.rst:277 msgid "For example::" msgstr "例えば::" -#: ../../library/symtable.rst:278 +#: ../../library/symtable.rst:279 msgid "" ">>> table = symtable.symtable(\"def some_func(): pass\", \"string\", " "\"exec\")\n" @@ -330,7 +334,7 @@ msgid "" "True" msgstr "" -#: ../../library/symtable.rst:282 +#: ../../library/symtable.rst:283 msgid "" "Note that a single name can be bound to multiple objects. If the result is " "``True``, the name may also be bound to other objects, like an int or list, " @@ -341,11 +345,11 @@ msgstr "" "ず、それがたとえば整数やリストであれば、そこでは新たな名前空間は導入されませ" "ん。" -#: ../../library/symtable.rst:288 +#: ../../library/symtable.rst:289 msgid "Return a list of namespaces bound to this name." msgstr "この名前に束縛された名前空間のリストを返します。" -#: ../../library/symtable.rst:292 +#: ../../library/symtable.rst:293 msgid "" "Return the namespace bound to this name. If more than one or no namespace is " "bound to this name, a :exc:`ValueError` is raised." @@ -353,20 +357,20 @@ msgstr "" "この名前に束縛された名前空間を返します。この名前に束縛された名前空間が複数あ" "るか一つもないなら :exc:`ValueError` が送出されます。" -#: ../../library/symtable.rst:299 +#: ../../library/symtable.rst:300 msgid "Command-Line Usage" msgstr "コマンドラインからの使用" -#: ../../library/symtable.rst:303 +#: ../../library/symtable.rst:304 msgid "" "The :mod:`symtable` module can be executed as a script from the command line." msgstr "" -#: ../../library/symtable.rst:305 +#: ../../library/symtable.rst:306 msgid "python -m symtable [infile...]" msgstr "" -#: ../../library/symtable.rst:309 +#: ../../library/symtable.rst:310 msgid "" "Symbol tables are generated for the specified Python source files and dumped " "to stdout. If no input file is specified, the content is read from stdin." diff --git a/library/sys.po b/library/sys.po index 8aa02b160..2d4df547d 100644 --- a/library/sys.po +++ b/library/sys.po @@ -18,7 +18,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:14+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -58,10 +58,14 @@ msgstr "" "デフォルトのフラグは空文字列になりました。 (pymalloc のための ``m`` フラグが" "取り除かれました)" -#: ../../library/sys.rst:25 ../../library/sys.rst:778 -#: ../../library/sys.rst:1489 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +#: ../../library/sys.rst:25 ../../library/sys.rst:299 ../../library/sys.rst:369 +#: ../../library/sys.rst:760 ../../library/sys.rst:778 +#: ../../library/sys.rst:991 ../../library/sys.rst:1490 +#: ../../library/sys.rst:1731 ../../library/sys.rst:1746 +#: ../../library/sys.rst:1754 ../../library/sys.rst:1770 +#: ../../library/sys.rst:2014 +msgid "Availability" +msgstr "" #: ../../library/sys.rst:30 msgid "" @@ -469,11 +473,6 @@ msgstr "" msgid "Integer specifying the handle of the Python DLL." msgstr "Python DLLのハンドルを示す整数です。" -#: ../../library/sys.rst:299 ../../library/sys.rst:991 -#: ../../library/sys.rst:1769 ../../library/sys.rst:2013 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" - #: ../../library/sys.rst:304 msgid "" "If *value* is not ``None``, this function prints ``repr(value)`` to ``sys." @@ -571,10 +570,6 @@ msgstr "" msgid "``True`` if Python is compiled with shared memory support." msgstr "" -#: ../../library/sys.rst:369 -msgid ":ref:`Availability `: Emscripten." -msgstr ":ref:`利用可能な環境 `: Emscripten 。" - #: ../../library/sys.rst:376 msgid "" "If this is set (not ``None``), Python will write bytecode-cache ``.pyc`` " @@ -1148,10 +1143,6 @@ msgid "" "version information, see :func:`platform.android_ver`." msgstr "" -#: ../../library/sys.rst:760 -msgid ":ref:`Availability `: Android." -msgstr ":ref:`利用可能な環境 `: Android 。" - #: ../../library/sys.rst:767 msgid "" "Return the name of the current default string encoding used by the Unicode " @@ -1513,7 +1504,7 @@ msgstr "" msgid "See :pep:`525` for more details." msgstr "より詳しくは :pep:`525` を参照してください。" -#: ../../library/sys.rst:1014 ../../library/sys.rst:1701 +#: ../../library/sys.rst:1014 ../../library/sys.rst:1702 msgid "" "This function has been added on a provisional basis (see :pep:`411` for " "details.)" @@ -1525,7 +1516,7 @@ msgid "" "`set_coroutine_origin_tracking_depth`." msgstr "" -#: ../../library/sys.rst:1026 ../../library/sys.rst:1722 +#: ../../library/sys.rst:1026 ../../library/sys.rst:1723 msgid "" "This function has been added on a provisional basis (see :pep:`411` for " "details.) Use it only for debugging purposes." @@ -1857,45 +1848,45 @@ msgid "" "implement Python's default import semantics. The :meth:`~importlib.abc." "MetaPathFinder.find_spec` method is called with at least the absolute name " "of the module being imported. If the module to be imported is contained in a " -"package, then the parent package's :attr:`__path__` attribute is passed in " -"as a second argument. The method returns a :term:`module spec`, or ``None`` " -"if the module cannot be found." +"package, then the parent package's :attr:`~module.__path__` attribute is " +"passed in as a second argument. The method returns a :term:`module spec`, or " +"``None`` if the module cannot be found." msgstr "" -#: ../../library/sys.rst:1283 +#: ../../library/sys.rst:1284 msgid ":class:`importlib.abc.MetaPathFinder`" msgstr ":class:`importlib.abc.MetaPathFinder`" -#: ../../library/sys.rst:1284 +#: ../../library/sys.rst:1285 msgid "" "The abstract base class defining the interface of finder objects on :data:" "`meta_path`." msgstr "" -#: ../../library/sys.rst:1286 +#: ../../library/sys.rst:1287 msgid ":class:`importlib.machinery.ModuleSpec`" msgstr ":class:`importlib.machinery.ModuleSpec`" -#: ../../library/sys.rst:1287 +#: ../../library/sys.rst:1288 msgid "" "The concrete class which :meth:`~importlib.abc.MetaPathFinder.find_spec` " "should return instances of." msgstr "" -#: ../../library/sys.rst:1293 +#: ../../library/sys.rst:1294 msgid "" ":term:`Module specs ` were introduced in Python 3.4, by :pep:" "`451`." msgstr "" -#: ../../library/sys.rst:1298 +#: ../../library/sys.rst:1299 msgid "" "Removed the fallback that looked for a :meth:`!find_module` method if a :" "data:`meta_path` entry didn't have a :meth:`~importlib.abc.MetaPathFinder." "find_spec` method." msgstr "" -#: ../../library/sys.rst:1304 +#: ../../library/sys.rst:1305 msgid "" "This is a dictionary that maps module names to modules which have already " "been loaded. This can be manipulated to force reloading of modules and " @@ -1907,13 +1898,13 @@ msgid "" "other threads." msgstr "" -#: ../../library/sys.rst:1316 +#: ../../library/sys.rst:1317 msgid "" "The list of the original command line arguments passed to the Python " "executable." msgstr "" -#: ../../library/sys.rst:1319 +#: ../../library/sys.rst:1320 msgid "" "The elements of :data:`sys.orig_argv` are the arguments to the Python " "interpreter, while the elements of :data:`sys.argv` are the arguments to the " @@ -1921,7 +1912,7 @@ msgid "" "in :data:`sys.orig_argv` and missing from :data:`sys.argv`." msgstr "" -#: ../../library/sys.rst:1331 +#: ../../library/sys.rst:1332 msgid "" "A list of strings that specifies the search path for modules. Initialized " "from the environment variable :envvar:`PYTHONPATH`, plus an installation-" @@ -1930,37 +1921,37 @@ msgstr "" "モジュールを検索するパスを示す文字列のリスト。 :envvar:`PYTHONPATH` 環境変数" "と、インストール時に指定したデフォルトパスで初期化されます。" -#: ../../library/sys.rst:1335 +#: ../../library/sys.rst:1336 msgid "" "By default, as initialized upon program startup, a potentially unsafe path " "is prepended to :data:`sys.path` (*before* the entries inserted as a result " "of :envvar:`PYTHONPATH`):" msgstr "" -#: ../../library/sys.rst:1339 +#: ../../library/sys.rst:1340 msgid "" "``python -m module`` command line: prepend the current working directory." msgstr "" -#: ../../library/sys.rst:1341 +#: ../../library/sys.rst:1342 msgid "" "``python script.py`` command line: prepend the script's directory. If it's a " "symbolic link, resolve symbolic links." msgstr "" -#: ../../library/sys.rst:1343 +#: ../../library/sys.rst:1344 msgid "" "``python -c code`` and ``python`` (REPL) command lines: prepend an empty " "string, which means the current working directory." msgstr "" -#: ../../library/sys.rst:1346 +#: ../../library/sys.rst:1347 msgid "" "To not prepend this potentially unsafe path, use the :option:`-P` command " "line option or the :envvar:`PYTHONSAFEPATH` environment variable." msgstr "" -#: ../../library/sys.rst:1349 +#: ../../library/sys.rst:1350 msgid "" "A program is free to modify this list for its own purposes. Only strings " "should be added to :data:`sys.path`; all other data types are ignored during " @@ -1970,7 +1961,7 @@ msgstr "" "data:`sys.path` に追加でき、 ほかの全てのデータ型はインポート中に無視されま" "す。" -#: ../../library/sys.rst:1355 +#: ../../library/sys.rst:1356 msgid "" "Module :mod:`site` This describes how to use .pth files to extend :data:`sys." "path`." @@ -1978,7 +1969,7 @@ msgstr "" ":mod:`site` モジュールのドキュメントで、 .pth ファイルを使って :data:`sys." "path` を拡張する方法を解説しています。" -#: ../../library/sys.rst:1360 +#: ../../library/sys.rst:1361 msgid "" "A list of callables that take a path argument to try to create a :term:" "`finder` for the path. If a finder can be created, it is to be returned by " @@ -1989,11 +1980,11 @@ msgstr "" "トのは finder を返します。失敗した場合は、 :exc:`ImportError` を発生させま" "す。" -#: ../../library/sys.rst:1364 ../../library/sys.rst:1375 +#: ../../library/sys.rst:1365 ../../library/sys.rst:1376 msgid "Originally specified in :pep:`302`." msgstr "オリジナルの仕様は :pep:`302` を参照してください。" -#: ../../library/sys.rst:1369 +#: ../../library/sys.rst:1370 msgid "" "A dictionary acting as a cache for :term:`finder` objects. The keys are " "paths that have been passed to :data:`sys.path_hooks` and the values are the " @@ -2005,91 +1996,91 @@ msgstr "" "が正常なファイルシステムパスであり、finder が :data:`sys.path_hooks` 上に見つ" "からない場合は ``None`` が格納されます。" -#: ../../library/sys.rst:1380 +#: ../../library/sys.rst:1381 msgid "A string containing a platform identifier. Known values are:" msgstr "" -#: ../../library/sys.rst:1383 +#: ../../library/sys.rst:1384 msgid "System" msgstr "システム" -#: ../../library/sys.rst:1383 +#: ../../library/sys.rst:1384 msgid "``platform`` value" msgstr "``platform`` の値" -#: ../../library/sys.rst:1385 +#: ../../library/sys.rst:1386 msgid "AIX" msgstr "AIX" -#: ../../library/sys.rst:1385 +#: ../../library/sys.rst:1386 msgid "``'aix'``" msgstr "``'aix'``" -#: ../../library/sys.rst:1386 +#: ../../library/sys.rst:1387 msgid "Android" msgstr "" -#: ../../library/sys.rst:1386 +#: ../../library/sys.rst:1387 msgid "``'android'``" msgstr "" -#: ../../library/sys.rst:1387 +#: ../../library/sys.rst:1388 msgid "Emscripten" msgstr "" -#: ../../library/sys.rst:1387 +#: ../../library/sys.rst:1388 msgid "``'emscripten'``" msgstr "" -#: ../../library/sys.rst:1388 +#: ../../library/sys.rst:1389 msgid "iOS" msgstr "iOS" -#: ../../library/sys.rst:1388 +#: ../../library/sys.rst:1389 msgid "``'ios'``" msgstr "" -#: ../../library/sys.rst:1389 +#: ../../library/sys.rst:1390 msgid "Linux" msgstr "Linux" -#: ../../library/sys.rst:1389 +#: ../../library/sys.rst:1390 msgid "``'linux'``" msgstr "``'linux'``" -#: ../../library/sys.rst:1390 +#: ../../library/sys.rst:1391 msgid "macOS" msgstr "macOS" -#: ../../library/sys.rst:1390 +#: ../../library/sys.rst:1391 msgid "``'darwin'``" msgstr "``'darwin'``" -#: ../../library/sys.rst:1391 +#: ../../library/sys.rst:1392 msgid "Windows" msgstr "Windows" -#: ../../library/sys.rst:1391 +#: ../../library/sys.rst:1392 msgid "``'win32'``" msgstr "``'win32'``" -#: ../../library/sys.rst:1392 +#: ../../library/sys.rst:1393 msgid "Windows/Cygwin" msgstr "Windows/Cygwin" -#: ../../library/sys.rst:1392 +#: ../../library/sys.rst:1393 msgid "``'cygwin'``" msgstr "``'cygwin'``" -#: ../../library/sys.rst:1393 +#: ../../library/sys.rst:1394 msgid "WASI" msgstr "" -#: ../../library/sys.rst:1393 +#: ../../library/sys.rst:1394 msgid "``'wasi'``" msgstr "" -#: ../../library/sys.rst:1396 +#: ../../library/sys.rst:1397 msgid "" "On Unix systems not listed in the table, the value is the lowercased OS name " "as returned by ``uname -s``, with the first part of the version as returned " @@ -2098,37 +2089,37 @@ msgid "" "version, it is therefore recommended to use the following idiom::" msgstr "" -#: ../../library/sys.rst:1402 +#: ../../library/sys.rst:1403 msgid "" "if sys.platform.startswith('freebsd'):\n" " # FreeBSD-specific code here..." msgstr "" -#: ../../library/sys.rst:1405 +#: ../../library/sys.rst:1406 msgid "" "On Linux, :data:`sys.platform` doesn't contain the major version anymore. It " "is always ``'linux'``, instead of ``'linux2'`` or ``'linux3'``." msgstr "" -#: ../../library/sys.rst:1409 +#: ../../library/sys.rst:1410 msgid "" "On AIX, :data:`sys.platform` doesn't contain the major version anymore. It " "is always ``'aix'``, instead of ``'aix5'`` or ``'aix7'``." msgstr "" -#: ../../library/sys.rst:1413 +#: ../../library/sys.rst:1414 msgid "" "On Android, :data:`sys.platform` now returns ``'android'`` rather than " "``'linux'``." msgstr "" -#: ../../library/sys.rst:1419 +#: ../../library/sys.rst:1420 msgid "" ":data:`os.name` has a coarser granularity. :func:`os.uname` gives system-" "dependent version information." msgstr "" -#: ../../library/sys.rst:1422 +#: ../../library/sys.rst:1423 msgid "" "The :mod:`platform` module provides detailed checks for the system's " "identity." @@ -2136,45 +2127,45 @@ msgstr "" ":mod:`platform` モジュールはシステムの詳細な識別情報をチェックする機能を提供" "しています。" -#: ../../library/sys.rst:1428 +#: ../../library/sys.rst:1429 msgid "" "Name of the platform-specific library directory. It is used to build the " "path of standard library and the paths of installed extension modules." msgstr "" -#: ../../library/sys.rst:1431 +#: ../../library/sys.rst:1432 msgid "" "It is equal to ``\"lib\"`` on most platforms. On Fedora and SuSE, it is " "equal to ``\"lib64\"`` on 64-bit platforms which gives the following ``sys." "path`` paths (where ``X.Y`` is the Python ``major.minor`` version):" msgstr "" -#: ../../library/sys.rst:1435 +#: ../../library/sys.rst:1436 msgid "" "``/usr/lib64/pythonX.Y/``: Standard library (like ``os.py`` of the :mod:`os` " "module)" msgstr "" -#: ../../library/sys.rst:1437 +#: ../../library/sys.rst:1438 msgid "" "``/usr/lib64/pythonX.Y/lib-dynload/``: C extension modules of the standard " "library (like the :mod:`errno` module, the exact filename is platform " "specific)" msgstr "" -#: ../../library/sys.rst:1440 +#: ../../library/sys.rst:1441 msgid "" "``/usr/lib/pythonX.Y/site-packages/`` (always use ``lib``, not :data:`sys." "platlibdir`): Third-party modules" msgstr "" -#: ../../library/sys.rst:1442 +#: ../../library/sys.rst:1443 msgid "" "``/usr/lib64/pythonX.Y/site-packages/``: C extension modules of third-party " "packages" msgstr "" -#: ../../library/sys.rst:1450 +#: ../../library/sys.rst:1451 msgid "" "A string giving the site-specific directory prefix where the platform " "independent Python files are installed; on Unix, the default is :file:`/usr/" @@ -2183,7 +2174,7 @@ msgid "" "derived paths." msgstr "" -#: ../../library/sys.rst:1456 +#: ../../library/sys.rst:1457 msgid "" "If a :ref:`virtual environment ` is in effect, this value will be " "changed in ``site.py`` to point to the virtual environment. The value for " @@ -2193,7 +2184,7 @@ msgstr "" "て仮想環境を示すよう変更されます。実際の Python のインストール先は :data:" "`base_prefix` から取得できます。" -#: ../../library/sys.rst:1471 +#: ../../library/sys.rst:1472 msgid "" "Strings specifying the primary and secondary prompt of the interpreter. " "These are only defined if the interpreter is in interactive mode. Their " @@ -2208,7 +2199,7 @@ msgstr "" "トの :func:`str` を評価します。この機能は、動的に変化するプロンプトを実装する" "場合に利用します。" -#: ../../library/sys.rst:1481 +#: ../../library/sys.rst:1482 msgid "" "Set the flags used by the interpreter for :c:func:`dlopen` calls, such as " "when the interpreter loads extension modules. Among other things, this will " @@ -2219,14 +2210,14 @@ msgid "" "g. :const:`os.RTLD_LAZY`)." msgstr "" -#: ../../library/sys.rst:1493 +#: ../../library/sys.rst:1494 msgid "" "Set the :ref:`integer string conversion length limitation " "` used by this interpreter. See also :func:" "`get_int_max_str_digits`." msgstr "" -#: ../../library/sys.rst:1505 +#: ../../library/sys.rst:1506 msgid "" "Set the system's profile function, which allows you to implement a Python " "source code profiler in Python. See chapter :ref:`profile` for more " @@ -2241,14 +2232,14 @@ msgid "" "in the profile function will cause itself unset." msgstr "" -#: ../../library/sys.rst:1517 +#: ../../library/sys.rst:1518 msgid "" "The same tracing mechanism is used for :func:`!setprofile` as :func:" "`settrace`. To trace calls with :func:`!setprofile` inside a tracing " "function (e.g. in a debugger breakpoint), see :func:`call_tracing`." msgstr "" -#: ../../library/sys.rst:1521 +#: ../../library/sys.rst:1522 msgid "" "Profile functions should have three arguments: *frame*, *event*, and *arg*. " "*frame* is the current stack frame. *event* is a string: ``'call'``, " @@ -2260,15 +2251,15 @@ msgstr "" "``'return'``, ``'c_call'``, ``'c_return'``, ``'c_exception'`` のどれかが渡さ" "れます。*arg* はイベントの種類によって異なります。" -#: ../../library/sys.rst:1526 ../../library/sys.rst:1613 +#: ../../library/sys.rst:1527 ../../library/sys.rst:1614 msgid "The events have the following meaning:" msgstr "*event* には以下の意味があります。" -#: ../../library/sys.rst:1528 ../../library/sys.rst:1615 +#: ../../library/sys.rst:1529 ../../library/sys.rst:1616 msgid "``'call'``" msgstr "``'call'``" -#: ../../library/sys.rst:1529 +#: ../../library/sys.rst:1530 msgid "" "A function is called (or some other code block entered). The profile " "function is called; *arg* is ``None``." @@ -2276,11 +2267,11 @@ msgstr "" "関数が呼び出された(もしくは、何かのコードブロックに入った)。プロファイル関数" "が呼ばれる。 *arg* は ``None`` が渡される。" -#: ../../library/sys.rst:1532 ../../library/sys.rst:1630 +#: ../../library/sys.rst:1533 ../../library/sys.rst:1631 msgid "``'return'``" msgstr "``'return'``" -#: ../../library/sys.rst:1533 +#: ../../library/sys.rst:1534 msgid "" "A function (or other code block) is about to return. The profile function " "is called; *arg* is the value that will be returned, or ``None`` if the " @@ -2290,11 +2281,11 @@ msgstr "" "れる。 *arg* は返されようとしている値、または、このイベントが例外が送出される" "ことによって起こったなら ``None`` 。" -#: ../../library/sys.rst:1537 +#: ../../library/sys.rst:1538 msgid "``'c_call'``" msgstr "``'c_call'``" -#: ../../library/sys.rst:1538 +#: ../../library/sys.rst:1539 msgid "" "A C function is about to be called. This may be an extension function or a " "built-in. *arg* is the C function object." @@ -2302,30 +2293,30 @@ msgstr "" "C 関数(拡張関数かビルトイン関数)が呼ばれようとしている。 *arg* は C 関数オブ" "ジェクト。" -#: ../../library/sys.rst:1541 +#: ../../library/sys.rst:1542 msgid "``'c_return'``" msgstr "``'c_return'``" -#: ../../library/sys.rst:1542 +#: ../../library/sys.rst:1543 msgid "A C function has returned. *arg* is the C function object." msgstr "C 関数から戻った。 *arg* は C の関数オブジェクト。" -#: ../../library/sys.rst:1544 +#: ../../library/sys.rst:1545 msgid "``'c_exception'``" msgstr "``'c_exception'``" -#: ../../library/sys.rst:1545 +#: ../../library/sys.rst:1546 msgid "A C function has raised an exception. *arg* is the C function object." msgstr "C 関数が例外を発生させた。 *arg* は C の関数オブジェクト。" -#: ../../library/sys.rst:1547 +#: ../../library/sys.rst:1548 msgid "" "Raises an :ref:`auditing event ` ``sys.setprofile`` with no " "arguments." msgstr "" "引数無しで :ref:`監査イベント ` ``sys.setprofile`` を送出します。 " -#: ../../library/sys.rst:1552 +#: ../../library/sys.rst:1553 msgid "" "Set the maximum depth of the Python interpreter stack to *limit*. This " "limit prevents infinite recursion from causing an overflow of the C stack " @@ -2335,7 +2326,7 @@ msgstr "" "は Python プログラムが無限に再帰し、 C スタックがオーバーフローしてクラッシュ" "することを防止するために設けられています。" -#: ../../library/sys.rst:1556 +#: ../../library/sys.rst:1557 msgid "" "The highest possible limit is platform-dependent. A user may need to set " "the limit higher when they have a program that requires deep recursion and a " @@ -2346,19 +2337,19 @@ msgstr "" "合にはプラットフォームがサポートしている範囲内でより大きな値を指定することが" "できますが、この値が大きすぎればクラッシュするので注意が必要です。" -#: ../../library/sys.rst:1561 +#: ../../library/sys.rst:1562 msgid "" "If the new limit is too low at the current recursion depth, a :exc:" "`RecursionError` exception is raised." msgstr "" -#: ../../library/sys.rst:1564 +#: ../../library/sys.rst:1565 msgid "" "A :exc:`RecursionError` exception is now raised if the new limit is too low " "at the current recursion depth." msgstr "" -#: ../../library/sys.rst:1571 +#: ../../library/sys.rst:1572 msgid "" "Set the interpreter's thread switch interval (in seconds). This floating-" "point value determines the ideal duration of the \"timeslices\" allocated to " @@ -2375,7 +2366,7 @@ msgstr "" "ケジュールされる(次に実行される)かはオペレーティングシステムが決定します。" "インタプリタは自身のスケジューラを持ちません。" -#: ../../library/sys.rst:1588 +#: ../../library/sys.rst:1589 msgid "" "Set the system's trace function, which allows you to implement a Python " "source code debugger in Python. The function is thread-specific; for a " @@ -2384,7 +2375,7 @@ msgid "" "`threading.settrace`." msgstr "" -#: ../../library/sys.rst:1593 +#: ../../library/sys.rst:1594 msgid "" "Trace functions should have three arguments: *frame*, *event*, and *arg*. " "*frame* is the current stack frame. *event* is a string: ``'call'``, " @@ -2396,7 +2387,7 @@ msgstr "" "``'line'``, ``'return'``, ``'exception'``, ``'opcode'`` のどれかが渡されま" "す。*arg* はイベントの種類によって異なります。" -#: ../../library/sys.rst:1598 +#: ../../library/sys.rst:1599 msgid "" "The trace function is invoked (with *event* set to ``'call'``) whenever a " "new local scope is entered; it should return a reference to a local trace " @@ -2407,25 +2398,25 @@ msgstr "" "に入るたびに呼ばれます。この場合、新しいスコープで利用するローカルの trace 関" "数への参照か、そのスコープを trace しないのであれば ``None`` を返します。" -#: ../../library/sys.rst:1603 +#: ../../library/sys.rst:1604 msgid "" "The local trace function should return a reference to itself, or to another " "function which would then be used as the local trace function for the scope." msgstr "" -#: ../../library/sys.rst:1606 +#: ../../library/sys.rst:1607 msgid "" "If there is any error occurred in the trace function, it will be unset, just " "like ``settrace(None)`` is called." msgstr "" -#: ../../library/sys.rst:1610 +#: ../../library/sys.rst:1611 msgid "" "Tracing is disabled while calling the trace function (e.g. a function set " "by :func:`!settrace`). For recursive tracing see :func:`call_tracing`." msgstr "" -#: ../../library/sys.rst:1616 +#: ../../library/sys.rst:1617 msgid "" "A function is called (or some other code block entered). The global trace " "function is called; *arg* is ``None``; the return value specifies the local " @@ -2435,11 +2426,11 @@ msgstr "" "trace 関数が呼ばれる。 *arg* は ``None`` が渡される。戻り値はローカルの " "trace 関数。" -#: ../../library/sys.rst:1620 +#: ../../library/sys.rst:1621 msgid "``'line'``" msgstr "``'line'``" -#: ../../library/sys.rst:1621 +#: ../../library/sys.rst:1622 msgid "" "The interpreter is about to execute a new line of code or re-execute the " "condition of a loop. The local trace function is called; *arg* is ``None``; " @@ -2449,7 +2440,7 @@ msgid "" "to :const:`False` on that :ref:`frame `." msgstr "" -#: ../../library/sys.rst:1631 +#: ../../library/sys.rst:1632 msgid "" "A function (or other code block) is about to return. The local trace " "function is called; *arg* is the value that will be returned, or ``None`` if " @@ -2460,11 +2451,11 @@ msgstr "" "呼ばれる。 *arg* は返されようとしている値、または、このイベントが例外が送出さ" "れることによって起こったなら ``None`` 。 trace 関数の戻り値は無視される。" -#: ../../library/sys.rst:1636 +#: ../../library/sys.rst:1637 msgid "``'exception'``" msgstr "``'exception'``" -#: ../../library/sys.rst:1637 +#: ../../library/sys.rst:1638 msgid "" "An exception has occurred. The local trace function is called; *arg* is a " "tuple ``(exception, value, traceback)``; the return value specifies the new " @@ -2473,11 +2464,11 @@ msgstr "" "例外が発生した。ローカルの trace 関数が呼ばれる。 *arg* は ``(exception, " "value, traceback)`` のタプル。戻り値は新しいローカルの trace 関数。" -#: ../../library/sys.rst:1641 +#: ../../library/sys.rst:1642 msgid "``'opcode'``" msgstr "``'opcode'``" -#: ../../library/sys.rst:1642 +#: ../../library/sys.rst:1643 msgid "" "The interpreter is about to execute a new opcode (see :mod:`dis` for opcode " "details). The local trace function is called; *arg* is ``None``; the return " @@ -2487,7 +2478,7 @@ msgid "" "objects>`." msgstr "" -#: ../../library/sys.rst:1649 +#: ../../library/sys.rst:1650 msgid "" "Note that as an exception is propagated down the chain of callers, an " "``'exception'`` event is generated at each level." @@ -2495,7 +2486,7 @@ msgstr "" "例外が呼び出しチェインを辿って伝播していくことに注意してください。 " "``'exception'`` イベントは各レベルで発生します。" -#: ../../library/sys.rst:1652 +#: ../../library/sys.rst:1653 msgid "" "For more fine-grained usage, it's possible to set a trace function by " "assigning ``frame.f_trace = tracefunc`` explicitly, rather than relying on " @@ -2509,19 +2500,19 @@ msgid "" "on each frame)." msgstr "" -#: ../../library/sys.rst:1663 +#: ../../library/sys.rst:1664 msgid "For more information on code and frame objects, refer to :ref:`types`." msgstr "" "code と frame オブジェクトについては、 :ref:`types` を参照してください。" -#: ../../library/sys.rst:1665 +#: ../../library/sys.rst:1666 msgid "" "Raises an :ref:`auditing event ` ``sys.settrace`` with no " "arguments." msgstr "" "引数無しで :ref:`監査イベント ` ``sys.settrace`` を送出します。 " -#: ../../library/sys.rst:1669 +#: ../../library/sys.rst:1670 msgid "" "The :func:`settrace` function is intended only for implementing debuggers, " "profilers, coverage tools and the like. Its behavior is part of the " @@ -2532,13 +2523,13 @@ msgstr "" "だけのものです。この関数の挙動は言語定義よりも実装プラットフォームの分野の問" "題で、全ての Python 実装で利用できるとは限りません。" -#: ../../library/sys.rst:1676 +#: ../../library/sys.rst:1677 msgid "" "``'opcode'`` event type added; :attr:`~frame.f_trace_lines` and :attr:" "`~frame.f_trace_opcodes` attributes added to frames" msgstr "" -#: ../../library/sys.rst:1681 +#: ../../library/sys.rst:1682 msgid "" "Accepts two optional keyword arguments which are callables that accept an :" "term:`asynchronous generator iterator` as an argument. The *firstiter* " @@ -2547,7 +2538,7 @@ msgid "" "about to be garbage collected." msgstr "" -#: ../../library/sys.rst:1687 +#: ../../library/sys.rst:1688 msgid "" "Raises an :ref:`auditing event ` ``sys." "set_asyncgen_hooks_firstiter`` with no arguments." @@ -2555,7 +2546,7 @@ msgstr "" "引数無しで :ref:`監査イベント ` ``sys." "set_asyncgen_hooks_firstiter`` を送出します。 " -#: ../../library/sys.rst:1689 +#: ../../library/sys.rst:1690 msgid "" "Raises an :ref:`auditing event ` ``sys." "set_asyncgen_hooks_finalizer`` with no arguments." @@ -2563,20 +2554,20 @@ msgstr "" "引数無しで :ref:`監査イベント ` ``sys." "set_asyncgen_hooks_finalizer`` を送出します。 " -#: ../../library/sys.rst:1691 +#: ../../library/sys.rst:1692 msgid "" "Two auditing events are raised because the underlying API consists of two " "calls, each of which must raise its own event." msgstr "" -#: ../../library/sys.rst:1694 +#: ../../library/sys.rst:1695 msgid "" "See :pep:`525` for more details, and for a reference example of a " "*finalizer* method see the implementation of ``asyncio.Loop." "shutdown_asyncgens`` in :source:`Lib/asyncio/base_events.py`" msgstr "" -#: ../../library/sys.rst:1706 +#: ../../library/sys.rst:1707 msgid "" "Allows enabling or disabling coroutine origin tracking. When enabled, the " "``cr_origin`` attribute on coroutine objects will contain a tuple of " @@ -2585,82 +2576,77 @@ msgid "" "disabled, ``cr_origin`` will be ``None``." msgstr "" -#: ../../library/sys.rst:1713 +#: ../../library/sys.rst:1714 msgid "" "To enable, pass a *depth* value greater than zero; this sets the number of " "frames whose information will be captured. To disable, pass set *depth* to " "zero." msgstr "" -#: ../../library/sys.rst:1717 +#: ../../library/sys.rst:1718 msgid "This setting is thread-specific." msgstr "" -#: ../../library/sys.rst:1727 +#: ../../library/sys.rst:1728 msgid "" "Activate the stack profiler trampoline *backend*. The only supported backend " "is ``\"perf\"``." msgstr "" -#: ../../library/sys.rst:1730 ../../library/sys.rst:1745 -#: ../../library/sys.rst:1753 -msgid ":ref:`Availability `: Linux." -msgstr ":ref:`利用可能な環境 `: Linux。" - -#: ../../library/sys.rst:1736 +#: ../../library/sys.rst:1737 msgid ":ref:`perf_profiling`" msgstr "" -#: ../../library/sys.rst:1737 +#: ../../library/sys.rst:1738 msgid "https://perf.wiki.kernel.org" msgstr "" -#: ../../library/sys.rst:1741 +#: ../../library/sys.rst:1742 msgid "Deactivate the current stack profiler trampoline backend." msgstr "" -#: ../../library/sys.rst:1743 +#: ../../library/sys.rst:1744 msgid "If no stack profiler is activated, this function has no effect." msgstr "" -#: ../../library/sys.rst:1751 +#: ../../library/sys.rst:1752 msgid "Return ``True`` if a stack profiler trampoline is active." msgstr "" -#: ../../library/sys.rst:1759 +#: ../../library/sys.rst:1760 msgid "" "Changes the :term:`filesystem encoding and error handler` to 'mbcs' and " "'replace' respectively, for consistency with versions of Python prior to 3.6." msgstr "" -#: ../../library/sys.rst:1763 +#: ../../library/sys.rst:1764 msgid "" "This is equivalent to defining the :envvar:`PYTHONLEGACYWINDOWSFSENCODING` " "environment variable before launching Python." msgstr "" -#: ../../library/sys.rst:1766 +#: ../../library/sys.rst:1767 msgid "" "See also :func:`sys.getfilesystemencoding` and :func:`sys." "getfilesystemencodeerrors`." msgstr "" -#: ../../library/sys.rst:1772 +#: ../../library/sys.rst:1773 msgid "" "Changing the filesystem encoding after Python startup is risky because the " "old fsencoding or paths encoded by the old fsencoding may be cached " "somewhere. Use :envvar:`PYTHONLEGACYWINDOWSFSENCODING` instead." msgstr "" -#: ../../library/sys.rst:1776 +#: ../../library/sys.rst:1777 msgid "See :pep:`529` for more details." msgstr "より詳しくは :pep:`529` を参照してください。" -#: ../../library/sys.rst:1779 +#: ../../library/sys.rst:1780 msgid "Use :envvar:`PYTHONLEGACYWINDOWSFSENCODING` instead." msgstr "" -#: ../../library/sys.rst:1786 +#: ../../library/sys.rst:1787 msgid "" ":term:`File objects ` used by the interpreter for standard " "input, output and errors:" @@ -2668,7 +2654,7 @@ msgstr "" "インタプリタが使用する、それぞれ標準入力、標準出力、および標準エラー出力の :" "term:`ファイルオブジェクト ` です:" -#: ../../library/sys.rst:1789 +#: ../../library/sys.rst:1790 msgid "" "``stdin`` is used for all interactive input (including calls to :func:" "`input`);" @@ -2676,7 +2662,7 @@ msgstr "" "``stdin`` は (:func:`input` の呼び出しも含む) すべての対話型入力に使われま" "す。" -#: ../../library/sys.rst:1791 +#: ../../library/sys.rst:1792 msgid "" "``stdout`` is used for the output of :func:`print` and :term:`expression` " "statements and for the prompts of :func:`input`;" @@ -2684,13 +2670,13 @@ msgstr "" "``stdout`` は :func:`print` および :term:`expression` 文の出力と、:func:" "`input` のプロンプトに使用されます。" -#: ../../library/sys.rst:1793 +#: ../../library/sys.rst:1794 msgid "The interpreter's own prompts and its error messages go to ``stderr``." msgstr "" "インタプリタ自身のプロンプトおよびエラーメッセージは ``stderr`` に出力されま" "す。" -#: ../../library/sys.rst:1795 +#: ../../library/sys.rst:1796 msgid "" "These streams are regular :term:`text files ` like those returned " "by the :func:`open` function. Their parameters are chosen as follows:" @@ -2698,13 +2684,13 @@ msgstr "" "これらのストリームは :func:`open` が返すような通常の :term:`テキストファイル " "` です。引数は以下のように選択されます:" -#: ../../library/sys.rst:1799 +#: ../../library/sys.rst:1800 msgid "" "The encoding and error handling are is initialized from :c:member:`PyConfig." "stdio_encoding` and :c:member:`PyConfig.stdio_errors`." msgstr "" -#: ../../library/sys.rst:1802 +#: ../../library/sys.rst:1803 msgid "" "On Windows, UTF-8 is used for the console device. Non-character devices " "such as disk files and pipes use the system locale encoding (i.e. the ANSI " @@ -2715,14 +2701,14 @@ msgid "" "initially attached to a console." msgstr "" -#: ../../library/sys.rst:1811 +#: ../../library/sys.rst:1812 msgid "" "The special behaviour of the console can be overridden by setting the " "environment variable PYTHONLEGACYWINDOWSSTDIO before starting Python. In " "that case, the console codepages are used as for any other character device." msgstr "" -#: ../../library/sys.rst:1816 +#: ../../library/sys.rst:1817 msgid "" "Under all platforms, you can override the character encoding by setting the :" "envvar:`PYTHONIOENCODING` environment variable before starting Python or by " @@ -2731,7 +2717,7 @@ msgid "" "only applies when :envvar:`PYTHONLEGACYWINDOWSSTDIO` is also set." msgstr "" -#: ../../library/sys.rst:1823 +#: ../../library/sys.rst:1824 msgid "" "When interactive, the ``stdout`` stream is line-buffered. Otherwise, it is " "block-buffered like regular text files. The ``stderr`` stream is line-" @@ -2740,12 +2726,12 @@ msgid "" "`PYTHONUNBUFFERED` environment variable." msgstr "" -#: ../../library/sys.rst:1829 +#: ../../library/sys.rst:1830 msgid "" "Non-interactive ``stderr`` is now line-buffered instead of fully buffered." msgstr "" -#: ../../library/sys.rst:1835 +#: ../../library/sys.rst:1836 msgid "" "To write or read binary data from/to the standard streams, use the " "underlying binary :data:`~io.TextIOBase.buffer` object. For example, to " @@ -2756,7 +2742,7 @@ msgstr "" "`bytes` を :data:`stdout` に書き出す場合は ``sys.stdout.buffer." "write(b'abc')`` を使用してください。" -#: ../../library/sys.rst:1839 +#: ../../library/sys.rst:1840 msgid "" "However, if you are writing a library (and do not control in which context " "its code will be executed), be aware that the standard streams may be " @@ -2764,7 +2750,7 @@ msgid "" "support the :attr:`!buffer` attribute." msgstr "" -#: ../../library/sys.rst:1849 +#: ../../library/sys.rst:1850 msgid "" "These objects contain the original values of ``stdin``, ``stderr`` and " "``stdout`` at the start of the program. They are used during finalization, " @@ -2776,7 +2762,7 @@ msgstr "" "イクオブジェクトに)リダイレクトされている場合でも、実際の標準ストリームへの出" "力に利用できます。" -#: ../../library/sys.rst:1854 +#: ../../library/sys.rst:1855 msgid "" "It can also be used to restore the actual files to known working file " "objects in case they have been overwritten with a broken object. However, " @@ -2787,7 +2773,7 @@ msgstr "" "のファイルを復元するために利用することもできます。しかし、明示的に置き換え前" "のストリームを保存しておき、そのオブジェクトを復元する事を推奨します。" -#: ../../library/sys.rst:1860 +#: ../../library/sys.rst:1861 msgid "" "Under some conditions ``stdin``, ``stdout`` and ``stderr`` as well as the " "original values ``__stdin__``, ``__stdout__`` and ``__stderr__`` can be " @@ -2799,12 +2785,12 @@ msgstr "" "す。これはコンソールに接続しない Windows GUI アプリケーションであり、かつ :" "program:`pythonw` で起動された Python アプリケーションが該当します。" -#: ../../library/sys.rst:1868 +#: ../../library/sys.rst:1869 msgid "" "A frozenset of strings containing the names of standard library modules." msgstr "" -#: ../../library/sys.rst:1870 +#: ../../library/sys.rst:1871 msgid "" "It is the same on all platforms. Modules which are not available on some " "platforms and modules disabled at Python build are also listed. All module " @@ -2812,7 +2798,7 @@ msgid "" "modules are excluded." msgstr "" -#: ../../library/sys.rst:1875 +#: ../../library/sys.rst:1876 msgid "" "For packages, only the main package is listed: sub-packages and sub-modules " "are not listed. For example, the ``email`` package is listed, but the " @@ -2820,60 +2806,60 @@ msgid "" "listed." msgstr "" -#: ../../library/sys.rst:1880 +#: ../../library/sys.rst:1881 msgid "See also the :data:`sys.builtin_module_names` list." msgstr "" -#: ../../library/sys.rst:1887 +#: ../../library/sys.rst:1888 msgid "" "A :term:`named tuple` holding information about the thread implementation." msgstr "スレッドの実装に関する情報が格納された :term:`named tuple` です。" -#: ../../library/sys.rst:1892 +#: ../../library/sys.rst:1893 msgid "The name of the thread implementation:" msgstr "" -#: ../../library/sys.rst:1894 +#: ../../library/sys.rst:1895 msgid "``\"nt\"``: Windows threads" msgstr "" -#: ../../library/sys.rst:1895 +#: ../../library/sys.rst:1896 msgid "``\"pthread\"``: POSIX threads" msgstr "" -#: ../../library/sys.rst:1896 +#: ../../library/sys.rst:1897 msgid "" "``\"pthread-stubs\"``: stub POSIX threads (on WebAssembly platforms without " "threading support)" msgstr "" -#: ../../library/sys.rst:1898 +#: ../../library/sys.rst:1899 msgid "``\"solaris\"``: Solaris threads" msgstr "" -#: ../../library/sys.rst:1902 +#: ../../library/sys.rst:1903 msgid "The name of the lock implementation:" msgstr "" -#: ../../library/sys.rst:1904 +#: ../../library/sys.rst:1905 msgid "``\"semaphore\"``: a lock uses a semaphore" msgstr "" -#: ../../library/sys.rst:1905 +#: ../../library/sys.rst:1906 msgid "``\"mutex+cond\"``: a lock uses a mutex and a condition variable" msgstr "" -#: ../../library/sys.rst:1906 +#: ../../library/sys.rst:1907 msgid "``None`` if this information is unknown" msgstr "``None`` この情報が不明の場合" -#: ../../library/sys.rst:1910 +#: ../../library/sys.rst:1911 msgid "" "The name and version of the thread library. It is a string, or ``None`` if " "this information is unknown." msgstr "" -#: ../../library/sys.rst:1918 +#: ../../library/sys.rst:1919 msgid "" "When this variable is set to an integer value, it determines the maximum " "number of levels of traceback information printed when an unhandled " @@ -2885,73 +2871,73 @@ msgstr "" "定する整数値(デフォルト値は ``1000``)。 ``0`` 以下の値が設定された場合、ト" "レースバック情報は出力されず例外型と例外値のみが出力されます。" -#: ../../library/sys.rst:1926 +#: ../../library/sys.rst:1927 msgid "Handle an unraisable exception." msgstr "" -#: ../../library/sys.rst:1928 +#: ../../library/sys.rst:1929 msgid "" "Called when an exception has occurred but there is no way for Python to " "handle it. For example, when a destructor raises an exception or during " "garbage collection (:func:`gc.collect`)." msgstr "" -#: ../../library/sys.rst:1932 +#: ../../library/sys.rst:1933 msgid "The *unraisable* argument has the following attributes:" msgstr "" -#: ../../library/sys.rst:1934 +#: ../../library/sys.rst:1935 msgid ":attr:`!exc_type`: Exception type." msgstr "" -#: ../../library/sys.rst:1935 +#: ../../library/sys.rst:1936 msgid ":attr:`!exc_value`: Exception value, can be ``None``." msgstr "" -#: ../../library/sys.rst:1936 +#: ../../library/sys.rst:1937 msgid ":attr:`!exc_traceback`: Exception traceback, can be ``None``." msgstr "" -#: ../../library/sys.rst:1937 +#: ../../library/sys.rst:1938 msgid ":attr:`!err_msg`: Error message, can be ``None``." msgstr "" -#: ../../library/sys.rst:1938 +#: ../../library/sys.rst:1939 msgid ":attr:`!object`: Object causing the exception, can be ``None``." msgstr "" -#: ../../library/sys.rst:1940 +#: ../../library/sys.rst:1941 msgid "" "The default hook formats :attr:`!err_msg` and :attr:`!object` as: " "``f'{err_msg}: {object!r}'``; use \"Exception ignored in\" error message if :" "attr:`!err_msg` is ``None``." msgstr "" -#: ../../library/sys.rst:1944 +#: ../../library/sys.rst:1945 msgid "" ":func:`sys.unraisablehook` can be overridden to control how unraisable " "exceptions are handled." msgstr "" -#: ../../library/sys.rst:1949 +#: ../../library/sys.rst:1950 msgid ":func:`excepthook` which handles uncaught exceptions." msgstr "" -#: ../../library/sys.rst:1953 +#: ../../library/sys.rst:1954 msgid "" "Storing :attr:`!exc_value` using a custom hook can create a reference cycle. " "It should be cleared explicitly to break the reference cycle when the " "exception is no longer needed." msgstr "" -#: ../../library/sys.rst:1957 +#: ../../library/sys.rst:1958 msgid "" "Storing :attr:`!object` using a custom hook can resurrect it if it is set to " "an object which is being finalized. Avoid storing :attr:`!object` after the " "custom hook completes to avoid resurrecting objects." msgstr "" -#: ../../library/sys.rst:1961 ../../library/sys.rst:1963 +#: ../../library/sys.rst:1962 ../../library/sys.rst:1964 msgid "" "Raise an auditing event ``sys.unraisablehook`` with arguments *hook*, " "*unraisable* when an exception that cannot be handled occurs. The " @@ -2959,7 +2945,7 @@ msgid "" "hook has been set, *hook* may be ``None``." msgstr "" -#: ../../library/sys.rst:1972 +#: ../../library/sys.rst:1973 msgid "" "A string containing the version number of the Python interpreter plus " "additional information on the build number and compiler used. This string " @@ -2972,7 +2958,7 @@ msgstr "" "れます。バージョン情報はここから抜き出さずに、 :data:`version_info` および :" "mod:`platform` が提供する関数を使って下さい。" -#: ../../library/sys.rst:1981 +#: ../../library/sys.rst:1982 msgid "" "The C API version for this interpreter. Programmers may find this useful " "when debugging version conflicts between Python and extension modules." @@ -2980,7 +2966,7 @@ msgstr "" "使用中のインタプリタの C API バージョン。 Python と拡張モジュール間の不整合を" "デバッグする場合などに利用できます。" -#: ../../library/sys.rst:1987 +#: ../../library/sys.rst:1988 msgid "" "A tuple containing the five components of the version number: *major*, " "*minor*, *micro*, *releaselevel*, and *serial*. All values except " @@ -2997,11 +2983,11 @@ msgstr "" "は名前でもアクセスできるので、 ``sys.version_info[0]`` は ``sys.version_info." "major`` と等価、などになります。" -#: ../../library/sys.rst:1995 +#: ../../library/sys.rst:1996 msgid "Added named component attributes." msgstr "名前を使った要素アクセスがサポートされました。" -#: ../../library/sys.rst:2000 +#: ../../library/sys.rst:2001 msgid "" "This is an implementation detail of the warnings framework; do not modify " "this value. Refer to the :mod:`warnings` module for more information on the " @@ -3010,7 +2996,7 @@ msgstr "" "この値は、warnings フレームワーク内部のみ使用され、変更することはできません。" "詳細は :mod:`warnings` を参照してください。" -#: ../../library/sys.rst:2007 +#: ../../library/sys.rst:2008 msgid "" "The version number used to form registry keys on Windows platforms. This is " "stored as string resource 1000 in the Python DLL. The value is normally the " @@ -3019,13 +3005,13 @@ msgid "" "has no effect on the registry keys used by Python." msgstr "" -#: ../../library/sys.rst:2019 +#: ../../library/sys.rst:2020 msgid "" "Namespace containing functions and constants for register callbacks and " "controlling monitoring events. See :mod:`sys.monitoring` for details." msgstr "" -#: ../../library/sys.rst:2025 +#: ../../library/sys.rst:2026 msgid "" "A dictionary of the various implementation-specific flags passed through " "the :option:`-X` command-line option. Option names are either mapped to " @@ -3035,7 +3021,7 @@ msgstr "" "です。オプション名にはその値が明示されていればそれが、それ以外の場合は :" "const:`True` がマップされます。例えば:" -#: ../../library/sys.rst:2029 +#: ../../library/sys.rst:2030 msgid "" "$ ./python -Xa=b -Xc\n" "Python 3.2a3+ (py3k, Oct 16 2010, 20:14:50)\n" @@ -3047,7 +3033,7 @@ msgid "" "{'a': 'b', 'c': True}" msgstr "" -#: ../../library/sys.rst:2041 +#: ../../library/sys.rst:2042 msgid "" "This is a CPython-specific way of accessing options passed through :option:`-" "X`. Other implementations may export them through other means, or not at " @@ -3057,11 +3043,11 @@ msgstr "" "です。他の実装ではそれらは他の意味でエクスポートされるか、あるいは何もしませ" "ん。" -#: ../../library/sys.rst:2049 +#: ../../library/sys.rst:2050 msgid "Citations" msgstr "出典" -#: ../../library/sys.rst:2050 +#: ../../library/sys.rst:2051 msgid "" "ISO/IEC 9899:1999. \"Programming languages -- C.\" A public draft of this " "standard is available at https://www.open-std.org/jtc1/sc22/wg14/www/docs/" @@ -3083,50 +3069,50 @@ msgstr "object" msgid "traceback" msgstr "traceback" -#: ../../library/sys.rst:925 ../../library/sys.rst:1501 +#: ../../library/sys.rst:925 ../../library/sys.rst:1502 msgid "profile function" msgstr "profile function" -#: ../../library/sys.rst:925 ../../library/sys.rst:1501 +#: ../../library/sys.rst:925 ../../library/sys.rst:1502 msgid "profiler" msgstr "profiler" -#: ../../library/sys.rst:934 ../../library/sys.rst:1584 +#: ../../library/sys.rst:934 ../../library/sys.rst:1585 msgid "trace function" msgstr "trace function" -#: ../../library/sys.rst:934 ../../library/sys.rst:1584 +#: ../../library/sys.rst:934 ../../library/sys.rst:1585 msgid "debugger" msgstr "debugger" -#: ../../library/sys.rst:1329 +#: ../../library/sys.rst:1330 msgid "module" msgstr "module" -#: ../../library/sys.rst:1329 +#: ../../library/sys.rst:1330 msgid "search" msgstr "検索" -#: ../../library/sys.rst:1329 +#: ../../library/sys.rst:1330 msgid "path" msgstr "パス" -#: ../../library/sys.rst:1465 +#: ../../library/sys.rst:1466 msgid "interpreter prompts" msgstr "interpreter prompts" -#: ../../library/sys.rst:1465 +#: ../../library/sys.rst:1466 msgid "prompts, interpreter" msgstr "prompts, interpreter" -#: ../../library/sys.rst:1465 +#: ../../library/sys.rst:1466 msgid ">>>" msgstr ">>>" -#: ../../library/sys.rst:1465 +#: ../../library/sys.rst:1466 msgid "interpreter prompt" msgstr "" -#: ../../library/sys.rst:1465 +#: ../../library/sys.rst:1466 msgid "..." msgstr "..." diff --git a/library/syslog.po b/library/syslog.po index dd390b668..eb9460808 100644 --- a/library/syslog.po +++ b/library/syslog.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:14+0000\n" "Last-Translator: 渋川よしき , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -41,8 +41,8 @@ msgstr "" "を参照してください。" #: ../../library/syslog.rst:14 -msgid ":ref:`Availability `: Unix, not WASI, not iOS." -msgstr ":ref:`利用可能な環境 `: WASI 及び iOS 以外の Unix 。" +msgid "Availability" +msgstr "" #: ../../library/syslog.rst:16 msgid "" diff --git a/library/termios.po b/library/termios.po index 62a735325..66c643cf8 100644 --- a/library/termios.po +++ b/library/termios.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:14+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -43,8 +43,8 @@ msgstr "" "バージョンでのみ利用可能です。" #: ../../library/termios.rst:19 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +msgid "Availability" +msgstr "" #: ../../library/termios.rst:21 msgid "" diff --git a/library/threading.po b/library/threading.po index f402a20d3..b208ae660 100644 --- a/library/threading.po +++ b/library/threading.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:15+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -95,9 +95,10 @@ msgstr "" "ProcessPoolExecutor` の利用をお勧めします。 ただし、I/Oバウンドなタスクを並行" "して複数走らせたい場合においては、 マルチスレッドは正しい選択肢です。" -#: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +#: ../../library/threading.rst:130 ../../library/threading.rst:229 +#: ../../library/threading.rst:468 ../../includes/wasm-notavail.rst:3 +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" @@ -227,12 +228,6 @@ msgid "" "after which the value may be recycled by the OS)." msgstr "" -#: ../../library/threading.rst:130 -msgid "" -":ref:`Availability `: Windows, FreeBSD, Linux, macOS, OpenBSD, " -"NetBSD, AIX, DragonFlyBSD, GNU/kFreeBSD." -msgstr "" - #: ../../library/threading.rst:134 msgid "Added support for GNU/kFreeBSD." msgstr "" @@ -344,10 +339,6 @@ msgstr "" "トフォームに関する情報がない場合は 4096 の整数倍のスタックサイズを選ぶといい" "かもしれません)。" -#: ../../library/threading.rst:229 -msgid ":ref:`Availability `: Windows, pthreads." -msgstr ":ref:`利用可能な環境 `: Windows, pthreads。" - #: ../../library/threading.rst:231 msgid "Unix platforms with POSIX threads support." msgstr "" @@ -781,14 +772,6 @@ msgid "" "terminated." msgstr "" -#: ../../library/threading.rst:468 -msgid "" -":ref:`Availability `: Windows, FreeBSD, Linux, macOS, OpenBSD, " -"NetBSD, AIX, DragonFlyBSD." -msgstr "" -":ref:`利用可能な環境 `: Windows, FreeBSD, Linux, macOS, " -"OpenBSD, NetBSD, AIX, DragonFlyBSD。" - #: ../../library/threading.rst:474 msgid "Return whether the thread is alive." msgstr "スレッドが生存中かどうかを返します。" diff --git a/library/time.po b/library/time.po index 51a6b2094..70a7d1413 100644 --- a/library/time.po +++ b/library/time.po @@ -4,9 +4,9 @@ # FIRST AUTHOR , YEAR. # # Translators: +# Takanori Suzuki , 2021 # Osamu NAKAMURA, 2021 # Atsuo Ishimoto , 2021 -# Takanori Suzuki , 2022 # Arihiro TAKASE, 2023 # Masato HASHIMOTO , 2023 # tomo, 2024 @@ -18,7 +18,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:15+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -266,9 +266,19 @@ msgid "" "such as segmentation fault." msgstr "" -#: ../../library/time.rst:149 -msgid ":ref:`Availability `: Unix" -msgstr ":ref:`利用可能な環境 `: Unix" +#: ../../library/time.rst:149 ../../library/time.rst:161 +#: ../../library/time.rst:174 ../../library/time.rst:183 +#: ../../library/time.rst:196 ../../library/time.rst:205 +#: ../../library/time.rst:721 ../../library/time.rst:745 +#: ../../library/time.rst:841 ../../library/time.rst:852 +#: ../../library/time.rst:862 ../../library/time.rst:872 +#: ../../library/time.rst:881 ../../library/time.rst:890 +#: ../../library/time.rst:899 ../../library/time.rst:910 +#: ../../library/time.rst:918 ../../library/time.rst:929 +#: ../../library/time.rst:940 ../../library/time.rst:949 +#: ../../library/time.rst:962 +msgid "Availability" +msgstr "" #: ../../library/time.rst:151 msgid "" @@ -286,13 +296,6 @@ msgstr "" "指定された *clk_id* クロックの分解能(精度)を返します。 *clk_id* として受け付" "けられる値の一覧は :ref:`time-clock-id-constants` を参照してください。" -#: ../../library/time.rst:161 ../../library/time.rst:174 -#: ../../library/time.rst:183 ../../library/time.rst:745 -#: ../../library/time.rst:862 ../../library/time.rst:890 -#: ../../library/time.rst:918 ../../library/time.rst:962 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" - #: ../../library/time.rst:168 msgid "" "Return the time of the specified clock *clk_id*. Refer to :ref:`time-clock-" @@ -325,10 +328,6 @@ msgid "" "class:`float` type." msgstr "" -#: ../../library/time.rst:196 ../../library/time.rst:205 -msgid ":ref:`Availability `: Unix, not Android, not iOS." -msgstr "" - #: ../../library/time.rst:203 msgid "Similar to :func:`clock_settime` but set time with nanoseconds." msgstr ":func:`clock_settime` に似ていますが、ナノ秒単位の時刻を設定します。" @@ -1270,10 +1269,6 @@ msgid "" "`float` type." msgstr "" -#: ../../library/time.rst:721 -msgid ":ref:`Availability `: Linux, Unix, Windows." -msgstr "" - #: ../../library/time.rst:723 msgid "Unix systems supporting ``CLOCK_THREAD_CPUTIME_ID``." msgstr "" @@ -1480,10 +1475,6 @@ msgid "" "similar." msgstr "" -#: ../../library/time.rst:841 -msgid ":ref:`Availability `: Linux >= 2.6.39." -msgstr ":ref:`利用可能な環境 `: Linux 2.6.39以上。" - #: ../../library/time.rst:848 msgid "" "The Solaris OS has a ``CLOCK_HIGHRES`` timer that attempts to use an optimal " @@ -1494,10 +1485,6 @@ msgstr "" "する ``CLOCK_HIGHRES`` タイマーを具備しています。``CLOCK_HIGHRES`` は変更不可" "で、高分解能のクロックです。" -#: ../../library/time.rst:852 -msgid ":ref:`Availability `: Solaris." -msgstr ":ref:`利用可能な環境 `: Solaris。" - #: ../../library/time.rst:859 msgid "" "Clock that cannot be set and represents monotonic time since some " @@ -1514,29 +1501,16 @@ msgstr "" ":data:`CLOCK_MONOTONIC` と似ていますが、NTP の影響を受けていない、ハードウェ" "アベースの時刻へのアクセスを提供します。" -#: ../../library/time.rst:872 -msgid ":ref:`Availability `: Linux >= 2.6.28, macOS >= 10.12." -msgstr "" - #: ../../library/time.rst:878 msgid "" "Similar to :data:`CLOCK_MONOTONIC_RAW`, but reads a value cached by the " "system at context switch and hence has less accuracy." msgstr "" -#: ../../library/time.rst:881 ../../library/time.rst:940 -#: ../../library/time.rst:949 -msgid ":ref:`Availability `: macOS >= 10.12." -msgstr "" - #: ../../library/time.rst:888 ../../library/time.rst:897 msgid "High-resolution per-process timer from the CPU." msgstr "CPU による高分解能のプロセスごとのタイマーです。" -#: ../../library/time.rst:899 -msgid ":ref:`Availability `: FreeBSD, NetBSD >= 7, OpenBSD." -msgstr "" - #: ../../library/time.rst:905 msgid "" "`International Atomic Time `: Linux." -msgstr ":ref:`利用可能な環境 `: Linux。" - #: ../../library/time.rst:916 msgid "Thread-specific CPU-time clock." msgstr "スレッド固有の CPU タイムクロックです。" @@ -1563,10 +1533,6 @@ msgid "" "suspended, providing accurate uptime measurement, both absolute and interval." msgstr "" -#: ../../library/time.rst:929 -msgid ":ref:`Availability `: FreeBSD, OpenBSD >= 5.5." -msgstr "" - #: ../../library/time.rst:936 msgid "" "Clock that increments monotonically, tracking the time since an arbitrary " diff --git a/library/traceback.po b/library/traceback.po index 433f019e0..5945b1d11 100644 --- a/library/traceback.po +++ b/library/traceback.po @@ -4,21 +4,21 @@ # FIRST AUTHOR , YEAR. # # Translators: -# tomo, 2023 # Arihiro TAKASE, 2023 # Takanori Suzuki , 2024 # Takeshi Nakazato, 2024 # Taichi Haradaguchi, 2024 # 石井明久, 2024 +# tomo, 2024 # #, fuzzy msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:16+0000\n" -"Last-Translator: 石井明久, 2024\n" +"Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" "ja/)\n" "MIME-Version: 1.0\n" @@ -38,18 +38,16 @@ msgstr "**ソースコード:** :source:`Lib/traceback.py`" #: ../../library/traceback.rst:11 msgid "" "This module provides a standard interface to extract, format and print stack " -"traces of Python programs. It exactly mimics the behavior of the Python " -"interpreter when it prints a stack trace. This is useful when you want to " -"print stack traces under program control, such as in a \"wrapper\" around " -"the interpreter." +"traces of Python programs. It is more flexible than the interpreter's " +"default traceback display, and therefore makes it possible to configure " +"certain aspects of the output. Finally, it contains a utility for capturing " +"enough information about an exception to print it later, without the need to " +"save a reference to the actual exception. Since exceptions can be the roots " +"of large objects graph, this utility can significantly improve memory " +"management." msgstr "" -"このモジュールは Python プログラムのスタックトレースを抽出し、書式を整え、表" -"示するための標準インターフェースを提供します。モジュールがスタックトレースを" -"表示するとき、Python インタープリタの動作を正確に模倣します。インタープリタの" -"\"ラッパー\"の場合のように、プログラムの制御の元でスタックトレースを表示した" -"いと思ったときに役に立ちます。" -#: ../../library/traceback.rst:19 +#: ../../library/traceback.rst:23 msgid "" "The module uses :ref:`traceback objects ` --- these are " "objects of type :class:`types.TracebackType`, which are assigned to the :" @@ -57,29 +55,48 @@ msgid "" "instances." msgstr "" -#: ../../library/traceback.rst:26 +#: ../../library/traceback.rst:30 msgid "Module :mod:`faulthandler`" msgstr ":mod:`faulthandler` モジュール" -#: ../../library/traceback.rst:27 +#: ../../library/traceback.rst:31 msgid "" "Used to dump Python tracebacks explicitly, on a fault, after a timeout, or " "on a user signal." msgstr "" -#: ../../library/traceback.rst:29 +#: ../../library/traceback.rst:33 msgid "Module :mod:`pdb`" msgstr "" -#: ../../library/traceback.rst:30 +#: ../../library/traceback.rst:34 msgid "Interactive source code debugger for Python programs." msgstr "" -#: ../../library/traceback.rst:32 -msgid "The module defines the following functions:" -msgstr "このモジュールには、以下の関数が定義されています:" - #: ../../library/traceback.rst:36 +msgid "The module's API can be divided into two parts:" +msgstr "" + +#: ../../library/traceback.rst:38 +msgid "" +"Module-level functions offering basic functionality, which are useful for " +"interactive inspection of exceptions and tracebacks." +msgstr "" + +#: ../../library/traceback.rst:41 +msgid "" +":class:`TracebackException` class and its helper classes :class:" +"`StackSummary` and :class:`FrameSummary`. These offer both more flexibility " +"in the output generated and the ability to store the information necessary " +"for later formatting without holding references to actual exception and " +"traceback objects." +msgstr "" + +#: ../../library/traceback.rst:49 +msgid "Module-Level Functions" +msgstr "モジュールレベルの関数" + +#: ../../library/traceback.rst:53 msgid "" "Print up to *limit* stack trace entries from :ref:`traceback object " "` *tb* (starting from the caller's frame) if *limit* is " @@ -90,7 +107,7 @@ msgid "" "output." msgstr "" -#: ../../library/traceback.rst:47 +#: ../../library/traceback.rst:64 msgid "" "The meaning of the *limit* parameter is different than the meaning of :const:" "`sys.tracebacklimit`. A negative *limit* value corresponds to a positive " @@ -98,18 +115,18 @@ msgid "" "*limit* value cannot be achieved with :const:`!sys.tracebacklimit`." msgstr "" -#: ../../library/traceback.rst:53 ../../library/traceback.rst:118 +#: ../../library/traceback.rst:70 ../../library/traceback.rst:135 msgid "Added negative *limit* support." msgstr "負の *limit* がサポートされました。" -#: ../../library/traceback.rst:60 +#: ../../library/traceback.rst:77 msgid "" "Print exception information and stack trace entries from :ref:`traceback " "object ` *tb* to *file*. This differs from :func:" "`print_tb` in the following ways:" msgstr "" -#: ../../library/traceback.rst:65 +#: ../../library/traceback.rst:82 msgid "" "if *tb* is not ``None``, it prints a header ``Traceback (most recent call " "last):``" @@ -117,11 +134,11 @@ msgstr "" "*tb* が ``None`` でない場合ヘッダ ``Traceback (most recent call last):`` を出" "力します" -#: ../../library/traceback.rst:68 +#: ../../library/traceback.rst:85 msgid "it prints the exception type and *value* after the stack trace" msgstr "" -#: ../../library/traceback.rst:72 +#: ../../library/traceback.rst:89 msgid "" "if *type(value)* is :exc:`SyntaxError` and *value* has the appropriate " "format, it prints the line where the syntax error occurred with a caret " @@ -131,14 +148,14 @@ msgstr "" "ば、そのエラーのおおよその位置を示すマークと共にシンタックスエラーが発生した" "行が表示されます。" -#: ../../library/traceback.rst:76 +#: ../../library/traceback.rst:93 msgid "" "Since Python 3.10, instead of passing *value* and *tb*, an exception object " "can be passed as the first argument. If *value* and *tb* are provided, the " "first argument is ignored in order to provide backwards compatibility." msgstr "" -#: ../../library/traceback.rst:80 +#: ../../library/traceback.rst:97 msgid "" "The optional *limit* argument has the same meaning as for :func:`print_tb`. " "If *chain* is true (the default), then chained exceptions (the :attr:" @@ -147,30 +164,30 @@ msgid "" "when printing an unhandled exception." msgstr "" -#: ../../library/traceback.rst:87 ../../library/traceback.rst:191 +#: ../../library/traceback.rst:104 ../../library/traceback.rst:208 msgid "The *etype* argument is ignored and inferred from the type of *value*." msgstr "引数 *etype* は無視され、 *value* の型から推論されます。" -#: ../../library/traceback.rst:90 ../../library/traceback.rst:171 +#: ../../library/traceback.rst:107 ../../library/traceback.rst:188 msgid "" "The *etype* parameter has been renamed to *exc* and is now positional-only." msgstr "" -#: ../../library/traceback.rst:97 +#: ../../library/traceback.rst:114 msgid "" "This is a shorthand for ``print_exception(sys.exception(), limit, file, " "chain)``." msgstr "" "``print_exception(sys.exception(), limit, file, chain)`` の省略表現です。" -#: ../../library/traceback.rst:103 +#: ../../library/traceback.rst:120 msgid "" "This is a shorthand for ``print_exception(sys.last_exc, limit, file, " "chain)``. In general it will work only after an exception has reached an " "interactive prompt (see :data:`sys.last_exc`)." msgstr "" -#: ../../library/traceback.rst:110 +#: ../../library/traceback.rst:127 msgid "" "Print up to *limit* stack trace entries (starting from the invocation point) " "if *limit* is positive. Otherwise, print the last ``abs(limit)`` entries. " @@ -180,7 +197,7 @@ msgid "" "for :func:`print_tb`." msgstr "" -#: ../../library/traceback.rst:124 +#: ../../library/traceback.rst:141 msgid "" "Return a :class:`StackSummary` object representing a list of \"pre-" "processed\" stack trace entries extracted from the :ref:`traceback object " @@ -193,7 +210,7 @@ msgid "" "for a stack trace." msgstr "" -#: ../../library/traceback.rst:137 +#: ../../library/traceback.rst:154 msgid "" "Extract the raw traceback from the current :ref:`stack frame `. The return value has the same format as for :func:`extract_tb`. " @@ -201,7 +218,7 @@ msgid "" "`print_stack`." msgstr "" -#: ../../library/traceback.rst:145 +#: ../../library/traceback.rst:162 msgid "" "Given a list of tuples or :class:`FrameSummary` objects as returned by :func:" "`extract_tb` or :func:`extract_stack`, return a list of strings ready for " @@ -217,7 +234,7 @@ msgstr "" "ソーステキスト行が ``None`` でないそれらの要素に対しては、文字列は内部に改行" "を含んでいるかもしれません。" -#: ../../library/traceback.rst:155 +#: ../../library/traceback.rst:172 msgid "" "Format the exception part of a traceback using an exception value such as " "given by :data:`sys.last_value`. The return value is a list of strings, " @@ -228,31 +245,31 @@ msgid "" "contains the exception's :attr:`notes `." msgstr "" -#: ../../library/traceback.rst:163 +#: ../../library/traceback.rst:180 msgid "" "Since Python 3.10, instead of passing *value*, an exception object can be " "passed as the first argument. If *value* is provided, the first argument is " "ignored in order to provide backwards compatibility." msgstr "" -#: ../../library/traceback.rst:167 ../../library/traceback.rst:394 +#: ../../library/traceback.rst:184 ../../library/traceback.rst:415 msgid "" "When *show_group* is ``True``, and the exception is an instance of :exc:" "`BaseExceptionGroup`, the nested exceptions are included as well, " "recursively, with indentation relative to their nesting depth." msgstr "" -#: ../../library/traceback.rst:175 +#: ../../library/traceback.rst:192 msgid "" "The returned list now includes any :attr:`notes ` " "attached to the exception." msgstr "" -#: ../../library/traceback.rst:179 +#: ../../library/traceback.rst:196 msgid "*show_group* parameter was added." msgstr "" -#: ../../library/traceback.rst:185 +#: ../../library/traceback.rst:202 msgid "" "Format a stack trace and the exception information. The arguments have the " "same meaning as the corresponding arguments to :func:`print_exception`. The " @@ -265,13 +282,13 @@ msgstr "" "改行で終わり、そのいくつかは内部に改行を含みます。これらの行が連結されて出力" "される場合は、厳密に :func:`print_exception` と同じテキストが出力されます。" -#: ../../library/traceback.rst:194 +#: ../../library/traceback.rst:211 msgid "" "This function's behavior and signature were modified to match :func:" "`print_exception`." msgstr "" -#: ../../library/traceback.rst:201 +#: ../../library/traceback.rst:218 msgid "" "This is like ``print_exc(limit)`` but returns a string instead of printing " "to a file." @@ -279,59 +296,57 @@ msgstr "" "これは、``print_exc(limit)`` に似ていますが、ファイルに出力する代わりに文字列" "を返します。" -#: ../../library/traceback.rst:207 +#: ../../library/traceback.rst:224 msgid "A shorthand for ``format_list(extract_tb(tb, limit))``." msgstr "``format_list(extract_tb(tb, limit))`` の省略表現です。" -#: ../../library/traceback.rst:212 +#: ../../library/traceback.rst:229 msgid "A shorthand for ``format_list(extract_stack(f, limit))``." msgstr "``format_list(extract_stack(f, limit))`` の省略表現です。" -#: ../../library/traceback.rst:216 +#: ../../library/traceback.rst:233 msgid "" "Clears the local variables of all the stack frames in a :ref:`traceback " "` *tb* by calling the :meth:`~frame.clear` method of " "each :ref:`frame object `." msgstr "" -#: ../../library/traceback.rst:225 +#: ../../library/traceback.rst:242 msgid "" "Walk a stack following :attr:`f.f_back ` from the given frame, " "yielding the frame and line number for each frame. If *f* is ``None``, the " "current stack is used. This helper is used with :meth:`StackSummary.extract`." msgstr "" -#: ../../library/traceback.rst:234 +#: ../../library/traceback.rst:251 msgid "" "Walk a traceback following :attr:`~traceback.tb_next` yielding the frame and " "line number for each frame. This helper is used with :meth:`StackSummary." "extract`." msgstr "" -#: ../../library/traceback.rst:240 -msgid "The module also defines the following classes:" -msgstr "このモジュールは以下のクラスも定義しています:" - -#: ../../library/traceback.rst:243 +#: ../../library/traceback.rst:259 msgid ":class:`!TracebackException` Objects" msgstr ":class:`!TracebackException` オブジェクト" -#: ../../library/traceback.rst:247 +#: ../../library/traceback.rst:263 msgid "" ":class:`!TracebackException` objects are created from actual exceptions to " -"capture data for later printing in a lightweight fashion." +"capture data for later printing. They offer a more lightweight method of " +"storing this information by avoiding holding references to :ref:" +"`traceback` and :ref:`frame` objects In " +"addition, they expose more options to configure the output compared to the " +"module-level functions described above." msgstr "" -#: ../../library/traceback.rst:252 ../../library/traceback.rst:359 +#: ../../library/traceback.rst:272 msgid "" -"Capture an exception for later rendering. *limit*, *lookup_lines* and " -"*capture_locals* are as for the :class:`StackSummary` class." +"Capture an exception for later rendering. The meaning of *limit*, " +"*lookup_lines* and *capture_locals* are as for the :class:`StackSummary` " +"class." msgstr "" -"後のレンダリングのために例外をキャプチャします。\n" -"*limit*、*lookup_lines*、*capture_locals* は :class:`StackSummary` class のも" -"のです。" -#: ../../library/traceback.rst:255 +#: ../../library/traceback.rst:276 msgid "" "If *compact* is true, only data that is required by :class:`!" "TracebackException`'s :meth:`format` method is saved in the class " @@ -339,14 +354,14 @@ msgid "" "if :attr:`__cause__` is ``None`` and :attr:`__suppress_context__` is false." msgstr "" -#: ../../library/traceback.rst:261 ../../library/traceback.rst:362 +#: ../../library/traceback.rst:282 ../../library/traceback.rst:383 msgid "" "Note that when locals are captured, they are also shown in the traceback." msgstr "" "局所変数がキャプチャされたとき、それらはトレースバックに表示されることに注意" "してください。" -#: ../../library/traceback.rst:263 +#: ../../library/traceback.rst:284 msgid "" "*max_group_width* and *max_group_depth* control the formatting of exception " "groups (see :exc:`BaseExceptionGroup`). The depth refers to the nesting " @@ -355,107 +370,116 @@ msgid "" "limit is exceeded." msgstr "" -#: ../../library/traceback.rst:269 +#: ../../library/traceback.rst:290 msgid "Added the *compact* parameter." msgstr "*compact* 引数が追加されました。" -#: ../../library/traceback.rst:272 +#: ../../library/traceback.rst:293 msgid "Added the *max_group_width* and *max_group_depth* parameters." msgstr "" -#: ../../library/traceback.rst:277 +#: ../../library/traceback.rst:298 msgid "" "A :class:`!TracebackException` of the original :attr:`~BaseException." "__cause__`." msgstr "" -#: ../../library/traceback.rst:282 +#: ../../library/traceback.rst:303 msgid "" "A :class:`!TracebackException` of the original :attr:`~BaseException." "__context__`." msgstr "" -#: ../../library/traceback.rst:287 +#: ../../library/traceback.rst:308 msgid "" "If ``self`` represents an :exc:`ExceptionGroup`, this field holds a list of :" "class:`!TracebackException` instances representing the nested exceptions. " "Otherwise it is ``None``." msgstr "" -#: ../../library/traceback.rst:295 +#: ../../library/traceback.rst:316 msgid "" "The :attr:`~BaseException.__suppress_context__` value from the original " "exception." msgstr "" -#: ../../library/traceback.rst:300 +#: ../../library/traceback.rst:321 msgid "" "The :attr:`~BaseException.__notes__` value from the original exception, or " "``None`` if the exception does not have any notes. If it is not ``None`` is " "it formatted in the traceback after the exception string." msgstr "" -#: ../../library/traceback.rst:309 +#: ../../library/traceback.rst:330 msgid "A :class:`StackSummary` representing the traceback." msgstr "トレースバックを表す :class:`StackSummary`。" -#: ../../library/traceback.rst:313 +#: ../../library/traceback.rst:334 msgid "The class of the original traceback." msgstr "元々のトレースバックのクラス。" -#: ../../library/traceback.rst:319 +#: ../../library/traceback.rst:340 msgid "String display of the class of the original exception." msgstr "" -#: ../../library/traceback.rst:325 +#: ../../library/traceback.rst:346 msgid "For syntax errors - the file name where the error occurred." msgstr "構文エラー用 - エラーが発生したファイルの名前。" -#: ../../library/traceback.rst:329 +#: ../../library/traceback.rst:350 msgid "For syntax errors - the line number where the error occurred." msgstr "構文エラー用 - エラーが発生した行番号。" -#: ../../library/traceback.rst:333 +#: ../../library/traceback.rst:354 msgid "" "For syntax errors - the end line number where the error occurred. Can be " "``None`` if not present." msgstr "" -#: ../../library/traceback.rst:340 +#: ../../library/traceback.rst:361 msgid "For syntax errors - the text where the error occurred." msgstr "構文エラー用 - エラーが発生したテクスト。" -#: ../../library/traceback.rst:344 +#: ../../library/traceback.rst:365 msgid "For syntax errors - the offset into the text where the error occurred." msgstr "構文エラー用 - エラーが発生したテクストへのオフセット。" -#: ../../library/traceback.rst:348 +#: ../../library/traceback.rst:369 msgid "" "For syntax errors - the end offset into the text where the error occurred. " "Can be ``None`` if not present." msgstr "" -#: ../../library/traceback.rst:355 +#: ../../library/traceback.rst:376 msgid "For syntax errors - the compiler error message." msgstr "構文エラー用 - コンパイラのエラーメッセージ。" -#: ../../library/traceback.rst:366 +#: ../../library/traceback.rst:380 +msgid "" +"Capture an exception for later rendering. *limit*, *lookup_lines* and " +"*capture_locals* are as for the :class:`StackSummary` class." +msgstr "" +"後のレンダリングのために例外をキャプチャします。\n" +"*limit*、*lookup_lines*、*capture_locals* は :class:`StackSummary` class のも" +"のです。" + +#: ../../library/traceback.rst:387 msgid "" "Print to *file* (default ``sys.stderr``) the exception information returned " "by :meth:`format`." msgstr "" -#: ../../library/traceback.rst:373 +#: ../../library/traceback.rst:394 msgid "Format the exception." msgstr "例外を書式化します。" -#: ../../library/traceback.rst:375 +#: ../../library/traceback.rst:396 msgid "" "If *chain* is not ``True``, :attr:`__cause__` and :attr:`__context__` will " "not be formatted." msgstr "" -#: ../../library/traceback.rst:378 +#: ../../library/traceback.rst:399 msgid "" "The return value is a generator of strings, each ending in a newline and " "some containing internal newlines. :func:`~traceback.print_exception` is a " @@ -466,15 +490,15 @@ msgstr "" ":func:`~traceback.print_exception` はこのメソッドのラッパで、単にファイルに出" "力します。" -#: ../../library/traceback.rst:384 +#: ../../library/traceback.rst:405 msgid "Format the exception part of the traceback." msgstr "トレースバックの例外部を書式化します。" -#: ../../library/traceback.rst:386 +#: ../../library/traceback.rst:407 msgid "The return value is a generator of strings, each ending in a newline." msgstr "返り値は文字列のジェネレータで、それぞれ改行で終わります。" -#: ../../library/traceback.rst:388 +#: ../../library/traceback.rst:409 msgid "" "When *show_group* is ``False``, the generator emits the exception's message " "followed by its notes (if it has any). The exception message is normally a " @@ -483,32 +507,32 @@ msgid "" "the syntax error occurred." msgstr "" -#: ../../library/traceback.rst:398 +#: ../../library/traceback.rst:419 msgid "" "The exception's :attr:`notes ` are now included in " "the output." msgstr "" -#: ../../library/traceback.rst:402 +#: ../../library/traceback.rst:423 msgid "Added the *show_group* parameter." msgstr "" -#: ../../library/traceback.rst:407 +#: ../../library/traceback.rst:428 msgid ":class:`!StackSummary` Objects" msgstr ":class:`!StackSummary` オブジェクト" -#: ../../library/traceback.rst:411 +#: ../../library/traceback.rst:432 msgid "" ":class:`!StackSummary` objects represent a call stack ready for formatting." msgstr "" -#: ../../library/traceback.rst:417 +#: ../../library/traceback.rst:438 msgid "" "Construct a :class:`!StackSummary` object from a frame generator (such as is " "returned by :func:`~traceback.walk_stack` or :func:`~traceback.walk_tb`)." msgstr "" -#: ../../library/traceback.rst:421 +#: ../../library/traceback.rst:442 msgid "" "If *limit* is supplied, only this many frames are taken from *frame_gen*. If " "*lookup_lines* is ``False``, the returned :class:`FrameSummary` objects will " @@ -518,20 +542,20 @@ msgid "" "class:`!FrameSummary` are captured as object representations." msgstr "" -#: ../../library/traceback.rst:429 +#: ../../library/traceback.rst:450 msgid "" "Exceptions raised from :func:`repr` on a local variable (when " "*capture_locals* is ``True``) are no longer propagated to the caller." msgstr "" -#: ../../library/traceback.rst:435 +#: ../../library/traceback.rst:456 msgid "" "Construct a :class:`!StackSummary` object from a supplied list of :class:" "`FrameSummary` objects or old-style list of tuples. Each tuple should be a " "4-tuple with *filename*, *lineno*, *name*, *line* as the elements." msgstr "" -#: ../../library/traceback.rst:442 +#: ../../library/traceback.rst:463 msgid "" "Returns a list of strings ready for printing. Each string in the resulting " "list corresponds to a single :ref:`frame ` from the stack. " @@ -539,18 +563,18 @@ msgid "" "well, for those items with source text lines." msgstr "" -#: ../../library/traceback.rst:448 +#: ../../library/traceback.rst:469 msgid "" "For long sequences of the same frame and line, the first few repetitions are " "shown, followed by a summary line stating the exact number of further " "repetitions." msgstr "" -#: ../../library/traceback.rst:452 +#: ../../library/traceback.rst:473 msgid "Long sequences of repeated frames are now abbreviated." msgstr "" -#: ../../library/traceback.rst:457 +#: ../../library/traceback.rst:478 msgid "" "Returns a string for printing one of the :ref:`frames ` " "involved in the stack. This method is called for each :class:`FrameSummary` " @@ -558,17 +582,17 @@ msgid "" "the frame is omitted from the output." msgstr "" -#: ../../library/traceback.rst:467 +#: ../../library/traceback.rst:488 msgid ":class:`!FrameSummary` Objects" msgstr ":class:`!FrameSummary` オブジェクト" -#: ../../library/traceback.rst:471 +#: ../../library/traceback.rst:492 msgid "" "A :class:`!FrameSummary` object represents a single :ref:`frame ` in a :ref:`traceback `." msgstr "" -#: ../../library/traceback.rst:476 +#: ../../library/traceback.rst:497 msgid "" "Represents a single :ref:`frame ` in the :ref:`traceback " "` or stack that is being formatted or printed. It may " @@ -582,38 +606,38 @@ msgid "" "display." msgstr "" -#: ../../library/traceback.rst:487 +#: ../../library/traceback.rst:508 msgid ":class:`!FrameSummary` instances have the following attributes:" msgstr "" -#: ../../library/traceback.rst:491 +#: ../../library/traceback.rst:512 msgid "" "The filename of the source code for this frame. Equivalent to accessing :" "attr:`f.f_code.co_filename ` on a :ref:`frame object " "` *f*." msgstr "" -#: ../../library/traceback.rst:497 +#: ../../library/traceback.rst:518 msgid "The line number of the source code for this frame." msgstr "" -#: ../../library/traceback.rst:501 +#: ../../library/traceback.rst:522 msgid "" "Equivalent to accessing :attr:`f.f_code.co_name ` on a :" "ref:`frame object ` *f*." msgstr "" -#: ../../library/traceback.rst:506 +#: ../../library/traceback.rst:527 msgid "" "A string representing the source code for this frame, with leading and " "trailing whitespace stripped. If the source is not available, it is ``None``." msgstr "" -#: ../../library/traceback.rst:513 -msgid "Traceback Examples" -msgstr "トレースバックの例" +#: ../../library/traceback.rst:534 +msgid "Examples of Using the Module-Level Functions" +msgstr "" -#: ../../library/traceback.rst:515 +#: ../../library/traceback.rst:536 msgid "" "This simple example implements a basic read-eval-print loop, similar to (but " "less useful than) the standard Python interactive interpreter loop. For a " @@ -625,7 +649,7 @@ msgstr "" "りません。インタープリタループのより完全な実装については、 :mod:`code` モ" "ジュールを参照してください。 ::" -#: ../../library/traceback.rst:520 +#: ../../library/traceback.rst:541 msgid "" "import sys, traceback\n" "\n" @@ -644,13 +668,13 @@ msgid "" " run_user_code(envdir)" msgstr "" -#: ../../library/traceback.rst:537 +#: ../../library/traceback.rst:558 msgid "" "The following example demonstrates the different ways to print and format " "the exception and traceback:" msgstr "次の例は例外とトレースバックの出力並びに形式が異なることを示します:" -#: ../../library/traceback.rst:540 +#: ../../library/traceback.rst:561 msgid "" "import sys, traceback\n" "\n" @@ -662,8 +686,7 @@ msgid "" "\n" "try:\n" " lumberjack()\n" -"except IndexError:\n" -" exc = sys.exception()\n" +"except IndexError as exc:\n" " print(\"*** print_tb:\")\n" " traceback.print_tb(exc.__traceback__, limit=1, file=sys.stdout)\n" " print(\"*** print_exception:\")\n" @@ -683,11 +706,11 @@ msgid "" " print(\"*** tb_lineno:\", exc.__traceback__.tb_lineno)" msgstr "" -#: ../../library/traceback.rst:572 +#: ../../library/traceback.rst:592 msgid "The output for the example would look similar to this:" msgstr "この例の出力は次のようになります:" -#: ../../library/traceback.rst:574 +#: ../../library/traceback.rst:594 msgid "" "*** print_tb:\n" " File \"\", line 10, in \n" @@ -737,13 +760,13 @@ msgid "" "*** tb_lineno: 10" msgstr "" -#: ../../library/traceback.rst:619 +#: ../../library/traceback.rst:639 msgid "" "The following example shows the different ways to print and format the " "stack::" msgstr "次の例は、スタックの print と format の違いを示しています::" -#: ../../library/traceback.rst:621 +#: ../../library/traceback.rst:641 msgid "" ">>> import traceback\n" ">>> def another_function():\n" @@ -771,11 +794,11 @@ msgid "" "format_stack()))\\n']" msgstr "" -#: ../../library/traceback.rst:645 +#: ../../library/traceback.rst:665 msgid "This last example demonstrates the final few formatting functions:" msgstr "最後の例は、残りの幾つかの関数のデモをします:" -#: ../../library/traceback.rst:647 +#: ../../library/traceback.rst:667 msgid "" ">>> import traceback\n" ">>> traceback.format_list([('spam.py', 3, '', 'spam.eggs()'),\n" @@ -783,22 +806,110 @@ msgid "" "[' File \"spam.py\", line 3, in \\n spam.eggs()\\n',\n" " ' File \"eggs.py\", line 42, in eggs\\n return \"bacon\"\\n']\n" ">>> an_error = IndexError('tuple index out of range')\n" -">>> traceback.format_exception_only(type(an_error), an_error)\n" +">>> traceback.format_exception_only(an_error)\n" "['IndexError: tuple index out of range\\n']" msgstr "" -#: ../../library/traceback.rst:17 +#: ../../library/traceback.rst:681 +msgid "Examples of Using :class:`TracebackException`" +msgstr "" + +#: ../../library/traceback.rst:683 +msgid "With the helper class, we have more options::" +msgstr "" + +#: ../../library/traceback.rst:685 +msgid "" +">>> import sys\n" +">>> from traceback import TracebackException\n" +">>>\n" +">>> def lumberjack():\n" +"... bright_side_of_life()\n" +"...\n" +">>> def bright_side_of_life():\n" +"... t = \"bright\", \"side\", \"of\", \"life\"\n" +"... return t[5]\n" +"...\n" +">>> try:\n" +"... lumberjack()\n" +"... except IndexError as e:\n" +"... exc = e\n" +"...\n" +">>> try:\n" +"... try:\n" +"... lumberjack()\n" +"... except:\n" +"... 1/0\n" +"... except Exception as e:\n" +"... chained_exc = e\n" +"...\n" +">>> # limit works as with the module-level functions\n" +">>> TracebackException.from_exception(exc, limit=-2).print()\n" +"Traceback (most recent call last):\n" +" File \"\", line 6, in lumberjack\n" +" bright_side_of_life()\n" +" ~~~~~~~~~~~~~~~~~~~^^\n" +" File \"\", line 10, in bright_side_of_life\n" +" return t[5]\n" +" ~^^^\n" +"IndexError: tuple index out of range\n" +"\n" +">>> # capture_locals adds local variables in frames\n" +">>> TracebackException.from_exception(exc, limit=-2, capture_locals=True)." +"print()\n" +"Traceback (most recent call last):\n" +" File \"\", line 6, in lumberjack\n" +" bright_side_of_life()\n" +" ~~~~~~~~~~~~~~~~~~~^^\n" +" File \"\", line 10, in bright_side_of_life\n" +" return t[5]\n" +" ~^^^\n" +" t = (\"bright\", \"side\", \"of\", \"life\")\n" +"IndexError: tuple index out of range\n" +"\n" +">>> # The *chain* kwarg to print() controls whether chained\n" +">>> # exceptions are displayed\n" +">>> TracebackException.from_exception(chained_exc).print()\n" +"Traceback (most recent call last):\n" +" File \"\", line 4, in \n" +" lumberjack()\n" +" ~~~~~~~~~~^^\n" +" File \"\", line 7, in lumberjack\n" +" bright_side_of_life()\n" +" ~~~~~~~~~~~~~~~~~~~^^\n" +" File \"\", line 11, in bright_side_of_life\n" +" return t[5]\n" +" ~^^^\n" +"IndexError: tuple index out of range\n" +"\n" +"During handling of the above exception, another exception occurred:\n" +"\n" +"Traceback (most recent call last):\n" +" File \"\", line 6, in \n" +" 1/0\n" +" ~^~\n" +"ZeroDivisionError: division by zero\n" +"\n" +">>> TracebackException.from_exception(chained_exc).print(chain=False)\n" +"Traceback (most recent call last):\n" +" File \"\", line 6, in \n" +" 1/0\n" +" ~^~\n" +"ZeroDivisionError: division by zero" +msgstr "" + +#: ../../library/traceback.rst:21 msgid "object" msgstr "object" -#: ../../library/traceback.rst:17 +#: ../../library/traceback.rst:21 msgid "traceback" msgstr "traceback" -#: ../../library/traceback.rst:70 +#: ../../library/traceback.rst:87 msgid "^ (caret)" msgstr "^ (キャレット)" -#: ../../library/traceback.rst:70 +#: ../../library/traceback.rst:87 msgid "marker" msgstr "" diff --git a/library/tty.po b/library/tty.po index 4fa7a28c2..041e22955 100644 --- a/library/tty.po +++ b/library/tty.po @@ -4,8 +4,8 @@ # FIRST AUTHOR , YEAR. # # Translators: +# tomo, 2021 # Osamu NAKAMURA, 2021 -# tomo, 2023 # 石井明久, 2024 # #, fuzzy @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:16+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -41,8 +41,8 @@ msgstr "" "しています。" #: ../../library/tty.rst:18 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" +msgid "Availability" +msgstr "" #: ../../library/tty.rst:20 msgid "" diff --git a/library/types.po b/library/types.po index a0f8bcfdf..8d4028684 100644 --- a/library/types.po +++ b/library/types.po @@ -17,7 +17,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:16+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -325,7 +325,7 @@ msgstr "" #: ../../library/types.rst:201 msgid "" "The type for cell objects: such objects are used as containers for a " -"function's free variables." +"function's :term:`closure variables `." msgstr "" #: ../../library/types.rst:209 @@ -377,97 +377,47 @@ msgstr "" ":term:`module` の型です。コンストラクタは生成するモジュールの名前と任意でそ" "の :term:`docstring` を受け取ります。" -#: ../../library/types.rst:264 -msgid "" -"Use :func:`importlib.util.module_from_spec` to create a new module if you " -"wish to set the various import-controlled attributes." -msgstr "" -"インポートによりコントロールされる様々な属性を設定する場合、:func:`importlib." -"util.module_from_spec` を使用して新しいモジュールを作成してください。" - -#: ../../library/types.rst:269 -msgid "The :term:`docstring` of the module. Defaults to ``None``." -msgstr "モジュールの :term:`docstring` です。デフォルトは ``None`` です。" - -#: ../../library/types.rst:273 -msgid "The :term:`loader` which loaded the module. Defaults to ``None``." -msgstr "" -"モジュールをロードする :term:`loader` です。デフォルトは ``None`` です。" - -#: ../../library/types.rst:275 -msgid "" -"This attribute is to match :attr:`importlib.machinery.ModuleSpec.loader` as " -"stored in the :attr:`__spec__` object." -msgstr "" - -#: ../../library/types.rst:279 -msgid "" -"A future version of Python may stop setting this attribute by default. To " -"guard against this potential change, preferably read from the :attr:" -"`__spec__` attribute instead or use ``getattr(module, \"__loader__\", " -"None)`` if you explicitly need to use this attribute." -msgstr "" - -#: ../../library/types.rst:285 ../../library/types.rst:310 -msgid "Defaults to ``None``. Previously the attribute was optional." -msgstr "デフォルトが ``None`` になりました。以前はオプションでした。" - -#: ../../library/types.rst:290 -msgid "" -"The name of the module. Expected to match :attr:`importlib.machinery." -"ModuleSpec.name`." -msgstr "" - -#: ../../library/types.rst:295 -msgid "" -"Which :term:`package` a module belongs to. If the module is top-level (i.e. " -"not a part of any specific package) then the attribute should be set to " -"``''``, else it should be set to the name of the package (which can be :attr:" -"`__name__` if the module is a package itself). Defaults to ``None``." +#: ../../library/types.rst:265 +msgid ":ref:`Documentation on module objects `" msgstr "" -"モジュールがどの :term:`package` に属しているかです。モジュールがトップレベル" -"である (すなわち、いかなる特定のパッケージの一部でもない) 場合、この属性は " -"``''`` に設定されます。そうでない場合、パッケージ名 (モジュールがパッケージ自" -"身なら :attr:`__name__`) に設定されます。デフォルトは ``None`` です。" -#: ../../library/types.rst:300 +#: ../../library/types.rst:266 msgid "" -"This attribute is to match :attr:`importlib.machinery.ModuleSpec.parent` as " -"stored in the :attr:`__spec__` object." +"Provides details on the special attributes that can be found on instances " +"of :class:`!ModuleType`." msgstr "" -#: ../../library/types.rst:304 -msgid "" -"A future version of Python may stop setting this attribute by default. To " -"guard against this potential change, preferably read from the :attr:" -"`__spec__` attribute instead or use ``getattr(module, \"__package__\", " -"None)`` if you explicitly need to use this attribute." +#: ../../library/types.rst:269 +msgid ":func:`importlib.util.module_from_spec`" msgstr "" -#: ../../library/types.rst:315 +#: ../../library/types.rst:270 msgid "" -"A record of the module's import-system-related state. Expected to be an " -"instance of :class:`importlib.machinery.ModuleSpec`." +"Modules created using the :class:`!ModuleType` constructor are created with " +"many of their special attributes unset or set to default values. :func:`!" +"module_from_spec` provides a more robust way of creating :class:`!" +"ModuleType` instances which ensures the various attributes are set " +"appropriately." msgstr "" -#: ../../library/types.rst:323 +#: ../../library/types.rst:278 msgid "The type of :data:`Ellipsis`." msgstr ":data:`Ellipsis` の型です。" -#: ../../library/types.rst:329 +#: ../../library/types.rst:284 msgid "" "The type of :ref:`parameterized generics ` such as " "``list[int]``." msgstr "" -#: ../../library/types.rst:332 +#: ../../library/types.rst:287 msgid "" "``t_origin`` should be a non-parameterized generic class, such as ``list``, " "``tuple`` or ``dict``. ``t_args`` should be a :class:`tuple` (possibly of " "length 1) of types which parameterize ``t_origin``::" msgstr "" -#: ../../library/types.rst:336 +#: ../../library/types.rst:291 msgid "" ">>> from types import GenericAlias\n" "\n" @@ -477,32 +427,32 @@ msgid "" "True" msgstr "" -#: ../../library/types.rst:345 +#: ../../library/types.rst:300 msgid "This type can now be subclassed." msgstr "" -#: ../../library/types.rst:350 +#: ../../library/types.rst:305 msgid ":ref:`Generic Alias Types`" msgstr "" -#: ../../library/types.rst:351 +#: ../../library/types.rst:306 msgid "In-depth documentation on instances of :class:`!types.GenericAlias`" msgstr "" -#: ../../library/types.rst:353 +#: ../../library/types.rst:308 msgid ":pep:`585` - Type Hinting Generics In Standard Collections" msgstr "" ":pep:`585` - 標準コレクション型の型ヒントにおける総称型 (generics) の使用" -#: ../../library/types.rst:354 +#: ../../library/types.rst:309 msgid "Introducing the :class:`!types.GenericAlias` class" msgstr "" -#: ../../library/types.rst:358 +#: ../../library/types.rst:313 msgid "The type of :ref:`union type expressions`." msgstr "" -#: ../../library/types.rst:364 +#: ../../library/types.rst:319 msgid "" "The type of traceback objects such as found in ``sys.exception()." "__traceback__``." @@ -510,20 +460,20 @@ msgstr "" "``sys.exception().__traceback__`` に含まれるようなトレースバックオブジェクト" "の型です。" -#: ../../library/types.rst:366 +#: ../../library/types.rst:321 msgid "" "See :ref:`the language reference ` for details of the " "available attributes and operations, and guidance on creating tracebacks " "dynamically." msgstr "" -#: ../../library/types.rst:373 +#: ../../library/types.rst:328 msgid "" "The type of :ref:`frame objects ` such as found in :attr:`tb." "tb_frame ` if ``tb`` is a traceback object." msgstr "" -#: ../../library/types.rst:379 +#: ../../library/types.rst:334 msgid "" "The type of objects defined in extension modules with ``PyGetSetDef``, such " "as :attr:`FrameType.f_locals ` or ``array.array.typecode``. " @@ -532,7 +482,7 @@ msgid "" "modules." msgstr "" -#: ../../library/types.rst:388 +#: ../../library/types.rst:343 msgid "" "The type of objects defined in extension modules with ``PyMemberDef``, such " "as ``datetime.timedelta.days``. This type is used as descriptor for simple " @@ -545,7 +495,7 @@ msgstr "" "うな、Cのシンプルなデータメンバで利用されます。 :class:`property` 型と同じ目" "的を持った型ですが、こちらは拡張モジュールで定義された型のためのものです。" -#: ../../library/types.rst:393 +#: ../../library/types.rst:348 msgid "" "In addition, when a class is defined with a :attr:`~object.__slots__` " "attribute, then for each slot, an instance of :class:`!MemberDescriptorType` " @@ -553,7 +503,7 @@ msgid "" "in the class's :attr:`~type.__dict__`." msgstr "" -#: ../../library/types.rst:399 +#: ../../library/types.rst:354 msgid "" "In other implementations of Python, this type may be identical to " "``GetSetDescriptorType``." @@ -561,7 +511,7 @@ msgstr "" "Pythonの他の実装では、この型は ``GetSetDescriptorType`` と同じかもしれませ" "ん。" -#: ../../library/types.rst:404 +#: ../../library/types.rst:359 msgid "" "Read-only proxy of a mapping. It provides a dynamic view on the mapping's " "entries, which means that when the mapping changes, the view reflects these " @@ -571,20 +521,20 @@ msgstr "" "ビューを提供します。つまり、マッピングが変わった場合にビューがこれらの変更を" "反映するということです。" -#: ../../library/types.rst:412 +#: ../../library/types.rst:367 msgid "" "Updated to support the new union (``|``) operator from :pep:`584`, which " "simply delegates to the underlying mapping." msgstr "" -#: ../../library/types.rst:417 +#: ../../library/types.rst:372 msgid "" "Return ``True`` if the underlying mapping has a key *key*, else ``False``." msgstr "" "元になったマッピングが *key* というキーを持っている場合 ``True`` を返します。" "そうでなければ ``False`` を返します。" -#: ../../library/types.rst:422 +#: ../../library/types.rst:377 msgid "" "Return the item of the underlying mapping with key *key*. Raises a :exc:" "`KeyError` if *key* is not in the underlying mapping." @@ -592,7 +542,7 @@ msgstr "" "元になったマッピングの *key* というキーに対応するアイテムを返します。 *key* " "が存在しなければ、 :exc:`KeyError` が発生します。" -#: ../../library/types.rst:427 +#: ../../library/types.rst:382 msgid "" "Return an iterator over the keys of the underlying mapping. This is a " "shortcut for ``iter(proxy.keys())``." @@ -600,15 +550,15 @@ msgstr "" "元になったマッピングのキーを列挙するイテレータを返します。これは " "``iter(proxy.keys())`` のショートカットです。" -#: ../../library/types.rst:432 +#: ../../library/types.rst:387 msgid "Return the number of items in the underlying mapping." msgstr "元になったマッピングに含まれるアイテムの数を返します。" -#: ../../library/types.rst:436 +#: ../../library/types.rst:391 msgid "Return a shallow copy of the underlying mapping." msgstr "元になったマッピングの浅いコピーを返します。" -#: ../../library/types.rst:440 +#: ../../library/types.rst:395 msgid "" "Return the value for *key* if *key* is in the underlying mapping, else " "*default*. If *default* is not given, it defaults to ``None``, so that this " @@ -619,38 +569,38 @@ msgstr "" "ト値の ``None`` になります。そのため、このメソッドが :exc:`KeyError` を発生さ" "せることはありません。" -#: ../../library/types.rst:446 +#: ../../library/types.rst:401 msgid "" "Return a new view of the underlying mapping's items (``(key, value)`` pairs)." msgstr "" "元になったマッピングの items (``(key, value)`` ペアの列) に対する新しいビュー" "を返します。" -#: ../../library/types.rst:451 +#: ../../library/types.rst:406 msgid "Return a new view of the underlying mapping's keys." msgstr "元になったマッピングの keys に対する新しいビューを返します。" -#: ../../library/types.rst:455 +#: ../../library/types.rst:410 msgid "Return a new view of the underlying mapping's values." msgstr "元になったマッピングの values に対する新しいビューを返します。" -#: ../../library/types.rst:459 +#: ../../library/types.rst:414 msgid "Return a reverse iterator over the keys of the underlying mapping." msgstr "" -#: ../../library/types.rst:465 +#: ../../library/types.rst:420 msgid "Return a hash of the underlying mapping." msgstr "" -#: ../../library/types.rst:471 +#: ../../library/types.rst:426 msgid "The type of :ref:`capsule objects `." msgstr "" -#: ../../library/types.rst:477 +#: ../../library/types.rst:432 msgid "Additional Utility Classes and Functions" msgstr "追加のユーティリティクラスと関数" -#: ../../library/types.rst:481 +#: ../../library/types.rst:436 msgid "" "A simple :class:`object` subclass that provides attribute access to its " "namespace, as well as a meaningful repr." @@ -658,13 +608,13 @@ msgstr "" "名前空間への属性アクセスに加えて意味のある repr を提供するための、単純な :" "class:`object` サブクラスです。" -#: ../../library/types.rst:484 +#: ../../library/types.rst:439 msgid "" "Unlike :class:`object`, with :class:`!SimpleNamespace` you can add and " "remove attributes." msgstr "" -#: ../../library/types.rst:487 +#: ../../library/types.rst:442 msgid "" ":py:class:`SimpleNamespace` objects may be initialized in the same way as :" "class:`dict`: either with keyword arguments, with a single positional " @@ -675,11 +625,11 @@ msgid "" "`iterable` object producing key-value pairs). All such keys must be strings." msgstr "" -#: ../../library/types.rst:498 +#: ../../library/types.rst:453 msgid "The type is roughly equivalent to the following code::" msgstr "この型は以下のコードとほぼ等価です::" -#: ../../library/types.rst:500 +#: ../../library/types.rst:455 msgid "" "class SimpleNamespace:\n" " def __init__(self, mapping_or_iterable=(), /, **kwargs):\n" @@ -697,7 +647,7 @@ msgid "" " return NotImplemented" msgstr "" -#: ../../library/types.rst:514 +#: ../../library/types.rst:469 msgid "" "``SimpleNamespace`` may be useful as a replacement for ``class NS: pass``. " "However, for a structured record type use :func:`~collections.namedtuple` " @@ -707,26 +657,26 @@ msgstr "" "ません。ですが、構造化されたレコード型に対しては、これよりはむしろ :func:" "`~collections.namedtuple` を使用してください。" -#: ../../library/types.rst:518 +#: ../../library/types.rst:473 msgid "" ":class:`!SimpleNamespace` objects are supported by :func:`copy.replace`." msgstr "" -#: ../../library/types.rst:522 +#: ../../library/types.rst:477 msgid "" "Attribute order in the repr changed from alphabetical to insertion (like " "``dict``)." msgstr "" -#: ../../library/types.rst:526 +#: ../../library/types.rst:481 msgid "Added support for an optional positional argument." msgstr "" -#: ../../library/types.rst:531 +#: ../../library/types.rst:486 msgid "Route attribute access on a class to __getattr__." msgstr "クラスの属性アクセスを __getattr__ に振り替えます。" -#: ../../library/types.rst:533 +#: ../../library/types.rst:488 msgid "" "This is a descriptor, used to define attributes that act differently when " "accessed through an instance and through a class. Instance access remains " @@ -738,7 +688,7 @@ msgstr "" "ス経由の属性アクセスはクラスの __getattr__ メソッドに振り替えられます。これ" "は AttributeError の送出により行われます。" -#: ../../library/types.rst:538 +#: ../../library/types.rst:493 msgid "" "This allows one to have properties active on an instance, and have virtual " "attributes on the class with the same name (see :class:`enum.Enum` for an " @@ -747,11 +697,11 @@ msgstr "" "これによって、インスタンス上で有効なプロパティを持ち、クラス上で同名の仮想属" "性を持つことができます (例については :class:`enum.Enum` を参照してください)。" -#: ../../library/types.rst:545 +#: ../../library/types.rst:500 msgid "Coroutine Utility Functions" msgstr "コルーチンユーティリティ関数" -#: ../../library/types.rst:549 +#: ../../library/types.rst:504 msgid "" "This function transforms a :term:`generator` function into a :term:" "`coroutine function` which returns a generator-based coroutine. The " @@ -766,11 +716,11 @@ msgstr "" "ブジェクトかつ :term:`awaitable` であるとみなされます。ただし、必ずしも :" "meth:`~object.__await__` メソッドを実装する必要はありません。" -#: ../../library/types.rst:556 +#: ../../library/types.rst:511 msgid "If *gen_func* is a generator function, it will be modified in-place." msgstr "*gen_func* はジェネレータ関数で、インプレースに変更されます。" -#: ../../library/types.rst:558 +#: ../../library/types.rst:513 msgid "" "If *gen_func* is not a generator function, it will be wrapped. If it returns " "an instance of :class:`collections.abc.Generator`, the instance will be " diff --git a/library/unittest.mock.po b/library/unittest.mock.po index c8fb33093..b975aa7d6 100644 --- a/library/unittest.mock.po +++ b/library/unittest.mock.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:16+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -105,11 +105,9 @@ msgstr "" #: ../../library/unittest.mock.rst:71 msgid "" -":attr:`side_effect` allows you to perform side effects, including raising an " -"exception when a mock is called:" +":attr:`~Mock.side_effect` allows you to perform side effects, including " +"raising an exception when a mock is called:" msgstr "" -":attr:`side_effect` によって、モック呼び出し時の例外発生などの副作用を実行で" -"きます:" #: ../../library/unittest.mock.rst:92 msgid "" @@ -773,23 +771,17 @@ msgstr "" #: ../../library/unittest.mock.rst:740 msgid "" -"Normally the :attr:`__class__` attribute of an object will return its type. " -"For a mock object with a :attr:`spec`, ``__class__`` returns the spec class " -"instead. This allows mock objects to pass :func:`isinstance` tests for the " -"object they are replacing / masquerading as:" +"Normally the :attr:`!__class__` attribute of an object will return its type. " +"For a mock object with a :attr:`!spec`, :attr:`!__class__` returns the spec " +"class instead. This allows mock objects to pass :func:`isinstance` tests for " +"the object they are replacing / masquerading as:" msgstr "" -"通常、オブジェクトの :attr:`__class__` 属性はその型を返します。 :attr:`spec` " -"を設定したオブジェクトの場合、 ``__class__`` は代わりに :attr:`spec` のクラス" -"を返します。これにより、置き換え / 偽装しているオブジェクトに対する :func:" -"`isinstance` も通過することができます:" #: ../../library/unittest.mock.rst:749 msgid "" -":attr:`__class__` is assignable to, this allows a mock to pass an :func:" +":attr:`!__class__` is assignable to, this allows a mock to pass an :func:" "`isinstance` check without forcing you to use a spec:" msgstr "" -":attr:`__class__` は書き換え可能で、 :func:`isinstance` を通るために必ず " -"spec を使う必要はありません:" #: ../../library/unittest.mock.rst:759 msgid "" @@ -802,11 +794,9 @@ msgstr "" #: ../../library/unittest.mock.rst:763 msgid "" -"Mock objects that use a class or an instance as a :attr:`spec` or :attr:" -"`spec_set` are able to pass :func:`isinstance` tests:" +"Mock objects that use a class or an instance as a :attr:`!spec` or :attr:`!" +"spec_set` are able to pass :func:`isinstance` tests:" msgstr "" -":attr:`spec` か :attr:`spec_set` にクラスかインスタンスを渡した mock は :" -"func:`isinstance` テストをパスします:" #: ../../library/unittest.mock.rst:773 msgid "" @@ -1157,12 +1147,9 @@ msgstr "" #: ../../library/unittest.mock.rst:1177 msgid "" "If :attr:`~Mock.side_effect` is set then it will be called after the call " -"has been recorded, so if :attr:`side_effect` raises an exception the call is " -"still recorded." +"has been recorded, so if :attr:`!side_effect` raises an exception the call " +"is still recorded." msgstr "" -"もし :attr:`~Mock.side_effect` が設定されている場合は、その呼び出しが記録され" -"た後に呼び出されます。よって、もし :attr:`side_effect` が例外を発生させても、" -"その呼び出しは記録されます。" #: ../../library/unittest.mock.rst:1181 msgid "" @@ -1174,44 +1161,32 @@ msgstr "" #: ../../library/unittest.mock.rst:1199 msgid "" -"If :attr:`side_effect` is a function then whatever that function returns is " -"what calls to the mock return. The :attr:`side_effect` function is called " -"with the same arguments as the mock. This allows you to vary the return " -"value of the call dynamically, based on the input:" +"If :attr:`~Mock.side_effect` is a function then whatever that function " +"returns is what calls to the mock return. The :attr:`!side_effect` function " +"is called with the same arguments as the mock. This allows you to vary the " +"return value of the call dynamically, based on the input:" msgstr "" -"もし :attr:`side_effect` が関数だった場合には、その関数の戻り値がモックを呼び" -"出した際の戻り値になります。 :attr:`side_effect` 関数には、モックの呼び出し時" -"に与えられた引数と同じ物があたえられます。これにより、入力によって動的に値を" -"返すことができます:" #: ../../library/unittest.mock.rst:1215 msgid "" "If you want the mock to still return the default return value (a new mock), " "or any set return value, then there are two ways of doing this. Either " -"return :attr:`mock.return_value` from inside :attr:`side_effect`, or return :" -"data:`DEFAULT`:" +"return :attr:`~Mock.return_value` from inside :attr:`~Mock.side_effect`, or " +"return :data:`DEFAULT`:" msgstr "" -"もし、モックにデフォルトの戻り値 (新しいモック) や設定した値を返して欲しい場" -"合は、2つの方法があります。 :attr:`side_effect` の内部で :attr:`mock." -"return_value` を返すか :data:`DEFAULT` を返します:" #: ../../library/unittest.mock.rst:1234 msgid "" -"To remove a :attr:`side_effect`, and return to the default behaviour, set " -"the :attr:`side_effect` to ``None``:" +"To remove a :attr:`~Mock.side_effect`, and return to the default behaviour, " +"set the :attr:`!side_effect` to ``None``:" msgstr "" -":attr:`side_effect` を削除し、デフォルトの挙動を行うようにするには、 :attr:" -"`side_effect` に ``None`` を設定します:" #: ../../library/unittest.mock.rst:1248 msgid "" -"The :attr:`side_effect` can also be any iterable object. Repeated calls to " -"the mock will return values from the iterable (until the iterable is " -"exhausted and a :exc:`StopIteration` is raised):" +"The :attr:`~Mock.side_effect` can also be any iterable object. Repeated " +"calls to the mock will return values from the iterable (until the iterable " +"is exhausted and a :exc:`StopIteration` is raised):" msgstr "" -":attr:`side_effect` には、イテレート可能オブジェクトを設定できます。モックが" -"呼び出されるごとに、イテレート可能オブジェクトから戻り値を得ます (イテレート" -"可能オブジェクトが尽きて :exc:`StopIteration` が発生するまで):" #: ../../library/unittest.mock.rst:1264 msgid "" @@ -1251,12 +1226,9 @@ msgstr "" msgid "" "You may want a mock object to return ``False`` to a :func:`hasattr` call, or " "raise an :exc:`AttributeError` when an attribute is fetched. You can do this " -"by providing an object as a :attr:`spec` for a mock, but that isn't always " +"by providing an object as a :attr:`!spec` for a mock, but that isn't always " "convenient." msgstr "" -":func:`hasattr` の呼び出しの際に ``False`` を返したり,属性にアクセスした際" -"に :exc:`AttributeError` を発生させたりしたい場合, :attr:`spec` を用いる方法" -"があります.しかし,この方法は必ずしも便利ではありません." #: ../../library/unittest.mock.rst:1291 msgid "" @@ -1507,21 +1479,14 @@ msgstr "" #: ../../library/unittest.mock.rst:1458 msgid "" -"Patch can be used as a :class:`TestCase` class decorator. It works by " -"decorating each test method in the class. This reduces the boilerplate code " -"when your test methods share a common patchings set. :func:`patch` finds " -"tests by looking for method names that start with ``patch.TEST_PREFIX``. By " -"default this is ``'test'``, which matches the way :mod:`unittest` finds " -"tests. You can specify an alternative prefix by setting ``patch." -"TEST_PREFIX``." -msgstr "" -"patch は :class:`TestCase` のクラスデコレータとして利用できます。この場合その" -"クラスの各テストメソッドをデコレートします。これによりテストメソッドが同じ " -"patch を共有している場合に退屈なコードを減らすことができます。 :func:`patch` " -"は ``patch.TEST_PREFIX`` で始まるメソッド名のメソッドを探します。デフォルトで" -"はこれは ``'test'`` で、 :mod:`unittest` がテストを探す方法とマッチしていま" -"す。 ``patch.TEST_PREFIX`` を設定することで異なる prefix を指定することもでき" -"ます。" +"Patch can be used as a :class:`~unittest.TestCase` class decorator. It works " +"by decorating each test method in the class. This reduces the boilerplate " +"code when your test methods share a common patchings set. :func:`patch` " +"finds tests by looking for method names that start with ``patch." +"TEST_PREFIX``. By default this is ``'test'``, which matches the way :mod:" +"`unittest` finds tests. You can specify an alternative prefix by setting " +"``patch.TEST_PREFIX``." +msgstr "" #: ../../library/unittest.mock.rst:1465 msgid "" @@ -1591,10 +1556,8 @@ msgstr "" #: ../../library/unittest.mock.rst:1495 msgid "" "To configure return values on methods of *instances* on the patched class " -"you must do this on the :attr:`return_value`. For example::" +"you must do this on the :attr:`~Mock.return_value`. For example::" msgstr "" -"パッチしたクラスの *インスタンス* のメソッドの戻り値をカスタマイズしたい場" -"合、 :attr:`return_value` に対して設定しなければなりません。例::" #: ../../library/unittest.mock.rst:1498 msgid "" @@ -2051,25 +2014,18 @@ msgstr "patch のメソッド: start と stop" #: ../../library/unittest.mock.rst:1817 msgid "" -"All the patchers have :meth:`start` and :meth:`stop` methods. These make it " -"simpler to do patching in ``setUp`` methods or where you want to do multiple " -"patches without nesting decorators or with statements." +"All the patchers have :meth:`!start` and :meth:`!stop` methods. These make " +"it simpler to do patching in ``setUp`` methods or where you want to do " +"multiple patches without nesting decorators or with statements." msgstr "" -"すべての patcher は :meth:`start` と :meth:`stop` メソッドを持ちます。これを" -"使うと、 with 文やデコレータをネストさせずに、 ``setUp`` メソッドで複数のパッ" -"チをシンプルに適用させることができます。" #: ../../library/unittest.mock.rst:1821 msgid "" "To use them call :func:`patch`, :func:`patch.object` or :func:`patch.dict` " "as normal and keep a reference to the returned ``patcher`` object. You can " -"then call :meth:`start` to put the patch in place and :meth:`stop` to undo " +"then call :meth:`!start` to put the patch in place and :meth:`!stop` to undo " "it." msgstr "" -"これらのメソッドを使うには、 :func:`patch`, :func:`patch.object`, :func:" -"`patch.dict` を通常の関数のように呼び出して、戻り値の ``patcher`` オブジェク" -"トを保持します。その :meth:`start` メソッドでパッチを適用し、 :meth:`stop` メ" -"ソッドで巻き戻すことができます。" #: ../../library/unittest.mock.rst:1825 msgid "" @@ -2095,10 +2051,8 @@ msgstr "" #: ../../library/unittest.mock.rst:1839 msgid "" "A typical use case for this might be for doing multiple patches in the " -"``setUp`` method of a :class:`TestCase`::" +"``setUp`` method of a :class:`~unittest.TestCase`::" msgstr "" -"この方式の典型的なユースケースは、 :class:`TestCase` の ``setUp`` メソッドで" -"複数のパッチを行うことです::" #: ../../library/unittest.mock.rst:1842 msgid "" @@ -3133,7 +3087,7 @@ msgstr "" msgid "" "Alternatively you can just use ``vars(my_mock)`` (instance members) and " "``dir(type(my_mock))`` (type members) to bypass the filtering irrespective " -"of :const:`mock.FILTER_DIR`." +"of :const:`FILTER_DIR`." msgstr "" #: ../../library/unittest.mock.rst:2517 @@ -3161,35 +3115,23 @@ msgstr "" #: ../../library/unittest.mock.rst:2528 msgid "" -"*read_data* is a string for the :meth:`~io.IOBase.read`, :meth:`~io.IOBase." -"readline`, and :meth:`~io.IOBase.readlines` methods of the file handle to " -"return. Calls to those methods will take data from *read_data* until it is " -"depleted. The mock of these methods is pretty simplistic: every time the " -"*mock* is called, the *read_data* is rewound to the start. If you need more " -"control over the data that you are feeding to the tested code you will need " -"to customize this mock for yourself. When that is insufficient, one of the " -"in-memory filesystem packages on `PyPI `_ can offer a " -"realistic filesystem for testing." -msgstr "" -"*read_data* は、ファイルハンドルの :meth:`~io.IOBase.read`, :meth:`~io." -"IOBase.readline`, そして :meth:`~io.IOBase.readlines` のメソッドが返す文字列" -"です。これらのメソッドを呼び出すと、読み出し終わるまで *read_data* からデータ" -"が読み出されます。これらモックのメソッドはとても単純化されています: *mock* が" -"呼ばれるたびに *read_data* は先頭に巻き戻されます。テストコードに与えるデータ" -"をさらにコントロールするには自分自身でモックをカスタマイズする必要がありま" -"す。それでも不十分な場合は、 `PyPI `_ にあるインメモリファ" -"イルシステムパッケージのうちのどれかを使えば、テストのための本物のファイルシ" -"ステムが得られるでしょう。" +"*read_data* is a string for the :meth:`~io.RawIOBase.read`, :meth:`~io." +"IOBase.readline`, and :meth:`~io.IOBase.readlines` methods of the file " +"handle to return. Calls to those methods will take data from *read_data* " +"until it is depleted. The mock of these methods is pretty simplistic: every " +"time the *mock* is called, the *read_data* is rewound to the start. If you " +"need more control over the data that you are feeding to the tested code you " +"will need to customize this mock for yourself. When that is insufficient, " +"one of the in-memory filesystem packages on `PyPI `_ can " +"offer a realistic filesystem for testing." +msgstr "" #: ../../library/unittest.mock.rst:2538 msgid "" "Added :meth:`~io.IOBase.readline` and :meth:`~io.IOBase.readlines` support. " -"The mock of :meth:`~io.IOBase.read` changed to consume *read_data* rather " +"The mock of :meth:`~io.RawIOBase.read` changed to consume *read_data* rather " "than returning it on each call." msgstr "" -":meth:`~io.IOBase.readline` および :meth:`~io.IOBase.readlines` のサポートが" -"追加されました。 :meth:`~io.IOBase.read` のモックは、個々の呼び出しで " -"*read_data* を返すのではなく、それを消費するように変わりました。" #: ../../library/unittest.mock.rst:2543 msgid "*read_data* is now reset on each call to the *mock*." @@ -3268,18 +3210,13 @@ msgstr "autospec を使う" #: ../../library/unittest.mock.rst:2592 msgid "" -"Autospeccing is based on the existing :attr:`spec` feature of mock. It " +"Autospeccing is based on the existing :attr:`!spec` feature of mock. It " "limits the api of mocks to the api of an original object (the spec), but it " "is recursive (implemented lazily) so that attributes of mocks only have the " "same api as the attributes of the spec. In addition mocked functions / " "methods have the same call signature as the original so they raise a :exc:" "`TypeError` if they are called incorrectly." msgstr "" -"autospec は mock の :attr:`spec` 機能を基盤にしています。 autospec は mock " -"の API を元のオブジェクト (spec) に制限しますが、再帰的に適用される (lazy に" -"実装されている) ので、 mock の属性も spec の属性と同じ API だけを持つようにな" -"ります。さらに、 mock された関数/メソッドは元と同じシグネチャを持ち、正しくな" -"い引数で呼び出されると :exc:`TypeError` を発生させます。" #: ../../library/unittest.mock.rst:2599 msgid "Before I explain how auto-speccing works, here's why it is needed." @@ -3315,13 +3252,10 @@ msgstr "" #: ../../library/unittest.mock.rst:2617 msgid "" -":mod:`mock` already provides a feature to help with this, called speccing. " -"If you use a class or instance as the :attr:`spec` for a mock then you can " -"only access attributes on the mock that exist on the real class:" +":mod:`unittest.mock` already provides a feature to help with this, called " +"speccing. If you use a class or instance as the :attr:`!spec` for a mock " +"then you can only access attributes on the mock that exist on the real class:" msgstr "" -":mod:`mock` はこの問題に対処するために spec と呼ばれる機能を提供しています。" -"何かクラスかインスタンスを :attr:`spec` として mock に渡すと、実際のクラスに" -"存在する属性にしか、 mock に対してもアクセスできなくなります:" #: ../../library/unittest.mock.rst:2628 msgid "" @@ -3375,13 +3309,10 @@ msgstr "" #: ../../library/unittest.mock.rst:2656 msgid "" -"You can see that :class:`request.Request` has a spec. :class:`request." +"You can see that :class:`!request.Request` has a spec. :class:`!request." "Request` takes two arguments in the constructor (one of which is *self*). " "Here's what happens if we try to call it incorrectly::" msgstr "" -":class:`request.Request` が spec を持っているのが分かります。 :class:" -"`request.Request` のコンストラクタは2つの引数を持っています (片方は *self* で" -"す)。コンストラクタを間違って呼び出した時に何が起こるでしょうか::" #: ../../library/unittest.mock.rst:2660 msgid "" @@ -3408,14 +3339,11 @@ msgstr "" #: ../../library/unittest.mock.rst:2672 msgid "" -":class:`Request` objects are not callable, so the return value of " -"instantiating our mocked out :class:`request.Request` is a non-callable " +":class:`!Request` objects are not callable, so the return value of " +"instantiating our mocked out :class:`!request.Request` is a non-callable " "mock. With the spec in place any typos in our asserts will raise the correct " "error::" msgstr "" -":class:`Request` オブジェクトは callable ではないので、 :class:`request." -"Request` の mock から返されたインスタンスの mock は callable ではなくなりま" -"す。 spec があれば、 assert のミススペルは正しいエラーを発生させます::" #: ../../library/unittest.mock.rst:2676 msgid "" @@ -3627,7 +3555,8 @@ msgstr "" #: ../../library/unittest.mock.rst:2826 msgid "" -"Order of precedence of :attr:`side_effect`, :attr:`return_value` and *wraps*" +"Order of precedence of :attr:`!side_effect`, :attr:`!return_value` and " +"*wraps*" msgstr "" #: ../../library/unittest.mock.rst:2828 diff --git a/library/urllib.request.po b/library/urllib.request.po index 19d0813aa..a45865e6d 100644 --- a/library/urllib.request.po +++ b/library/urllib.request.po @@ -18,7 +18,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:17+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -64,8 +64,8 @@ msgid "" msgstr "" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/venv.po b/library/venv.po index 1b42264c0..691811b01 100644 --- a/library/venv.po +++ b/library/venv.po @@ -16,7 +16,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:17+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -111,7 +111,7 @@ msgstr "" "environments/#create-and-use-virtual-environments>`__" #: ../../includes/wasm-mobile-notavail.rst:3 -msgid ":ref:`Availability `: not Android, not iOS, not WASI." +msgid "Availability" msgstr "" #: ../../includes/wasm-mobile-notavail.rst:5 @@ -373,9 +373,9 @@ msgstr "csh/tcsh" msgid ":samp:`$ source {}/bin/activate.csh`" msgstr ":samp:`$ source {}/bin/activate.csh`" -#: ../../library/venv.rst:218 ../../library/venv.rst:222 -msgid "PowerShell" -msgstr "PowerShell" +#: ../../library/venv.rst:218 +msgid "pwsh" +msgstr "" #: ../../library/venv.rst:218 msgid ":samp:`$ {}/bin/Activate.ps1`" @@ -393,6 +393,10 @@ msgstr "cmd.exe" msgid ":samp:`C:\\\\> {}\\\\Scripts\\\\activate.bat`" msgstr ":samp:`C:\\\\> {}\\\\Scripts\\\\activate.bat`" +#: ../../library/venv.rst:222 +msgid "PowerShell" +msgstr "PowerShell" + #: ../../library/venv.rst:222 msgid ":samp:`PS C:\\\\> {}\\\\Scripts\\\\Activate.ps1`" msgstr ":samp:`PS C:\\\\> {}\\\\Scripts\\\\Activate.ps1`" diff --git a/library/webbrowser.po b/library/webbrowser.po index 18a64346d..25bc0dca3 100644 --- a/library/webbrowser.po +++ b/library/webbrowser.po @@ -13,7 +13,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:17+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -129,7 +129,7 @@ msgid "python -m webbrowser -t \"https://www.python.org\"" msgstr "" #: ../../library/webbrowser.rst:54 -msgid ":ref:`Availability `: not WASI, not Android." +msgid "Availability" msgstr "" #: ../../library/webbrowser.rst:56 diff --git a/library/xmlrpc.client.po b/library/xmlrpc.client.po index 4589dfc3f..62345cae6 100644 --- a/library/xmlrpc.client.po +++ b/library/xmlrpc.client.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:18+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -67,8 +67,8 @@ msgstr "" "を全てデフォルトで行います。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/xmlrpc.server.po b/library/xmlrpc.server.po index 1877098f5..adc306b21 100644 --- a/library/xmlrpc.server.po +++ b/library/xmlrpc.server.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:18+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -56,8 +56,8 @@ msgstr "" "合は、 :ref:`xml-vulnerabilities` を参照してください。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/library/zoneinfo.po b/library/zoneinfo.po index 956b2968d..b4133631a 100644 --- a/library/zoneinfo.po +++ b/library/zoneinfo.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:19+0000\n" "Last-Translator: 石井明久, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -72,8 +72,8 @@ msgstr "" "パッケージ。タイムゾーンデータを供給し、PyPIで配布されている。" #: ../../includes/wasm-notavail.rst:3 -msgid ":ref:`Availability `: not WASI." -msgstr ":ref:`利用可能な環境 `: WASI 以外。" +msgid "Availability" +msgstr "" #: ../../includes/wasm-notavail.rst:5 msgid "" diff --git a/reference/datamodel.po b/reference/datamodel.po index 78bbf5ce6..f6f4e2d6e 100644 --- a/reference/datamodel.po +++ b/reference/datamodel.po @@ -22,7 +22,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:19+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -782,18 +782,18 @@ msgstr "" "`function` 参照)。関数は、仮引数 (formal parameter) リストと同じ数の要素が" "入った引数リストとともに呼び出されます。" -#: ../../reference/datamodel.rst:545 ../../reference/datamodel.rst:1206 -#: ../../reference/datamodel.rst:1403 +#: ../../reference/datamodel.rst:545 ../../reference/datamodel.rst:1395 +#: ../../reference/datamodel.rst:1596 msgid "Special read-only attributes" msgstr "" -#: ../../reference/datamodel.rst:555 ../../reference/datamodel.rst:589 -#: ../../reference/datamodel.rst:981 +#: ../../reference/datamodel.rst:555 ../../reference/datamodel.rst:590 +#: ../../reference/datamodel.rst:1170 msgid "Attribute" msgstr "属性" -#: ../../reference/datamodel.rst:556 ../../reference/datamodel.rst:590 -#: ../../reference/datamodel.rst:982 +#: ../../reference/datamodel.rst:556 ../../reference/datamodel.rst:591 +#: ../../reference/datamodel.rst:1171 msgid "Meaning" msgstr "意味" @@ -806,11 +806,12 @@ msgstr "" #: ../../reference/datamodel.rst:564 msgid "" -"``None`` or a :class:`tuple` of cells that contain bindings for the " -"function's free variables." +"``None`` or a :class:`tuple` of cells that contain bindings for the names " +"specified in the :attr:`~codeobject.co_freevars` attribute of the " +"function's :attr:`code object `." msgstr "" -#: ../../reference/datamodel.rst:567 +#: ../../reference/datamodel.rst:568 msgid "" "A cell object has the attribute ``cell_contents``. This can be used to get " "the value of the cell, as well as set the value." @@ -818,33 +819,33 @@ msgstr "" "セルオブジェクトは属性 ``cell_contents`` を持っています。\n" "これはセルの値を設定するのに加えて、セルの値を得るのにも使えます。" -#: ../../reference/datamodel.rst:571 ../../reference/datamodel.rst:1445 +#: ../../reference/datamodel.rst:572 ../../reference/datamodel.rst:1638 msgid "Special writable attributes" msgstr "" -#: ../../reference/datamodel.rst:584 +#: ../../reference/datamodel.rst:585 msgid "Most of these attributes check the type of the assigned value:" msgstr "" -#: ../../reference/datamodel.rst:593 +#: ../../reference/datamodel.rst:594 msgid "The function's documentation string, or ``None`` if unavailable." msgstr "" "関数のドキュメンテーション文字列です。ドキュメンテーションがない場合は " "``None`` になります。" -#: ../../reference/datamodel.rst:596 +#: ../../reference/datamodel.rst:597 msgid "" "The function's name. See also: :attr:`__name__ attributes `." msgstr "" -#: ../../reference/datamodel.rst:600 +#: ../../reference/datamodel.rst:601 msgid "" "The function's :term:`qualified name`. See also: :attr:`__qualname__ " "attributes `." msgstr "" -#: ../../reference/datamodel.rst:606 +#: ../../reference/datamodel.rst:607 msgid "" "The name of the module the function was defined in, or ``None`` if " "unavailable." @@ -852,26 +853,26 @@ msgstr "" "関数が定義されているモジュールの名前です。モジュール名がない場合は ``None`` " "になります。" -#: ../../reference/datamodel.rst:610 +#: ../../reference/datamodel.rst:611 msgid "" "A :class:`tuple` containing default :term:`parameter` values for those " "parameters that have defaults, or ``None`` if no parameters have a default " "value." msgstr "" -#: ../../reference/datamodel.rst:615 +#: ../../reference/datamodel.rst:616 msgid "" "The :ref:`code object ` representing the compiled function " "body." msgstr "" -#: ../../reference/datamodel.rst:619 +#: ../../reference/datamodel.rst:620 msgid "" "The namespace supporting arbitrary function attributes. See also: :attr:" "`__dict__ attributes `." msgstr "" -#: ../../reference/datamodel.rst:623 +#: ../../reference/datamodel.rst:624 msgid "" "A :class:`dictionary ` containing annotations of :term:`parameters " "`. The keys of the dictionary are the parameter names, and " @@ -879,44 +880,44 @@ msgid "" "`annotations-howto`." msgstr "" -#: ../../reference/datamodel.rst:630 +#: ../../reference/datamodel.rst:631 msgid "" "A :class:`dictionary ` containing defaults for keyword-only :term:" "`parameters `." msgstr "" -#: ../../reference/datamodel.rst:634 +#: ../../reference/datamodel.rst:635 msgid "" "A :class:`tuple` containing the :ref:`type parameters ` of a :" "ref:`generic function `." msgstr "" -#: ../../reference/datamodel.rst:639 +#: ../../reference/datamodel.rst:640 msgid "" "Function objects also support getting and setting arbitrary attributes, " "which can be used, for example, to attach metadata to functions. Regular " "attribute dot-notation is used to get and set such attributes." msgstr "" -#: ../../reference/datamodel.rst:645 +#: ../../reference/datamodel.rst:646 msgid "" "CPython's current implementation only supports function attributes on user-" "defined functions. Function attributes on :ref:`built-in functions ` may be supported in the future." msgstr "" -#: ../../reference/datamodel.rst:650 +#: ../../reference/datamodel.rst:651 msgid "" "Additional information about a function's definition can be retrieved from " "its :ref:`code object ` (accessible via the :attr:`~function." "__code__` attribute)." msgstr "" -#: ../../reference/datamodel.rst:658 +#: ../../reference/datamodel.rst:659 msgid "Instance methods" msgstr "インスタンスメソッド" -#: ../../reference/datamodel.rst:665 +#: ../../reference/datamodel.rst:666 msgid "" "An instance method object combines a class, a class instance and any " "callable object (normally a user-defined function)." @@ -924,45 +925,45 @@ msgstr "" "インスタンスメソッドオブジェクトは、クラス、クラスインスタンスと任意の呼び出" "し可能オブジェクト (通常はユーザ定義関数) を結びつけます。" -#: ../../reference/datamodel.rst:675 ../../reference/datamodel.rst:1541 +#: ../../reference/datamodel.rst:676 ../../reference/datamodel.rst:1734 msgid "Special read-only attributes:" msgstr "" -#: ../../reference/datamodel.rst:680 +#: ../../reference/datamodel.rst:681 msgid "" "Refers to the class instance object to which the method is :ref:`bound " "`" msgstr "" -#: ../../reference/datamodel.rst:684 +#: ../../reference/datamodel.rst:685 msgid "Refers to the original :ref:`function object `" msgstr "" -#: ../../reference/datamodel.rst:687 +#: ../../reference/datamodel.rst:688 msgid "" "The method's documentation (same as :attr:`method.__func__.__doc__ `). A :class:`string ` if the original function had a " "docstring, else ``None``." msgstr "" -#: ../../reference/datamodel.rst:693 +#: ../../reference/datamodel.rst:694 msgid "" "The name of the method (same as :attr:`method.__func__.__name__ `)" msgstr "" -#: ../../reference/datamodel.rst:697 +#: ../../reference/datamodel.rst:698 msgid "" "The name of the module the method was defined in, or ``None`` if unavailable." msgstr "" -#: ../../reference/datamodel.rst:700 +#: ../../reference/datamodel.rst:701 msgid "" "Methods also support accessing (but not setting) the arbitrary function " "attributes on the underlying :ref:`function object `." msgstr "" -#: ../../reference/datamodel.rst:703 +#: ../../reference/datamodel.rst:704 msgid "" "User-defined method objects may be created when getting an attribute of a " "class (perhaps via an instance of that class), if that attribute is a user-" @@ -970,7 +971,7 @@ msgid "" "`classmethod` object." msgstr "" -#: ../../reference/datamodel.rst:710 +#: ../../reference/datamodel.rst:711 msgid "" "When an instance method object is created by retrieving a user-defined :ref:" "`function object ` from a class via one of its " @@ -979,7 +980,7 @@ msgid "" "__func__` attribute is the original function object." msgstr "" -#: ../../reference/datamodel.rst:716 +#: ../../reference/datamodel.rst:717 msgid "" "When an instance method object is created by retrieving a :class:" "`classmethod` object from a class or instance, its :attr:`~method.__self__` " @@ -987,7 +988,7 @@ msgid "" "the function object underlying the class method." msgstr "" -#: ../../reference/datamodel.rst:721 +#: ../../reference/datamodel.rst:722 msgid "" "When an instance method object is called, the underlying function (:attr:" "`~method.__func__`) is called, inserting the class instance (:attr:`~method." @@ -997,7 +998,7 @@ msgid "" "f(x, 1)``." msgstr "" -#: ../../reference/datamodel.rst:728 +#: ../../reference/datamodel.rst:729 msgid "" "When an instance method object is derived from a :class:`classmethod` " "object, the \"class instance\" stored in :attr:`~method.__self__` will " @@ -1006,18 +1007,18 @@ msgid "" "function." msgstr "" -#: ../../reference/datamodel.rst:733 +#: ../../reference/datamodel.rst:734 msgid "" "It is important to note that user-defined functions which are attributes of " "a class instance are not converted to bound methods; this *only* happens " "when the function is an attribute of the class." msgstr "" -#: ../../reference/datamodel.rst:740 +#: ../../reference/datamodel.rst:741 msgid "Generator functions" msgstr "ジェネレータ関数 (generator function)" -#: ../../reference/datamodel.rst:746 +#: ../../reference/datamodel.rst:747 msgid "" "A function or method which uses the :keyword:`yield` statement (see section :" "ref:`yield`) is called a :dfn:`generator function`. Such a function, when " @@ -1039,11 +1040,11 @@ msgstr "" "`StopIteration` 例外が送出され、イテレータが返すべき値の最後まで到達していま" "す。" -#: ../../reference/datamodel.rst:758 +#: ../../reference/datamodel.rst:759 msgid "Coroutine functions" msgstr "コルーチン関数 (coroutine function)" -#: ../../reference/datamodel.rst:763 +#: ../../reference/datamodel.rst:764 msgid "" "A function or method which is defined using :keyword:`async def` is called " "a :dfn:`coroutine function`. Such a function, when called, returns a :term:" @@ -1058,11 +1059,11 @@ msgstr "" "keyword:`await` 式を持つことが出来ます。\n" ":ref:`coroutine-objects` を参照してください。" -#: ../../reference/datamodel.rst:771 +#: ../../reference/datamodel.rst:772 msgid "Asynchronous generator functions" msgstr "非同期ジェネレータ関数 (asynchronous generator function)" -#: ../../reference/datamodel.rst:777 +#: ../../reference/datamodel.rst:778 msgid "" "A function or method which is defined using :keyword:`async def` and which " "uses the :keyword:`yield` statement is called a :dfn:`asynchronous generator " @@ -1077,7 +1078,7 @@ msgstr "" "このオブジェクトは :keyword:`async for` 文で関数の本体を実行するのに使えま" "す。" -#: ../../reference/datamodel.rst:783 +#: ../../reference/datamodel.rst:784 msgid "" "Calling the asynchronous iterator's :meth:`aiterator.__anext__ ` method will return an :term:`awaitable` which when awaited will " @@ -1094,11 +1095,11 @@ msgstr "" "ときは、 :exc:`StopAsyncIteration` 例外が送出され、非同期イテレータは出力すべ" "き値の最後に到達したことになります。" -#: ../../reference/datamodel.rst:796 +#: ../../reference/datamodel.rst:797 msgid "Built-in functions" msgstr "組み込み関数 (built-in function)" -#: ../../reference/datamodel.rst:803 +#: ../../reference/datamodel.rst:804 msgid "" "A built-in function object is a wrapper around a C function. Examples of " "built-in functions are :func:`len` and :func:`math.sin` (:mod:`math` is a " @@ -1106,32 +1107,32 @@ msgid "" "determined by the C function. Special read-only attributes:" msgstr "" -#: ../../reference/datamodel.rst:808 +#: ../../reference/datamodel.rst:809 msgid "" ":attr:`!__doc__` is the function's documentation string, or ``None`` if " "unavailable. See :attr:`function.__doc__`." msgstr "" -#: ../../reference/datamodel.rst:810 +#: ../../reference/datamodel.rst:811 msgid "" ":attr:`!__name__` is the function's name. See :attr:`function.__name__`." msgstr "" -#: ../../reference/datamodel.rst:811 +#: ../../reference/datamodel.rst:812 msgid ":attr:`!__self__` is set to ``None`` (but see the next item)." msgstr "" -#: ../../reference/datamodel.rst:812 +#: ../../reference/datamodel.rst:813 msgid "" ":attr:`!__module__` is the name of the module the function was defined in or " "``None`` if unavailable. See :attr:`function.__module__`." msgstr "" -#: ../../reference/datamodel.rst:820 +#: ../../reference/datamodel.rst:821 msgid "Built-in methods" msgstr "組み込みメソッド (built-in method)" -#: ../../reference/datamodel.rst:827 +#: ../../reference/datamodel.rst:828 msgid "" "This is really a different disguise of a built-in function, this time " "containing an object passed to the C function as an implicit extra " @@ -1142,11 +1143,11 @@ msgid "" "__self__>`.)" msgstr "" -#: ../../reference/datamodel.rst:837 +#: ../../reference/datamodel.rst:838 msgid "Classes" msgstr "クラス" -#: ../../reference/datamodel.rst:839 +#: ../../reference/datamodel.rst:840 msgid "" "Classes are callable. These objects normally act as factories for new " "instances of themselves, but variations are possible for class types that " @@ -1155,11 +1156,11 @@ msgid "" "initialize the new instance." msgstr "" -#: ../../reference/datamodel.rst:847 +#: ../../reference/datamodel.rst:848 msgid "Class Instances" msgstr "クラスのインスタンス" -#: ../../reference/datamodel.rst:849 +#: ../../reference/datamodel.rst:850 msgid "" "Instances of arbitrary classes can be made callable by defining a :meth:" "`~object.__call__` method in their class." @@ -1167,11 +1168,11 @@ msgstr "" "任意のクラスのインスタンスは、クラスで :meth:`~object.__call__` メソッドを定" "義することで呼び出し可能になります。" -#: ../../reference/datamodel.rst:854 +#: ../../reference/datamodel.rst:857 msgid "Modules" msgstr "モジュール" -#: ../../reference/datamodel.rst:860 +#: ../../reference/datamodel.rst:863 msgid "" "Modules are a basic organizational unit of Python code, and are created by " "the :ref:`import system ` as invoked either by the :keyword:" @@ -1186,7 +1187,7 @@ msgid "" "done)." msgstr "" -#: ../../reference/datamodel.rst:873 +#: ../../reference/datamodel.rst:876 msgid "" "Attribute assignment updates the module's namespace dictionary, e.g., ``m.x " "= 1`` is equivalent to ``m.__dict__[\"x\"] = 1``." @@ -1194,49 +1195,258 @@ msgstr "" "属性の代入を行うと、モジュールの名前空間辞書の内容を更新します。例えば、 ``m." "x = 1`` は ``m.__dict__[\"x\"] = 1`` と同じです。" -#: ../../reference/datamodel.rst:883 -msgid "Predefined (writable) attributes:" -msgstr "定義済みの (書き込み可能な) 属性:" +#: ../../reference/datamodel.rst:894 +msgid "Import-related attributes on module objects" +msgstr "" -#: ../../reference/datamodel.rst:885 -msgid ":attr:`__name__`" -msgstr ":attr:`__name__`" +#: ../../reference/datamodel.rst:896 +msgid "" +"Module objects have the following attributes that relate to the :ref:`import " +"system `. When a module is created using the machinery " +"associated with the import system, these attributes are filled in based on " +"the module's :term:`spec `, before the :term:`loader` executes " +"and loads the module." +msgstr "" -#: ../../reference/datamodel.rst:886 -msgid "The module's name." -msgstr "モジュールの名前。" +#: ../../reference/datamodel.rst:902 +msgid "" +"To create a module dynamically rather than using the import system, it's " +"recommended to use :func:`importlib.util.module_from_spec`, which will set " +"the various import-controlled attributes to appropriate values. It's also " +"possible to use the :class:`types.ModuleType` constructor to create modules " +"directly, but this technique is more error-prone, as most attributes must be " +"manually set on the module object after it has been created when using this " +"approach." +msgstr "" -#: ../../reference/datamodel.rst:888 -msgid ":attr:`__doc__`" -msgstr ":attr:`__doc__`" +#: ../../reference/datamodel.rst:912 +msgid "" +"With the exception of :attr:`~module.__name__`, it is **strongly** " +"recommended that you rely on :attr:`~module.__spec__` and its attributes " +"instead of any of the other individual attributes listed in this subsection. " +"Note that updating an attribute on :attr:`!__spec__` will not update the " +"corresponding attribute on the module itself:" +msgstr "" -#: ../../reference/datamodel.rst:889 -msgid "The module's documentation string, or ``None`` if unavailable." +#: ../../reference/datamodel.rst:918 +msgid "" +">>> import typing\n" +">>> typing.__name__, typing.__spec__.name\n" +"('typing', 'typing')\n" +">>> typing.__spec__.name = 'spelling'\n" +">>> typing.__name__, typing.__spec__.name\n" +"('typing', 'spelling')\n" +">>> typing.__name__ = 'keyboard_smashing'\n" +">>> typing.__name__, typing.__spec__.name\n" +"('keyboard_smashing', 'spelling')" msgstr "" -"モジュールのドキュメントで、文字列か、もし利用できない場合は ``None`` です。" -#: ../../reference/datamodel.rst:892 -msgid ":attr:`__file__`" -msgstr ":attr:`__file__`" +#: ../../reference/datamodel.rst:932 +msgid "" +"The name used to uniquely identify the module in the import system. For a " +"directly executed module, this will be set to ``\"__main__\"``." +msgstr "" -#: ../../reference/datamodel.rst:893 +#: ../../reference/datamodel.rst:935 msgid "" -"The pathname of the file from which the module was loaded, if it was loaded " -"from a file. The :attr:`__file__` attribute may be missing for certain types " -"of modules, such as C modules that are statically linked into the " -"interpreter. For extension modules loaded dynamically from a shared " -"library, it's the pathname of the shared library file." +"This attribute must be set to the fully qualified name of the module. It is " +"expected to match the value of :attr:`module.__spec__.name `." msgstr "" -"ロードされたモジュールファイルのパス名です。インタプリタに静的にリンクされて" -"いる C モジュールのような特定の種類のモジュールでは、 :attr:`__file__` 属性は" -"存在しないかもしれません。共有ライブラリから動的にロードされた拡張モジュール" -"の場合、この属性は 共有ライブラリファイルのパス名になります。" -#: ../../reference/datamodel.rst:901 -msgid ":attr:`__annotations__`" -msgstr ":attr:`__annotations__`" +#: ../../reference/datamodel.rst:941 +msgid "A record of the module's import-system-related state." +msgstr "" -#: ../../reference/datamodel.rst:902 +#: ../../reference/datamodel.rst:943 +msgid "" +"Set to the :class:`module spec ` that was " +"used when importing the module. See :ref:`module-specs` for more details." +msgstr "" + +#: ../../reference/datamodel.rst:950 +msgid "The :term:`package` a module belongs to." +msgstr "" + +#: ../../reference/datamodel.rst:952 +msgid "" +"If the module is top-level (that is, not a part of any specific package) " +"then the attribute should be set to ``''`` (the empty string). Otherwise, it " +"should be set to the name of the module's package (which can be equal to :" +"attr:`module.__name__` if the module itself is a package). See :pep:`366` " +"for further details." +msgstr "" + +#: ../../reference/datamodel.rst:958 +msgid "" +"This attribute is used instead of :attr:`~module.__name__` to calculate " +"explicit relative imports for main modules. It defaults to ``None`` for " +"modules created dynamically using the :class:`types.ModuleType` constructor; " +"use :func:`importlib.util.module_from_spec` instead to ensure the attribute " +"is set to a :class:`str`." +msgstr "" + +#: ../../reference/datamodel.rst:964 +msgid "" +"It is **strongly** recommended that you use :attr:`module.__spec__.parent " +"` instead of :attr:`!module." +"__package__`. :attr:`__package__` is now only used as a fallback if :attr:`!" +"__spec__.parent` is not set, and this fallback path is deprecated." +msgstr "" + +#: ../../reference/datamodel.rst:970 ../../reference/datamodel.rst:1011 +msgid "" +"This attribute now defaults to ``None`` for modules created dynamically " +"using the :class:`types.ModuleType` constructor. Previously the attribute " +"was optional." +msgstr "" + +#: ../../reference/datamodel.rst:975 +msgid "" +"The value of :attr:`!__package__` is expected to be the same as :attr:" +"`__spec__.parent `. :attr:" +"`__package__` is now only used as a fallback during import resolution if :" +"attr:`!__spec__.parent` is not defined." +msgstr "" + +#: ../../reference/datamodel.rst:981 +msgid "" +":exc:`ImportWarning` is raised if an import resolution falls back to :attr:`!" +"__package__` instead of :attr:`__spec__.parent `." +msgstr "" + +#: ../../reference/datamodel.rst:986 +msgid "" +"Raise :exc:`DeprecationWarning` instead of :exc:`ImportWarning` when falling " +"back to :attr:`!__package__` during import resolution." +msgstr "" + +#: ../../reference/datamodel.rst:990 +msgid "" +":attr:`!__package__` will cease to be set or taken into consideration by the " +"import system or standard library." +msgstr "" + +#: ../../reference/datamodel.rst:996 +msgid "" +"The :term:`loader` object that the import machinery used to load the module." +msgstr "" + +#: ../../reference/datamodel.rst:998 +msgid "" +"This attribute is mostly useful for introspection, but can be used for " +"additional loader-specific functionality, for example getting data " +"associated with a loader." +msgstr "" + +#: ../../reference/datamodel.rst:1002 +msgid "" +":attr:`!__loader__` defaults to ``None`` for modules created dynamically " +"using the :class:`types.ModuleType` constructor; use :func:`importlib.util." +"module_from_spec` instead to ensure the attribute is set to a :term:`loader` " +"object." +msgstr "" + +#: ../../reference/datamodel.rst:1007 +msgid "" +"It is **strongly** recommended that you use :attr:`module.__spec__.loader " +"` instead of :attr:`!module." +"__loader__`." +msgstr "" + +#: ../../reference/datamodel.rst:1016 +msgid "" +"Setting :attr:`!__loader__` on a module while failing to set :attr:`!" +"__spec__.loader` is deprecated. In Python 3.14, :attr:`!__loader__` will " +"cease to be set or taken into consideration by the import system or the " +"standard library." +msgstr "" + +#: ../../reference/datamodel.rst:1024 +msgid "" +"A (possibly empty) :term:`sequence` of strings enumerating the locations " +"where the package's submodules will be found. Non-package modules should not " +"have a :attr:`!__path__` attribute. See :ref:`package-path-rules` for more " +"details." +msgstr "" + +#: ../../reference/datamodel.rst:1029 +msgid "" +"It is **strongly** recommended that you use :attr:`module.__spec__." +"submodule_search_locations ` instead of :attr:`!module.__path__`." +msgstr "" + +#: ../../reference/datamodel.rst:1036 +msgid "" +":attr:`!__file__` and :attr:`!__cached__` are both optional attributes that " +"may or may not be set. Both attributes should be a :class:`str` when they " +"are available." +msgstr "" + +#: ../../reference/datamodel.rst:1040 +msgid "" +":attr:`!__file__` indicates the pathname of the file from which the module " +"was loaded (if loaded from a file), or the pathname of the shared library " +"file for extension modules loaded dynamically from a shared library. It " +"might be missing for certain types of modules, such as C modules that are " +"statically linked into the interpreter, and the :ref:`import system " +"` may opt to leave it unset if it has no semantic meaning (for " +"example, a module loaded from a database)." +msgstr "" + +#: ../../reference/datamodel.rst:1048 +msgid "" +"If :attr:`!__file__` is set then the :attr:`!__cached__` attribute might " +"also be set, which is the path to any compiled version of the code (for " +"example, a byte-compiled file). The file does not need to exist to set this " +"attribute; the path can simply point to where the compiled file *would* " +"exist (see :pep:`3147`)." +msgstr "" + +#: ../../reference/datamodel.rst:1054 +msgid "" +"Note that :attr:`!__cached__` may be set even if :attr:`!__file__` is not " +"set. However, that scenario is quite atypical. Ultimately, the :term:" +"`loader` is what makes use of the module spec provided by the :term:`finder` " +"(from which :attr:`!__file__` and :attr:`!__cached__` are derived). So if a " +"loader can load from a cached module but otherwise does not load from a " +"file, that atypical scenario may be appropriate." +msgstr "" + +#: ../../reference/datamodel.rst:1061 +msgid "" +"It is **strongly** recommended that you use :attr:`module.__spec__.cached " +"` instead of :attr:`!module." +"__cached__`." +msgstr "" + +#: ../../reference/datamodel.rst:1065 +msgid "" +"Setting :attr:`!__cached__` on a module while failing to set :attr:`!" +"__spec__.cached` is deprecated. In Python 3.15, :attr:`!__cached__` will " +"cease to be set or taken into consideration by the import system or standard " +"library." +msgstr "" + +#: ../../reference/datamodel.rst:1072 +msgid "Other writable attributes on module objects" +msgstr "" + +#: ../../reference/datamodel.rst:1074 +msgid "" +"As well as the import-related attributes listed above, module objects also " +"have the following writable attributes:" +msgstr "" + +#: ../../reference/datamodel.rst:1079 +msgid "" +"The module's documentation string, or ``None`` if unavailable. See also: :" +"attr:`__doc__ attributes `." +msgstr "" + +#: ../../reference/datamodel.rst:1084 msgid "" "A dictionary containing :term:`variable annotations ` " "collected during module body execution. For best practices on working with :" @@ -1247,15 +1457,22 @@ msgstr "" "ラクティスについては、 :ref:`アノテーションのHOWTO ` を参" "照してください。" -#: ../../reference/datamodel.rst:909 +#: ../../reference/datamodel.rst:1090 +msgid "Module dictionaries" +msgstr "" + +#: ../../reference/datamodel.rst:1092 +msgid "Module objects also have the following special read-only attribute:" +msgstr "" + +#: ../../reference/datamodel.rst:1097 msgid "" -"Special read-only attribute: :attr:`~object.__dict__` is the module's " -"namespace as a dictionary object." +"The module's namespace as a dictionary object. Uniquely among the attributes " +"listed here, :attr:`!__dict__` cannot be accessed as a global variable from " +"within a module; it can only be accessed as an attribute on module objects." msgstr "" -"読み出し専用の特殊属性: :attr:`~object.__dict__` はモジュールの名前空間で、辞" -"書オブジェクトです。" -#: ../../reference/datamodel.rst:914 +#: ../../reference/datamodel.rst:1103 msgid "" "Because of the way CPython clears module dictionaries, the module dictionary " "will be cleared when the module falls out of scope even if the dictionary " @@ -1267,11 +1484,11 @@ msgstr "" "これを避けるには、辞書をコピーするか、辞書を直接使っている間モジュールを保持" "してください。" -#: ../../reference/datamodel.rst:923 +#: ../../reference/datamodel.rst:1112 msgid "Custom classes" msgstr "カスタムクラス型" -#: ../../reference/datamodel.rst:925 +#: ../../reference/datamodel.rst:1114 msgid "" "Custom class types are typically created by class definitions (see section :" "ref:`class`). A class has a namespace implemented by a dictionary object. " @@ -1286,7 +1503,7 @@ msgid "" "found at :ref:`python_2.3_mro`." msgstr "" -#: ../../reference/datamodel.rst:946 +#: ../../reference/datamodel.rst:1135 msgid "" "When a class attribute reference (for class :class:`!C`, say) would yield a " "class method object, it is transformed into an instance method object whose :" @@ -1297,7 +1514,7 @@ msgid "" "contained in its :attr:`~object.__dict__`." msgstr "" -#: ../../reference/datamodel.rst:957 +#: ../../reference/datamodel.rst:1146 msgid "" "Class attribute assignments update the class's dictionary, never the " "dictionary of a base class." @@ -1305,7 +1522,7 @@ msgstr "" "クラス属性を代入すると、そのクラスの辞書だけが更新され、基底クラスの辞書は更" "新しません。" -#: ../../reference/datamodel.rst:962 +#: ../../reference/datamodel.rst:1151 msgid "" "A class object can be called (see above) to yield a class instance (see " "below)." @@ -1313,54 +1530,54 @@ msgstr "" "クラスオブジェクトを呼び出す (上記を参照) と、クラスインスタンスを生成します " "(下記を参照)。" -#: ../../reference/datamodel.rst:965 ../../reference/datamodel.rst:1112 +#: ../../reference/datamodel.rst:1154 ../../reference/datamodel.rst:1301 msgid "Special attributes" msgstr "" -#: ../../reference/datamodel.rst:985 +#: ../../reference/datamodel.rst:1174 msgid "" "The class's name. See also: :attr:`__name__ attributes `." msgstr "" -#: ../../reference/datamodel.rst:989 +#: ../../reference/datamodel.rst:1178 msgid "" "The class's :term:`qualified name`. See also: :attr:`__qualname__ attributes " "`." msgstr "" -#: ../../reference/datamodel.rst:993 +#: ../../reference/datamodel.rst:1182 msgid "The name of the module in which the class was defined." msgstr "クラスが定義されているモジュールの名前。" -#: ../../reference/datamodel.rst:996 +#: ../../reference/datamodel.rst:1185 msgid "" "A :class:`mapping proxy ` providing a read-only view " "of the class's namespace. See also: :attr:`__dict__ attributes `." msgstr "" -#: ../../reference/datamodel.rst:1001 +#: ../../reference/datamodel.rst:1190 msgid "" "A :class:`tuple` containing the class's bases. In most cases, for a class " "defined as ``class X(A, B, C)``, ``X.__bases__`` will be exactly equal to " "``(A, B, C)``." msgstr "" -#: ../../reference/datamodel.rst:1006 +#: ../../reference/datamodel.rst:1195 msgid "" "The class's documentation string, or ``None`` if undefined. Not inherited by " "subclasses." msgstr "" -#: ../../reference/datamodel.rst:1010 +#: ../../reference/datamodel.rst:1199 msgid "" "A dictionary containing :term:`variable annotations ` " "collected during class body execution. For best practices on working with :" "attr:`!__annotations__`, please see :ref:`annotations-howto`." msgstr "" -#: ../../reference/datamodel.rst:1017 +#: ../../reference/datamodel.rst:1206 msgid "" "Accessing the :attr:`!__annotations__` attribute of a class object directly " "may yield incorrect results in the presence of metaclasses. In addition, the " @@ -1368,56 +1585,56 @@ msgid "" "get_annotations` to retrieve class annotations safely." msgstr "" -#: ../../reference/datamodel.rst:1024 +#: ../../reference/datamodel.rst:1213 msgid "" "A :class:`tuple` containing the :ref:`type parameters ` of a :" "ref:`generic class `." msgstr "" -#: ../../reference/datamodel.rst:1030 +#: ../../reference/datamodel.rst:1219 msgid "" "A :class:`tuple` containing names of attributes of this class which are " "assigned through ``self.X`` from any function in its body." msgstr "" -#: ../../reference/datamodel.rst:1036 +#: ../../reference/datamodel.rst:1225 msgid "" "The line number of the first line of the class definition, including " "decorators. Setting the :attr:`__module__` attribute removes the :attr:`!" "__firstlineno__` item from the type's dictionary." msgstr "" -#: ../../reference/datamodel.rst:1044 +#: ../../reference/datamodel.rst:1233 msgid "" "The :class:`tuple` of classes that are considered when looking for base " "classes during method resolution." msgstr "" -#: ../../reference/datamodel.rst:1049 +#: ../../reference/datamodel.rst:1238 msgid "Special methods" msgstr "" -#: ../../reference/datamodel.rst:1051 +#: ../../reference/datamodel.rst:1240 msgid "" "In addition to the special attributes described above, all Python classes " "also have the following two methods available:" msgstr "" -#: ../../reference/datamodel.rst:1056 +#: ../../reference/datamodel.rst:1245 msgid "" "This method can be overridden by a metaclass to customize the method " "resolution order for its instances. It is called at class instantiation, " "and its result is stored in :attr:`~type.__mro__`." msgstr "" -#: ../../reference/datamodel.rst:1062 +#: ../../reference/datamodel.rst:1251 msgid "" "Each class keeps a list of weak references to its immediate subclasses. This " "method returns a list of all those references still alive. The list is in " "definition order. Example:" msgstr "" -#: ../../reference/datamodel.rst:1066 +#: ../../reference/datamodel.rst:1255 msgid "" ">>> class A: pass\n" ">>> class B(A): pass\n" @@ -1425,11 +1642,11 @@ msgid "" "[]" msgstr "" -#: ../../reference/datamodel.rst:1074 +#: ../../reference/datamodel.rst:1263 msgid "Class instances" msgstr "クラスインスタンス (class instance)" -#: ../../reference/datamodel.rst:1082 +#: ../../reference/datamodel.rst:1271 msgid "" "A class instance is created by calling a class object (see above). A class " "instance has a namespace implemented as a dictionary which is the first " @@ -1446,7 +1663,7 @@ msgid "" "__getattr__` method, that is called to satisfy the lookup." msgstr "" -#: ../../reference/datamodel.rst:1098 +#: ../../reference/datamodel.rst:1287 msgid "" "Attribute assignments and deletions update the instance's dictionary, never " "a class's dictionary. If the class has a :meth:`~object.__setattr__` or :" @@ -1458,7 +1675,7 @@ msgstr "" "`~object.__delattr__` メソッドが定義されている場合、直接インスタンスの辞書を" "更新する代わりにこれらのメソッドが呼び出されます。" -#: ../../reference/datamodel.rst:1108 +#: ../../reference/datamodel.rst:1297 msgid "" "Class instances can pretend to be numbers, sequences, or mappings if they " "have methods with certain special names. See section :ref:`specialnames`." @@ -1467,22 +1684,22 @@ msgstr "" "ケンス型、あるいはマップ型のように振舞うことができます。 :ref:`specialnames` " "を参照してください。" -#: ../../reference/datamodel.rst:1120 +#: ../../reference/datamodel.rst:1309 msgid "The class to which a class instance belongs." msgstr "クラスインスタンスが属しているクラスです。" -#: ../../reference/datamodel.rst:1124 +#: ../../reference/datamodel.rst:1313 msgid "" "A dictionary or other mapping object used to store an object's (writable) " "attributes. Not all instances have a :attr:`!__dict__` attribute; see the " "section on :ref:`slots` for more details." msgstr "" -#: ../../reference/datamodel.rst:1130 +#: ../../reference/datamodel.rst:1319 msgid "I/O objects (also known as file objects)" msgstr "I/O オブジェクト (ファイルオブジェクトの別名)" -#: ../../reference/datamodel.rst:1145 +#: ../../reference/datamodel.rst:1334 msgid "" "A :term:`file object` represents an open file. Various shortcuts are " "available to create file objects: the :func:`open` built-in function, and " @@ -1496,7 +1713,7 @@ msgstr "" "makefile` メソッド (あるいは拡張モジュールから提供される他の関数やメソッ" "ド) 。" -#: ../../reference/datamodel.rst:1151 +#: ../../reference/datamodel.rst:1340 msgid "" "The objects ``sys.stdin``, ``sys.stdout`` and ``sys.stderr`` are initialized " "to file objects corresponding to the interpreter's standard input, output " @@ -1508,11 +1725,11 @@ msgstr "" "オブジェクトに初期化されます。これらはすべてテキストモードで開かれ、 :class:" "`io.TextIOBase` 抽象クラスによって定義されたインターフェースに従います。" -#: ../../reference/datamodel.rst:1159 +#: ../../reference/datamodel.rst:1348 msgid "Internal types" msgstr "内部型 (internal type)" -#: ../../reference/datamodel.rst:1165 +#: ../../reference/datamodel.rst:1354 msgid "" "A few types used internally by the interpreter are exposed to the user. " "Their definitions may change with future versions of the interpreter, but " @@ -1522,11 +1739,11 @@ msgstr "" "れらの定義は将来のインタプリタのバージョンでは変更される可能性がありますが、" "ここでは記述の完全性のために触れておきます。" -#: ../../reference/datamodel.rst:1173 +#: ../../reference/datamodel.rst:1362 msgid "Code objects" msgstr "コードオブジェクト" -#: ../../reference/datamodel.rst:1177 +#: ../../reference/datamodel.rst:1366 msgid "" "Code objects represent *byte-compiled* executable Python code, or :term:" "`bytecode`. The difference between a code object and a function object is " @@ -1547,103 +1764,111 @@ msgstr "" "ジェクトは変更不可能で、変更可能なオブジェクトへの参照を (直接、間接に関わら" "ず) 含みません。" -#: ../../reference/datamodel.rst:1211 +#: ../../reference/datamodel.rst:1400 msgid "The function name" msgstr "" -#: ../../reference/datamodel.rst:1214 +#: ../../reference/datamodel.rst:1403 msgid "The fully qualified function name" msgstr "" -#: ../../reference/datamodel.rst:1219 +#: ../../reference/datamodel.rst:1408 msgid "" "The total number of positional :term:`parameters ` (including " "positional-only parameters and parameters with default values) that the " "function has" msgstr "" -#: ../../reference/datamodel.rst:1224 +#: ../../reference/datamodel.rst:1413 msgid "" "The number of positional-only :term:`parameters ` (including " "arguments with default values) that the function has" msgstr "" -#: ../../reference/datamodel.rst:1228 +#: ../../reference/datamodel.rst:1417 msgid "" "The number of keyword-only :term:`parameters ` (including " "arguments with default values) that the function has" msgstr "" -#: ../../reference/datamodel.rst:1232 +#: ../../reference/datamodel.rst:1421 msgid "" "The number of :ref:`local variables ` used by the function " "(including parameters)" msgstr "" -#: ../../reference/datamodel.rst:1236 +#: ../../reference/datamodel.rst:1425 msgid "" "A :class:`tuple` containing the names of the local variables in the function " "(starting with the parameter names)" msgstr "" -#: ../../reference/datamodel.rst:1240 +#: ../../reference/datamodel.rst:1429 msgid "" "A :class:`tuple` containing the names of :ref:`local variables ` " -"that are referenced by nested functions inside the function" +"that are referenced from at least one :term:`nested scope` inside the " +"function" +msgstr "" + +#: ../../reference/datamodel.rst:1433 +msgid "" +"A :class:`tuple` containing the names of :term:`free (closure) variables " +"` that a :term:`nested scope` references in an outer " +"scope. See also :attr:`function.__closure__`." msgstr "" -#: ../../reference/datamodel.rst:1244 -msgid "A :class:`tuple` containing the names of free variables in the function" +#: ../../reference/datamodel.rst:1437 +msgid "Note: references to global and builtin names are *not* included." msgstr "" -#: ../../reference/datamodel.rst:1247 +#: ../../reference/datamodel.rst:1440 msgid "" "A string representing the sequence of :term:`bytecode` instructions in the " "function" msgstr "" -#: ../../reference/datamodel.rst:1251 +#: ../../reference/datamodel.rst:1444 msgid "" "A :class:`tuple` containing the literals used by the :term:`bytecode` in the " "function" msgstr "" -#: ../../reference/datamodel.rst:1255 +#: ../../reference/datamodel.rst:1448 msgid "" "A :class:`tuple` containing the names used by the :term:`bytecode` in the " "function" msgstr "" -#: ../../reference/datamodel.rst:1259 +#: ../../reference/datamodel.rst:1452 msgid "The name of the file from which the code was compiled" msgstr "" -#: ../../reference/datamodel.rst:1262 +#: ../../reference/datamodel.rst:1455 msgid "The line number of the first line of the function" msgstr "" -#: ../../reference/datamodel.rst:1265 +#: ../../reference/datamodel.rst:1458 msgid "" "A string encoding the mapping from :term:`bytecode` offsets to line numbers. " "For details, see the source code of the interpreter." msgstr "" -#: ../../reference/datamodel.rst:1268 +#: ../../reference/datamodel.rst:1461 msgid "" "This attribute of code objects is deprecated, and may be removed in Python " "3.14." msgstr "" -#: ../../reference/datamodel.rst:1273 +#: ../../reference/datamodel.rst:1466 msgid "The required stack size of the code object" msgstr "" -#: ../../reference/datamodel.rst:1276 +#: ../../reference/datamodel.rst:1469 msgid "" "An :class:`integer ` encoding a number of flags for the interpreter." msgstr "" -#: ../../reference/datamodel.rst:1281 +#: ../../reference/datamodel.rst:1474 msgid "" "The following flag bits are defined for :attr:`~codeobject.co_flags`: bit " "``0x04`` is set if the function uses the ``*arguments`` syntax to accept an " @@ -1654,7 +1879,7 @@ msgid "" "might be present." msgstr "" -#: ../../reference/datamodel.rst:1289 +#: ../../reference/datamodel.rst:1482 msgid "" "Future feature declarations (``from __future__ import division``) also use " "bits in :attr:`~codeobject.co_flags` to indicate whether a code object was " @@ -1663,29 +1888,29 @@ msgid "" "``0x1000`` were used in earlier versions of Python." msgstr "" -#: ../../reference/datamodel.rst:1295 +#: ../../reference/datamodel.rst:1488 msgid "" "Other bits in :attr:`~codeobject.co_flags` are reserved for internal use." msgstr "" -#: ../../reference/datamodel.rst:1299 +#: ../../reference/datamodel.rst:1492 msgid "" "If a code object represents a function, the first item in :attr:`~codeobject." "co_consts` is the documentation string of the function, or ``None`` if " "undefined." msgstr "" -#: ../../reference/datamodel.rst:1304 +#: ../../reference/datamodel.rst:1497 msgid "Methods on code objects" msgstr "" -#: ../../reference/datamodel.rst:1308 +#: ../../reference/datamodel.rst:1501 msgid "" "Returns an iterable over the source code positions of each :term:`bytecode` " "instruction in the code object." msgstr "" -#: ../../reference/datamodel.rst:1311 +#: ../../reference/datamodel.rst:1504 msgid "" "The iterator returns :class:`tuple`\\s containing the ``(start_line, " "end_line, start_column, end_column)``. The *i-th* tuple corresponds to the " @@ -1693,37 +1918,37 @@ msgid "" "information is 0-indexed utf-8 byte offsets on the given source line." msgstr "" -#: ../../reference/datamodel.rst:1317 +#: ../../reference/datamodel.rst:1510 msgid "" "This positional information can be missing. A non-exhaustive lists of cases " "where this may happen:" msgstr "" -#: ../../reference/datamodel.rst:1320 +#: ../../reference/datamodel.rst:1513 msgid "Running the interpreter with :option:`-X` ``no_debug_ranges``." msgstr "" -#: ../../reference/datamodel.rst:1321 +#: ../../reference/datamodel.rst:1514 msgid "" "Loading a pyc file compiled while using :option:`-X` ``no_debug_ranges``." msgstr "" -#: ../../reference/datamodel.rst:1322 +#: ../../reference/datamodel.rst:1515 msgid "Position tuples corresponding to artificial instructions." msgstr "" -#: ../../reference/datamodel.rst:1323 +#: ../../reference/datamodel.rst:1516 msgid "" "Line and column numbers that can't be represented due to implementation " "specific limitations." msgstr "" -#: ../../reference/datamodel.rst:1326 +#: ../../reference/datamodel.rst:1519 msgid "" "When this occurs, some or all of the tuple elements can be :const:`None`." msgstr "" -#: ../../reference/datamodel.rst:1332 +#: ../../reference/datamodel.rst:1525 msgid "" "This feature requires storing column positions in code objects which may " "result in a small increase of disk usage of compiled Python files or " @@ -1733,155 +1958,155 @@ msgid "" "environment variable can be used." msgstr "" -#: ../../reference/datamodel.rst:1341 +#: ../../reference/datamodel.rst:1534 msgid "" "Returns an iterator that yields information about successive ranges of :term:" "`bytecode`\\s. Each item yielded is a ``(start, end, lineno)`` :class:" "`tuple`:" msgstr "" -#: ../../reference/datamodel.rst:1345 +#: ../../reference/datamodel.rst:1538 msgid "" "``start`` (an :class:`int`) represents the offset (inclusive) of the start " "of the :term:`bytecode` range" msgstr "" -#: ../../reference/datamodel.rst:1347 +#: ../../reference/datamodel.rst:1540 msgid "" "``end`` (an :class:`int`) represents the offset (exclusive) of the end of " "the :term:`bytecode` range" msgstr "" -#: ../../reference/datamodel.rst:1349 +#: ../../reference/datamodel.rst:1542 msgid "" "``lineno`` is an :class:`int` representing the line number of the :term:" "`bytecode` range, or ``None`` if the bytecodes in the given range have no " "line number" msgstr "" -#: ../../reference/datamodel.rst:1353 +#: ../../reference/datamodel.rst:1546 msgid "The items yielded will have the following properties:" msgstr "" -#: ../../reference/datamodel.rst:1355 +#: ../../reference/datamodel.rst:1548 msgid "The first range yielded will have a ``start`` of 0." msgstr "" -#: ../../reference/datamodel.rst:1356 +#: ../../reference/datamodel.rst:1549 msgid "" "The ``(start, end)`` ranges will be non-decreasing and consecutive. That is, " "for any pair of :class:`tuple`\\s, the ``start`` of the second will be equal " "to the ``end`` of the first." msgstr "" -#: ../../reference/datamodel.rst:1359 +#: ../../reference/datamodel.rst:1552 msgid "No range will be backwards: ``end >= start`` for all triples." msgstr "" -#: ../../reference/datamodel.rst:1360 +#: ../../reference/datamodel.rst:1553 msgid "" "The last :class:`tuple` yielded will have ``end`` equal to the size of the :" "term:`bytecode`." msgstr "" -#: ../../reference/datamodel.rst:1363 +#: ../../reference/datamodel.rst:1556 msgid "" "Zero-width ranges, where ``start == end``, are allowed. Zero-width ranges " "are used for lines that are present in the source code, but have been " "eliminated by the :term:`bytecode` compiler." msgstr "" -#: ../../reference/datamodel.rst:1371 +#: ../../reference/datamodel.rst:1564 msgid ":pep:`626` - Precise line numbers for debugging and other tools." msgstr "" -#: ../../reference/datamodel.rst:1372 +#: ../../reference/datamodel.rst:1565 msgid "The PEP that introduced the :meth:`!co_lines` method." msgstr "" -#: ../../reference/datamodel.rst:1376 +#: ../../reference/datamodel.rst:1569 msgid "" "Return a copy of the code object with new values for the specified fields." msgstr "" -#: ../../reference/datamodel.rst:1378 +#: ../../reference/datamodel.rst:1571 msgid "" "Code objects are also supported by the generic function :func:`copy.replace`." msgstr "" -#: ../../reference/datamodel.rst:1386 +#: ../../reference/datamodel.rst:1579 msgid "Frame objects" msgstr "フレーム (frame) オブジェクト" -#: ../../reference/datamodel.rst:1390 +#: ../../reference/datamodel.rst:1583 msgid "" "Frame objects represent execution frames. They may occur in :ref:`traceback " "objects `, and are also passed to registered trace " "functions." msgstr "" -#: ../../reference/datamodel.rst:1408 +#: ../../reference/datamodel.rst:1601 msgid "" "Points to the previous stack frame (towards the caller), or ``None`` if this " "is the bottom stack frame" msgstr "" -#: ../../reference/datamodel.rst:1412 +#: ../../reference/datamodel.rst:1605 msgid "" "The :ref:`code object ` being executed in this frame. " "Accessing this attribute raises an :ref:`auditing event ` ``object." "__getattr__`` with arguments ``obj`` and ``\"f_code\"``." msgstr "" -#: ../../reference/datamodel.rst:1417 +#: ../../reference/datamodel.rst:1610 msgid "" "The mapping used by the frame to look up :ref:`local variables `. If " "the frame refers to an :term:`optimized scope`, this may return a write-" "through proxy object." msgstr "" -#: ../../reference/datamodel.rst:1422 +#: ../../reference/datamodel.rst:1615 msgid "Return a proxy for optimized scopes." msgstr "" -#: ../../reference/datamodel.rst:1426 +#: ../../reference/datamodel.rst:1619 msgid "" "The dictionary used by the frame to look up :ref:`global variables `" msgstr "" -#: ../../reference/datamodel.rst:1430 +#: ../../reference/datamodel.rst:1623 msgid "" "The dictionary used by the frame to look up :ref:`built-in (intrinsic) names " "`" msgstr "" -#: ../../reference/datamodel.rst:1434 +#: ../../reference/datamodel.rst:1627 msgid "" "The \"precise instruction\" of the frame object (this is an index into the :" "term:`bytecode` string of the :ref:`code object `)" msgstr "" -#: ../../reference/datamodel.rst:1450 +#: ../../reference/datamodel.rst:1643 msgid "" "If not ``None``, this is a function called for various events during code " "execution (this is used by debuggers). Normally an event is triggered for " "each new source line (see :attr:`~frame.f_trace_lines`)." msgstr "" -#: ../../reference/datamodel.rst:1455 +#: ../../reference/datamodel.rst:1648 msgid "" "Set this attribute to :const:`False` to disable triggering a tracing event " "for each source line." msgstr "" -#: ../../reference/datamodel.rst:1459 +#: ../../reference/datamodel.rst:1652 msgid "" "Set this attribute to :const:`True` to allow per-opcode events to be " "requested. Note that this may lead to undefined interpreter behaviour if " "exceptions raised by the trace function escape to the function being traced." msgstr "" -#: ../../reference/datamodel.rst:1465 +#: ../../reference/datamodel.rst:1658 msgid "" "The current line number of the frame -- writing to this from within a trace " "function jumps to the given line (only for the bottom-most frame). A " @@ -1889,15 +2114,15 @@ msgid "" "this attribute." msgstr "" -#: ../../reference/datamodel.rst:1471 +#: ../../reference/datamodel.rst:1664 msgid "Frame object methods" msgstr "" -#: ../../reference/datamodel.rst:1473 +#: ../../reference/datamodel.rst:1666 msgid "Frame objects support one method:" msgstr "フレームオブジェクトはメソッドを一つサポートします:" -#: ../../reference/datamodel.rst:1477 +#: ../../reference/datamodel.rst:1670 msgid "" "This method clears all references to :ref:`local variables ` held by " "the frame. Also, if the frame belonged to a :term:`generator`, the " @@ -1906,34 +2131,34 @@ msgid "" "and storing its :ref:`traceback ` for later use)." msgstr "" -#: ../../reference/datamodel.rst:1483 +#: ../../reference/datamodel.rst:1676 msgid "" ":exc:`RuntimeError` is raised if the frame is currently executing or " "suspended." msgstr "" -#: ../../reference/datamodel.rst:1488 +#: ../../reference/datamodel.rst:1681 msgid "" "Attempting to clear a suspended frame raises :exc:`RuntimeError` (as has " "always been the case for executing frames)." msgstr "" -#: ../../reference/datamodel.rst:1496 +#: ../../reference/datamodel.rst:1689 msgid "Traceback objects" msgstr "トレースバック (traceback) オブジェクト" -#: ../../reference/datamodel.rst:1509 +#: ../../reference/datamodel.rst:1702 msgid "" "Traceback objects represent the stack trace of an :ref:`exception `. A traceback object is implicitly created when an exception occurs, " "and may also be explicitly created by calling :class:`types.TracebackType`." msgstr "" -#: ../../reference/datamodel.rst:1514 +#: ../../reference/datamodel.rst:1707 msgid "Traceback objects can now be explicitly instantiated from Python code." msgstr "" -#: ../../reference/datamodel.rst:1517 +#: ../../reference/datamodel.rst:1710 msgid "" "For implicitly created tracebacks, when the search for an exception handler " "unwinds the execution stack, at each unwound level a traceback object is " @@ -1944,7 +2169,7 @@ msgid "" "the caught exception." msgstr "" -#: ../../reference/datamodel.rst:1526 +#: ../../reference/datamodel.rst:1719 msgid "" "When the program contains no suitable handler, the stack trace is written " "(nicely formatted) to the standard error stream; if the interpreter is " @@ -1952,33 +2177,33 @@ msgid "" "last_traceback`." msgstr "" -#: ../../reference/datamodel.rst:1531 +#: ../../reference/datamodel.rst:1724 msgid "" "For explicitly created tracebacks, it is up to the creator of the traceback " "to determine how the :attr:`~traceback.tb_next` attributes should be linked " "to form a full stack trace." msgstr "" -#: ../../reference/datamodel.rst:1546 +#: ../../reference/datamodel.rst:1739 msgid "" "Points to the execution :ref:`frame ` of the current level." msgstr "" -#: ../../reference/datamodel.rst:1549 +#: ../../reference/datamodel.rst:1742 msgid "" "Accessing this attribute raises an :ref:`auditing event ` ``object." "__getattr__`` with arguments ``obj`` and ``\"tb_frame\"``." msgstr "" -#: ../../reference/datamodel.rst:1554 +#: ../../reference/datamodel.rst:1747 msgid "Gives the line number where the exception occurred" msgstr "" -#: ../../reference/datamodel.rst:1557 +#: ../../reference/datamodel.rst:1750 msgid "Indicates the \"precise instruction\"." msgstr "" -#: ../../reference/datamodel.rst:1559 +#: ../../reference/datamodel.rst:1752 msgid "" "The line number and last instruction in the traceback may differ from the " "line number of its :ref:`frame object ` if the exception " @@ -1986,22 +2211,22 @@ msgid "" "with a :keyword:`finally` clause." msgstr "" -#: ../../reference/datamodel.rst:1570 +#: ../../reference/datamodel.rst:1763 msgid "" "The special writable attribute :attr:`!tb_next` is the next level in the " "stack trace (towards the frame where the exception occurred), or ``None`` if " "there is no next level." msgstr "" -#: ../../reference/datamodel.rst:1574 +#: ../../reference/datamodel.rst:1767 msgid "This attribute is now writable" msgstr "" -#: ../../reference/datamodel.rst:1579 +#: ../../reference/datamodel.rst:1772 msgid "Slice objects" msgstr "スライス (slice) オブジェクト" -#: ../../reference/datamodel.rst:1583 +#: ../../reference/datamodel.rst:1776 msgid "" "Slice objects are used to represent slices for :meth:`~object.__getitem__` " "methods. They are also created by the built-in :func:`slice` function." @@ -2010,7 +2235,7 @@ msgstr "" "を表すのに使われます。スライスオブジェクトは組み込みの :func:`slice` 関数でも" "生成されます。" -#: ../../reference/datamodel.rst:1592 +#: ../../reference/datamodel.rst:1785 msgid "" "Special read-only attributes: :attr:`~slice.start` is the lower bound; :attr:" "`~slice.stop` is the upper bound; :attr:`~slice.step` is the step value; " @@ -2020,11 +2245,11 @@ msgstr "" "は上限です; :attr:`~slice.step` はステップの値です; それぞれ省略された場合は " "``None`` となっています。これらの属性は任意の型を持てます。" -#: ../../reference/datamodel.rst:1596 +#: ../../reference/datamodel.rst:1789 msgid "Slice objects support one method:" msgstr "スライスオブジェクトはメソッドを一つサポートします:" -#: ../../reference/datamodel.rst:1600 +#: ../../reference/datamodel.rst:1793 msgid "" "This method takes a single integer argument *length* and computes " "information about the slice that the slice object would describe if applied " @@ -2040,11 +2265,11 @@ msgstr "" "す。インデックス値がないか、範囲外の値であれば、通常のスライスと変わらないや" "りかたで扱われます。" -#: ../../reference/datamodel.rst:1609 +#: ../../reference/datamodel.rst:1802 msgid "Static method objects" msgstr "静的メソッド (static method) オブジェクト" -#: ../../reference/datamodel.rst:1611 +#: ../../reference/datamodel.rst:1804 msgid "" "Static method objects provide a way of defeating the transformation of " "function objects to method objects described above. A static method object " @@ -2063,11 +2288,11 @@ msgstr "" "ジェクト自体は呼び出し可能です。静的オブジェクトは組み込みコンストラクタ :" "func:`staticmethod` で生成されます。" -#: ../../reference/datamodel.rst:1621 +#: ../../reference/datamodel.rst:1814 msgid "Class method objects" msgstr "クラスメソッドオブジェクト" -#: ../../reference/datamodel.rst:1623 +#: ../../reference/datamodel.rst:1816 msgid "" "A class method object, like a static method object, is a wrapper around " "another object that alters the way in which that object is retrieved from " @@ -2077,11 +2302,11 @@ msgid "" "`classmethod` constructor." msgstr "" -#: ../../reference/datamodel.rst:1633 +#: ../../reference/datamodel.rst:1826 msgid "Special method names" msgstr "特殊メソッド名" -#: ../../reference/datamodel.rst:1639 +#: ../../reference/datamodel.rst:1832 msgid "" "A class can implement certain operations that are invoked by special syntax " "(such as arithmetic operations or subscripting and slicing) by defining " @@ -2104,7 +2329,7 @@ msgstr "" "き、このような演算を試みると例外 (たいていは :exc:`AttributeError` か :exc:" "`TypeError`) が送出されます。" -#: ../../reference/datamodel.rst:1650 +#: ../../reference/datamodel.rst:1843 msgid "" "Setting a special method to ``None`` indicates that the corresponding " "operation is not available. For example, if a class sets :meth:`~object." @@ -2119,7 +2344,7 @@ msgstr "" "(:meth:`~object.__getitem__` に処理が戻されずに) :exc:`TypeError` を送出しま" "す。 [#]_" -#: ../../reference/datamodel.rst:1656 +#: ../../reference/datamodel.rst:1849 msgid "" "When implementing a class that emulates any built-in type, it is important " "that the emulation only be implemented to the degree that it makes sense for " @@ -2134,11 +2359,11 @@ msgstr "" "いかもしれません。 (W3C のドキュメントオブジェクトモデルにある :class:`~xml." "dom.NodeList` インターフェースがその一例です。)" -#: ../../reference/datamodel.rst:1667 +#: ../../reference/datamodel.rst:1860 msgid "Basic customization" msgstr "基本的なカスタマイズ" -#: ../../reference/datamodel.rst:1673 +#: ../../reference/datamodel.rst:1866 msgid "" "Called to create a new instance of class *cls*. :meth:`__new__` is a static " "method (special-cased so you need not declare it as such) that takes the " @@ -2154,7 +2379,7 @@ msgstr "" "(クラスの呼び出し文) に渡されます。 :meth:`__new__` の戻り値は新しいオブジェ" "クトのインスタンス (通常は *cls* のインスタンス) でなければなりません。" -#: ../../reference/datamodel.rst:1680 +#: ../../reference/datamodel.rst:1873 msgid "" "Typical implementations create a new instance of the class by invoking the " "superclass's :meth:`__new__` method using ``super().__new__(cls[, ...])`` " @@ -2166,7 +2391,7 @@ msgstr "" "ソッドを呼び出し、新たに生成されたインスタンスに必要な変更を加えてから返しま" "す。" -#: ../../reference/datamodel.rst:1685 +#: ../../reference/datamodel.rst:1878 msgid "" "If :meth:`__new__` is invoked during object construction and it returns an " "instance of *cls*, then the new instance’s :meth:`__init__` method will be " @@ -2180,7 +2405,7 @@ msgstr "" "ンスタンスで、残りの引数はオブジェクトコンストラクタに渡された引数と同じにな" "ります。" -#: ../../reference/datamodel.rst:1690 +#: ../../reference/datamodel.rst:1883 msgid "" "If :meth:`__new__` does not return an instance of *cls*, then the new " "instance's :meth:`__init__` method will not be invoked." @@ -2188,7 +2413,7 @@ msgstr "" ":meth:`__new__` が *cls* のインスタンスを返さない場合、インスタンスの :meth:" "`__init__` メソッドは呼び出されません。" -#: ../../reference/datamodel.rst:1693 +#: ../../reference/datamodel.rst:1886 msgid "" ":meth:`__new__` is intended mainly to allow subclasses of immutable types " "(like int, str, or tuple) to customize instance creation. It is also " @@ -2199,7 +2424,7 @@ msgstr "" "スでインスタンス生成をカスタマイズすることにあります。また、クラス生成をカス" "タマイズするために、カスタムのメタクラスでよくオーバーライドされます。" -#: ../../reference/datamodel.rst:1702 +#: ../../reference/datamodel.rst:1895 msgid "" "Called after the instance has been created (by :meth:`__new__`), but before " "it is returned to the caller. The arguments are those passed to the class " @@ -2215,7 +2440,7 @@ msgstr "" "示的に呼び出して、インスタンスの基底クラス部分が適切に初期化されること保証し" "なければなりません。例えば、 ``super().__init__([args...])`` 。" -#: ../../reference/datamodel.rst:1709 +#: ../../reference/datamodel.rst:1902 msgid "" "Because :meth:`__new__` and :meth:`__init__` work together in constructing " "objects (:meth:`__new__` to create it, and :meth:`__init__` to customize " @@ -2227,7 +2452,7 @@ msgstr "" "`__init__` から非 ``None`` 値を返してはいけません; そうしてしまうと、実行時" "に :exc:`TypeError` が送出されてしまいます。" -#: ../../reference/datamodel.rst:1722 +#: ../../reference/datamodel.rst:1915 msgid "" "Called when the instance is about to be destroyed. This is also called a " "finalizer or (improperly) a destructor. If a base class has a :meth:" @@ -2242,7 +2467,7 @@ msgstr "" "に呼び出して、インスタンスの基底クラス部分をきちんと確実に削除しなければなり" "ません。" -#: ../../reference/datamodel.rst:1728 +#: ../../reference/datamodel.rst:1921 msgid "" "It is possible (though not recommended!) for the :meth:`__del__` method to " "postpone destruction of the instance by creating a new reference to it. " @@ -2258,7 +2483,7 @@ msgstr "" "うかは実装依存です;\n" "現在の :term:`CPython` の実装では最初の一回しか呼び出されません。" -#: ../../reference/datamodel.rst:1735 +#: ../../reference/datamodel.rst:1928 msgid "" "It is not guaranteed that :meth:`__del__` methods are called for objects " "that still exist when the interpreter exits. :class:`weakref.finalize` " @@ -2266,7 +2491,7 @@ msgid "" "when an object is garbage collected." msgstr "" -#: ../../reference/datamodel.rst:1742 +#: ../../reference/datamodel.rst:1935 msgid "" "``del x`` doesn't directly call ``x.__del__()`` --- the former decrements " "the reference count for ``x`` by one, and the latter is only called when " @@ -2276,7 +2501,7 @@ msgstr "" "ントを 1 つ減らし、後者は ``x`` の参照カウントが 0 まで落ちたときのみ呼び出さ" "れます。" -#: ../../reference/datamodel.rst:1747 +#: ../../reference/datamodel.rst:1940 msgid "" "It is possible for a reference cycle to prevent the reference count of an " "object from going to zero. In this case, the cycle will be later detected " @@ -2287,11 +2512,11 @@ msgid "" "caught in the traceback." msgstr "" -#: ../../reference/datamodel.rst:1757 +#: ../../reference/datamodel.rst:1950 msgid "Documentation for the :mod:`gc` module." msgstr ":mod:`gc` モジュールのドキュメント。" -#: ../../reference/datamodel.rst:1761 +#: ../../reference/datamodel.rst:1954 msgid "" "Due to the precarious circumstances under which :meth:`__del__` methods are " "invoked, exceptions that occur during their execution are ignored, and a " @@ -2300,7 +2525,7 @@ msgstr "" "メソッド :meth:`__del__` は不安定な状況で呼び出されるため、実行中に発生した例" "外は無視され、代わりに ``sys.stderr`` に警告が表示されます。特に:" -#: ../../reference/datamodel.rst:1765 +#: ../../reference/datamodel.rst:1958 msgid "" ":meth:`__del__` can be invoked when arbitrary code is being executed, " "including from any arbitrary thread. If :meth:`__del__` needs to take a " @@ -2314,7 +2539,7 @@ msgstr "" "必要がある場合、 :meth:`__del__` の実行により中断されたコードにより、そのリ" "ソースが既に取得されていて、デッドロックが起きるかもしれません。" -#: ../../reference/datamodel.rst:1771 +#: ../../reference/datamodel.rst:1964 msgid "" ":meth:`__del__` can be executed during interpreter shutdown. As a " "consequence, the global variables it needs to access (including other " @@ -2333,7 +2558,7 @@ msgstr "" "が呼ばれた時点で、インポートされたモジュールがまだ利用可能であることを保証す" "るのに役立つかもしれません。" -#: ../../reference/datamodel.rst:1786 +#: ../../reference/datamodel.rst:1979 msgid "" "Called by the :func:`repr` built-in function to compute the \"official\" " "string representation of an object. If at all possible, this should look " @@ -2353,7 +2578,7 @@ msgstr "" "スのインスタンスの「非公式の (informal)」文字列表現が要求されたときにも :" "meth:`__repr__` が使われます。" -#: ../../reference/datamodel.rst:1795 +#: ../../reference/datamodel.rst:1988 msgid "" "This is typically used for debugging, so it is important that the " "representation is information-rich and unambiguous." @@ -2361,7 +2586,7 @@ msgstr "" "この関数はデバッグの際によく用いられるので、たくさんの情報を含み、あいまいで" "ないような表記にすることが重要です。" -#: ../../reference/datamodel.rst:1806 +#: ../../reference/datamodel.rst:1999 msgid "" "Called by :func:`str(object) ` and the built-in functions :func:" "`format` and :func:`print` to compute the \"informal\" or nicely printable " @@ -2373,7 +2598,7 @@ msgstr "" "`print` によって呼ばれます。戻り値は :ref:`string ` オブジェクトでな" "ければなりません。" -#: ../../reference/datamodel.rst:1811 +#: ../../reference/datamodel.rst:2004 msgid "" "This method differs from :meth:`object.__repr__` in that there is no " "expectation that :meth:`__str__` return a valid Python expression: a more " @@ -2383,7 +2608,7 @@ msgstr "" "メソッドは :meth:`object.__repr__` とは異なります: より便利な、または簡潔な表" "現を使用することができます。" -#: ../../reference/datamodel.rst:1815 +#: ../../reference/datamodel.rst:2008 msgid "" "The default implementation defined by the built-in type :class:`object` " "calls :meth:`object.__repr__`." @@ -2391,7 +2616,7 @@ msgstr "" "組み込み型 :class:`object` によって定義されたデフォルト実装は、 :meth:" "`object.__repr__` を呼び出します。" -#: ../../reference/datamodel.rst:1825 +#: ../../reference/datamodel.rst:2018 msgid "" "Called by :ref:`bytes ` to compute a byte-string representation " "of an object. This should return a :class:`bytes` object." @@ -2399,7 +2624,7 @@ msgstr "" ":ref:`bytes ` によって呼び出され、オブジェクトのバイト文字列表現" "を計算します。これは :class:`bytes` オブジェクトを返すべきです。" -#: ../../reference/datamodel.rst:1836 +#: ../../reference/datamodel.rst:2029 msgid "" "Called by the :func:`format` built-in function, and by extension, evaluation " "of :ref:`formatted string literals ` and the :meth:`str.format` " @@ -2418,17 +2643,17 @@ msgstr "" "が、 ほとんどのクラスは組み込み型のいずれかにフォーマット化を委譲したり、 同" "じようなフォーマット化オプション構文を使います。" -#: ../../reference/datamodel.rst:1846 +#: ../../reference/datamodel.rst:2039 msgid "" "See :ref:`formatspec` for a description of the standard formatting syntax." msgstr "" "標準のフォーマット構文の解説は、 :ref:`formatspec` を参照してください。" -#: ../../reference/datamodel.rst:1848 +#: ../../reference/datamodel.rst:2041 msgid "The return value must be a string object." msgstr "戻り値は文字列オブジェクトでなければなりません。" -#: ../../reference/datamodel.rst:1850 +#: ../../reference/datamodel.rst:2043 msgid "" "The __format__ method of ``object`` itself raises a :exc:`TypeError` if " "passed any non-empty string." @@ -2436,7 +2661,7 @@ msgstr "" "空でない文字列が渡された場合 ``object`` 自身の __format__ メソッドは :exc:" "`TypeError` を送出します。" -#: ../../reference/datamodel.rst:1854 +#: ../../reference/datamodel.rst:2047 msgid "" "``object.__format__(x, '')`` is now equivalent to ``str(x)`` rather than " "``format(str(x), '')``." @@ -2444,7 +2669,7 @@ msgstr "" "``object.__format__(x, '')`` は ``format(str(x), '')`` ではなく ``str(x)`` と" "等価になりました。" -#: ../../reference/datamodel.rst:1870 +#: ../../reference/datamodel.rst:2063 msgid "" "These are the so-called \"rich comparison\" methods. The correspondence " "between operator symbols and method names is as follows: ``xy`` は ``x." "__gt__(y)`` を呼び出します; ``x>=y`` は ``x.__ge__(y)`` を呼び出します。" -#: ../../reference/datamodel.rst:1876 +#: ../../reference/datamodel.rst:2069 msgid "" "A rich comparison method may return the singleton :data:`NotImplemented` if " "it does not implement the operation for a given pair of arguments. By " @@ -2469,7 +2694,7 @@ msgid "" "result is true or false." msgstr "" -#: ../../reference/datamodel.rst:1883 +#: ../../reference/datamodel.rst:2076 msgid "" "By default, ``object`` implements :meth:`__eq__` by using ``is``, returning :" "data:`NotImplemented` in the case of a false comparison: ``True if x is y " @@ -2481,7 +2706,7 @@ msgid "" "operation, see :func:`functools.total_ordering`." msgstr "" -#: ../../reference/datamodel.rst:1892 +#: ../../reference/datamodel.rst:2085 msgid "" "See the paragraph on :meth:`__hash__` for some important notes on creating :" "term:`hashable` objects which support custom comparison operations and are " @@ -2491,7 +2716,7 @@ msgstr "" "ハッシュ可能 ` オブジェクトを作るときの重要な注意点について、 :" "meth:`__hash__` のドキュメント内に書かれているので参照してください。" -#: ../../reference/datamodel.rst:1896 +#: ../../reference/datamodel.rst:2089 msgid "" "There are no swapped-argument versions of these methods (to be used when the " "left argument does not support the operation but the right argument does); " @@ -2504,14 +2729,14 @@ msgid "" "Virtual subclassing is not considered." msgstr "" -#: ../../reference/datamodel.rst:1907 +#: ../../reference/datamodel.rst:2100 msgid "" "When no appropriate method returns any value other than :data:" "`NotImplemented`, the ``==`` and ``!=`` operators will fall back to ``is`` " "and ``is not``, respectively." msgstr "" -#: ../../reference/datamodel.rst:1916 +#: ../../reference/datamodel.rst:2109 msgid "" "Called by built-in function :func:`hash` and for operations on members of " "hashed collections including :class:`set`, :class:`frozenset`, and :class:" @@ -2530,13 +2755,13 @@ msgstr "" "オブジェクトを比較するときでも利用される要素をタプルに詰めてハッシュ値を計算" "することで、それぞれの要素のハッシュ値を混合することをおすすめします。" -#: ../../reference/datamodel.rst:1924 +#: ../../reference/datamodel.rst:2117 msgid "" "def __hash__(self):\n" " return hash((self.name, self.nick, self.color))" msgstr "" -#: ../../reference/datamodel.rst:1929 +#: ../../reference/datamodel.rst:2122 msgid "" ":func:`hash` truncates the value returned from an object's custom :meth:" "`__hash__` method to the size of a :c:type:`Py_ssize_t`. This is typically " @@ -2554,7 +2779,7 @@ msgstr "" "そうする簡単な方法は ``python -c \"import sys; print(sys.hash_info." "width)\"`` を実行することです。" -#: ../../reference/datamodel.rst:1937 +#: ../../reference/datamodel.rst:2130 msgid "" "If a class does not define an :meth:`__eq__` method it should not define a :" "meth:`__hash__` operation either; if it defines :meth:`__eq__` but not :meth:" @@ -2575,7 +2800,7 @@ msgstr "" "クトのハッシュ値が変化すると、誤ったハッシュバケツ: hash bucket に入ってしま" "います)。" -#: ../../reference/datamodel.rst:1946 +#: ../../reference/datamodel.rst:2139 msgid "" "User-defined classes have :meth:`__eq__` and :meth:`__hash__` methods by " "default; with them, all objects compare unequal (except with themselves) and " @@ -2587,7 +2812,7 @@ msgstr "" "り、 ``x.__hash__()`` は ``x == y`` が ``x is y`` と ``hash(x) == hash(y)`` " "の両方を意味するような適切な値を返します。" -#: ../../reference/datamodel.rst:1951 +#: ../../reference/datamodel.rst:2144 msgid "" "A class that overrides :meth:`__eq__` and does not define :meth:`__hash__` " "will have its :meth:`__hash__` implicitly set to ``None``. When the :meth:" @@ -2603,7 +2828,7 @@ msgstr "" "``isinstance(obj, collections.abc.Hashable)`` でチェックするとハッシュ不能な" "ものとして正しく認識されます。" -#: ../../reference/datamodel.rst:1958 +#: ../../reference/datamodel.rst:2151 msgid "" "If a class that overrides :meth:`__eq__` needs to retain the implementation " "of :meth:`__hash__` from a parent class, the interpreter must be told this " @@ -2613,7 +2838,7 @@ msgstr "" "の 実装を保持したいなら、明示的に ``__hash__ = .__hash__`` を設" "定することで、それをインタプリタに伝えなければなりません。" -#: ../../reference/datamodel.rst:1962 +#: ../../reference/datamodel.rst:2155 msgid "" "If a class that does not override :meth:`__eq__` wishes to suppress hash " "support, it should include ``__hash__ = None`` in the class definition. A " @@ -2627,7 +2852,7 @@ msgstr "" "``isinstance(obj, collections.abc.Hashable)`` 呼び出しで誤ってハッシュ可能と" "識別されるでしょう。" -#: ../../reference/datamodel.rst:1971 +#: ../../reference/datamodel.rst:2164 msgid "" "By default, the :meth:`__hash__` values of str and bytes objects are " "\"salted\" with an unpredictable random value. Although they remain " @@ -2638,7 +2863,7 @@ msgstr "" "値で \"ソルト\" されます。 ハッシュ値は単独の Python プロセス内では定数であり" "続けますが、Python を繰り返し起動する毎に、予測できなくなります。" -#: ../../reference/datamodel.rst:1976 +#: ../../reference/datamodel.rst:2169 msgid "" "This is intended to provide protection against a denial-of-service caused by " "carefully chosen inputs that exploit the worst case performance of a dict " @@ -2646,7 +2871,7 @@ msgid "" "advisories/ocert-2011-003.html for details." msgstr "" -#: ../../reference/datamodel.rst:1981 +#: ../../reference/datamodel.rst:2174 msgid "" "Changing hash values affects the iteration order of sets. Python has never " "made guarantees about this ordering (and it typically varies between 32-bit " @@ -2655,15 +2880,15 @@ msgstr "" "ハッシュ値の変更は、集合のイテレーション順序に影響します。Python はこの順序付" "けを保証していません (そして通常 32-bit と 64-bit の間でも異なります)。" -#: ../../reference/datamodel.rst:1985 +#: ../../reference/datamodel.rst:2178 msgid "See also :envvar:`PYTHONHASHSEED`." msgstr ":envvar:`PYTHONHASHSEED` も参照してください。" -#: ../../reference/datamodel.rst:1987 +#: ../../reference/datamodel.rst:2180 msgid "Hash randomization is enabled by default." msgstr "ハッシュのランダム化がデフォルトで有効になりました。" -#: ../../reference/datamodel.rst:1995 +#: ../../reference/datamodel.rst:2188 msgid "" "Called to implement truth value testing and the built-in operation " "``bool()``; should return ``False`` or ``True``. When this method is not " @@ -2672,11 +2897,11 @@ msgid "" "meth:`!__len__` nor :meth:`!__bool__`, all its instances are considered true." msgstr "" -#: ../../reference/datamodel.rst:2006 +#: ../../reference/datamodel.rst:2199 msgid "Customizing attribute access" msgstr "属性値アクセスをカスタマイズする" -#: ../../reference/datamodel.rst:2008 +#: ../../reference/datamodel.rst:2201 msgid "" "The following methods can be defined to customize the meaning of attribute " "access (use of, assignment to, or deletion of ``x.name``) for class " @@ -2686,7 +2911,7 @@ msgstr "" "使用、 ``x.name`` への代入、 ``x.name`` の削除) の意味をカスタマイズすること" "ができます。" -#: ../../reference/datamodel.rst:2016 +#: ../../reference/datamodel.rst:2209 msgid "" "Called when the default attribute access fails with an :exc:`AttributeError` " "(either :meth:`__getattribute__` raises an :exc:`AttributeError` because " @@ -2703,7 +2928,7 @@ msgstr "" "このメソッドは (計算された) 属性値を返すか、 :exc:`AttributeError` 例外を送出" "しなければなりません。" -#: ../../reference/datamodel.rst:2023 +#: ../../reference/datamodel.rst:2216 msgid "" "Note that if the attribute is found through the normal mechanism, :meth:" "`__getattr__` is not called. (This is an intentional asymmetry between :" @@ -2716,7 +2941,7 @@ msgid "" "actually get total control over attribute access." msgstr "" -#: ../../reference/datamodel.rst:2036 +#: ../../reference/datamodel.rst:2229 msgid "" "Called unconditionally to implement attribute accesses for instances of the " "class. If the class also defines :meth:`__getattr__`, the latter will not be " @@ -2736,14 +2961,14 @@ msgstr "" "で、例えば ``object.__getattribute__(self, name)`` のように基底クラスのメソッ" "ドを同じ属性名を使って呼び出さなければなりません。" -#: ../../reference/datamodel.rst:2047 +#: ../../reference/datamodel.rst:2240 msgid "" "This method may still be bypassed when looking up special methods as the " "result of implicit invocation via language syntax or :ref:`built-in " "functions `. See :ref:`special-lookup`." msgstr "" -#: ../../reference/datamodel.rst:2052 ../../reference/datamodel.rst:2054 +#: ../../reference/datamodel.rst:2245 ../../reference/datamodel.rst:2247 msgid "" "For certain sensitive attribute accesses, raises an :ref:`auditing event " "` ``object.__getattr__`` with arguments ``obj`` and ``name``." @@ -2752,7 +2977,7 @@ msgstr "" "__getattr__`` を使った属性アクセスは :ref:`監査イベント ` を送出し" "ます。" -#: ../../reference/datamodel.rst:2061 +#: ../../reference/datamodel.rst:2254 msgid "" "Called when an attribute assignment is attempted. This is called instead of " "the normal mechanism (i.e. store the value in the instance dictionary). " @@ -2762,7 +2987,7 @@ msgstr "" "インスタンス辞書への値の代入) の代わりに呼び出されます。*name* は属性名で、" "*value* はその属性に代入する値です。" -#: ../../reference/datamodel.rst:2065 +#: ../../reference/datamodel.rst:2258 msgid "" "If :meth:`__setattr__` wants to assign to an instance attribute, it should " "call the base class method with the same name, for example, ``object." @@ -2772,7 +2997,7 @@ msgstr "" "れと同じ名前のメソッドを呼び出さなければなりません。例えば、 ``object." "__setattr__(self, name, value)`` とします。" -#: ../../reference/datamodel.rst:2069 ../../reference/datamodel.rst:2071 +#: ../../reference/datamodel.rst:2262 ../../reference/datamodel.rst:2264 msgid "" "For certain sensitive attribute assignments, raises an :ref:`auditing event " "` ``object.__setattr__`` with arguments ``obj``, ``name``, " @@ -2782,7 +3007,7 @@ msgstr "" "``object.__setattr__`` を使った属性のアサインは :ref:`監査イベント " "` を送出します。" -#: ../../reference/datamodel.rst:2078 +#: ../../reference/datamodel.rst:2271 msgid "" "Like :meth:`__setattr__` but for attribute deletion instead of assignment. " "This should only be implemented if ``del obj.name`` is meaningful for the " @@ -2792,7 +3017,7 @@ msgstr "" "ソッドを実装するのは、オブジェクトにとって ``del obj.name`` が意味がある場合" "だけにしなければなりません。" -#: ../../reference/datamodel.rst:2081 ../../reference/datamodel.rst:2083 +#: ../../reference/datamodel.rst:2274 ../../reference/datamodel.rst:2276 msgid "" "For certain sensitive attribute deletions, raises an :ref:`auditing event " "` ``object.__delattr__`` with arguments ``obj`` and ``name``." @@ -2801,17 +3026,17 @@ msgstr "" "__getattr__`` を使った属性の削除は :ref:`監査イベント ` を送出しま" "す。" -#: ../../reference/datamodel.rst:2090 +#: ../../reference/datamodel.rst:2283 msgid "" "Called when :func:`dir` is called on the object. An iterable must be " "returned. :func:`dir` converts the returned iterable to a list and sorts it." msgstr "" -#: ../../reference/datamodel.rst:2095 +#: ../../reference/datamodel.rst:2288 msgid "Customizing module attribute access" msgstr "モジュールの属性値アクセスをカスタマイズする" -#: ../../reference/datamodel.rst:2102 +#: ../../reference/datamodel.rst:2295 msgid "" "Special names ``__getattr__`` and ``__dir__`` can be also used to customize " "access to module attributes. The ``__getattr__`` function at the module " @@ -2831,14 +3056,14 @@ msgstr "" "前に、モジュールの ``__dict__`` から ``__getattr__`` が検索されます。\n" "見付かった場合は、その属性名で呼び出され、結果が返されます。" -#: ../../reference/datamodel.rst:2111 +#: ../../reference/datamodel.rst:2304 msgid "" "The ``__dir__`` function should accept no arguments, and return an iterable " "of strings that represents the names accessible on module. If present, this " "function overrides the standard :func:`dir` search on a module." msgstr "" -#: ../../reference/datamodel.rst:2115 +#: ../../reference/datamodel.rst:2308 msgid "" "For a more fine grained customization of the module behavior (setting " "attributes, properties, etc.), one can set the ``__class__`` attribute of a " @@ -2849,7 +3074,7 @@ msgstr "" "ModuleType` のサブクラスが設定できます。\n" "例えば次のようになります::" -#: ../../reference/datamodel.rst:2119 +#: ../../reference/datamodel.rst:2312 msgid "" "import sys\n" "from types import ModuleType\n" @@ -2865,7 +3090,7 @@ msgid "" "sys.modules[__name__].__class__ = VerboseModule" msgstr "" -#: ../../reference/datamodel.rst:2133 +#: ../../reference/datamodel.rst:2326 msgid "" "Defining module ``__getattr__`` and setting module ``__class__`` only affect " "lookups made using the attribute access syntax -- directly accessing the " @@ -2877,27 +3102,27 @@ msgstr "" "globals への直接アクセスは (モジュール内のコードからとモジュールの globals の" "どちらでも) 影響を受けません。" -#: ../../reference/datamodel.rst:2138 +#: ../../reference/datamodel.rst:2331 msgid "``__class__`` module attribute is now writable." msgstr "モジュールの属性 ``__class__`` が書き込み可能になりました。" -#: ../../reference/datamodel.rst:2141 +#: ../../reference/datamodel.rst:2334 msgid "``__getattr__`` and ``__dir__`` module attributes." msgstr "``__getattr__`` モジュール属性と ``__dir__`` モジュール属性。" -#: ../../reference/datamodel.rst:2146 +#: ../../reference/datamodel.rst:2339 msgid ":pep:`562` - Module __getattr__ and __dir__" msgstr ":pep:`562` - モジュールの __getattr__ と __dir__" -#: ../../reference/datamodel.rst:2147 +#: ../../reference/datamodel.rst:2340 msgid "Describes the ``__getattr__`` and ``__dir__`` functions on modules." msgstr "モジュールの ``__getattr__`` 関数および ``__dir__`` 関数の説明。" -#: ../../reference/datamodel.rst:2153 +#: ../../reference/datamodel.rst:2346 msgid "Implementing Descriptors" msgstr "デスクリプタ (descriptor) の実装" -#: ../../reference/datamodel.rst:2155 +#: ../../reference/datamodel.rst:2348 msgid "" "The following methods only apply when an instance of the class containing " "the method (a so-called *descriptor* class) appears in an *owner* class (the " @@ -2913,7 +3138,7 @@ msgstr "" "以下の例では、\"属性\" とは、名前がオーナークラスの :attr:`~object.__dict__` " "のプロパティ (porperty) のキーであるような属性を指します。" -#: ../../reference/datamodel.rst:2165 +#: ../../reference/datamodel.rst:2358 msgid "" "Called to get the attribute of the owner class (class attribute access) or " "of an instance of that class (instance attribute access). The optional " @@ -2926,7 +3151,7 @@ msgstr "" "性をアクセスする時に、オプションの *owner* 引数はオーナークラスです。 " "*owner* を通じて属性アクセスするときは ``None`` です。" -#: ../../reference/datamodel.rst:2171 +#: ../../reference/datamodel.rst:2364 msgid "" "This method should return the computed attribute value or raise an :exc:" "`AttributeError` exception." @@ -2934,7 +3159,7 @@ msgstr "" "このメソッドは、算出された属性値を返すか、 :exc:`AttributeError` 例外を送出し" "ます。" -#: ../../reference/datamodel.rst:2174 +#: ../../reference/datamodel.rst:2367 msgid "" ":PEP:`252` specifies that :meth:`__get__` is callable with one or two " "arguments. Python's own built-in descriptors support this specification; " @@ -2949,7 +3174,7 @@ msgstr "" "ます。Pythonの :meth:`__getattribute__` 実装は必要かどうかに関わらず、両方の" "引数を常に渡します。" -#: ../../reference/datamodel.rst:2183 +#: ../../reference/datamodel.rst:2376 msgid "" "Called to set the attribute on an instance *instance* of the owner class to " "a new value, *value*." @@ -2957,7 +3182,7 @@ msgstr "" "オーナークラスのインスタンス *instance* 上の属性を新たな値 *value* に設定する" "際に呼び出されます。" -#: ../../reference/datamodel.rst:2186 +#: ../../reference/datamodel.rst:2379 msgid "" "Note, adding :meth:`__set__` or :meth:`__delete__` changes the kind of " "descriptor to a \"data descriptor\". See :ref:`descriptor-invocation` for " @@ -2967,20 +3192,20 @@ msgstr "" "「データデスクリプタ」に変わります。詳細は :ref:`descriptor-invocation` を参" "照してください。" -#: ../../reference/datamodel.rst:2192 +#: ../../reference/datamodel.rst:2385 msgid "" "Called to delete the attribute on an instance *instance* of the owner class." msgstr "" "オーナークラスのインスタンス *instance* 上の属性を削除する際に呼び出されま" "す。" -#: ../../reference/datamodel.rst:2194 +#: ../../reference/datamodel.rst:2387 msgid "" "Instances of descriptors may also have the :attr:`!__objclass__` attribute " "present:" msgstr "" -#: ../../reference/datamodel.rst:2199 +#: ../../reference/datamodel.rst:2392 msgid "" "The attribute :attr:`!__objclass__` is interpreted by the :mod:`inspect` " "module as specifying the class where this object was defined (setting this " @@ -2991,11 +3216,11 @@ msgid "" "are implemented in C)." msgstr "" -#: ../../reference/datamodel.rst:2210 +#: ../../reference/datamodel.rst:2403 msgid "Invoking Descriptors" msgstr "デスクリプタの呼び出し" -#: ../../reference/datamodel.rst:2212 +#: ../../reference/datamodel.rst:2405 msgid "" "In general, a descriptor is an object attribute with \"binding behavior\", " "one whose attribute access has been overridden by methods in the descriptor " @@ -3010,7 +3235,7 @@ msgstr "" "ライドしているものです。これらのメソッドのいずれかがオブジェクトに対して定義" "されている場合、オブジェクトはデスクリプタであるといいます。" -#: ../../reference/datamodel.rst:2218 +#: ../../reference/datamodel.rst:2411 msgid "" "The default behavior for attribute access is to get, set, or delete the " "attribute from an object's dictionary. For instance, ``a.x`` has a lookup " @@ -3023,7 +3248,7 @@ msgstr "" "``type(a)`` の基底クラスでメタクラスでないものに続く、といった具合に連鎖が起" "こります。" -#: ../../reference/datamodel.rst:2223 +#: ../../reference/datamodel.rst:2416 msgid "" "However, if the looked-up value is an object defining one of the descriptor " "methods, then Python may override the default behavior and invoke the " @@ -3036,7 +3261,7 @@ msgstr "" "出されるかは、どのデスクリプタメソッドが定義されていて、どのように呼び出され" "たかに依存します。" -#: ../../reference/datamodel.rst:2228 +#: ../../reference/datamodel.rst:2421 msgid "" "The starting point for descriptor invocation is a binding, ``a.x``. How the " "arguments are assembled depends on ``a``:" @@ -3045,11 +3270,11 @@ msgstr "" "``a.x`` です。引数がどのようにデスクリプタに結合されるかは ``a`` に依存しま" "す:" -#: ../../reference/datamodel.rst:2231 +#: ../../reference/datamodel.rst:2424 msgid "Direct Call" msgstr "直接呼び出し (Direct Call)" -#: ../../reference/datamodel.rst:2232 +#: ../../reference/datamodel.rst:2425 msgid "" "The simplest and least common call is when user code directly invokes a " "descriptor method: ``x.__get__(a)``." @@ -3057,11 +3282,11 @@ msgstr "" "最も単純で、かつめったに使われない呼び出し操作は、コード中で直接デスクリプタ" "メソッドの呼び出し: ``x.__get__(a)`` を行うというものです。" -#: ../../reference/datamodel.rst:2235 +#: ../../reference/datamodel.rst:2428 msgid "Instance Binding" msgstr "インスタンス束縛 (Instance Binding)" -#: ../../reference/datamodel.rst:2236 +#: ../../reference/datamodel.rst:2429 msgid "" "If binding to an object instance, ``a.x`` is transformed into the call: " "``type(a).__dict__['x'].__get__(a, type(a))``." @@ -3069,11 +3294,11 @@ msgstr "" "オブジェクトインスタンスへ束縛すると、``a.x`` は呼び出し ``type(a)." "__dict__['x'].__get__(a, type(a))`` に変換されます。" -#: ../../reference/datamodel.rst:2239 +#: ../../reference/datamodel.rst:2432 msgid "Class Binding" msgstr "クラス束縛 (Class Binding)" -#: ../../reference/datamodel.rst:2240 +#: ../../reference/datamodel.rst:2433 msgid "" "If binding to a class, ``A.x`` is transformed into the call: ``A." "__dict__['x'].__get__(None, A)``." @@ -3081,11 +3306,11 @@ msgstr "" "クラスへ束縛すると、``A.x`` は呼び出し ``A.__dict__['x'].__get__(None, A)`` " "に変換されます。" -#: ../../reference/datamodel.rst:2243 +#: ../../reference/datamodel.rst:2436 msgid "Super Binding" msgstr "super 束縛 (Super Binding)" -#: ../../reference/datamodel.rst:2244 +#: ../../reference/datamodel.rst:2437 msgid "" "A dotted lookup such as ``super(A, a).x`` searches ``a.__class__.__mro__`` " "for a base class ``B`` following ``A`` and then returns ``B.__dict__['x']." @@ -3096,7 +3321,7 @@ msgstr "" "__dict__['x'].__get__(a, A)`` を返します。もしデスクリプタでなければ ``x`` を" "変更せずに返します。" -#: ../../reference/datamodel.rst:2281 +#: ../../reference/datamodel.rst:2474 msgid "" "For instance bindings, the precedence of descriptor invocation depends on " "which descriptor methods are defined. A descriptor can define any " @@ -3114,7 +3339,7 @@ msgid "" "instances." msgstr "" -#: ../../reference/datamodel.rst:2296 +#: ../../reference/datamodel.rst:2489 msgid "" "Python methods (including those decorated with :func:`@staticmethod " "` and :func:`@classmethod `) are implemented as " @@ -3128,7 +3353,7 @@ msgstr "" "より、個々のインスタンスが同じクラスの他のインスタンスと互いに異なる動作を獲" "得することができます。" -#: ../../reference/datamodel.rst:2302 +#: ../../reference/datamodel.rst:2495 msgid "" "The :func:`property` function is implemented as a data descriptor. " "Accordingly, instances cannot override the behavior of a property." @@ -3136,11 +3361,11 @@ msgstr "" ":func:`property` 関数はデータデスクリプタとして実装されています。従って、イン" "スタンスはあるプロパティの動作をオーバーライドすることができません。" -#: ../../reference/datamodel.rst:2309 +#: ../../reference/datamodel.rst:2502 msgid "__slots__" msgstr "__slots__" -#: ../../reference/datamodel.rst:2311 +#: ../../reference/datamodel.rst:2504 msgid "" "*__slots__* allow us to explicitly declare data members (like properties) " "and deny the creation of :attr:`~object.__dict__` and *__weakref__* (unless " @@ -3150,7 +3375,7 @@ msgstr "" "示的に *__slots__* で宣言しているか親クラスに存在しているかでない限り) :attr:" "`~object.__dict__` や *__weakref__* を作成しないようにできます。" -#: ../../reference/datamodel.rst:2315 +#: ../../reference/datamodel.rst:2508 msgid "" "The space saved over using :attr:`~object.__dict__` can be significant. " "Attribute lookup speed can be significantly improved as well." @@ -3159,7 +3384,7 @@ msgstr "" "です。\n" "属性探索のスピードもかなり向上できます。" -#: ../../reference/datamodel.rst:2320 +#: ../../reference/datamodel.rst:2513 msgid "" "This class variable can be assigned a string, iterable, or sequence of " "strings with variable names used by instances. *__slots__* reserves space " @@ -3171,11 +3396,11 @@ msgstr "" "宣言された変数に必要な記憶領域を確保し、:attr:`~object.__dict__` と " "*__weakref__* が自動的に生成されないようにします。" -#: ../../reference/datamodel.rst:2329 +#: ../../reference/datamodel.rst:2522 msgid "Notes on using *__slots__*:" msgstr "" -#: ../../reference/datamodel.rst:2331 +#: ../../reference/datamodel.rst:2524 msgid "" "When inheriting from a class without *__slots__*, the :attr:`~object." "__dict__` and *__weakref__* attribute of the instances will always be " @@ -3184,7 +3409,7 @@ msgstr "" "*__slots__* を持たないクラスから継承するとき、インスタンスの :attr:`~object." "__dict__` 属性と *__weakref__* 属性は常に利用可能です。" -#: ../../reference/datamodel.rst:2335 +#: ../../reference/datamodel.rst:2528 msgid "" "Without a :attr:`~object.__dict__` variable, instances cannot be assigned " "new variables not listed in the *__slots__* definition. Attempts to assign " @@ -3198,7 +3423,7 @@ msgstr "" "的に代入したいのなら、 *__slots__* を宣言する際に ``'__dict__'`` を変数名の" "シーケンスに追加してください。" -#: ../../reference/datamodel.rst:2342 +#: ../../reference/datamodel.rst:2535 msgid "" "Without a *__weakref__* variable for each instance, classes defining " "*__slots__* do not support :mod:`weak references ` to its " @@ -3210,7 +3435,7 @@ msgstr "" "されません。弱参照のサポートが必要なら、 *__slots__* を宣言する際に " "``'__weakref__'`` を変数名のシーケンスに追加してください。" -#: ../../reference/datamodel.rst:2348 +#: ../../reference/datamodel.rst:2541 msgid "" "*__slots__* are implemented at the class level by creating :ref:`descriptors " "` for each variable name. As a result, class attributes cannot " @@ -3222,7 +3447,7 @@ msgstr "" "インスタンス変数のデフォルト値はクラス属性を使って設定できなくなっています; " "そうしないと、デスクリプタによる代入をクラス属性が上書きしてしまうからです。" -#: ../../reference/datamodel.rst:2354 +#: ../../reference/datamodel.rst:2547 msgid "" "The action of a *__slots__* declaration is not limited to the class where it " "is defined. *__slots__* declared in parents are available in child classes. " @@ -3231,7 +3456,7 @@ msgid "" "only contain names of any *additional* slots)." msgstr "" -#: ../../reference/datamodel.rst:2360 +#: ../../reference/datamodel.rst:2553 msgid "" "If a class defines a slot also defined in a base class, the instance " "variable defined by the base class slot is inaccessible (except by " @@ -3245,7 +3470,7 @@ msgstr "" "が不定になってしまいます。将来は、この問題を避けるために何らかのチェックが追" "加されるかもしれません。" -#: ../../reference/datamodel.rst:2365 +#: ../../reference/datamodel.rst:2558 msgid "" ":exc:`TypeError` will be raised if nonempty *__slots__* are defined for a " "class derived from a :c:member:`\"variable-length\" built-in type " @@ -3253,11 +3478,11 @@ msgid "" "`tuple`." msgstr "" -#: ../../reference/datamodel.rst:2370 +#: ../../reference/datamodel.rst:2563 msgid "Any non-string :term:`iterable` may be assigned to *__slots__*." msgstr "" -#: ../../reference/datamodel.rst:2372 +#: ../../reference/datamodel.rst:2565 msgid "" "If a :class:`dictionary ` is used to assign *__slots__*, the " "dictionary keys will be used as the slot names. The values of the dictionary " @@ -3265,13 +3490,13 @@ msgid "" "func:`inspect.getdoc` and displayed in the output of :func:`help`." msgstr "" -#: ../../reference/datamodel.rst:2377 +#: ../../reference/datamodel.rst:2570 msgid "" ":attr:`~object.__class__` assignment works only if both classes have the " "same *__slots__*." msgstr "" -#: ../../reference/datamodel.rst:2380 +#: ../../reference/datamodel.rst:2573 msgid "" ":ref:`Multiple inheritance ` with multiple slotted parent " "classes can be used, but only one parent is allowed to have attributes " @@ -3283,7 +3508,7 @@ msgstr "" "スのスロットは空でなければなりません) - それに違反すると :exc:`TypeError` が" "送出されます。" -#: ../../reference/datamodel.rst:2386 +#: ../../reference/datamodel.rst:2579 msgid "" "If an :term:`iterator` is used for *__slots__* then a :term:`descriptor` is " "created for each of the iterator's values. However, the *__slots__* " @@ -3293,11 +3518,11 @@ msgstr "" "レータの値ごとに :term:`デスクリプタ ` が作られます。しかし、 " "*__slots__* 属性は空のイテレータとなります。" -#: ../../reference/datamodel.rst:2394 +#: ../../reference/datamodel.rst:2587 msgid "Customizing class creation" msgstr "クラス生成をカスタマイズする" -#: ../../reference/datamodel.rst:2396 +#: ../../reference/datamodel.rst:2589 msgid "" "Whenever a class inherits from another class, :meth:`~object." "__init_subclass__` is called on the parent class. This way, it is possible " @@ -3313,7 +3538,7 @@ msgstr "" "して、 ``__init_subclass__`` は、もっぱら、このメソッドを定義したクラスの将来" "のサブクラスに適用されます。" -#: ../../reference/datamodel.rst:2405 +#: ../../reference/datamodel.rst:2598 msgid "" "This method is called whenever the containing class is subclassed. *cls* is " "then the new subclass. If defined as a normal instance method, this method " @@ -3323,7 +3548,7 @@ msgstr "" "*cls* は新しいサブクラスです。もし、このメソッドがインスタンスメソッドとして" "定義されると、暗黙的にクラスメソッドに変換されます。" -#: ../../reference/datamodel.rst:2409 +#: ../../reference/datamodel.rst:2602 msgid "" "Keyword arguments which are given to a new class are passed to the parent " "class's ``__init_subclass__``. For compatibility with other classes using " @@ -3331,7 +3556,7 @@ msgid "" "pass the others over to the base class, as in::" msgstr "" -#: ../../reference/datamodel.rst:2415 +#: ../../reference/datamodel.rst:2608 msgid "" "class Philosopher:\n" " def __init_subclass__(cls, /, default_name, **kwargs):\n" @@ -3342,7 +3567,7 @@ msgid "" " pass" msgstr "" -#: ../../reference/datamodel.rst:2423 +#: ../../reference/datamodel.rst:2616 msgid "" "The default implementation ``object.__init_subclass__`` does nothing, but " "raises an error if it is called with any arguments." @@ -3350,7 +3575,7 @@ msgstr "" "``object.__init_subclass__`` のデフォルト実装は何も行いませんが、何らかの引数" "とともに呼び出された場合は、エラーを送出します。" -#: ../../reference/datamodel.rst:2428 +#: ../../reference/datamodel.rst:2621 msgid "" "The metaclass hint ``metaclass`` is consumed by the rest of the type " "machinery, and is never passed to ``__init_subclass__`` implementations. The " @@ -3362,13 +3587,13 @@ msgstr "" "実際のメタクラス (明示的なヒントではなく) は、 ``type(cls)`` としてアクセスで" "きます。" -#: ../../reference/datamodel.rst:2436 +#: ../../reference/datamodel.rst:2629 msgid "" "When a class is created, :meth:`type.__new__` scans the class variables and " "makes callbacks to those with a :meth:`~object.__set_name__` hook." msgstr "" -#: ../../reference/datamodel.rst:2441 +#: ../../reference/datamodel.rst:2634 msgid "" "Automatically called at the time the owning class *owner* is created. The " "object has been assigned to *name* in that class::" @@ -3376,20 +3601,20 @@ msgstr "" "オーナーとなるクラス *owner* が作成された時点で自動的に呼び出されます。\n" "オブジェクトはそのクラスの *name* に割り当てられます。" -#: ../../reference/datamodel.rst:2444 +#: ../../reference/datamodel.rst:2637 msgid "" "class A:\n" " x = C() # Automatically calls: x.__set_name__(A, 'x')" msgstr "" -#: ../../reference/datamodel.rst:2447 +#: ../../reference/datamodel.rst:2640 msgid "" "If the class variable is assigned after the class is created, :meth:" "`__set_name__` will not be called automatically. If needed, :meth:" "`__set_name__` can be called directly::" msgstr "" -#: ../../reference/datamodel.rst:2451 +#: ../../reference/datamodel.rst:2644 msgid "" "class A:\n" " pass\n" @@ -3399,15 +3624,15 @@ msgid "" "c.__set_name__(A, 'x') # Manually invoke the hook" msgstr "" -#: ../../reference/datamodel.rst:2458 +#: ../../reference/datamodel.rst:2651 msgid "See :ref:`class-object-creation` for more details." msgstr "詳細は :ref:`class-object-creation` を参照してください。" -#: ../../reference/datamodel.rst:2466 +#: ../../reference/datamodel.rst:2659 msgid "Metaclasses" msgstr "メタクラス" -#: ../../reference/datamodel.rst:2473 +#: ../../reference/datamodel.rst:2666 msgid "" "By default, classes are constructed using :func:`type`. The class body is " "executed in a new namespace and the class name is bound locally to the " @@ -3417,7 +3642,7 @@ msgstr "" "い名前空間で実行され、クラス名が ``type(name, bases, namespace)`` の結果に" "ローカルに束縛されます。" -#: ../../reference/datamodel.rst:2477 +#: ../../reference/datamodel.rst:2670 msgid "" "The class creation process can be customized by passing the ``metaclass`` " "keyword argument in the class definition line, or by inheriting from an " @@ -3430,7 +3655,7 @@ msgstr "" "次の例で ``MyClass`` と ``MySubclass`` は両方とも ``Meta`` のインスタンスで" "す::" -#: ../../reference/datamodel.rst:2482 +#: ../../reference/datamodel.rst:2675 msgid "" "class Meta(type):\n" " pass\n" @@ -3442,7 +3667,7 @@ msgid "" " pass" msgstr "" -#: ../../reference/datamodel.rst:2491 +#: ../../reference/datamodel.rst:2684 msgid "" "Any other keyword arguments that are specified in the class definition are " "passed through to all metaclass operations described below." @@ -3450,35 +3675,35 @@ msgstr "" "クラス定義の中で指定された他のキーワード引数は、後述するすべてのメタクラス操" "作に渡されます。" -#: ../../reference/datamodel.rst:2494 +#: ../../reference/datamodel.rst:2687 msgid "When a class definition is executed, the following steps occur:" msgstr "クラス定義が実行される際に、以下のステップが生じます:" -#: ../../reference/datamodel.rst:2496 +#: ../../reference/datamodel.rst:2689 msgid "MRO entries are resolved;" msgstr "MRO エントリの解決が行われる;" -#: ../../reference/datamodel.rst:2497 +#: ../../reference/datamodel.rst:2690 msgid "the appropriate metaclass is determined;" msgstr "適切なメタクラスが決定される;" -#: ../../reference/datamodel.rst:2498 +#: ../../reference/datamodel.rst:2691 msgid "the class namespace is prepared;" msgstr "クラスの名前空間が準備される;" -#: ../../reference/datamodel.rst:2499 +#: ../../reference/datamodel.rst:2692 msgid "the class body is executed;" msgstr "クラスの本体が実行される;" -#: ../../reference/datamodel.rst:2500 +#: ../../reference/datamodel.rst:2693 msgid "the class object is created." msgstr "クラスオブジェクトが作られる。" -#: ../../reference/datamodel.rst:2504 +#: ../../reference/datamodel.rst:2697 msgid "Resolving MRO entries" msgstr "MRO エントリの解決" -#: ../../reference/datamodel.rst:2508 +#: ../../reference/datamodel.rst:2701 msgid "" "If a base that appears in a class definition is not an instance of :class:" "`type`, then an :meth:`!__mro_entries__` method is searched on the base. If " @@ -3490,48 +3715,48 @@ msgid "" "is ignored." msgstr "" -#: ../../reference/datamodel.rst:2519 +#: ../../reference/datamodel.rst:2712 msgid ":func:`types.resolve_bases`" msgstr "" -#: ../../reference/datamodel.rst:2520 +#: ../../reference/datamodel.rst:2713 msgid "Dynamically resolve bases that are not instances of :class:`type`." msgstr "" -#: ../../reference/datamodel.rst:2522 +#: ../../reference/datamodel.rst:2715 msgid ":func:`types.get_original_bases`" msgstr "" -#: ../../reference/datamodel.rst:2523 +#: ../../reference/datamodel.rst:2716 msgid "" "Retrieve a class's \"original bases\" prior to modifications by :meth:" "`~object.__mro_entries__`." msgstr "" -#: ../../reference/datamodel.rst:2526 +#: ../../reference/datamodel.rst:2719 msgid ":pep:`560`" msgstr "" -#: ../../reference/datamodel.rst:2527 +#: ../../reference/datamodel.rst:2720 msgid "Core support for typing module and generic types." msgstr "" -#: ../../reference/datamodel.rst:2531 +#: ../../reference/datamodel.rst:2724 msgid "Determining the appropriate metaclass" msgstr "適切なメタクラスの決定" -#: ../../reference/datamodel.rst:2535 +#: ../../reference/datamodel.rst:2728 msgid "" "The appropriate metaclass for a class definition is determined as follows:" msgstr "クラス定義に対して適切なメタクラスは、以下のように決定されます:" -#: ../../reference/datamodel.rst:2537 +#: ../../reference/datamodel.rst:2730 msgid "" "if no bases and no explicit metaclass are given, then :func:`type` is used;" msgstr "" "基底も明示的なメタクラスも与えられていない場合は、 :func:`type` が使われます;" -#: ../../reference/datamodel.rst:2538 +#: ../../reference/datamodel.rst:2731 msgid "" "if an explicit metaclass is given and it is *not* an instance of :func:" "`type`, then it is used directly as the metaclass;" @@ -3539,7 +3764,7 @@ msgstr "" "明示的なメタクラスが与えられていて、それが :func:`type` のインスタンス *では" "ない* 場合、それをメタクラスとして直接使います;" -#: ../../reference/datamodel.rst:2540 +#: ../../reference/datamodel.rst:2733 msgid "" "if an instance of :func:`type` is given as the explicit metaclass, or bases " "are defined, then the most derived metaclass is used." @@ -3548,7 +3773,7 @@ msgstr "" "義されていた場合は、最も派生した (継承関係で最も下の) メタクラスが使われま" "す。" -#: ../../reference/datamodel.rst:2543 +#: ../../reference/datamodel.rst:2736 msgid "" "The most derived metaclass is selected from the explicitly specified " "metaclass (if any) and the metaclasses (i.e. ``type(cls)``) of all specified " @@ -3562,11 +3787,11 @@ msgstr "" "ス候補のどれもその基準を満たさなければ、クラス定義は ``TypeError`` で失敗しま" "す。" -#: ../../reference/datamodel.rst:2553 +#: ../../reference/datamodel.rst:2746 msgid "Preparing the class namespace" msgstr "クラスの名前空間の準備" -#: ../../reference/datamodel.rst:2558 +#: ../../reference/datamodel.rst:2751 msgid "" "Once the appropriate metaclass has been identified, then the class namespace " "is prepared. If the metaclass has a ``__prepare__`` attribute, it is called " @@ -3585,7 +3810,7 @@ msgstr "" "て返した名前空間は ``__new__`` に渡されますが、最終的なクラスオブジェクトは新" "しい ``dict`` にコピーして作成されます。" -#: ../../reference/datamodel.rst:2567 +#: ../../reference/datamodel.rst:2760 msgid "" "If the metaclass has no ``__prepare__`` attribute, then the class namespace " "is initialised as an empty ordered mapping." @@ -3593,19 +3818,19 @@ msgstr "" "メタクラスに ``__prepare__`` 属性がない場合、クラスの名前空間は空の 順序付き" "マッピングとして初期化されます。" -#: ../../reference/datamodel.rst:2572 +#: ../../reference/datamodel.rst:2765 msgid ":pep:`3115` - Metaclasses in Python 3000" msgstr ":pep:`3115` - Metaclasses in Python 3000" -#: ../../reference/datamodel.rst:2573 +#: ../../reference/datamodel.rst:2766 msgid "Introduced the ``__prepare__`` namespace hook" msgstr "``__prepare__`` 名前空間フックの導入" -#: ../../reference/datamodel.rst:2577 +#: ../../reference/datamodel.rst:2770 msgid "Executing the class body" msgstr "クラス本体の実行" -#: ../../reference/datamodel.rst:2582 +#: ../../reference/datamodel.rst:2775 msgid "" "The class body is executed (approximately) as ``exec(body, globals(), " "namespace)``. The key difference from a normal call to :func:`exec` is that " @@ -3618,7 +3843,7 @@ msgstr "" "われる場合、レキシカルスコープによってクラス本体 (任意のメソッドを含む) が現" "在のスコープと外側のスコープから名前を参照できるという点です。" -#: ../../reference/datamodel.rst:2588 +#: ../../reference/datamodel.rst:2781 msgid "" "However, even when the class definition occurs inside the function, methods " "defined inside the class still cannot see names defined at the class scope. " @@ -3632,11 +3857,11 @@ msgstr "" "説明する、暗黙的に静的スコープが切られている ``__class__`` 参照からアクセスし" "なければなりません。" -#: ../../reference/datamodel.rst:2597 +#: ../../reference/datamodel.rst:2790 msgid "Creating the class object" msgstr "クラスオブジェクトの作成" -#: ../../reference/datamodel.rst:2604 +#: ../../reference/datamodel.rst:2797 msgid "" "Once the class namespace has been populated by executing the class body, the " "class object is created by calling ``metaclass(name, bases, namespace, " @@ -3647,7 +3872,7 @@ msgstr "" "bases, namespace, **kwds)`` を呼び出すことでクラスオブジェクトが作成されます " "(ここで渡される追加のキーワードは ``__prepare__`` に渡されるものと同じです)。" -#: ../../reference/datamodel.rst:2609 +#: ../../reference/datamodel.rst:2802 msgid "" "This class object is the one that will be referenced by the zero-argument " "form of :func:`super`. ``__class__`` is an implicit closure reference " @@ -3665,7 +3890,7 @@ msgstr "" "`super` の無引数形式がレキシカルスコープに基づいて定義されているクラスを正確" "に識別することを可能にします。" -#: ../../reference/datamodel.rst:2619 +#: ../../reference/datamodel.rst:2812 msgid "" "In CPython 3.6 and later, the ``__class__`` cell is passed to the metaclass " "as a ``__classcell__`` entry in the class namespace. If present, this must " @@ -3679,7 +3904,7 @@ msgstr "" "に、 ``type.__new__`` の呼び出しに到達するまで上に伝搬されます。\n" "失敗した場合は、Python 3.8 では :exc:`RuntimeError` になります。" -#: ../../reference/datamodel.rst:2625 +#: ../../reference/datamodel.rst:2818 msgid "" "When using the default metaclass :class:`type`, or any metaclass that " "ultimately calls ``type.__new__``, the following additional customization " @@ -3689,7 +3914,7 @@ msgstr "" "メタクラスを使っているときは、クラスオブジェクトを作成した後に次のカスタム化" "の手順が起動されます:" -#: ../../reference/datamodel.rst:2629 +#: ../../reference/datamodel.rst:2822 msgid "" "The ``type.__new__`` method collects all of the attributes in the class " "namespace that define a :meth:`~object.__set_name__` method;" @@ -3697,7 +3922,7 @@ msgstr "" "``type.__new__`` メソッドが :meth:`~object.__set_name__` が定義されているクラ" "スの名前空間にある全ての属性を収集します;" -#: ../../reference/datamodel.rst:2631 +#: ../../reference/datamodel.rst:2824 msgid "" "Those ``__set_name__`` methods are called with the class being defined and " "the assigned name of that particular attribute;" @@ -3705,7 +3930,7 @@ msgstr "" "それらの ``__set_name__`` メソッドが、そのメソッドが定義されているクラス、お" "よびそこに属する属性に割り当てられている名前を引数として呼び出されます;" -#: ../../reference/datamodel.rst:2633 +#: ../../reference/datamodel.rst:2826 msgid "" "The :meth:`~object.__init_subclass__` hook is called on the immediate parent " "of the new class in its method resolution order." @@ -3713,7 +3938,7 @@ msgstr "" "新しいクラスのメソッド解決順序ですぐ上に位置する親クラスで :meth:`~object." "__init_subclass__` フックが呼び出されます。" -#: ../../reference/datamodel.rst:2636 +#: ../../reference/datamodel.rst:2829 msgid "" "After the class object is created, it is passed to the class decorators " "included in the class definition (if any) and the resulting object is bound " @@ -3723,7 +3948,7 @@ msgstr "" "タ (もしあれば) にクラスオブジェクトが渡され、デコレータが返すオブジェクトが" "ここで定義されたクラスとしてローカルの名前空間に束縛されます。" -#: ../../reference/datamodel.rst:2640 +#: ../../reference/datamodel.rst:2833 msgid "" "When a new class is created by ``type.__new__``, the object provided as the " "namespace parameter is copied to a new ordered mapping and the original " @@ -3731,19 +3956,19 @@ msgid "" "becomes the :attr:`~type.__dict__` attribute of the class object." msgstr "" -#: ../../reference/datamodel.rst:2647 +#: ../../reference/datamodel.rst:2840 msgid ":pep:`3135` - New super" msgstr ":pep:`3135` - New super" -#: ../../reference/datamodel.rst:2648 +#: ../../reference/datamodel.rst:2841 msgid "Describes the implicit ``__class__`` closure reference" msgstr "暗黙の ``__class__`` クロージャ参照について記述しています" -#: ../../reference/datamodel.rst:2652 +#: ../../reference/datamodel.rst:2845 msgid "Uses for metaclasses" msgstr "メタクラスの用途" -#: ../../reference/datamodel.rst:2654 +#: ../../reference/datamodel.rst:2847 msgid "" "The potential uses for metaclasses are boundless. Some ideas that have been " "explored include enum, logging, interface checking, automatic delegation, " @@ -3755,11 +3980,11 @@ msgstr "" "動プロパティ生成、プロキシ、フレームワーク、そして自動リソースロック/同期と" "いったものがあります。" -#: ../../reference/datamodel.rst:2661 +#: ../../reference/datamodel.rst:2854 msgid "Customizing instance and subclass checks" msgstr "インスタンスのカスタマイズとサブクラスチェック" -#: ../../reference/datamodel.rst:2663 +#: ../../reference/datamodel.rst:2856 msgid "" "The following methods are used to override the default behavior of the :func:" "`isinstance` and :func:`issubclass` built-in functions." @@ -3767,7 +3992,7 @@ msgstr "" "以下のメソッドは組み込み関数 :func:`isinstance` と :func:`issubclass` のデ" "フォルトの動作を上書きするのに利用します。" -#: ../../reference/datamodel.rst:2666 +#: ../../reference/datamodel.rst:2859 msgid "" "In particular, the metaclass :class:`abc.ABCMeta` implements these methods " "in order to allow the addition of Abstract Base Classes (ABCs) as \"virtual " @@ -3778,7 +4003,7 @@ msgstr "" "クラス (virtual base classes)\" として、他の ABC を含む、任意のクラスや (組み" "込み型を含む) 型に追加するために、これらのメソッドを実装しています。" -#: ../../reference/datamodel.rst:2673 +#: ../../reference/datamodel.rst:2866 msgid "" "Return true if *instance* should be considered a (direct or indirect) " "instance of *class*. If defined, called to implement ``isinstance(instance, " @@ -3788,7 +4013,7 @@ msgstr "" "に true を返します。定義されていれば、 ``isinstance(instance, class)`` の実装" "のために呼び出されます。" -#: ../../reference/datamodel.rst:2680 +#: ../../reference/datamodel.rst:2873 msgid "" "Return true if *subclass* should be considered a (direct or indirect) " "subclass of *class*. If defined, called to implement ``issubclass(subclass, " @@ -3798,7 +4023,7 @@ msgstr "" "true を返します。定義されていれば、 ``issubclass(subclass, class)`` の実装の" "ために呼び出されます。" -#: ../../reference/datamodel.rst:2685 +#: ../../reference/datamodel.rst:2878 msgid "" "Note that these methods are looked up on the type (metaclass) of a class. " "They cannot be defined as class methods in the actual class. This is " @@ -3810,11 +4035,11 @@ msgstr "" "自体がクラスであるこの場合にのみ、インスタンスに呼び出される特殊メソッドの検" "索と一貫しています。" -#: ../../reference/datamodel.rst:2692 +#: ../../reference/datamodel.rst:2885 msgid ":pep:`3119` - Introducing Abstract Base Classes" msgstr ":pep:`3119` - 抽象基底クラスの導入" -#: ../../reference/datamodel.rst:2693 +#: ../../reference/datamodel.rst:2886 msgid "" "Includes the specification for customizing :func:`isinstance` and :func:" "`issubclass` behavior through :meth:`~type.__instancecheck__` and :meth:" @@ -3823,11 +4048,11 @@ msgid "" "language." msgstr "" -#: ../../reference/datamodel.rst:2701 +#: ../../reference/datamodel.rst:2894 msgid "Emulating generic types" msgstr "ジェネリック型をエミュレートする" -#: ../../reference/datamodel.rst:2703 +#: ../../reference/datamodel.rst:2896 msgid "" "When using :term:`type annotations`, it is often useful to " "*parameterize* a :term:`generic type` using Python's square-brackets " @@ -3835,29 +4060,29 @@ msgid "" "a :class:`list` in which all the elements are of type :class:`int`." msgstr "" -#: ../../reference/datamodel.rst:2710 +#: ../../reference/datamodel.rst:2903 msgid ":pep:`484` - Type Hints" msgstr ":pep:`484` - 型ヒント" -#: ../../reference/datamodel.rst:2711 +#: ../../reference/datamodel.rst:2904 msgid "Introducing Python's framework for type annotations" msgstr "" -#: ../../reference/datamodel.rst:2713 +#: ../../reference/datamodel.rst:2906 msgid ":ref:`Generic Alias Types`" msgstr "" -#: ../../reference/datamodel.rst:2714 +#: ../../reference/datamodel.rst:2907 msgid "Documentation for objects representing parameterized generic classes" msgstr "" -#: ../../reference/datamodel.rst:2716 +#: ../../reference/datamodel.rst:2909 msgid "" ":ref:`Generics`, :ref:`user-defined generics` and :" "class:`typing.Generic`" msgstr "" -#: ../../reference/datamodel.rst:2717 +#: ../../reference/datamodel.rst:2910 msgid "" "Documentation on how to implement generic classes that can be parameterized " "at runtime and understood by static type-checkers." @@ -3865,13 +4090,13 @@ msgstr "" "実行時にパラメータ設定が可能であり、かつ静的な型チェッカーが理解できるジェネ" "リッククラスを実装する方法のドキュメントです。" -#: ../../reference/datamodel.rst:2720 +#: ../../reference/datamodel.rst:2913 msgid "" "A class can *generally* only be parameterized if it defines the special " "class method ``__class_getitem__()``." msgstr "" -#: ../../reference/datamodel.rst:2725 +#: ../../reference/datamodel.rst:2918 msgid "" "Return an object representing the specialization of a generic class by type " "arguments found in *key*." @@ -3879,25 +4104,25 @@ msgstr "" "*key* にある型引数で特殊化されたジェネリッククラスを表すオブジェクトを返しま" "す。" -#: ../../reference/datamodel.rst:2728 +#: ../../reference/datamodel.rst:2921 msgid "" "When defined on a class, ``__class_getitem__()`` is automatically a class " "method. As such, there is no need for it to be decorated with :func:" "`@classmethod` when it is defined." msgstr "" -#: ../../reference/datamodel.rst:2734 +#: ../../reference/datamodel.rst:2927 msgid "The purpose of *__class_getitem__*" msgstr "" -#: ../../reference/datamodel.rst:2736 +#: ../../reference/datamodel.rst:2929 msgid "" "The purpose of :meth:`~object.__class_getitem__` is to allow runtime " "parameterization of standard-library generic classes in order to more easily " "apply :term:`type hints` to these classes." msgstr "" -#: ../../reference/datamodel.rst:2740 +#: ../../reference/datamodel.rst:2933 msgid "" "To implement custom generic classes that can be parameterized at runtime and " "understood by static type-checkers, users should either inherit from a " @@ -3906,7 +4131,7 @@ msgid "" "own implementation of ``__class_getitem__()``." msgstr "" -#: ../../reference/datamodel.rst:2746 +#: ../../reference/datamodel.rst:2939 msgid "" "Custom implementations of :meth:`~object.__class_getitem__` on classes " "defined outside of the standard library may not be understood by third-party " @@ -3914,11 +4139,11 @@ msgid "" "purposes other than type hinting is discouraged." msgstr "" -#: ../../reference/datamodel.rst:2756 +#: ../../reference/datamodel.rst:2949 msgid "*__class_getitem__* versus *__getitem__*" msgstr "" -#: ../../reference/datamodel.rst:2758 +#: ../../reference/datamodel.rst:2951 msgid "" "Usually, the :ref:`subscription` of an object using square " "brackets will call the :meth:`~object.__getitem__` instance method defined " @@ -3928,14 +4153,14 @@ msgid "" "genericalias>` object if it is properly defined." msgstr "" -#: ../../reference/datamodel.rst:2765 +#: ../../reference/datamodel.rst:2958 msgid "" "Presented with the :term:`expression` ``obj[x]``, the Python interpreter " "follows something like the following process to decide whether :meth:" "`~object.__getitem__` or :meth:`~object.__class_getitem__` should be called::" msgstr "" -#: ../../reference/datamodel.rst:2770 +#: ../../reference/datamodel.rst:2963 msgid "" "from inspect import isclass\n" "\n" @@ -3961,7 +4186,7 @@ msgid "" " )" msgstr "" -#: ../../reference/datamodel.rst:2793 +#: ../../reference/datamodel.rst:2986 msgid "" "In Python, all classes are themselves instances of other classes. The class " "of a class is known as that class's :term:`metaclass`, and most classes have " @@ -3971,7 +4196,7 @@ msgid "" "__class_getitem__` being called::" msgstr "" -#: ../../reference/datamodel.rst:2800 +#: ../../reference/datamodel.rst:2993 msgid "" ">>> # list has class \"type\" as its metaclass, like most classes:\n" ">>> type(list)\n" @@ -3986,14 +4211,14 @@ msgid "" "" msgstr "" -#: ../../reference/datamodel.rst:2812 +#: ../../reference/datamodel.rst:3005 msgid "" "However, if a class has a custom metaclass that defines :meth:`~object." "__getitem__`, subscribing the class may result in different behaviour. An " "example of this can be found in the :mod:`enum` module::" msgstr "" -#: ../../reference/datamodel.rst:2816 +#: ../../reference/datamodel.rst:3009 msgid "" ">>> from enum import Enum\n" ">>> class Menu(Enum):\n" @@ -4013,23 +4238,23 @@ msgid "" "" msgstr "" -#: ../../reference/datamodel.rst:2835 +#: ../../reference/datamodel.rst:3028 msgid ":pep:`560` - Core Support for typing module and generic types" msgstr "" ":pep:`560` - typing モジュールとジェネリック型に対する言語コアによるサポート" -#: ../../reference/datamodel.rst:2836 +#: ../../reference/datamodel.rst:3029 msgid "" "Introducing :meth:`~object.__class_getitem__`, and outlining when a :ref:" "`subscription` results in ``__class_getitem__()`` being " "called instead of :meth:`~object.__getitem__`" msgstr "" -#: ../../reference/datamodel.rst:2844 +#: ../../reference/datamodel.rst:3037 msgid "Emulating callable objects" msgstr "呼び出し可能オブジェクトをエミュレートする" -#: ../../reference/datamodel.rst:2851 +#: ../../reference/datamodel.rst:3044 msgid "" "Called when the instance is \"called\" as a function; if this method is " "defined, ``x(arg1, arg2, ...)`` roughly translates to ``type(x).__call__(x, " @@ -4039,11 +4264,11 @@ msgstr "" "されている場合、 ``x(arg1, arg2, ...)`` は大まかには ``type(x).__call__(x, " "arg1, ...)`` に変換されます。" -#: ../../reference/datamodel.rst:2858 +#: ../../reference/datamodel.rst:3051 msgid "Emulating container types" msgstr "コンテナをエミュレートする" -#: ../../reference/datamodel.rst:2860 +#: ../../reference/datamodel.rst:3053 msgid "" "The following methods can be defined to implement container objects. " "Containers usually are :term:`sequences ` (such as :class:`lists " @@ -4079,7 +4304,7 @@ msgid "" "should iterate through the values." msgstr "" -#: ../../reference/datamodel.rst:2901 +#: ../../reference/datamodel.rst:3094 msgid "" "Called to implement the built-in function :func:`len`. Should return the " "length of the object, an integer ``>=`` 0. Also, an object that doesn't " @@ -4087,7 +4312,7 @@ msgid "" "returns zero is considered to be false in a Boolean context." msgstr "" -#: ../../reference/datamodel.rst:2908 +#: ../../reference/datamodel.rst:3101 msgid "" "In CPython, the length is required to be at most :data:`sys.maxsize`. If the " "length is larger than :data:`!sys.maxsize` some features (such as :func:" @@ -4096,7 +4321,7 @@ msgid "" "`~object.__bool__` method." msgstr "" -#: ../../reference/datamodel.rst:2917 +#: ../../reference/datamodel.rst:3110 msgid "" "Called to implement :func:`operator.length_hint`. Should return an estimated " "length for the object (which may be greater or less than the actual length). " @@ -4106,30 +4331,30 @@ msgid "" "never required for correctness." msgstr "" -#: ../../reference/datamodel.rst:2931 +#: ../../reference/datamodel.rst:3124 msgid "" "Slicing is done exclusively with the following three methods. A call like ::" msgstr "" "スライシングは、以下の 3 メソッドによって排他的に行われます。次のような呼び出" "しは ::" -#: ../../reference/datamodel.rst:2933 +#: ../../reference/datamodel.rst:3126 msgid "a[1:2] = b" msgstr "" -#: ../../reference/datamodel.rst:2935 +#: ../../reference/datamodel.rst:3128 msgid "is translated to ::" msgstr "次のように翻訳され ::" -#: ../../reference/datamodel.rst:2937 +#: ../../reference/datamodel.rst:3130 msgid "a[slice(1, 2, None)] = b" msgstr "" -#: ../../reference/datamodel.rst:2939 +#: ../../reference/datamodel.rst:3132 msgid "and so forth. Missing slice items are always filled in with ``None``." msgstr "以下も同様です。存在しないスライスの要素は ``None`` で埋められます。" -#: ../../reference/datamodel.rst:2944 +#: ../../reference/datamodel.rst:3137 msgid "" "Called to implement evaluation of ``self[key]``. For :term:`sequence` types, " "the accepted keys should be integers. Optionally, they may support :class:" @@ -4141,7 +4366,7 @@ msgid "" "`KeyError` should be raised." msgstr "" -#: ../../reference/datamodel.rst:2956 +#: ../../reference/datamodel.rst:3149 msgid "" ":keyword:`for` loops expect that an :exc:`IndexError` will be raised for " "illegal indexes to allow proper detection of the end of the sequence." @@ -4150,14 +4375,14 @@ msgstr "" "に、不正なインデクスに対して :exc:`IndexError` が送出されるものと期待していま" "す。" -#: ../../reference/datamodel.rst:2961 +#: ../../reference/datamodel.rst:3154 msgid "" "When :ref:`subscripting` a *class*, the special class method :" "meth:`~object.__class_getitem__` may be called instead of ``__getitem__()``. " "See :ref:`classgetitem-versus-getitem` for more details." msgstr "" -#: ../../reference/datamodel.rst:2969 +#: ../../reference/datamodel.rst:3162 msgid "" "Called to implement assignment to ``self[key]``. Same note as for :meth:" "`__getitem__`. This should only be implemented for mappings if the objects " @@ -4172,7 +4397,7 @@ msgstr "" "正な *key* に対しては、 :meth:`__getitem__` メソッドと同様の例外の送出を行わ" "なければなりません。" -#: ../../reference/datamodel.rst:2978 +#: ../../reference/datamodel.rst:3171 msgid "" "Called to implement deletion of ``self[key]``. Same note as for :meth:" "`__getitem__`. This should only be implemented for mappings if the objects " @@ -4186,7 +4411,7 @@ msgstr "" "*key* に対しては、 :meth:`__getitem__` メソッドと同様の例外の送出を行わなけれ" "ばなりません。" -#: ../../reference/datamodel.rst:2987 +#: ../../reference/datamodel.rst:3180 msgid "" "Called by :class:`dict`\\ .\\ :meth:`__getitem__` to implement ``self[key]`` " "for dict subclasses when key is not in the dictionary." @@ -4195,7 +4420,7 @@ msgstr "" "クラスのために :class:`dict`\\ .\\ :meth:`__getitem__` によって呼び出されま" "す。" -#: ../../reference/datamodel.rst:2993 +#: ../../reference/datamodel.rst:3186 msgid "" "This method is called when an :term:`iterator` is required for a container. " "This method should return a new iterator object that can iterate over all " @@ -4207,7 +4432,7 @@ msgstr "" "処理できるような、新たなイテレータオブジェクトを返さなければなりません。マッ" "ピングでは、コンテナ内のキーに渡って反復処理しなければなりません。" -#: ../../reference/datamodel.rst:3001 +#: ../../reference/datamodel.rst:3194 msgid "" "Called (if present) by the :func:`reversed` built-in to implement reverse " "iteration. It should return a new iterator object that iterates over all " @@ -4217,7 +4442,7 @@ msgstr "" "れば)呼び出します。コンテナ内の全要素を逆順にイテレートする、新しいイテレータ" "を返すべきです。" -#: ../../reference/datamodel.rst:3005 +#: ../../reference/datamodel.rst:3198 msgid "" "If the :meth:`__reversed__` method is not provided, the :func:`reversed` " "built-in will fall back to using the sequence protocol (:meth:`__len__` and :" @@ -4231,7 +4456,7 @@ msgstr "" "は、 :func:`reversed` よりも効率のいい実装を提供できる場合にのみ :meth:" "`__reversed__` を定義するべきです。" -#: ../../reference/datamodel.rst:3012 +#: ../../reference/datamodel.rst:3205 msgid "" "The membership test operators (:keyword:`in` and :keyword:`not in`) are " "normally implemented as an iteration through a container. However, container " @@ -4243,7 +4468,7 @@ msgstr "" "の特殊メソッドを定義して、より効率的な実装を行ったり、オブジェクトがイテラブ" "ルでなくてもよいようにできます。" -#: ../../reference/datamodel.rst:3019 +#: ../../reference/datamodel.rst:3212 msgid "" "Called to implement membership test operators. Should return true if *item* " "is in *self*, false otherwise. For mapping objects, this should consider " @@ -4254,7 +4479,7 @@ msgstr "" "トの場合、値やキーと値の組ではなく、キーに対する帰属テストを考えなければなり" "ません。" -#: ../../reference/datamodel.rst:3023 +#: ../../reference/datamodel.rst:3216 msgid "" "For objects that don't define :meth:`__contains__`, the membership test " "first tries iteration via :meth:`__iter__`, then the old sequence iteration " @@ -4266,11 +4491,11 @@ msgstr "" "コル :meth:`__getitem__` を使います、 :ref:`言語レファレンスのこの節 " "` を参照して下さい。" -#: ../../reference/datamodel.rst:3032 +#: ../../reference/datamodel.rst:3225 msgid "Emulating numeric types" msgstr "数値型をエミュレートする" -#: ../../reference/datamodel.rst:3034 +#: ../../reference/datamodel.rst:3227 msgid "" "The following methods can be defined to emulate numeric objects. Methods " "corresponding to operations that are not supported by the particular kind of " @@ -4282,7 +4507,7 @@ msgstr "" "(非整数の数値に対するビット単位演算など) は、未定義のままにしておかなければな" "りません。" -#: ../../reference/datamodel.rst:3060 +#: ../../reference/datamodel.rst:3253 msgid "" "These methods are called to implement the binary arithmetic operations " "(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" @@ -4307,13 +4532,13 @@ msgstr "" "合、 :meth:`__pow__` はオプションの第三引数を受け取るものとして定義されなけれ" "ばなりません。" -#: ../../reference/datamodel.rst:3071 +#: ../../reference/datamodel.rst:3264 msgid "" "If one of those methods does not support the operation with the supplied " "arguments, it should return :data:`NotImplemented`." msgstr "" -#: ../../reference/datamodel.rst:3094 +#: ../../reference/datamodel.rst:3287 msgid "" "These methods are called to implement the binary arithmetic operations " "(``+``, ``-``, ``*``, ``@``, ``/``, ``//``, ``%``, :func:`divmod`, :func:" @@ -4326,7 +4551,7 @@ msgid "" "`NotImplemented`." msgstr "" -#: ../../reference/datamodel.rst:3106 +#: ../../reference/datamodel.rst:3299 msgid "" "Note that ternary :func:`pow` will not try calling :meth:`__rpow__` (the " "coercion rules would become too complicated)." @@ -4334,7 +4559,7 @@ msgstr "" "ただし、三項演算子 :func:`pow` が :meth:`__rpow__` を呼ぶことはないので注意し" "てください (型強制の規則が非常に難解になるからです)。" -#: ../../reference/datamodel.rst:3111 +#: ../../reference/datamodel.rst:3304 msgid "" "If the right operand's type is a subclass of the left operand's type and " "that subclass provides a different implementation of the reflected method " @@ -4347,7 +4572,7 @@ msgstr "" "演算子の非反射メソッドが呼ばれる前に、このメソッドが呼ばれます。この振る舞い" "により、サブクラスが親の演算をオーバーライドすることが可能になります。" -#: ../../reference/datamodel.rst:3132 +#: ../../reference/datamodel.rst:3325 msgid "" "These methods are called to implement the augmented arithmetic assignments " "(``+=``, ``-=``, ``*=``, ``@=``, ``/=``, ``//=``, ``%=``, ``**=``, ``<<=``, " @@ -4365,7 +4590,7 @@ msgid "" "data model." msgstr "" -#: ../../reference/datamodel.rst:3155 +#: ../../reference/datamodel.rst:3348 msgid "" "Called to implement the unary arithmetic operations (``-``, ``+``, :func:" "`abs` and ``~``)." @@ -4373,7 +4598,7 @@ msgstr "" "呼び出して単項算術演算 (``-``, ``+``, :func:`abs` および ``~``) を実装しま" "す。" -#: ../../reference/datamodel.rst:3168 +#: ../../reference/datamodel.rst:3361 msgid "" "Called to implement the built-in functions :func:`complex`, :func:`int` and :" "func:`float`. Should return a value of the appropriate type." @@ -4382,7 +4607,7 @@ msgstr "" "れます。\n" "適切な型の値を返さなければなりません。" -#: ../../reference/datamodel.rst:3175 +#: ../../reference/datamodel.rst:3368 msgid "" "Called to implement :func:`operator.index`, and whenever Python needs to " "losslessly convert the numeric object to an integer object (such as in " @@ -4397,7 +4622,7 @@ msgstr "" "このメソッドがあるとその数値オブジェクトが整数型であることが示唆されます。\n" "整数を返さなければなりません。" -#: ../../reference/datamodel.rst:3181 +#: ../../reference/datamodel.rst:3374 msgid "" "If :meth:`__int__`, :meth:`__float__` and :meth:`__complex__` are not " "defined then corresponding built-in functions :func:`int`, :func:`float` " @@ -4407,7 +4632,7 @@ msgstr "" "い場合、組み込み関数の :func:`int`, :func:`float`, :func:`complex` は :meth:" "`__index__` にフォールバックします。" -#: ../../reference/datamodel.rst:3193 +#: ../../reference/datamodel.rst:3386 msgid "" "Called to implement the built-in function :func:`round` and :mod:`math` " "functions :func:`~math.trunc`, :func:`~math.floor` and :func:`~math.ceil`. " @@ -4421,21 +4646,21 @@ msgstr "" "は :class:`~numbers.Integral` (たいていは :class:`int`) に切り詰められたオブ" "ジェクトの値を返すべきです。" -#: ../../reference/datamodel.rst:3199 +#: ../../reference/datamodel.rst:3392 msgid "" "The built-in function :func:`int` falls back to :meth:`__trunc__` if " "neither :meth:`__int__` nor :meth:`__index__` is defined." msgstr "" -#: ../../reference/datamodel.rst:3202 +#: ../../reference/datamodel.rst:3395 msgid "The delegation of :func:`int` to :meth:`__trunc__` is deprecated." msgstr ":func:`int` の :meth:`__trunc__` への処理の委譲は非推奨になりました。" -#: ../../reference/datamodel.rst:3209 +#: ../../reference/datamodel.rst:3402 msgid "With Statement Context Managers" msgstr "with文とコンテキストマネージャ" -#: ../../reference/datamodel.rst:3211 +#: ../../reference/datamodel.rst:3404 msgid "" "A :dfn:`context manager` is an object that defines the runtime context to be " "established when executing a :keyword:`with` statement. The context manager " @@ -4451,7 +4676,7 @@ msgstr "" "照)により起動されますが、これらのメソッドを直接呼び出すことで起動することも" "できます。" -#: ../../reference/datamodel.rst:3222 +#: ../../reference/datamodel.rst:3415 msgid "" "Typical uses of context managers include saving and restoring various kinds " "of global state, locking and unlocking resources, closing opened files, etc." @@ -4460,14 +4685,14 @@ msgstr "" "よび更新、リソースのロックとアンロック、ファイルのオープンとクローズなどが挙" "げられます。" -#: ../../reference/datamodel.rst:3225 +#: ../../reference/datamodel.rst:3418 msgid "" "For more information on context managers, see :ref:`typecontextmanager`." msgstr "" "コンテキストマネージャについてのさらなる情報については、 :ref:" "`typecontextmanager` を参照してください。" -#: ../../reference/datamodel.rst:3230 +#: ../../reference/datamodel.rst:3423 msgid "" "Enter the runtime context related to this object. The :keyword:`with` " "statement will bind this method's return value to the target(s) specified in " @@ -4476,7 +4701,7 @@ msgstr "" "コンテキストマネージャのの入り口で実行される処理です。 :keyword:`with` 文は、" "文の :keyword:`!as` 節で規定された値を返すこのメソッドを呼び出します。" -#: ../../reference/datamodel.rst:3237 +#: ../../reference/datamodel.rst:3430 msgid "" "Exit the runtime context related to this object. The parameters describe the " "exception that caused the context to be exited. If the context was exited " @@ -4486,7 +4711,7 @@ msgstr "" "が終了した原因となった例外について説明しています。コンテキストが例外を送出せ" "ず終了した場合は、全ての引き数に :const:`None` が設定されます。" -#: ../../reference/datamodel.rst:3241 +#: ../../reference/datamodel.rst:3434 msgid "" "If an exception is supplied, and the method wishes to suppress the exception " "(i.e., prevent it from being propagated), it should return a true value. " @@ -4497,27 +4722,27 @@ msgstr "" "播されるのを防ぎたい場合)、このメソッドは True を返す必要があります。そうで" "なければ、このメソッドの終了後、例外は通常通り伝播することになります。" -#: ../../reference/datamodel.rst:3245 +#: ../../reference/datamodel.rst:3438 msgid "" "Note that :meth:`~object.__exit__` methods should not reraise the passed-in " "exception; this is the caller's responsibility." msgstr "" -#: ../../reference/datamodel.rst:3251 +#: ../../reference/datamodel.rst:3444 msgid ":pep:`343` - The \"with\" statement" msgstr ":pep:`343` - \"with\" ステートメント" -#: ../../reference/datamodel.rst:3252 +#: ../../reference/datamodel.rst:3445 msgid "" "The specification, background, and examples for the Python :keyword:`with` " "statement." msgstr "Python の :keyword:`with` 文の仕様、背景、および例が記載されています。" -#: ../../reference/datamodel.rst:3259 +#: ../../reference/datamodel.rst:3452 msgid "Customizing positional arguments in class pattern matching" msgstr "クラスパターンマッチの位置引数のカスタマイズ" -#: ../../reference/datamodel.rst:3261 +#: ../../reference/datamodel.rst:3454 msgid "" "When using a class name in a pattern, positional arguments in the pattern " "are not allowed by default, i.e. ``case MyClass(x, y)`` is typically invalid " @@ -4529,7 +4754,7 @@ msgstr "" "です。このようなパターンを利用するには、 *__match_args__* 属性をクラスに定義" "する必要があります。" -#: ../../reference/datamodel.rst:3268 +#: ../../reference/datamodel.rst:3461 msgid "" "This class variable can be assigned a tuple of strings. When this class is " "used in a class pattern with positional arguments, each positional argument " @@ -4542,7 +4767,7 @@ msgstr "" "*__match_args__* の中の値をキーワードとする、キーワード引数に変換されます。こ" "の属性がない時は、 ``()`` が設定されているのと同義です。" -#: ../../reference/datamodel.rst:3274 +#: ../../reference/datamodel.rst:3467 msgid "" "For example, if ``MyClass.__match_args__`` is ``(\"left\", \"center\", " "\"right\")`` that means that ``case MyClass(x, y)`` is equivalent to ``case " @@ -4557,19 +4782,19 @@ msgstr "" "*__match_args__* の要素数と同等かそれ以下でなければならない点に注意してくださ" "い。もし、多かった場合には、パターンマッチは :exc:`TypeError` を送出します。" -#: ../../reference/datamodel.rst:3284 +#: ../../reference/datamodel.rst:3477 msgid ":pep:`634` - Structural Pattern Matching" msgstr ":pep:`634` - 構造的パターンマッチ" -#: ../../reference/datamodel.rst:3285 +#: ../../reference/datamodel.rst:3478 msgid "The specification for the Python ``match`` statement." msgstr "``match`` 文の詳細。" -#: ../../reference/datamodel.rst:3291 +#: ../../reference/datamodel.rst:3484 msgid "Emulating buffer types" msgstr "" -#: ../../reference/datamodel.rst:3293 +#: ../../reference/datamodel.rst:3486 msgid "" "The :ref:`buffer protocol ` provides a way for Python objects " "to expose efficient access to a low-level memory array. This protocol is " @@ -4577,13 +4802,13 @@ msgid "" "and third-party libraries may define additional buffer types." msgstr "" -#: ../../reference/datamodel.rst:3298 +#: ../../reference/datamodel.rst:3491 msgid "" "While buffer types are usually implemented in C, it is also possible to " "implement the protocol in Python." msgstr "" -#: ../../reference/datamodel.rst:3303 +#: ../../reference/datamodel.rst:3496 msgid "" "Called when a buffer is requested from *self* (for example, by the :class:" "`memoryview` constructor). The *flags* argument is an integer representing " @@ -4593,7 +4818,7 @@ msgid "" "`memoryview` object." msgstr "" -#: ../../reference/datamodel.rst:3312 +#: ../../reference/datamodel.rst:3505 msgid "" "Called when a buffer is no longer needed. The *buffer* argument is a :class:" "`memoryview` object that was previously returned by :meth:`~object." @@ -4602,28 +4827,28 @@ msgid "" "to perform any cleanup are not required to implement this method." msgstr "" -#: ../../reference/datamodel.rst:3323 +#: ../../reference/datamodel.rst:3516 msgid ":pep:`688` - Making the buffer protocol accessible in Python" msgstr "" -#: ../../reference/datamodel.rst:3324 +#: ../../reference/datamodel.rst:3517 msgid "" "Introduces the Python ``__buffer__`` and ``__release_buffer__`` methods." msgstr "" -#: ../../reference/datamodel.rst:3326 +#: ../../reference/datamodel.rst:3519 msgid ":class:`collections.abc.Buffer`" msgstr "" -#: ../../reference/datamodel.rst:3327 +#: ../../reference/datamodel.rst:3520 msgid "ABC for buffer types." msgstr "" -#: ../../reference/datamodel.rst:3332 +#: ../../reference/datamodel.rst:3525 msgid "Special method lookup" msgstr "特殊メソッド検索" -#: ../../reference/datamodel.rst:3334 +#: ../../reference/datamodel.rst:3527 msgid "" "For custom classes, implicit invocations of special methods are only " "guaranteed to work correctly if defined on an object's type, not in the " @@ -4634,7 +4859,7 @@ msgstr "" "ス辞書ではなく、オブジェクトの型で定義されているときにのみ正しく動作すること" "が保証されます。この動作のため、以下のコードは例外を送出します::" -#: ../../reference/datamodel.rst:3339 +#: ../../reference/datamodel.rst:3532 msgid "" ">>> class C:\n" "... pass\n" @@ -4647,7 +4872,7 @@ msgid "" "TypeError: object of type 'C' has no len()" msgstr "" -#: ../../reference/datamodel.rst:3349 +#: ../../reference/datamodel.rst:3542 msgid "" "The rationale behind this behaviour lies with a number of special methods " "such as :meth:`~object.__hash__` and :meth:`~object.__repr__` that are " @@ -4661,7 +4886,7 @@ msgstr "" "使った場合、 type オブジェクト自体に対して実行されたときに失敗してしまいま" "す::" -#: ../../reference/datamodel.rst:3356 +#: ../../reference/datamodel.rst:3549 msgid "" ">>> 1 .__hash__() == hash(1)\n" "True\n" @@ -4671,7 +4896,7 @@ msgid "" "TypeError: descriptor '__hash__' of 'int' object needs an argument" msgstr "" -#: ../../reference/datamodel.rst:3363 +#: ../../reference/datamodel.rst:3556 msgid "" "Incorrectly attempting to invoke an unbound method of a class in this way is " "sometimes referred to as 'metaclass confusion', and is avoided by bypassing " @@ -4681,7 +4906,7 @@ msgstr "" "confusion' と呼ばれることもあり、特殊メソッドを検索するときはインスタンスをバ" "イパスすることで回避されます::" -#: ../../reference/datamodel.rst:3367 +#: ../../reference/datamodel.rst:3560 msgid "" ">>> type(1).__hash__(1) == hash(1)\n" "True\n" @@ -4689,7 +4914,7 @@ msgid "" "True" msgstr "" -#: ../../reference/datamodel.rst:3372 +#: ../../reference/datamodel.rst:3565 msgid "" "In addition to bypassing any instance attributes in the interest of " "correctness, implicit special method lookup generally also bypasses the :" @@ -4699,7 +4924,7 @@ msgstr "" "ブジェクトのメタクラスを含めて、 :meth:`~object.__getattribute__` メソッドも" "バイパスします::" -#: ../../reference/datamodel.rst:3376 +#: ../../reference/datamodel.rst:3569 msgid "" ">>> class Meta(type):\n" "... def __getattribute__(*args):\n" @@ -4724,7 +4949,7 @@ msgid "" "10" msgstr "" -#: ../../reference/datamodel.rst:3398 +#: ../../reference/datamodel.rst:3591 msgid "" "Bypassing the :meth:`~object.__getattribute__` machinery in this fashion " "provides significant scope for speed optimisations within the interpreter, " @@ -4737,15 +4962,15 @@ msgstr "" "から一貫して実行されるためにクラスオブジェクトに設定 *しなければならない*)、" "インタープリタを高速化するための大きな余地が手に入ります。" -#: ../../reference/datamodel.rst:3409 +#: ../../reference/datamodel.rst:3602 msgid "Coroutines" msgstr "コルーチン" -#: ../../reference/datamodel.rst:3413 +#: ../../reference/datamodel.rst:3606 msgid "Awaitable Objects" msgstr "待機可能オブジェクト (Awaitable Object)" -#: ../../reference/datamodel.rst:3415 +#: ../../reference/datamodel.rst:3608 msgid "" "An :term:`awaitable` object generally implements an :meth:`~object." "__await__` method. :term:`Coroutine objects ` returned from :" @@ -4755,7 +4980,7 @@ msgstr "" "が実装されています。 :keyword:`async def` 関数が返す :term:`Coroutineオブジェ" "クト ` は待機可能です。" -#: ../../reference/datamodel.rst:3421 +#: ../../reference/datamodel.rst:3614 msgid "" "The :term:`generator iterator` objects returned from generators decorated " "with :func:`types.coroutine` are also awaitable, but they do not implement :" @@ -4765,7 +4990,7 @@ msgstr "" "される :term:`generator iterator` オブジェクトも待機可能ですが、 :meth:" "`~object.__await__` は実装されていません。" -#: ../../reference/datamodel.rst:3427 +#: ../../reference/datamodel.rst:3620 msgid "" "Must return an :term:`iterator`. Should be used to implement :term:" "`awaitable` objects. For instance, :class:`asyncio.Future` implements this " @@ -4777,7 +5002,7 @@ msgstr "" "簡単のために、 :class:`asyncio.Future` にはこのメソッドが実装され、 :keyword:" "`await` 式と互換性を持つようになっています。" -#: ../../reference/datamodel.rst:3433 +#: ../../reference/datamodel.rst:3626 msgid "" "The language doesn't place any restriction on the type or value of the " "objects yielded by the iterator returned by ``__await__``, as this is " @@ -4785,16 +5010,16 @@ msgid "" "g. :mod:`asyncio`) that will be managing the :term:`awaitable` object." msgstr "" -#: ../../reference/datamodel.rst:3441 +#: ../../reference/datamodel.rst:3634 msgid ":pep:`492` for additional information about awaitable objects." msgstr "" "待機可能オブジェクトについてより詳しくは :pep:`492` を参照してください。" -#: ../../reference/datamodel.rst:3447 +#: ../../reference/datamodel.rst:3640 msgid "Coroutine Objects" msgstr "コルーチンオブジェクト" -#: ../../reference/datamodel.rst:3449 +#: ../../reference/datamodel.rst:3642 msgid "" ":term:`Coroutine objects ` are :term:`awaitable` objects. A " "coroutine's execution can be controlled by calling :meth:`~object.__await__` " @@ -4812,7 +5037,7 @@ msgstr "" "により伝搬されます。コルーチンから :exc:`StopIteration` 例外を外に送出すべき" "ではありません。" -#: ../../reference/datamodel.rst:3457 +#: ../../reference/datamodel.rst:3650 msgid "" "Coroutines also have the methods listed below, which are analogous to those " "of generators (see :ref:`generator-methods`). However, unlike generators, " @@ -4823,12 +5048,12 @@ msgstr "" "ただし、ジェネレータと違って、コルーチンは反復処理を直接はサポートしていませ" "ん。" -#: ../../reference/datamodel.rst:3461 +#: ../../reference/datamodel.rst:3654 msgid "It is a :exc:`RuntimeError` to await on a coroutine more than once." msgstr "" "コルーチンで2回以上待機 (await) すると :exc:`RuntimeError` となります。" -#: ../../reference/datamodel.rst:3467 +#: ../../reference/datamodel.rst:3660 msgid "" "Starts or resumes execution of the coroutine. If *value* is ``None``, this " "is equivalent to advancing the iterator returned by :meth:`~object." @@ -4839,7 +5064,7 @@ msgid "" "value, described above." msgstr "" -#: ../../reference/datamodel.rst:3478 +#: ../../reference/datamodel.rst:3671 msgid "" "Raises the specified exception in the coroutine. This method delegates to " "the :meth:`~generator.throw` method of the iterator that caused the " @@ -4857,13 +5082,13 @@ msgstr "" "meth:`~object.__await__` の返り値に対して反復処理を行ったときと同じです。\n" "例外がコルーチンの中で捕捉されなかった場合、呼び出し元へ伝搬されます。" -#: ../../reference/datamodel.rst:3489 +#: ../../reference/datamodel.rst:3682 msgid "" "The second signature \\(type\\[, value\\[, traceback\\]\\]\\) is deprecated " "and may be removed in a future version of Python." msgstr "" -#: ../../reference/datamodel.rst:3494 +#: ../../reference/datamodel.rst:3687 msgid "" "Causes the coroutine to clean itself up and exit. If the coroutine is " "suspended, this method first delegates to the :meth:`~generator.close` " @@ -4880,7 +5105,7 @@ msgstr "" "最後に、実行が開始されていなかった場合でも、コルーチンに実行が完了した印を付" "けます。" -#: ../../reference/datamodel.rst:3502 +#: ../../reference/datamodel.rst:3695 msgid "" "Coroutine objects are automatically closed using the above process when they " "are about to be destroyed." @@ -4888,27 +5113,27 @@ msgstr "" "コルーチンオブジェクトが破棄されるときには、上記の手順を経て自動的に閉じられ" "ます。" -#: ../../reference/datamodel.rst:3508 +#: ../../reference/datamodel.rst:3701 msgid "Asynchronous Iterators" msgstr "非同期イテレータ (Asynchronous Iterator)" -#: ../../reference/datamodel.rst:3510 +#: ../../reference/datamodel.rst:3703 msgid "" "An *asynchronous iterator* can call asynchronous code in its ``__anext__`` " "method." msgstr "" "*非同期イテレータ* の ``__anext__`` メソッドからは非同期のコードが呼べます。" -#: ../../reference/datamodel.rst:3513 +#: ../../reference/datamodel.rst:3706 msgid "" "Asynchronous iterators can be used in an :keyword:`async for` statement." msgstr "非同期イテレータは :keyword:`async for` 文の中で使えます。" -#: ../../reference/datamodel.rst:3517 +#: ../../reference/datamodel.rst:3710 msgid "Must return an *asynchronous iterator* object." msgstr "*非同期イテレータ* オブジェクトを返さなくてはなりません。" -#: ../../reference/datamodel.rst:3521 +#: ../../reference/datamodel.rst:3714 msgid "" "Must return an *awaitable* resulting in a next value of the iterator. " "Should raise a :exc:`StopAsyncIteration` error when the iteration is over." @@ -4916,11 +5141,11 @@ msgstr "" "イテレータの次の値を返す *待機可能オブジェクト* を返さなければなりません。\n" "反復処理が終了したときには :exc:`StopAsyncIteration` エラーを送出すべきです。" -#: ../../reference/datamodel.rst:3524 +#: ../../reference/datamodel.rst:3717 msgid "An example of an asynchronous iterable object::" msgstr "非同期イテラブルオブジェクトの例::" -#: ../../reference/datamodel.rst:3526 +#: ../../reference/datamodel.rst:3719 msgid "" "class Reader:\n" " async def readline(self):\n" @@ -4936,7 +5161,7 @@ msgid "" " return val" msgstr "" -#: ../../reference/datamodel.rst:3541 +#: ../../reference/datamodel.rst:3734 msgid "" "Prior to Python 3.7, :meth:`~object.__aiter__` could return an *awaitable* " "that would resolve to an :term:`asynchronous iterator ` になる *awaitable* を返せました。" -#: ../../reference/datamodel.rst:3546 +#: ../../reference/datamodel.rst:3739 msgid "" "Starting with Python 3.7, :meth:`~object.__aiter__` must return an " "asynchronous iterator object. Returning anything else will result in a :exc:" @@ -4955,11 +5180,11 @@ msgstr "" "を返さなければなりません。\n" "それ以外のものを返すと :exc:`TypeError` になります。" -#: ../../reference/datamodel.rst:3554 +#: ../../reference/datamodel.rst:3747 msgid "Asynchronous Context Managers" msgstr "非同期コンテキストマネージャ (Asynchronous Context Manager)" -#: ../../reference/datamodel.rst:3556 +#: ../../reference/datamodel.rst:3749 msgid "" "An *asynchronous context manager* is a *context manager* that is able to " "suspend execution in its ``__aenter__`` and ``__aexit__`` methods." @@ -4967,30 +5192,30 @@ msgstr "" "*非同期コンテキストマネージャ* は、 ``__aenter__`` メソッドと ``__aexit__`` " "メソッド内部で実行を一時停止できる *コンテキストマネージャ* です。" -#: ../../reference/datamodel.rst:3559 +#: ../../reference/datamodel.rst:3752 msgid "" "Asynchronous context managers can be used in an :keyword:`async with` " "statement." msgstr "" "非同期コンテキストマネージャは :keyword:`async with` 文の中で使えます。" -#: ../../reference/datamodel.rst:3563 +#: ../../reference/datamodel.rst:3756 msgid "" "Semantically similar to :meth:`~object.__enter__`, the only difference being " "that it must return an *awaitable*." msgstr "" -#: ../../reference/datamodel.rst:3568 +#: ../../reference/datamodel.rst:3761 msgid "" "Semantically similar to :meth:`~object.__exit__`, the only difference being " "that it must return an *awaitable*." msgstr "" -#: ../../reference/datamodel.rst:3571 +#: ../../reference/datamodel.rst:3764 msgid "An example of an asynchronous context manager class::" msgstr "非同期コンテキストマネージャクラスの例::" -#: ../../reference/datamodel.rst:3573 +#: ../../reference/datamodel.rst:3766 msgid "" "class AsyncContextManager:\n" " async def __aenter__(self):\n" @@ -5000,11 +5225,11 @@ msgid "" " await log('exiting context')" msgstr "" -#: ../../reference/datamodel.rst:3584 +#: ../../reference/datamodel.rst:3777 msgid "Footnotes" msgstr "脚注" -#: ../../reference/datamodel.rst:3585 +#: ../../reference/datamodel.rst:3778 msgid "" "It *is* possible in some cases to change an object's type, under certain " "controlled conditions. It generally isn't a good idea though, since it can " @@ -5014,7 +5239,7 @@ msgstr "" "* 。これは、正しく扱われなかった場合にとても奇妙な動作を引き起こすので、一般" "的には良い考えではありません。" -#: ../../reference/datamodel.rst:3589 +#: ../../reference/datamodel.rst:3782 msgid "" "The :meth:`~object.__hash__`, :meth:`~object.__iter__`, :meth:`~object." "__reversed__`, :meth:`~object.__contains__`, :meth:`~object." @@ -5023,7 +5248,7 @@ msgid "" "by relying on the behavior that ``None`` is not callable." msgstr "" -#: ../../reference/datamodel.rst:3596 +#: ../../reference/datamodel.rst:3789 msgid "" "\"Does not support\" here means that the class has no such method, or the " "method returns :data:`NotImplemented`. Do not set the method to ``None`` if " @@ -5031,7 +5256,7 @@ msgid "" "instead have the opposite effect of explicitly *blocking* such fallback." msgstr "" -#: ../../reference/datamodel.rst:3602 +#: ../../reference/datamodel.rst:3795 msgid "" "For operands of the same type, it is assumed that if the non-reflected " "method -- such as :meth:`~object.__add__` -- fails then the overall " @@ -5051,13 +5276,13 @@ msgstr "" #: ../../reference/datamodel.rst:427 ../../reference/datamodel.rst:447 #: ../../reference/datamodel.rst:455 ../../reference/datamodel.rst:466 #: ../../reference/datamodel.rst:483 ../../reference/datamodel.rst:519 -#: ../../reference/datamodel.rst:534 ../../reference/datamodel.rst:660 -#: ../../reference/datamodel.rst:798 ../../reference/datamodel.rst:822 -#: ../../reference/datamodel.rst:856 ../../reference/datamodel.rst:937 -#: ../../reference/datamodel.rst:1076 ../../reference/datamodel.rst:1103 -#: ../../reference/datamodel.rst:1175 ../../reference/datamodel.rst:1279 -#: ../../reference/datamodel.rst:1388 ../../reference/datamodel.rst:1498 -#: ../../reference/datamodel.rst:1912 ../../reference/datamodel.rst:2927 +#: ../../reference/datamodel.rst:534 ../../reference/datamodel.rst:661 +#: ../../reference/datamodel.rst:799 ../../reference/datamodel.rst:823 +#: ../../reference/datamodel.rst:859 ../../reference/datamodel.rst:1126 +#: ../../reference/datamodel.rst:1265 ../../reference/datamodel.rst:1292 +#: ../../reference/datamodel.rst:1364 ../../reference/datamodel.rst:1472 +#: ../../reference/datamodel.rst:1581 ../../reference/datamodel.rst:1691 +#: ../../reference/datamodel.rst:2105 ../../reference/datamodel.rst:3120 msgid "object" msgstr "object" @@ -5067,14 +5292,14 @@ msgstr "データ" #: ../../reference/datamodel.rst:23 ../../reference/datamodel.rst:296 #: ../../reference/datamodel.rst:343 ../../reference/datamodel.rst:427 -#: ../../reference/datamodel.rst:466 ../../reference/datamodel.rst:798 -#: ../../reference/datamodel.rst:1132 ../../reference/datamodel.rst:1581 -#: ../../reference/datamodel.rst:1823 ../../reference/datamodel.rst:1828 -#: ../../reference/datamodel.rst:1912 ../../reference/datamodel.rst:2468 -#: ../../reference/datamodel.rst:2897 ../../reference/datamodel.rst:3055 -#: ../../reference/datamodel.rst:3090 ../../reference/datamodel.rst:3104 -#: ../../reference/datamodel.rst:3153 ../../reference/datamodel.rst:3163 -#: ../../reference/datamodel.rst:3191 +#: ../../reference/datamodel.rst:466 ../../reference/datamodel.rst:799 +#: ../../reference/datamodel.rst:1321 ../../reference/datamodel.rst:1774 +#: ../../reference/datamodel.rst:2016 ../../reference/datamodel.rst:2021 +#: ../../reference/datamodel.rst:2105 ../../reference/datamodel.rst:2661 +#: ../../reference/datamodel.rst:3090 ../../reference/datamodel.rst:3248 +#: ../../reference/datamodel.rst:3283 ../../reference/datamodel.rst:3297 +#: ../../reference/datamodel.rst:3346 ../../reference/datamodel.rst:3356 +#: ../../reference/datamodel.rst:3384 msgid "built-in function" msgstr "組み込み関数" @@ -5083,7 +5308,7 @@ msgid "id" msgstr "id" #: ../../reference/datamodel.rst:23 ../../reference/datamodel.rst:126 -#: ../../reference/datamodel.rst:2468 +#: ../../reference/datamodel.rst:2661 msgid "type" msgstr "type" @@ -5119,7 +5344,7 @@ msgstr "参照カウント" msgid "unreachable object" msgstr "到達不能オブジェクト" -#: ../../reference/datamodel.rst:95 ../../reference/datamodel.rst:937 +#: ../../reference/datamodel.rst:95 ../../reference/datamodel.rst:1126 msgid "container" msgstr "コンテナ" @@ -5133,24 +5358,24 @@ msgstr "拡張" #: ../../reference/datamodel.rst:126 ../../reference/datamodel.rst:400 #: ../../reference/datamodel.rst:401 ../../reference/datamodel.rst:502 -#: ../../reference/datamodel.rst:856 ../../reference/datamodel.rst:876 -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:859 ../../reference/datamodel.rst:879 +#: ../../reference/datamodel.rst:1321 msgid "module" msgstr "module" #: ../../reference/datamodel.rst:126 ../../reference/datamodel.rst:265 -#: ../../reference/datamodel.rst:798 +#: ../../reference/datamodel.rst:799 msgid "C" msgstr "C" #: ../../reference/datamodel.rst:126 ../../reference/datamodel.rst:265 -#: ../../reference/datamodel.rst:798 +#: ../../reference/datamodel.rst:799 msgid "language" msgstr "言語" -#: ../../reference/datamodel.rst:139 ../../reference/datamodel.rst:937 -#: ../../reference/datamodel.rst:955 ../../reference/datamodel.rst:1076 -#: ../../reference/datamodel.rst:1096 +#: ../../reference/datamodel.rst:139 ../../reference/datamodel.rst:1126 +#: ../../reference/datamodel.rst:1144 ../../reference/datamodel.rst:1265 +#: ../../reference/datamodel.rst:1285 msgid "attribute" msgstr "属性" @@ -5170,7 +5395,7 @@ msgstr "..." msgid "ellipsis literal" msgstr "ellipsisリテラル" -#: ../../reference/datamodel.rst:196 ../../reference/datamodel.rst:1103 +#: ../../reference/datamodel.rst:196 ../../reference/datamodel.rst:1292 msgid "numeric" msgstr "数値" @@ -5207,16 +5432,16 @@ msgstr "number" msgid "Java" msgstr "Java" -#: ../../reference/datamodel.rst:283 ../../reference/datamodel.rst:3163 +#: ../../reference/datamodel.rst:283 ../../reference/datamodel.rst:3356 msgid "complex" msgstr "複素数" #: ../../reference/datamodel.rst:296 ../../reference/datamodel.rst:427 -#: ../../reference/datamodel.rst:466 ../../reference/datamodel.rst:2897 +#: ../../reference/datamodel.rst:466 ../../reference/datamodel.rst:3090 msgid "len" msgstr "len" -#: ../../reference/datamodel.rst:296 ../../reference/datamodel.rst:1103 +#: ../../reference/datamodel.rst:296 ../../reference/datamodel.rst:1292 msgid "sequence" msgstr "sequence" @@ -5245,8 +5470,8 @@ msgstr "変更不能なシーケンス" msgid "immutable" msgstr "immutable" -#: ../../reference/datamodel.rst:339 ../../reference/datamodel.rst:1798 -#: ../../reference/datamodel.rst:1828 +#: ../../reference/datamodel.rst:339 ../../reference/datamodel.rst:1991 +#: ../../reference/datamodel.rst:2021 msgid "string" msgstr "string" @@ -5282,7 +5507,7 @@ msgstr "単一要素の" msgid "empty" msgstr "空の" -#: ../../reference/datamodel.rst:376 ../../reference/datamodel.rst:1823 +#: ../../reference/datamodel.rst:376 ../../reference/datamodel.rst:2016 msgid "bytes" msgstr "bytes" @@ -5298,14 +5523,14 @@ msgstr "変更可能なシーケンス" msgid "mutable" msgstr "mutable" -#: ../../reference/datamodel.rst:388 ../../reference/datamodel.rst:955 -#: ../../reference/datamodel.rst:1096 +#: ../../reference/datamodel.rst:388 ../../reference/datamodel.rst:1144 +#: ../../reference/datamodel.rst:1285 msgid "assignment" msgstr "代入" -#: ../../reference/datamodel.rst:388 ../../reference/datamodel.rst:856 -#: ../../reference/datamodel.rst:1535 ../../reference/datamodel.rst:1717 -#: ../../reference/datamodel.rst:3218 +#: ../../reference/datamodel.rst:388 ../../reference/datamodel.rst:859 +#: ../../reference/datamodel.rst:1728 ../../reference/datamodel.rst:1910 +#: ../../reference/datamodel.rst:3411 msgid "statement" msgstr "statement" @@ -5337,12 +5562,12 @@ msgstr "集合" msgid "frozenset" msgstr "frozenset" -#: ../../reference/datamodel.rst:466 ../../reference/datamodel.rst:1103 +#: ../../reference/datamodel.rst:466 ../../reference/datamodel.rst:1292 msgid "mapping" msgstr "mapping" -#: ../../reference/datamodel.rst:483 ../../reference/datamodel.rst:937 -#: ../../reference/datamodel.rst:1912 +#: ../../reference/datamodel.rst:483 ../../reference/datamodel.rst:1126 +#: ../../reference/datamodel.rst:2105 msgid "dictionary" msgstr "dictionary" @@ -5359,13 +5584,13 @@ msgid "callable" msgstr "callable" #: ../../reference/datamodel.rst:519 ../../reference/datamodel.rst:534 -#: ../../reference/datamodel.rst:742 ../../reference/datamodel.rst:760 -#: ../../reference/datamodel.rst:773 ../../reference/datamodel.rst:798 +#: ../../reference/datamodel.rst:743 ../../reference/datamodel.rst:761 +#: ../../reference/datamodel.rst:774 ../../reference/datamodel.rst:799 msgid "function" msgstr "関数" -#: ../../reference/datamodel.rst:519 ../../reference/datamodel.rst:937 -#: ../../reference/datamodel.rst:960 ../../reference/datamodel.rst:2849 +#: ../../reference/datamodel.rst:519 ../../reference/datamodel.rst:1126 +#: ../../reference/datamodel.rst:1149 ../../reference/datamodel.rst:3042 msgid "call" msgstr "call" @@ -5377,7 +5602,7 @@ msgstr "関数呼び出し" msgid "argument" msgstr "引数 (argument)" -#: ../../reference/datamodel.rst:534 ../../reference/datamodel.rst:660 +#: ../../reference/datamodel.rst:534 ../../reference/datamodel.rst:661 msgid "user-defined" msgstr "ユーザ定義の" @@ -5397,607 +5622,627 @@ msgstr "__globals__ (関数属性)" msgid "global" msgstr "グローバル" -#: ../../reference/datamodel.rst:547 ../../reference/datamodel.rst:876 +#: ../../reference/datamodel.rst:547 ../../reference/datamodel.rst:879 msgid "namespace" msgstr "namespace" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__doc__ (function attribute)" msgstr "__doc__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__name__ (function attribute)" msgstr "__name__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__module__ (function attribute)" msgstr "__module__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__dict__ (function attribute)" msgstr "__dict__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__defaults__ (function attribute)" msgstr "__defaults__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__code__ (function attribute)" msgstr "__code__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__annotations__ (function attribute)" msgstr "__annotations__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__kwdefaults__ (function attribute)" msgstr "__kwdefaults__ (関数属性)" -#: ../../reference/datamodel.rst:573 +#: ../../reference/datamodel.rst:574 msgid "__type_params__ (function attribute)" msgstr "" -#: ../../reference/datamodel.rst:660 ../../reference/datamodel.rst:822 +#: ../../reference/datamodel.rst:661 ../../reference/datamodel.rst:823 msgid "method" msgstr "メソッド" -#: ../../reference/datamodel.rst:660 +#: ../../reference/datamodel.rst:661 msgid "user-defined method" msgstr "ユーザ定義メソッド" -#: ../../reference/datamodel.rst:668 +#: ../../reference/datamodel.rst:669 msgid "__func__ (method attribute)" msgstr "__func__ (メソッド属性)" -#: ../../reference/datamodel.rst:668 +#: ../../reference/datamodel.rst:669 msgid "__self__ (method attribute)" msgstr "__self__ (メソッド属性)" -#: ../../reference/datamodel.rst:668 +#: ../../reference/datamodel.rst:669 msgid "__doc__ (method attribute)" msgstr "__doc__ (メソッド属性)" -#: ../../reference/datamodel.rst:668 +#: ../../reference/datamodel.rst:669 msgid "__name__ (method attribute)" msgstr "__name__ (メソッド属性)" -#: ../../reference/datamodel.rst:668 +#: ../../reference/datamodel.rst:669 msgid "__module__ (method attribute)" msgstr "__module__ (メソッド属性)" -#: ../../reference/datamodel.rst:742 ../../reference/datamodel.rst:1279 +#: ../../reference/datamodel.rst:743 ../../reference/datamodel.rst:1472 msgid "generator" msgstr "ジェネレータ" -#: ../../reference/datamodel.rst:742 +#: ../../reference/datamodel.rst:743 msgid "iterator" msgstr "iterator" -#: ../../reference/datamodel.rst:760 ../../reference/datamodel.rst:3405 +#: ../../reference/datamodel.rst:761 ../../reference/datamodel.rst:3598 msgid "coroutine" msgstr "コルーチン" -#: ../../reference/datamodel.rst:773 +#: ../../reference/datamodel.rst:774 msgid "asynchronous generator" msgstr "asynchronous generator" -#: ../../reference/datamodel.rst:773 +#: ../../reference/datamodel.rst:774 msgid "asynchronous iterator" msgstr "asynchronous iterator" -#: ../../reference/datamodel.rst:822 +#: ../../reference/datamodel.rst:823 msgid "built-in method" msgstr "組み込みメソッド" -#: ../../reference/datamodel.rst:822 +#: ../../reference/datamodel.rst:823 msgid "built-in" msgstr "組み込み" -#: ../../reference/datamodel.rst:856 +#: ../../reference/datamodel.rst:859 msgid "import" msgstr "import" -#: ../../reference/datamodel.rst:876 +#: ../../reference/datamodel.rst:879 msgid "__name__ (module attribute)" msgstr "__name__ (モジュール属性)" -#: ../../reference/datamodel.rst:876 -msgid "__doc__ (module attribute)" -msgstr "__doc__ (モジュール属性)" +#: ../../reference/datamodel.rst:879 +msgid "__spec__ (module attribute)" +msgstr "" -#: ../../reference/datamodel.rst:876 +#: ../../reference/datamodel.rst:879 +msgid "__package__ (module attribute)" +msgstr "" + +#: ../../reference/datamodel.rst:879 +msgid "__loader__ (module attribute)" +msgstr "" + +#: ../../reference/datamodel.rst:879 +msgid "__path__ (module attribute)" +msgstr "" + +#: ../../reference/datamodel.rst:879 msgid "__file__ (module attribute)" msgstr "__file__ (モジュール属性)" -#: ../../reference/datamodel.rst:876 +#: ../../reference/datamodel.rst:879 +msgid "__cached__ (module attribute)" +msgstr "" + +#: ../../reference/datamodel.rst:879 +msgid "__doc__ (module attribute)" +msgstr "__doc__ (モジュール属性)" + +#: ../../reference/datamodel.rst:879 msgid "__annotations__ (module attribute)" msgstr "" -#: ../../reference/datamodel.rst:907 +#: ../../reference/datamodel.rst:1094 msgid "__dict__ (module attribute)" msgstr "__dict__ (モジュール属性)" -#: ../../reference/datamodel.rst:937 ../../reference/datamodel.rst:955 -#: ../../reference/datamodel.rst:1076 ../../reference/datamodel.rst:1700 -#: ../../reference/datamodel.rst:2579 +#: ../../reference/datamodel.rst:1126 ../../reference/datamodel.rst:1144 +#: ../../reference/datamodel.rst:1265 ../../reference/datamodel.rst:1893 +#: ../../reference/datamodel.rst:2772 msgid "class" msgstr "クラス" -#: ../../reference/datamodel.rst:937 ../../reference/datamodel.rst:1076 -#: ../../reference/datamodel.rst:1096 +#: ../../reference/datamodel.rst:1126 ../../reference/datamodel.rst:1265 +#: ../../reference/datamodel.rst:1285 msgid "class instance" msgstr "クラスインスタンス" -#: ../../reference/datamodel.rst:937 ../../reference/datamodel.rst:1076 -#: ../../reference/datamodel.rst:2849 +#: ../../reference/datamodel.rst:1126 ../../reference/datamodel.rst:1265 +#: ../../reference/datamodel.rst:3042 msgid "instance" msgstr "instance" -#: ../../reference/datamodel.rst:937 ../../reference/datamodel.rst:960 +#: ../../reference/datamodel.rst:1126 ../../reference/datamodel.rst:1149 msgid "class object" msgstr "クラスオブジェクト" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__name__ (class attribute)" msgstr "__name__ (クラス属性)" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__module__ (class attribute)" msgstr "__module__ (クラス属性)" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__dict__ (class attribute)" msgstr "__dict__ (クラス属性)" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__bases__ (class attribute)" msgstr "__bases__ (クラス属性)" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__doc__ (class attribute)" msgstr "__doc__ (クラス属性)" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__annotations__ (class attribute)" msgstr "" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__type_params__ (class attribute)" msgstr "" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__static_attributes__ (class attribute)" msgstr "" -#: ../../reference/datamodel.rst:967 +#: ../../reference/datamodel.rst:1156 msgid "__firstlineno__ (class attribute)" msgstr "" -#: ../../reference/datamodel.rst:1114 +#: ../../reference/datamodel.rst:1303 msgid "__dict__ (instance attribute)" msgstr "__dict__ (インスタンス属性)" -#: ../../reference/datamodel.rst:1114 +#: ../../reference/datamodel.rst:1303 msgid "__class__ (instance attribute)" msgstr "__class__ (インスタンス属性)" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "open" msgstr "open" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "io" msgstr "io" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "popen() (in module os)" msgstr "popen() (os モジュール)" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "makefile() (socket method)" msgstr "makefile() (socket のメソッド)" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "sys.stdin" msgstr "sys.stdin" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "sys.stdout" msgstr "sys.stdout" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "sys.stderr" msgstr "sys.stderr" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "stdio" msgstr "stdio" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "stdin (in module sys)" msgstr "stdin (sys モジュール)" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "stdout (in module sys)" msgstr "stdout (sys モジュール)" -#: ../../reference/datamodel.rst:1132 +#: ../../reference/datamodel.rst:1321 msgid "stderr (in module sys)" msgstr "stderr (sys モジュール)" -#: ../../reference/datamodel.rst:1161 +#: ../../reference/datamodel.rst:1350 msgid "internal type" msgstr "内部型" -#: ../../reference/datamodel.rst:1161 +#: ../../reference/datamodel.rst:1350 msgid "types, internal" msgstr "型, 内部の" -#: ../../reference/datamodel.rst:1175 +#: ../../reference/datamodel.rst:1364 msgid "bytecode" msgstr "bytecode" -#: ../../reference/datamodel.rst:1175 +#: ../../reference/datamodel.rst:1364 msgid "code" msgstr "コード" -#: ../../reference/datamodel.rst:1175 +#: ../../reference/datamodel.rst:1364 msgid "code object" msgstr "コードオブジェクト" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_argcount (code object attribute)" msgstr "co_argcount (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_posonlyargcount (code object attribute)" msgstr "" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_kwonlyargcount (code object attribute)" msgstr "" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_code (code object attribute)" msgstr "co_code (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_consts (code object attribute)" msgstr "co_consts (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_filename (code object attribute)" msgstr "co_filename (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_firstlineno (code object attribute)" msgstr "co_firstlineno (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_flags (code object attribute)" msgstr "co_flags (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_lnotab (code object attribute)" msgstr "co_lnotab (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_name (code object attribute)" msgstr "co_name (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_names (code object attribute)" msgstr "co_names (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_nlocals (code object attribute)" msgstr "co_nlocals (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_stacksize (code object attribute)" msgstr "co_stacksize (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_varnames (code object attribute)" msgstr "co_varnames (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_cellvars (code object attribute)" msgstr "co_cellvars (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_freevars (code object attribute)" msgstr "co_freevars (コードオブジェクトの属性)" -#: ../../reference/datamodel.rst:1186 +#: ../../reference/datamodel.rst:1375 msgid "co_qualname (code object attribute)" msgstr "" -#: ../../reference/datamodel.rst:1297 +#: ../../reference/datamodel.rst:1490 msgid "documentation string" msgstr "ドキュメント文字列" -#: ../../reference/datamodel.rst:1388 +#: ../../reference/datamodel.rst:1581 msgid "frame" msgstr "フレーム" -#: ../../reference/datamodel.rst:1394 +#: ../../reference/datamodel.rst:1587 msgid "f_back (frame attribute)" msgstr "f_back (フレーム属性)" -#: ../../reference/datamodel.rst:1394 +#: ../../reference/datamodel.rst:1587 msgid "f_code (frame attribute)" msgstr "f_code (フレーム属性)" -#: ../../reference/datamodel.rst:1394 +#: ../../reference/datamodel.rst:1587 msgid "f_globals (frame attribute)" msgstr "f_globals (フレーム属性)" -#: ../../reference/datamodel.rst:1394 +#: ../../reference/datamodel.rst:1587 msgid "f_locals (frame attribute)" msgstr "f_locals (フレーム属性)" -#: ../../reference/datamodel.rst:1394 +#: ../../reference/datamodel.rst:1587 msgid "f_lasti (frame attribute)" msgstr "f_lasti (フレーム属性)" -#: ../../reference/datamodel.rst:1394 +#: ../../reference/datamodel.rst:1587 msgid "f_builtins (frame attribute)" msgstr "f_builtins (フレーム属性)" -#: ../../reference/datamodel.rst:1438 +#: ../../reference/datamodel.rst:1631 msgid "f_trace (frame attribute)" msgstr "f_trace (フレーム属性)" -#: ../../reference/datamodel.rst:1438 +#: ../../reference/datamodel.rst:1631 msgid "f_trace_lines (frame attribute)" msgstr "" -#: ../../reference/datamodel.rst:1438 +#: ../../reference/datamodel.rst:1631 msgid "f_trace_opcodes (frame attribute)" msgstr "" -#: ../../reference/datamodel.rst:1438 +#: ../../reference/datamodel.rst:1631 msgid "f_lineno (frame attribute)" msgstr "f_lineno (フレーム属性)" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "traceback" msgstr "traceback" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "stack" msgstr "スタック" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "trace" msgstr "トレース" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "exception" msgstr "例外" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "handler" msgstr "ハンドラ" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "execution" msgstr "実行" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "exc_info (in module sys)" msgstr "exc_info (sys モジュール)" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "last_traceback (in module sys)" msgstr "last_traceback (sys モジュール)" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "sys.exc_info" msgstr "sys.exc_info" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "sys.exception" msgstr "" -#: ../../reference/datamodel.rst:1498 +#: ../../reference/datamodel.rst:1691 msgid "sys.last_traceback" msgstr "sys.last_traceback" -#: ../../reference/datamodel.rst:1535 +#: ../../reference/datamodel.rst:1728 msgid "tb_frame (traceback attribute)" msgstr "tb_frame (トレースバック属性)" -#: ../../reference/datamodel.rst:1535 +#: ../../reference/datamodel.rst:1728 msgid "tb_lineno (traceback attribute)" msgstr "tb_lineno (トレースバック属性)" -#: ../../reference/datamodel.rst:1535 +#: ../../reference/datamodel.rst:1728 msgid "tb_lasti (traceback attribute)" msgstr "tb_lasti (トレースバック属性)" -#: ../../reference/datamodel.rst:1535 +#: ../../reference/datamodel.rst:1728 msgid "try" msgstr "try" -#: ../../reference/datamodel.rst:1565 +#: ../../reference/datamodel.rst:1758 msgid "tb_next (traceback attribute)" msgstr "tb_next (トレースバック属性)" -#: ../../reference/datamodel.rst:1581 ../../reference/datamodel.rst:2927 +#: ../../reference/datamodel.rst:1774 ../../reference/datamodel.rst:3120 msgid "slice" msgstr "slice" -#: ../../reference/datamodel.rst:1587 +#: ../../reference/datamodel.rst:1780 msgid "start (slice object attribute)" msgstr "start (スライスオブジェクトの属性)" -#: ../../reference/datamodel.rst:1587 +#: ../../reference/datamodel.rst:1780 msgid "stop (slice object attribute)" msgstr "stop (スライスオブジェクトの属性)" -#: ../../reference/datamodel.rst:1587 +#: ../../reference/datamodel.rst:1780 msgid "step (slice object attribute)" msgstr "step (スライスオブジェクトの属性)" -#: ../../reference/datamodel.rst:1635 +#: ../../reference/datamodel.rst:1828 msgid "operator" msgstr "operator" -#: ../../reference/datamodel.rst:1635 +#: ../../reference/datamodel.rst:1828 msgid "overloading" msgstr "オーバーロード" -#: ../../reference/datamodel.rst:1635 +#: ../../reference/datamodel.rst:1828 msgid "__getitem__() (mapping object method)" msgstr "__getitem__() (マップオブジェクトのメソッド)" -#: ../../reference/datamodel.rst:1671 +#: ../../reference/datamodel.rst:1864 msgid "subclassing" msgstr "サブクラス化" -#: ../../reference/datamodel.rst:1671 +#: ../../reference/datamodel.rst:1864 msgid "immutable types" msgstr "変更不能な型" -#: ../../reference/datamodel.rst:1700 +#: ../../reference/datamodel.rst:1893 msgid "constructor" msgstr "コンストラクタ" -#: ../../reference/datamodel.rst:1717 +#: ../../reference/datamodel.rst:1910 msgid "destructor" msgstr "デストラクタ" -#: ../../reference/datamodel.rst:1717 +#: ../../reference/datamodel.rst:1910 msgid "finalizer" msgstr "" -#: ../../reference/datamodel.rst:1717 +#: ../../reference/datamodel.rst:1910 msgid "del" msgstr "del" -#: ../../reference/datamodel.rst:1781 +#: ../../reference/datamodel.rst:1974 msgid "repr() (built-in function)" msgstr "repr() (組み込み関数)" -#: ../../reference/datamodel.rst:1781 +#: ../../reference/datamodel.rst:1974 msgid "__repr__() (object method)" msgstr "__repr__() (オブジェクトメソッド)" -#: ../../reference/datamodel.rst:1798 +#: ../../reference/datamodel.rst:1991 msgid "__str__() (object method)" msgstr "__str__() (オブジェクトメソッド)" -#: ../../reference/datamodel.rst:1798 +#: ../../reference/datamodel.rst:1991 msgid "format() (built-in function)" msgstr "format() (組み込み関数)" -#: ../../reference/datamodel.rst:1798 +#: ../../reference/datamodel.rst:1991 msgid "print() (built-in function)" msgstr "print() (組み込み関数)" -#: ../../reference/datamodel.rst:1828 +#: ../../reference/datamodel.rst:2021 msgid "__format__() (object method)" msgstr "__format__() (オブジェクトメソッド)" -#: ../../reference/datamodel.rst:1828 +#: ../../reference/datamodel.rst:2021 msgid "conversion" msgstr "変換" -#: ../../reference/datamodel.rst:1828 +#: ../../reference/datamodel.rst:2021 msgid "print" msgstr "print" -#: ../../reference/datamodel.rst:1867 +#: ../../reference/datamodel.rst:2060 msgid "comparisons" msgstr "比較" -#: ../../reference/datamodel.rst:1912 +#: ../../reference/datamodel.rst:2105 msgid "hash" msgstr "hash" -#: ../../reference/datamodel.rst:1993 +#: ../../reference/datamodel.rst:2186 msgid "__len__() (mapping object method)" msgstr "__len__() (マップオブジェクトのメソッド)" -#: ../../reference/datamodel.rst:2097 +#: ../../reference/datamodel.rst:2290 msgid "__getattr__ (module attribute)" msgstr "" -#: ../../reference/datamodel.rst:2097 +#: ../../reference/datamodel.rst:2290 msgid "__dir__ (module attribute)" msgstr "" -#: ../../reference/datamodel.rst:2097 +#: ../../reference/datamodel.rst:2290 msgid "__class__ (module attribute)" msgstr "" -#: ../../reference/datamodel.rst:2468 +#: ../../reference/datamodel.rst:2661 msgid "metaclass" msgstr "metaclass" -#: ../../reference/datamodel.rst:2468 +#: ../../reference/datamodel.rst:2661 msgid "= (equals)" msgstr "= (等号)" -#: ../../reference/datamodel.rst:2468 +#: ../../reference/datamodel.rst:2661 msgid "class definition" msgstr "" -#: ../../reference/datamodel.rst:2532 +#: ../../reference/datamodel.rst:2725 msgid "metaclass hint" msgstr "" -#: ../../reference/datamodel.rst:2555 +#: ../../reference/datamodel.rst:2748 msgid "__prepare__ (metaclass method)" msgstr "" -#: ../../reference/datamodel.rst:2579 +#: ../../reference/datamodel.rst:2772 msgid "body" msgstr "" -#: ../../reference/datamodel.rst:2599 +#: ../../reference/datamodel.rst:2792 msgid "__class__ (method cell)" msgstr "" -#: ../../reference/datamodel.rst:2599 +#: ../../reference/datamodel.rst:2792 msgid "__classcell__ (class namespace entry)" msgstr "" -#: ../../reference/datamodel.rst:2897 +#: ../../reference/datamodel.rst:3090 msgid "__bool__() (object method)" msgstr "__bool__() (オブジェクトメソッド)" -#: ../../reference/datamodel.rst:3055 ../../reference/datamodel.rst:3090 +#: ../../reference/datamodel.rst:3248 ../../reference/datamodel.rst:3283 msgid "divmod" msgstr "divmod" -#: ../../reference/datamodel.rst:3055 ../../reference/datamodel.rst:3090 -#: ../../reference/datamodel.rst:3104 +#: ../../reference/datamodel.rst:3248 ../../reference/datamodel.rst:3283 +#: ../../reference/datamodel.rst:3297 msgid "pow" msgstr "pow" -#: ../../reference/datamodel.rst:3153 +#: ../../reference/datamodel.rst:3346 msgid "abs" msgstr "abs" -#: ../../reference/datamodel.rst:3163 +#: ../../reference/datamodel.rst:3356 msgid "int" msgstr "int" -#: ../../reference/datamodel.rst:3163 +#: ../../reference/datamodel.rst:3356 msgid "float" msgstr "浮動小数点数" -#: ../../reference/datamodel.rst:3191 +#: ../../reference/datamodel.rst:3384 msgid "round" msgstr "round" -#: ../../reference/datamodel.rst:3218 +#: ../../reference/datamodel.rst:3411 msgid "with" msgstr "with" -#: ../../reference/datamodel.rst:3218 +#: ../../reference/datamodel.rst:3411 msgid "context manager" msgstr "context manager" diff --git a/reference/executionmodel.po b/reference/executionmodel.po index 37e205d85..1b70e4cd7 100644 --- a/reference/executionmodel.po +++ b/reference/executionmodel.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:19+0000\n" "Last-Translator: tomo, 2023\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -169,17 +169,8 @@ msgid "" "declared as :keyword:`nonlocal` or :keyword:`global`. If a name is bound at " "the module level, it is a global variable. (The variables of the module " "code block are local and global.) If a variable is used in a code block but " -"not defined there, it is a :dfn:`free variable`." -msgstr "" -"ある名前がブロック内で束縛されているなら、 :keyword:`nonlocal` や :keyword:" -"`global` として宣言されていない限り、それはそのブロックのローカル変数 (local " -"variable) です。\n" -"ある名前がモジュールレベルで束縛されているなら、その名前はグローバル変数 " -"(global variable) です。 \n" -"(モジュールコードブロックの変数は、ローカル変数でも、グローバル変数でもありま" -"す。) \n" -"ある変数があるコードブロック内で使われていて、そのブロックで定義はされていな" -"いなら、それは自由変数 (:dfn:`free variable`) です。" +"not defined there, it is a :term:`free variable`." +msgstr "" #: ../../reference/executionmodel.rst:95 msgid "" @@ -558,11 +549,11 @@ msgstr "" "とローカル名前空間をオーバライドできます。名前空間が一つしか指定されなけれ" "ば、両方の名前空間として使われます。" -#: ../../reference/executionmodel.rst:337 +#: ../../reference/executionmodel.rst:340 msgid "Exceptions" msgstr "例外" -#: ../../reference/executionmodel.rst:348 +#: ../../reference/executionmodel.rst:351 msgid "" "Exceptions are a means of breaking out of the normal flow of control of a " "code block in order to handle errors or other exceptional conditions. An " @@ -576,7 +567,7 @@ msgstr "" "ラーが発生したコードブロック直接または間接的に呼び出しているコードブロックで " "*処理 (handle)* することができます。" -#: ../../reference/executionmodel.rst:354 +#: ../../reference/executionmodel.rst:357 msgid "" "The Python interpreter raises an exception when it detects a run-time error " "(such as division by zero). A Python program can also explicitly raise an " @@ -594,7 +585,7 @@ msgstr "" "きます。このコードは例外は処理しませんが、先行するコードブロックで例外が起き" "ても起きなくても実行されます。" -#: ../../reference/executionmodel.rst:364 +#: ../../reference/executionmodel.rst:367 msgid "" "Python uses the \"termination\" model of error handling: an exception " "handler can find out what happened and continue execution at an outer level, " @@ -607,7 +598,7 @@ msgstr "" "から実行しなおすのでない限り) エラーの原因を修復したり、実行に失敗した操作を" "やり直すことはできません。" -#: ../../reference/executionmodel.rst:371 +#: ../../reference/executionmodel.rst:374 msgid "" "When an exception is not handled at all, the interpreter terminates " "execution of the program, or returns to its interactive main loop. In " @@ -619,7 +610,7 @@ msgstr "" "どちらの場合も、例外が :exc:`SystemExit` でなければ、スタックのトレースバック" "を出力します。" -#: ../../reference/executionmodel.rst:375 +#: ../../reference/executionmodel.rst:378 msgid "" "Exceptions are identified by class instances. The :keyword:`except` clause " "is selected depending on the class of the instance: it must reference the " @@ -633,7 +624,7 @@ msgstr "" "はハンドラによって受け取られ、例外条件に関する追加情報を伝えることができま" "す。" -#: ../../reference/executionmodel.rst:383 +#: ../../reference/executionmodel.rst:386 msgid "" "Exception messages are not part of the Python API. Their contents may " "change from one version of Python to the next without warning and should not " @@ -645,7 +636,7 @@ msgstr "" "るので、複数バージョンのインタプリタで動作するようなコードは、例外メッセージ" "の内容に依存させるべきではありません。" -#: ../../reference/executionmodel.rst:387 +#: ../../reference/executionmodel.rst:390 msgid "" "See also the description of the :keyword:`try` statement in section :ref:" "`try` and :keyword:`raise` statement in section :ref:`raise`." @@ -653,11 +644,11 @@ msgstr "" ":keyword:`try` 文については、 :ref:`try` 節、 :keyword:`raise` 文については :" "ref:`raise` 節も参照してください。" -#: ../../reference/executionmodel.rst:392 +#: ../../reference/executionmodel.rst:395 msgid "Footnotes" msgstr "脚注" -#: ../../reference/executionmodel.rst:393 +#: ../../reference/executionmodel.rst:396 msgid "" "This limitation occurs because the code that is executed by these operations " "is not available at the time the module is compiled." @@ -741,34 +732,34 @@ msgstr "__main__" msgid "restricted" msgstr "制限" -#: ../../reference/executionmodel.rst:339 +#: ../../reference/executionmodel.rst:342 msgid "exception" msgstr "例外" -#: ../../reference/executionmodel.rst:341 +#: ../../reference/executionmodel.rst:344 msgid "raise an exception" msgstr "例外を送出する" -#: ../../reference/executionmodel.rst:341 +#: ../../reference/executionmodel.rst:344 msgid "handle an exception" msgstr "例外を扱う" -#: ../../reference/executionmodel.rst:341 +#: ../../reference/executionmodel.rst:344 msgid "exception handler" msgstr "例外ハンドラ" -#: ../../reference/executionmodel.rst:341 +#: ../../reference/executionmodel.rst:344 msgid "errors" msgstr "エラー" -#: ../../reference/executionmodel.rst:341 +#: ../../reference/executionmodel.rst:344 msgid "error handling" msgstr "エラー処理" -#: ../../reference/executionmodel.rst:362 +#: ../../reference/executionmodel.rst:365 msgid "termination model" msgstr "終了モデル" -#: ../../reference/executionmodel.rst:369 +#: ../../reference/executionmodel.rst:372 msgid "SystemExit (built-in exception)" msgstr "SystemExit (組み込み例外)" diff --git a/reference/expressions.po b/reference/expressions.po index 48cc0d108..df305b87f 100644 --- a/reference/expressions.po +++ b/reference/expressions.po @@ -23,7 +23,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:49+0000\n" "Last-Translator: Nozomu Kaneko , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -1612,7 +1612,7 @@ msgid "" "the same as if that method was called." msgstr "" -#: ../../reference/expressions.rst:1205 ../../reference/expressions.rst:2004 +#: ../../reference/expressions.rst:1205 ../../reference/expressions.rst:2006 msgid "Await expression" msgstr "Await 式" @@ -2502,11 +2502,11 @@ msgstr "" ":keyword:`not` は必ず新しい値を作成するので、引数の型に関係なくブール値を返し" "ます (例えば、 ``not 'foo'`` は ``''`` ではなく ``False`` になります)。" -#: ../../reference/expressions.rst:1813 +#: ../../reference/expressions.rst:1815 msgid "Assignment expressions" msgstr "代入式" -#: ../../reference/expressions.rst:1818 +#: ../../reference/expressions.rst:1820 msgid "" "An assignment expression (sometimes also called a \"named expression\" or " "\"walrus\") assigns an :token:`~python-grammar:expression` to an :token:" @@ -2514,27 +2514,27 @@ msgid "" "`~python-grammar:expression`." msgstr "" -#: ../../reference/expressions.rst:1823 +#: ../../reference/expressions.rst:1825 msgid "One common use case is when handling matched regular expressions:" msgstr "" -#: ../../reference/expressions.rst:1825 +#: ../../reference/expressions.rst:1827 msgid "" "if matching := pattern.search(data):\n" " do_something(matching)" msgstr "" -#: ../../reference/expressions.rst:1830 +#: ../../reference/expressions.rst:1832 msgid "Or, when processing a file stream in chunks:" msgstr "" -#: ../../reference/expressions.rst:1832 +#: ../../reference/expressions.rst:1834 msgid "" "while chunk := file.read(9000):\n" " process(chunk)" msgstr "" -#: ../../reference/expressions.rst:1837 +#: ../../reference/expressions.rst:1839 msgid "" "Assignment expressions must be surrounded by parentheses when used as " "expression statements and when used as sub-expressions in slicing, " @@ -2544,15 +2544,15 @@ msgid "" "and ``while`` statements." msgstr "" -#: ../../reference/expressions.rst:1845 +#: ../../reference/expressions.rst:1847 msgid "See :pep:`572` for more details about assignment expressions." msgstr "代入式に関してより詳しくは :pep:`572` を参照してください。" -#: ../../reference/expressions.rst:1852 +#: ../../reference/expressions.rst:1854 msgid "Conditional expressions" msgstr "条件式 (Conditional Expressions)" -#: ../../reference/expressions.rst:1864 +#: ../../reference/expressions.rst:1866 msgid "" "Conditional expressions (sometimes called a \"ternary operator\") have the " "lowest priority of all Python operations." @@ -2560,7 +2560,7 @@ msgstr "" "条件式 (しばしば \"三項演算子\" と呼ばれます) は最も優先度が低いPython の演算" "です。" -#: ../../reference/expressions.rst:1867 +#: ../../reference/expressions.rst:1869 msgid "" "The expression ``x if C else y`` first evaluates the condition, *C* rather " "than *x*. If *C* is true, *x* is evaluated and its value is returned; " @@ -2570,15 +2570,15 @@ msgstr "" "が true の場合 *x* が評価され値が返されます。 それ以外の場合には *y* が評価さ" "れ返されます。" -#: ../../reference/expressions.rst:1871 +#: ../../reference/expressions.rst:1873 msgid "See :pep:`308` for more details about conditional expressions." msgstr "条件演算に関してより詳しくは :pep:`308` を参照してください。" -#: ../../reference/expressions.rst:1878 +#: ../../reference/expressions.rst:1880 msgid "Lambdas" msgstr "ラムダ (lambda)" -#: ../../reference/expressions.rst:1889 +#: ../../reference/expressions.rst:1891 msgid "" "Lambda expressions (sometimes called lambda forms) are used to create " "anonymous functions. The expression ``lambda parameters: expression`` yields " @@ -2589,13 +2589,13 @@ msgstr "" "式 ``lambda parameters: expression`` は関数オブジェクトになります。\n" "この無名オブジェクトは以下に定義されている関数オブジェクト同様に動作します:" -#: ../../reference/expressions.rst:1893 +#: ../../reference/expressions.rst:1895 msgid "" "def (parameters):\n" " return expression" msgstr "" -#: ../../reference/expressions.rst:1898 +#: ../../reference/expressions.rst:1900 msgid "" "See section :ref:`function` for the syntax of parameter lists. Note that " "functions created with lambda expressions cannot contain statements or " @@ -2604,11 +2604,11 @@ msgstr "" "引数の一覧の構文は :ref:`関数定義 ` を参照してください。ラムダ式で" "作成された関数は文やアノテーションを含むことができない点に注意してください。" -#: ../../reference/expressions.rst:1906 +#: ../../reference/expressions.rst:1908 msgid "Expression lists" msgstr "式のリスト" -#: ../../reference/expressions.rst:1922 +#: ../../reference/expressions.rst:1924 msgid "" "Except when part of a list or set display, an expression list containing at " "least one comma yields a tuple. The length of the tuple is the number of " @@ -2619,7 +2619,7 @@ msgstr "" "タプルの長さは、リストにある式の数に等しくなります。\n" "式は左から右へ評価されます。" -#: ../../reference/expressions.rst:1931 +#: ../../reference/expressions.rst:1933 msgid "" "An asterisk ``*`` denotes :dfn:`iterable unpacking`. Its operand must be " "an :term:`iterable`. The iterable is expanded into a sequence of items, " @@ -2631,17 +2631,17 @@ msgstr "" "このイテラブルはアンパックされた位置で要素のシーケンスに展開され、新しいタプ" "ル、リスト、集合に入れ込まれます。" -#: ../../reference/expressions.rst:1936 +#: ../../reference/expressions.rst:1938 msgid "" "Iterable unpacking in expression lists, originally proposed by :pep:`448`." msgstr "" "式リストでのイテラブルのアンパックは最初に :pep:`448` で提案されました。" -#: ../../reference/expressions.rst:1939 +#: ../../reference/expressions.rst:1941 msgid "Any item in an expression list may be starred. See :pep:`646`." msgstr "" -#: ../../reference/expressions.rst:1944 +#: ../../reference/expressions.rst:1946 msgid "" "A trailing comma is required only to create a one-item tuple, such as ``1," "``; it is optional in all other cases. A single expression without a " @@ -2650,11 +2650,11 @@ msgid "" "``()``.)" msgstr "" -#: ../../reference/expressions.rst:1955 +#: ../../reference/expressions.rst:1957 msgid "Evaluation order" msgstr "評価順序" -#: ../../reference/expressions.rst:1959 +#: ../../reference/expressions.rst:1961 msgid "" "Python evaluates expressions from left to right. Notice that while " "evaluating an assignment, the right-hand side is evaluated before the left-" @@ -2663,14 +2663,14 @@ msgstr "" "Python は、式を左から右へと順に評価します。\n" "ただし、代入式を評価するときは、右辺が左辺よりも先に評価されます。" -#: ../../reference/expressions.rst:1962 +#: ../../reference/expressions.rst:1964 msgid "" "In the following lines, expressions will be evaluated in the arithmetic " "order of their suffixes::" msgstr "" "以下に示す実行文の各行での評価順序は、添え字の数字順序と同じになります::" -#: ../../reference/expressions.rst:1965 +#: ../../reference/expressions.rst:1967 msgid "" "expr1, expr2, expr3, expr4\n" "(expr1, expr2, expr3, expr4)\n" @@ -2680,11 +2680,11 @@ msgid "" "expr3, expr4 = expr1, expr2" msgstr "" -#: ../../reference/expressions.rst:1976 +#: ../../reference/expressions.rst:1978 msgid "Operator precedence" msgstr "演算子の優先順位" -#: ../../reference/expressions.rst:1981 +#: ../../reference/expressions.rst:1983 msgid "" "The following table summarizes the operator precedence in Python, from " "highest precedence (most binding) to lowest precedence (least binding). " @@ -2699,7 +2699,7 @@ msgstr "" "ものは二項演算子です。同じボックス内の演算子は、左から右へとグループ化されま" "す (例外として、べき乗および条件式は右から左にグループ化されます)。" -#: ../../reference/expressions.rst:1987 +#: ../../reference/expressions.rst:1989 msgid "" "Note that comparisons, membership tests, and identity tests, all have the " "same precedence and have a left-to-right chaining feature as described in " @@ -2709,107 +2709,107 @@ msgstr "" "が同じ優先順位を持っていて、左から右に連鎖するという特徴を持っていることに注" "意してください。" -#: ../../reference/expressions.rst:1993 +#: ../../reference/expressions.rst:1995 msgid "Operator" msgstr "演算子" -#: ../../reference/expressions.rst:1993 +#: ../../reference/expressions.rst:1995 msgid "Description" msgstr "説明" -#: ../../reference/expressions.rst:1995 +#: ../../reference/expressions.rst:1997 msgid "``(expressions...)``," msgstr "``(expressions...)``," -#: ../../reference/expressions.rst:1997 +#: ../../reference/expressions.rst:1999 msgid "``[expressions...]``, ``{key: value...}``, ``{expressions...}``" msgstr "``[expressions...]``, ``{key: value...}``, ``{expressions...}``" -#: ../../reference/expressions.rst:1995 +#: ../../reference/expressions.rst:1997 msgid "" "Binding or parenthesized expression, list display, dictionary display, set " "display" msgstr "結合式または括弧式、リスト表示、辞書表示、集合表示" -#: ../../reference/expressions.rst:2001 +#: ../../reference/expressions.rst:2003 msgid "``x[index]``, ``x[index:index]``, ``x(arguments...)``, ``x.attribute``" msgstr "``x[index]``, ``x[index:index]``, ``x(arguments...)``, ``x.attribute``" -#: ../../reference/expressions.rst:2001 +#: ../../reference/expressions.rst:2003 msgid "Subscription, slicing, call, attribute reference" msgstr "添字指定、スライス操作、呼び出し、属性参照" -#: ../../reference/expressions.rst:2004 +#: ../../reference/expressions.rst:2006 msgid ":keyword:`await x `" msgstr ":keyword:`await x `" -#: ../../reference/expressions.rst:2006 +#: ../../reference/expressions.rst:2008 msgid "``**``" msgstr "``**``" -#: ../../reference/expressions.rst:2006 +#: ../../reference/expressions.rst:2008 msgid "Exponentiation [#]_" msgstr "べき乗 [#]_" -#: ../../reference/expressions.rst:2008 +#: ../../reference/expressions.rst:2010 msgid "``+x``, ``-x``, ``~x``" msgstr "``+x``, ``-x``, ``~x``" -#: ../../reference/expressions.rst:2008 +#: ../../reference/expressions.rst:2010 msgid "Positive, negative, bitwise NOT" msgstr "正数、負数、ビット単位 NOT" -#: ../../reference/expressions.rst:2010 +#: ../../reference/expressions.rst:2012 msgid "``*``, ``@``, ``/``, ``//``, ``%``" msgstr "``*``, ``@``, ``/``, ``//``, ``%``" -#: ../../reference/expressions.rst:2010 +#: ../../reference/expressions.rst:2012 msgid "" "Multiplication, matrix multiplication, division, floor division, remainder " "[#]_" msgstr "乗算、行列乗算、除算、切り捨て除算、剰余 [#]_" -#: ../../reference/expressions.rst:2014 +#: ../../reference/expressions.rst:2016 msgid "``+``, ``-``" msgstr "``+``, ``-``" -#: ../../reference/expressions.rst:2014 +#: ../../reference/expressions.rst:2016 msgid "Addition and subtraction" msgstr "加算および減算" -#: ../../reference/expressions.rst:2016 +#: ../../reference/expressions.rst:2018 msgid "``<<``, ``>>``" msgstr "``<<``, ``>>``" -#: ../../reference/expressions.rst:2016 +#: ../../reference/expressions.rst:2018 msgid "Shifts" msgstr "シフト演算" -#: ../../reference/expressions.rst:2018 +#: ../../reference/expressions.rst:2020 msgid "``&``" msgstr "``&``" -#: ../../reference/expressions.rst:2018 +#: ../../reference/expressions.rst:2020 msgid "Bitwise AND" msgstr "ビット単位 AND" -#: ../../reference/expressions.rst:2020 +#: ../../reference/expressions.rst:2022 msgid "``^``" msgstr "``^``" -#: ../../reference/expressions.rst:2020 +#: ../../reference/expressions.rst:2022 msgid "Bitwise XOR" msgstr "ビット単位 XOR" -#: ../../reference/expressions.rst:2022 +#: ../../reference/expressions.rst:2024 msgid "``|``" msgstr "``|``" -#: ../../reference/expressions.rst:2022 +#: ../../reference/expressions.rst:2024 msgid "Bitwise OR" msgstr "ビット単位 OR" -#: ../../reference/expressions.rst:2024 +#: ../../reference/expressions.rst:2026 msgid "" ":keyword:`in`, :keyword:`not in`, :keyword:`is`, :keyword:`is not`, ``<``, " "``<=``, ``>``, ``>=``, ``!=``, ``==``" @@ -2817,63 +2817,63 @@ msgstr "" ":keyword:`in`, :keyword:`not in`, :keyword:`is`, :keyword:`is not`, ``<``, " "``<=``, ``>``, ``>=``, ``!=``, ``==``" -#: ../../reference/expressions.rst:2024 +#: ../../reference/expressions.rst:2026 msgid "Comparisons, including membership tests and identity tests" msgstr "所属や同一性のテストを含む比較" -#: ../../reference/expressions.rst:2028 +#: ../../reference/expressions.rst:2030 msgid ":keyword:`not x `" msgstr ":keyword:`not x `" -#: ../../reference/expressions.rst:2028 +#: ../../reference/expressions.rst:2030 msgid "Boolean NOT" msgstr "ブール演算 NOT" -#: ../../reference/expressions.rst:2030 +#: ../../reference/expressions.rst:2032 msgid ":keyword:`and`" msgstr ":keyword:`and`" -#: ../../reference/expressions.rst:2030 +#: ../../reference/expressions.rst:2032 msgid "Boolean AND" msgstr "ブール演算 AND" -#: ../../reference/expressions.rst:2032 +#: ../../reference/expressions.rst:2034 msgid ":keyword:`or`" msgstr ":keyword:`or`" -#: ../../reference/expressions.rst:2032 +#: ../../reference/expressions.rst:2034 msgid "Boolean OR" msgstr "ブール演算 OR" -#: ../../reference/expressions.rst:2034 +#: ../../reference/expressions.rst:2036 msgid ":keyword:`if ` -- :keyword:`!else`" msgstr ":keyword:`if ` -- :keyword:`!else`" -#: ../../reference/expressions.rst:2034 +#: ../../reference/expressions.rst:2036 msgid "Conditional expression" msgstr "条件式" -#: ../../reference/expressions.rst:2036 +#: ../../reference/expressions.rst:2038 msgid ":keyword:`lambda`" msgstr ":keyword:`lambda`" -#: ../../reference/expressions.rst:2036 +#: ../../reference/expressions.rst:2038 msgid "Lambda expression" msgstr "ラムダ式" -#: ../../reference/expressions.rst:2038 +#: ../../reference/expressions.rst:2040 msgid "``:=``" msgstr "``:=``" -#: ../../reference/expressions.rst:2038 +#: ../../reference/expressions.rst:2040 msgid "Assignment expression" msgstr "代入式" -#: ../../reference/expressions.rst:2043 +#: ../../reference/expressions.rst:2045 msgid "Footnotes" msgstr "脚注" -#: ../../reference/expressions.rst:2044 +#: ../../reference/expressions.rst:2046 msgid "" "While ``abs(x%y) < abs(y)`` is true mathematically, for floats it may not be " "true numerically due to roundoff. For example, and assuming a platform on " @@ -2893,7 +2893,7 @@ msgstr "" "うな値を返すので、上記の場合には ``-1e-100`` を返します。どちらのアプローチが" "適切かは、アプリケーションに依存します。" -#: ../../reference/expressions.rst:2053 +#: ../../reference/expressions.rst:2055 msgid "" "If x is very close to an exact integer multiple of y, it's possible for ``x//" "y`` to be one larger than ``(x-x%y)//y`` due to rounding. In such cases, " @@ -2905,7 +2905,7 @@ msgstr "" "``divmod(x,y)[0] * y + x % y`` が ``x`` に非常に近くなるという関係を保つため" "に、後者の値を返します。" -#: ../../reference/expressions.rst:2058 +#: ../../reference/expressions.rst:2060 msgid "" "The Unicode standard distinguishes between :dfn:`code points` (e.g. U+0041) " "and :dfn:`abstract characters` (e.g. \"LATIN CAPITAL LETTER A\"). While most " @@ -2930,7 +2930,7 @@ msgstr "" "character)` の後ろに、コード位置 U+0327 (COMBINING CEDILLA) にある :dfn:`結合" "文字 (combining character)` が続く列としても表現できます。" -#: ../../reference/expressions.rst:2069 +#: ../../reference/expressions.rst:2071 msgid "" "The comparison operators on strings compare at the level of Unicode code " "points. This may be counter-intuitive to humans. For example, ``\"\\u00C7\" " @@ -2943,7 +2943,7 @@ msgstr "" "字 \"LATIN CAPITAL LETTER C WITH CEDILLA\" を表現しているにもかかわらず、その" "結果は ``False`` となります。" -#: ../../reference/expressions.rst:2074 +#: ../../reference/expressions.rst:2076 msgid "" "To compare strings at the level of abstract characters (that is, in a way " "intuitive to humans), use :func:`unicodedata.normalize`." @@ -2951,7 +2951,7 @@ msgstr "" "抽象文字のレベルで (つまり、人間にとって直感的な方法で) 文字列を比較するに" "は :func:`unicodedata.normalize` を使ってください。" -#: ../../reference/expressions.rst:2077 +#: ../../reference/expressions.rst:2079 msgid "" "Due to automatic garbage-collection, free lists, and the dynamic nature of " "descriptors, you may notice seemingly unusual behaviour in certain uses of " @@ -2963,7 +2963,7 @@ msgstr "" "利用は、一見すると普通ではない振る舞いだと気付くかもしれません。詳細はそれぞ" "れのドキュメントを確認してください。" -#: ../../reference/expressions.rst:2082 +#: ../../reference/expressions.rst:2084 msgid "" "The power operator ``**`` binds less tightly than an arithmetic or bitwise " "unary operator on its right, that is, ``2**-1`` is ``0.5``." @@ -2972,7 +2972,7 @@ msgstr "" "弱い結合優先順位となります。\n" "つまり ``2**-1`` は ``0.5`` になります。" -#: ../../reference/expressions.rst:2085 +#: ../../reference/expressions.rst:2087 msgid "" "The ``%`` operator is also used for string formatting; the same precedence " "applies." @@ -2981,8 +2981,8 @@ msgstr "" #: ../../reference/expressions.rst:8 ../../reference/expressions.rst:393 #: ../../reference/expressions.rst:448 ../../reference/expressions.rst:1765 -#: ../../reference/expressions.rst:1805 ../../reference/expressions.rst:1854 -#: ../../reference/expressions.rst:1880 ../../reference/expressions.rst:1908 +#: ../../reference/expressions.rst:1805 ../../reference/expressions.rst:1856 +#: ../../reference/expressions.rst:1882 ../../reference/expressions.rst:1910 msgid "expression" msgstr "expression" @@ -3059,7 +3059,7 @@ msgstr "type" #: ../../reference/expressions.rst:957 ../../reference/expressions.rst:1001 #: ../../reference/expressions.rst:1149 ../../reference/expressions.rst:1162 #: ../../reference/expressions.rst:1176 ../../reference/expressions.rst:1183 -#: ../../reference/expressions.rst:1730 ../../reference/expressions.rst:1920 +#: ../../reference/expressions.rst:1730 ../../reference/expressions.rst:1922 msgid "object" msgstr "object" @@ -3081,18 +3081,18 @@ msgid "empty" msgstr "空の" #: ../../reference/expressions.rst:175 ../../reference/expressions.rst:880 -#: ../../reference/expressions.rst:957 ../../reference/expressions.rst:1920 +#: ../../reference/expressions.rst:957 ../../reference/expressions.rst:1922 msgid "tuple" msgstr "tuple" -#: ../../reference/expressions.rst:181 ../../reference/expressions.rst:1942 +#: ../../reference/expressions.rst:181 ../../reference/expressions.rst:1944 msgid "comma" msgstr "カンマ" #: ../../reference/expressions.rst:181 ../../reference/expressions.rst:275 #: ../../reference/expressions.rst:301 ../../reference/expressions.rst:329 #: ../../reference/expressions.rst:951 ../../reference/expressions.rst:1001 -#: ../../reference/expressions.rst:1908 +#: ../../reference/expressions.rst:1910 msgid ", (comma)" msgstr ", (comma)" @@ -3109,7 +3109,7 @@ msgstr "for" msgid "in comprehensions" msgstr "" -#: ../../reference/expressions.rst:206 ../../reference/expressions.rst:1854 +#: ../../reference/expressions.rst:206 ../../reference/expressions.rst:1856 msgid "if" msgstr "if" @@ -3123,7 +3123,7 @@ msgstr "" #: ../../reference/expressions.rst:275 ../../reference/expressions.rst:851 #: ../../reference/expressions.rst:880 ../../reference/expressions.rst:957 -#: ../../reference/expressions.rst:1908 +#: ../../reference/expressions.rst:1910 msgid "list" msgstr "list" @@ -3141,7 +3141,7 @@ msgid "list expression" msgstr "" #: ../../reference/expressions.rst:275 ../../reference/expressions.rst:301 -#: ../../reference/expressions.rst:1908 +#: ../../reference/expressions.rst:1910 msgid "expression list" msgstr "" @@ -3179,7 +3179,7 @@ msgid "dictionary expression" msgstr "" #: ../../reference/expressions.rst:329 ../../reference/expressions.rst:951 -#: ../../reference/expressions.rst:1880 +#: ../../reference/expressions.rst:1882 msgid ": (colon)" msgstr ": (コロン)" @@ -3192,7 +3192,7 @@ msgid "in dictionary displays" msgstr "" #: ../../reference/expressions.rst:355 ../../reference/expressions.rst:1084 -#: ../../reference/expressions.rst:1927 +#: ../../reference/expressions.rst:1929 msgid "unpacking" msgstr "" @@ -3227,7 +3227,7 @@ msgid "from" msgstr "from" #: ../../reference/expressions.rst:448 ../../reference/expressions.rst:1149 -#: ../../reference/expressions.rst:1162 ../../reference/expressions.rst:1880 +#: ../../reference/expressions.rst:1162 ../../reference/expressions.rst:1882 msgid "function" msgstr "関数" @@ -3369,7 +3369,7 @@ msgid "parameter" msgstr "parameter" #: ../../reference/expressions.rst:1084 ../../reference/expressions.rst:1318 -#: ../../reference/expressions.rst:1927 +#: ../../reference/expressions.rst:1929 msgid "* (asterisk)" msgstr "* (アスタリスク)" @@ -3433,7 +3433,7 @@ msgstr "演算" #: ../../reference/expressions.rst:1491 ../../reference/expressions.rst:1730 #: ../../reference/expressions.rst:1739 ../../reference/expressions.rst:1781 #: ../../reference/expressions.rst:1786 ../../reference/expressions.rst:1791 -#: ../../reference/expressions.rst:1854 ../../reference/expressions.rst:1978 +#: ../../reference/expressions.rst:1856 ../../reference/expressions.rst:1980 msgid "operator" msgstr "operator" @@ -3688,58 +3688,58 @@ msgstr "" msgid "assignment" msgstr "代入" -#: ../../reference/expressions.rst:1854 +#: ../../reference/expressions.rst:1856 msgid "conditional" msgstr "条件" -#: ../../reference/expressions.rst:1854 +#: ../../reference/expressions.rst:1856 msgid "ternary" msgstr "三項" -#: ../../reference/expressions.rst:1854 +#: ../../reference/expressions.rst:1856 msgid "conditional expression" msgstr "" -#: ../../reference/expressions.rst:1854 +#: ../../reference/expressions.rst:1856 msgid "else" msgstr "else" -#: ../../reference/expressions.rst:1880 +#: ../../reference/expressions.rst:1882 msgid "lambda" msgstr "lambda" -#: ../../reference/expressions.rst:1880 +#: ../../reference/expressions.rst:1882 msgid "form" msgstr "形式" -#: ../../reference/expressions.rst:1880 +#: ../../reference/expressions.rst:1882 msgid "anonymous" msgstr "無名" -#: ../../reference/expressions.rst:1880 +#: ../../reference/expressions.rst:1882 msgid "lambda expression" msgstr "" -#: ../../reference/expressions.rst:1927 +#: ../../reference/expressions.rst:1929 msgid "iterable" msgstr "iterable" -#: ../../reference/expressions.rst:1927 +#: ../../reference/expressions.rst:1929 msgid "in expression lists" msgstr "" -#: ../../reference/expressions.rst:1942 +#: ../../reference/expressions.rst:1944 msgid "trailing" msgstr "末尾の" -#: ../../reference/expressions.rst:1957 +#: ../../reference/expressions.rst:1959 msgid "evaluation" msgstr "評価" -#: ../../reference/expressions.rst:1957 +#: ../../reference/expressions.rst:1959 msgid "order" msgstr "順序" -#: ../../reference/expressions.rst:1978 +#: ../../reference/expressions.rst:1980 msgid "precedence" msgstr "優先順位" diff --git a/reference/import.po b/reference/import.po index 89e1d9367..d3d232845 100644 --- a/reference/import.po +++ b/reference/import.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:49+0000\n" "Last-Translator: tomo, 2023\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -982,11 +982,11 @@ msgstr "" "foo']`` が存在する場合、後者が前者の ``foo`` 属性として存在しなければならない" "ということです。" -#: ../../reference/import.rst:517 -msgid "Module spec" -msgstr "モジュール仕様" - #: ../../reference/import.rst:519 +msgid "Module specs" +msgstr "" + +#: ../../reference/import.rst:521 msgid "" "The import machinery uses a variety of information about each module during " "import, especially before loading. Most of the information is common to all " @@ -998,7 +998,7 @@ msgstr "" "モジュール仕様の目的は、このインポート関連の情報をモジュールの単位でカプセル" "化することです。" -#: ../../reference/import.rst:524 +#: ../../reference/import.rst:526 msgid "" "Using a spec during import allows state to be transferred between import " "system components, e.g. between the finder that creates the module spec and " @@ -1012,269 +1012,63 @@ msgstr "" "がロードの定型的な作業を実行できるようになるということです。これに対して、モ" "ジュール仕様なしではローダがその責任を担っていました。" -#: ../../reference/import.rst:530 -msgid "" -"The module's spec is exposed as the ``__spec__`` attribute on a module " -"object. See :class:`~importlib.machinery.ModuleSpec` for details on the " -"contents of the module spec." -msgstr "" -"モジュール仕様は、モジュールオブジェクトの ``__spec__`` 属性として公開されま" -"す。\n" -"モジュール仕様の内容の詳細については :class:`~importlib.machinery." -"ModuleSpec` を参照してください。" - -#: ../../reference/import.rst:539 -msgid "Import-related module attributes" -msgstr "インポート関連のモジュール属性" - -#: ../../reference/import.rst:541 -msgid "" -"The import machinery fills in these attributes on each module object during " -"loading, based on the module's spec, before the loader executes the module." -msgstr "" -"インポート機構はロードの間、モジュールの仕様に基づいて、ローダーがモジュール" -"が実行する前に以下の属性を書き込みます。" - -#: ../../reference/import.rst:545 -msgid "" -"It is **strongly** recommended that you rely on :attr:`__spec__` and its " -"attributes instead of any of the other individual attributes listed below." -msgstr "" - -#: ../../reference/import.rst:551 -msgid "" -"The ``__name__`` attribute must be set to the fully qualified name of the " -"module. This name is used to uniquely identify the module in the import " -"system." -msgstr "" -"``__name__`` 属性はモジュールの完全修飾名に設定されなければなりません。この名" -"前を利用してインポートシステムでモジュールを一意に識別します。" - -#: ../../reference/import.rst:557 -msgid "" -"The ``__loader__`` attribute must be set to the loader object that the " -"import machinery used when loading the module. This is mostly for " -"introspection, but can be used for additional loader-specific functionality, " -"for example getting data associated with a loader." -msgstr "" -"``__loader__`` 属性はモジュールロード時にインポート機構が使用したローダーオブ" -"ジェクトに設定されなければなりません。この属性は普通は内省用のものですが、" -"ローダー固有の追加機能のために用いることが出来ます。例えばローダー関連のデー" -"タの取得です。" - -#: ../../reference/import.rst:562 ../../reference/import.rst:583 -msgid "" -"It is **strongly** recommended that you rely on :attr:`__spec__` instead of " -"this attribute." -msgstr "" - -#: ../../reference/import.rst:565 -msgid "" -"The value of ``__loader__`` is expected to be the same as ``__spec__." -"loader``. The use of ``__loader__`` is deprecated and slated for removal in " -"Python 3.14." -msgstr "" - -#: ../../reference/import.rst:572 -msgid "" -"The module's ``__package__`` attribute may be set. Its value must be a " -"string, but it can be the same value as its ``__name__``. When the module " -"is a package, its ``__package__`` value should be set to its ``__name__``. " -"When the module is not a package, ``__package__`` should be set to the empty " -"string for top-level modules, or for submodules, to the parent package's " -"name. See :pep:`366` for further details." -msgstr "" - -#: ../../reference/import.rst:580 -msgid "" -"This attribute is used instead of ``__name__`` to calculate explicit " -"relative imports for main modules, as defined in :pep:`366`." -msgstr "" -"この属性は :pep:`366` で定義されているように、メインモジュールからの明示的な" -"相対インポートを計算するために、 ``__name__`` の代わりに使用されます。" - -#: ../../reference/import.rst:586 -msgid "" -"The value of ``__package__`` is expected to be the same as ``__spec__." -"parent``." -msgstr "" -"``__package__`` の値が ``__spec__.parent`` と同じ値を持つことを要求されるよう" -"になりました。" - -#: ../../reference/import.rst:590 -msgid "" -":exc:`ImportWarning` is raised if import falls back to ``__package__`` " -"instead of :attr:`~importlib.machinery.ModuleSpec.parent`." -msgstr "" - -#: ../../reference/import.rst:595 -msgid "" -"Raise :exc:`DeprecationWarning` instead of :exc:`ImportWarning` when falling " -"back to ``__package__``." -msgstr "" - -#: ../../reference/import.rst:599 -msgid "" -"``__package__`` will cease to be set or taken into consideration by the " -"import system or standard library." -msgstr "" - -#: ../../reference/import.rst:606 -msgid "" -"The ``__spec__`` attribute must be set to the module spec that was used when " -"importing the module. Setting ``__spec__`` appropriately applies equally to :" -"ref:`modules initialized during interpreter startup `. The one " -"exception is ``__main__``, where ``__spec__`` is :ref:`set to None in some " -"cases `." -msgstr "" -"``__spec__`` 属性はモジュールロード時に使用されたモジュールスペックに設定され" -"なければなりません。\n" -"``__spec__`` を適切に設定すると :ref:`インタープリタ起動中に初期化されるモ" -"ジュール ` にも同様に適用されます。\n" -"例外は ``__main__`` で、``__spec__`` は :ref:`場合によっては None に設定され" -"ます `。" - -#: ../../reference/import.rst:612 -msgid "" -"When ``__spec__.parent`` is not set, ``__package__`` is used as a fallback." -msgstr "" - -#: ../../reference/import.rst:617 -msgid "" -"``__spec__.parent`` is used as a fallback when ``__package__`` is not " -"defined." -msgstr "" -"``__package__`` が定義されていないときに ``__spec__.parent`` がフォールバック" -"として使われるようになりました。" - -#: ../../reference/import.rst:623 +#: ../../reference/import.rst:532 msgid "" -"If the module is a package (either regular or namespace), the module " -"object's ``__path__`` attribute must be set. The value must be iterable, " -"but may be empty if ``__path__`` has no further significance. If " -"``__path__`` is not empty, it must produce strings when iterated over. More " -"details on the semantics of ``__path__`` are given :ref:`below `." +"The module's spec is exposed as :attr:`module.__spec__`. Setting :attr:`!" +"__spec__` appropriately applies equally to :ref:`modules initialized during " +"interpreter startup `. The one exception is ``__main__``, where :" +"attr:`!__spec__` is :ref:`set to None in some cases `." msgstr "" -"モジュールが (通常のまたは名前空間) パッケージの場合、モジュールオブジェクト" -"の ``__path__`` 属性が設定される必要があります。値はイテレート可能でなければ" -"なりませんが、``__path__`` に意味がない場合は空でも構いません。``__path__`` " -"が空でない場合、イテレート時に文字列を生成しなければなりません。``__path__`` " -"のセマンティクスの詳細は :ref:`下記 ` の通りです。" -#: ../../reference/import.rst:630 -msgid "Non-package modules should not have a ``__path__`` attribute." -msgstr "パッケージでないモジュールは ``__path__`` 属性を持ってはいけません。" - -#: ../../reference/import.rst:635 +#: ../../reference/import.rst:538 msgid "" -"``__file__`` is optional (if set, value must be a string). It indicates the " -"pathname of the file from which the module was loaded (if loaded from a " -"file), or the pathname of the shared library file for extension modules " -"loaded dynamically from a shared library. It might be missing for certain " -"types of modules, such as C modules that are statically linked into the " -"interpreter, and the import system may opt to leave it unset if it has no " -"semantic meaning (e.g. a module loaded from a database)." +"See :class:`~importlib.machinery.ModuleSpec` for details on the contents of " +"the module spec." msgstr "" -#: ../../reference/import.rst:644 -msgid "" -"If ``__file__`` is set then the ``__cached__`` attribute might also be set, " -"which is the path to any compiled version of the code (e.g. byte-compiled " -"file). The file does not need to exist to set this attribute; the path can " -"simply point to where the compiled file would exist (see :pep:`3147`)." +#: ../../reference/import.rst:546 +msgid "__path__ attributes on modules" msgstr "" -"もし ``__file__`` を設定するなら、 ``__cached__`` 属性もコードのコンパイルさ" -"れたバージョンのどれか (例えば、バイトコンパイルされたファイル) へのパスに設" -"定できます。この属性を設定するにあたってファイルが存在する必要はありません; " -"パスは、単にコンパイルされたファイルが存在するかもしれない場所を示しているだ" -"けです (:pep:`3147` を参照)。" -#: ../../reference/import.rst:650 +#: ../../reference/import.rst:548 msgid "" -"Note that ``__cached__`` may be set even if ``__file__`` is not set. " -"However, that scenario is quite atypical. Ultimately, the loader is what " -"makes use of the module spec provided by the finder (from which ``__file__`` " -"and ``__cached__`` are derived). So if a loader can load from a cached " -"module but otherwise does not load from a file, that atypical scenario may " -"be appropriate." +"The :attr:`~module.__path__` attribute should be a (possibly empty) :term:" +"`sequence` of strings enumerating the locations where the package's " +"submodules will be found. By definition, if a module has a :attr:`!__path__` " +"attribute, it is a :term:`package`." msgstr "" -"``__file__`` が設定されていないときにも ``__cached__`` は設定できることに注意" -"してください。ただし、そのシナリオはかなり変則的です。究極的には、ローダーと" -"は (``__file__`` と ``__cached__`` の由来である) ファインダーが提供するモ" -"ジュール仕様を利用するものです。したがって、もしローダーがキャッシュされたモ" -"ジュールからロードする一方でファイルからはロードしないなら、その変則的なシナ" -"リオは適切でしょう。" -#: ../../reference/import.rst:657 +#: ../../reference/import.rst:553 msgid "" -"It is **strongly** recommended that you rely on :attr:`__spec__` instead of " -"``__cached__``." +"A package's :attr:`~module.__path__` attribute is used during imports of its " +"subpackages. Within the import machinery, it functions much the same as :" +"data:`sys.path`, i.e. providing a list of locations to search for modules " +"during import. However, :attr:`!__path__` is typically much more constrained " +"than :data:`!sys.path`." msgstr "" -#: ../../reference/import.rst:660 +#: ../../reference/import.rst:560 msgid "" -"``__cached__`` will cease to be set or taken into consideration by the " -"import system or standard library." +"The same rules used for :data:`sys.path` also apply to a package's :attr:`!" +"__path__`. :data:`sys.path_hooks` (described below) are consulted when " +"traversing a package's :attr:`!__path__`." msgstr "" -#: ../../reference/import.rst:667 -msgid "module.__path__" -msgstr "module.__path__" - -#: ../../reference/import.rst:669 +#: ../../reference/import.rst:564 msgid "" -"By definition, if a module has a ``__path__`` attribute, it is a package." +"A package's ``__init__.py`` file may set or alter the package's :attr:" +"`~module.__path__` attribute, and this was typically the way namespace " +"packages were implemented prior to :pep:`420`. With the adoption of :pep:" +"`420`, namespace packages no longer need to supply ``__init__.py`` files " +"containing only :attr:`!__path__` manipulation code; the import machinery " +"automatically sets :attr:`!__path__` correctly for the namespace package." msgstr "" -"定義より、モジュールに ``__path__`` 属性があれば、そのモジュールはパッケージ" -"となります。" -#: ../../reference/import.rst:671 -msgid "" -"A package's ``__path__`` attribute is used during imports of its " -"subpackages. Within the import machinery, it functions much the same as :" -"data:`sys.path`, i.e. providing a list of locations to search for modules " -"during import. However, ``__path__`` is typically much more constrained " -"than :data:`sys.path`." -msgstr "" -"パッケージの ``__path__`` 属性は、そのサブパッケージのインポート中に使われま" -"す。インポート機構の内部では、それは :data:`sys.path` とほとんど同じように機" -"能します。つまり、インポート中にモジュールを探す場所のリストを提供します。し" -"かし、一般的に ``__path__`` は :data:`sys.path` よりも制約が強いです。" - -#: ../../reference/import.rst:677 -msgid "" -"``__path__`` must be an iterable of strings, but it may be empty. The same " -"rules used for :data:`sys.path` also apply to a package's ``__path__``, and :" -"data:`sys.path_hooks` (described below) are consulted when traversing a " -"package's ``__path__``." -msgstr "" -"``__path__`` は文字列の iterable でなければいけませんが、空でも構いません。 :" -"data:`sys.path` と同じ規則がパッケージの ``__path__`` にも適用され、パッケー" -"ジの ``__path__`` を走査するときに (後で解説する) :data:`sys.path_hooks` が考" -"慮に入れられます。" - -#: ../../reference/import.rst:682 -msgid "" -"A package's ``__init__.py`` file may set or alter the package's ``__path__`` " -"attribute, and this was typically the way namespace packages were " -"implemented prior to :pep:`420`. With the adoption of :pep:`420`, namespace " -"packages no longer need to supply ``__init__.py`` files containing only " -"``__path__`` manipulation code; the import machinery automatically sets " -"``__path__`` correctly for the namespace package." -msgstr "" -"パッケージの ``__init__.py`` ファイルは、パッケージの ``__path__`` 属性を設定" -"もしくは変更することがあり、これが :pep:`420` 以前の名前空間パッケージの典型" -"的な実装方法でした。 :pep:`420` の採択により、もはや名前空間パッケージは、 " -"``__path__`` を操作するコードだけを含む ``__init__.py`` ファイルを提供する必" -"要がなくなりました;インポート機構は、名前空間パッケージに対し自動的に適切な " -"``__path__`` をセットします。" - -#: ../../reference/import.rst:690 +#: ../../reference/import.rst:573 msgid "Module reprs" msgstr "モジュールの repr" -#: ../../reference/import.rst:692 +#: ../../reference/import.rst:575 msgid "" "By default, all modules have a usable repr, however depending on the " "attributes set above, and in the module's spec, you can more explicitly " @@ -1284,7 +1078,7 @@ msgstr "" "れは、これまでに説明した属性の設定内容に依存しており、モジュール仕様によって" "モジュールオブジェクトの repr をより明示的に制御することができます。" -#: ../../reference/import.rst:696 +#: ../../reference/import.rst:579 msgid "" "If the module has a spec (``__spec__``), the import machinery will try to " "generate a repr from it. If that fails or there is no spec, the import " @@ -1300,11 +1094,11 @@ msgstr "" "__loader__`` を (足りない情報についてはデフォルト値を使って補いながら) repr " "への入力として使おうと試みます。" -#: ../../reference/import.rst:703 +#: ../../reference/import.rst:586 msgid "Here are the exact rules used:" msgstr "これが使われている正確な規則です:" -#: ../../reference/import.rst:705 +#: ../../reference/import.rst:588 msgid "" "If the module has a ``__spec__`` attribute, the information in the spec is " "used to generate the repr. The \"name\", \"loader\", \"origin\", and " @@ -1314,7 +1108,7 @@ msgstr "" "成するために使われます。 \"name\", \"loader\", \"origin\", \"has_location\" " "属性が参照されます。" -#: ../../reference/import.rst:709 +#: ../../reference/import.rst:592 msgid "" "If the module has a ``__file__`` attribute, this is used as part of the " "module's repr." @@ -1322,7 +1116,7 @@ msgstr "" "モジュールに ``__file__`` 属性がある場合は、モジュールの repr の一部として使" "われます。" -#: ../../reference/import.rst:712 +#: ../../reference/import.rst:595 msgid "" "If the module has no ``__file__`` but does have a ``__loader__`` that is not " "``None``, then the loader's repr is used as part of the module's repr." @@ -1330,22 +1124,22 @@ msgstr "" "モジュールに ``__file__`` はないが ``__loader__`` があり、その値が ``None`` " "ではない場合は、ローダーの repr がモジュールの repr の一部として使われます。" -#: ../../reference/import.rst:715 +#: ../../reference/import.rst:598 msgid "Otherwise, just use the module's ``__name__`` in the repr." msgstr "そうでなければ、単にモジュールの ``__name__`` を repr の中で使います。" -#: ../../reference/import.rst:717 +#: ../../reference/import.rst:600 msgid "" "Use of :meth:`!module_repr`, having been deprecated since Python 3.4, was " "removed in Python 3.12 and is no longer called during the resolution of a " "module's repr." msgstr "" -#: ../../reference/import.rst:725 +#: ../../reference/import.rst:608 msgid "Cached bytecode invalidation" msgstr "キャッシュされたバイトコードの無効化" -#: ../../reference/import.rst:727 +#: ../../reference/import.rst:610 msgid "" "Before Python loads cached bytecode from a ``.pyc`` file, it checks whether " "the cache is up-to-date with the source ``.py`` file. By default, Python " @@ -1355,7 +1149,7 @@ msgid "" "source's metadata." msgstr "" -#: ../../reference/import.rst:734 +#: ../../reference/import.rst:617 msgid "" "Python also supports \"hash-based\" cache files, which store a hash of the " "source file's contents rather than its metadata. There are two variants of " @@ -1369,17 +1163,17 @@ msgid "" "option:`--check-hash-based-pycs` flag." msgstr "" -#: ../../reference/import.rst:745 +#: ../../reference/import.rst:628 msgid "" "Added hash-based ``.pyc`` files. Previously, Python only supported timestamp-" "based invalidation of bytecode caches." msgstr "" -#: ../../reference/import.rst:751 +#: ../../reference/import.rst:634 msgid "The Path Based Finder" msgstr "パスベース・ファインダー" -#: ../../reference/import.rst:756 +#: ../../reference/import.rst:639 msgid "" "As mentioned previously, Python comes with several default meta path " "finders. One of these, called the :term:`path based finder` (:class:" @@ -1393,7 +1187,7 @@ msgstr "" "ントリ ` のリストである :term:`インポートパス ` を検" "索します。それぞれのパスエントリは、モジュールを探す場所を指しています。" -#: ../../reference/import.rst:762 +#: ../../reference/import.rst:645 msgid "" "The path based finder itself doesn't know how to import anything. Instead, " "it traverses the individual path entries, associating each of them with a " @@ -1403,7 +1197,7 @@ msgstr "" "せん。その代わりに、個々のパスエントリを走査し、それぞれに特定の種類のパスの" "扱いを知っているパスエントリ・ファインダーを関連付けます。" -#: ../../reference/import.rst:766 +#: ../../reference/import.rst:649 msgid "" "The default set of path entry finders implement all the semantics for " "finding modules on the file system, handling special file types such as " @@ -1421,7 +1215,7 @@ msgstr "" "トのパスエントリ・ファインダーは (共有ライブラリ以外の) すべてのファイルタイ" "プの zip ファイルからのロードも扱います。" -#: ../../reference/import.rst:773 +#: ../../reference/import.rst:656 msgid "" "Path entries need not be limited to file system locations. They can refer " "to URLs, database queries, or any other location that can be specified as a " @@ -1430,7 +1224,7 @@ msgstr "" "パスエントリはファイルシステム上の場所に限定される必要はありません。URL や" "データベースクエリやその他文字列で指定できる場所を参照することも可能です。" -#: ../../reference/import.rst:777 +#: ../../reference/import.rst:660 msgid "" "The path based finder provides additional hooks and protocols so that you " "can extend and customize the types of searchable path entries. For example, " @@ -1449,7 +1243,7 @@ msgstr "" "します。このプロトコルは web からモジュールのローダーを取得するのに使われま" "す。" -#: ../../reference/import.rst:785 +#: ../../reference/import.rst:668 msgid "" "A word of warning: this section and the previous both use the term *finder*, " "distinguishing between them by using the terms :term:`meta path finder` and :" @@ -1467,7 +1261,7 @@ msgstr "" "に、メタパス・ファインダーはインポート処理の開始時、 :data:`sys.meta_path` の" "走査が動くときに動作します。" -#: ../../reference/import.rst:793 +#: ../../reference/import.rst:676 msgid "" "By contrast, path entry finders are in a sense an implementation detail of " "the path based finder, and in fact, if the path based finder were to be " @@ -1479,11 +1273,11 @@ msgstr "" "が取り除かれた場合、パスエントリ・ファインダーの実装は何も実行されないでしょ" "う。" -#: ../../reference/import.rst:800 +#: ../../reference/import.rst:683 msgid "Path entry finders" msgstr "パスエントリ・ファインダー" -#: ../../reference/import.rst:808 +#: ../../reference/import.rst:691 msgid "" "The :term:`path based finder` is responsible for finding and loading Python " "modules and packages whose location is specified with a string :term:`path " @@ -1495,7 +1289,7 @@ msgstr "" "ジを見つけ、ロードする責任があります。ほとんどのパスエントリはファイルシステ" "ム上の場所を指定していますが、そこに制限される必要はありません。" -#: ../../reference/import.rst:813 +#: ../../reference/import.rst:696 msgid "" "As a meta path finder, the :term:`path based finder` implements the :meth:" "`~importlib.abc.MetaPathFinder.find_spec` protocol previously described, " @@ -1508,7 +1302,7 @@ msgstr "" "path>` からモジュールを見つけ、ロードする方法をカスタマイズするために使える" "フックを提供しています。" -#: ../../reference/import.rst:818 +#: ../../reference/import.rst:701 msgid "" "Three variables are used by the :term:`path based finder`, :data:`sys." "path`, :data:`sys.path_hooks` and :data:`sys.path_importer_cache`. The " @@ -1520,7 +1314,7 @@ msgstr "" "使います。さらにパッケージオブジェクトの ``__path__`` 属性も使います。これら" "によって、インポート処理をカスタマイズする方法が提供されます。" -#: ../../reference/import.rst:823 +#: ../../reference/import.rst:706 msgid "" ":data:`sys.path` contains a list of strings providing search locations for " "modules and packages. It is initialized from the :envvar:`PYTHONPATH` " @@ -1532,7 +1326,7 @@ msgid "" "other data types are ignored." msgstr "" -#: ../../reference/import.rst:832 +#: ../../reference/import.rst:715 msgid "" "The :term:`path based finder` is a :term:`meta path finder`, so the import " "machinery begins the :term:`import path` search by calling the path based " @@ -1553,7 +1347,7 @@ msgstr "" "``None`` だった場合、それは最上位のインポートであることを示していて、 :data:" "`sys.path` が使われます。" -#: ../../reference/import.rst:841 +#: ../../reference/import.rst:724 msgid "" "The path based finder iterates over every entry in the search path, and for " "each of these, looks for an appropriate :term:`path entry finder` (:class:" @@ -1569,7 +1363,7 @@ msgid "" "finder to perform the path entry search again." msgstr "" -#: ../../reference/import.rst:854 +#: ../../reference/import.rst:737 msgid "" "If the path entry is not present in the cache, the path based finder " "iterates over every callable in :data:`sys.path_hooks`. Each of the :term:" @@ -1598,7 +1392,7 @@ msgstr "" "ルシステムのエンコーディングの UTF-8 やそれ以外などです) 、フックが引数をデ" "コードできなかった場合は :exc:`ImportError` を送出すべきです。" -#: ../../reference/import.rst:868 +#: ../../reference/import.rst:751 msgid "" "If :data:`sys.path_hooks` iteration ends with no :term:`path entry finder` " "being returned, then the path based finder's :meth:`~importlib.machinery." @@ -1615,7 +1409,7 @@ msgstr "" "finder>` はモジュールが見つからなかったことを伝えるために ``None`` を返しま" "す。" -#: ../../reference/import.rst:875 +#: ../../reference/import.rst:758 msgid "" "If a :term:`path entry finder` *is* returned by one of the :term:`path entry " "hook` callables on :data:`sys.path_hooks`, then the following protocol is " @@ -1627,7 +1421,7 @@ msgstr "" "` *であった* 場合、後で出てくるモジュール仕様を探すための" "プロトコルが使われ、それがモジュールをロードするために使われます。" -#: ../../reference/import.rst:880 +#: ../../reference/import.rst:763 msgid "" "The current working directory -- denoted by an empty string -- is handled " "slightly differently from other entries on :data:`sys.path`. First, if the " @@ -1646,11 +1440,11 @@ msgstr "" "meth:`importlib.machinery.PathFinder.find_spec` が返すパスは、実際のディレク" "トリであって空の文字列ではありません。" -#: ../../reference/import.rst:890 +#: ../../reference/import.rst:773 msgid "Path entry finder protocol" msgstr "パスエントリ・ファインダー・プロトコル" -#: ../../reference/import.rst:892 +#: ../../reference/import.rst:775 msgid "" "In order to support imports of modules and initialized packages and also to " "contribute portions to namespace packages, path entry finders must implement " @@ -1661,7 +1455,7 @@ msgstr "" "は :meth:`~importlib.abc.PathEntryFinder.find_spec` メソッドを実装しなければ" "いけません。" -#: ../../reference/import.rst:896 +#: ../../reference/import.rst:779 msgid "" ":meth:`~importlib.abc.PathEntryFinder.find_spec` takes two arguments: the " "fully qualified name of the module being imported, and the (optional) target " @@ -1674,21 +1468,21 @@ msgstr "" "された仕様を返します。この仕様は (1つの例外を除いて) 常に \"loader\" セットを" "持っています。" -#: ../../reference/import.rst:901 +#: ../../reference/import.rst:784 msgid "" "To indicate to the import machinery that the spec represents a namespace :" "term:`portion`, the path entry finder sets ``submodule_search_locations`` to " "a list containing the portion." msgstr "" -#: ../../reference/import.rst:905 +#: ../../reference/import.rst:788 msgid "" ":meth:`~importlib.abc.PathEntryFinder.find_spec` replaced :meth:`!" "find_loader` and :meth:`!find_module`, both of which are now deprecated, but " "will be used if ``find_spec()`` is not defined." msgstr "" -#: ../../reference/import.rst:911 +#: ../../reference/import.rst:794 msgid "" "Older path entry finders may implement one of these two deprecated methods " "instead of ``find_spec()``. The methods are still respected for the sake of " @@ -1701,14 +1495,14 @@ msgstr "" "エントリ・ファインダーに ``find_spec()`` が実装されていれば、古いメソッドは無" "視されます。" -#: ../../reference/import.rst:916 +#: ../../reference/import.rst:799 msgid "" ":meth:`!find_loader` takes one argument, the fully qualified name of the " "module being imported. ``find_loader()`` returns a 2-tuple where the first " "item is the loader and the second item is a namespace :term:`portion`." msgstr "" -#: ../../reference/import.rst:921 +#: ../../reference/import.rst:804 msgid "" "For backwards compatibility with other implementations of the import " "protocol, many path entry finders also support the same, traditional " @@ -1724,7 +1518,7 @@ msgstr "" "せん (このメソッドは、パスフックの最初の呼び出しから適切なパス情報を記録する" "動作が期待されています)。" -#: ../../reference/import.rst:928 +#: ../../reference/import.rst:811 msgid "" "The ``find_module()`` method on path entry finders is deprecated, as it does " "not allow the path entry finder to contribute portions to namespace " @@ -1739,21 +1533,21 @@ msgstr "" "システムは常に ``find_module()`` よりも ``find_loader()`` を優先して呼び出し" "ます。" -#: ../../reference/import.rst:934 +#: ../../reference/import.rst:817 msgid "" "Calls to :meth:`!find_module` and :meth:`!find_loader` by the import system " "will raise :exc:`ImportWarning`." msgstr "" -#: ../../reference/import.rst:939 +#: ../../reference/import.rst:822 msgid "``find_module()`` and ``find_loader()`` have been removed." msgstr "" -#: ../../reference/import.rst:944 +#: ../../reference/import.rst:827 msgid "Replacing the standard import system" msgstr "標準のインポートシステムを置き換える" -#: ../../reference/import.rst:946 +#: ../../reference/import.rst:829 msgid "" "The most reliable mechanism for replacing the entire import system is to " "delete the default contents of :data:`sys.meta_path`, replacing them " @@ -1763,7 +1557,7 @@ msgstr "" "`sys.meta_path` のデフォルトの内容を削除し、全部をカスタムのメタパスフックで" "置き換えるものです。" -#: ../../reference/import.rst:950 +#: ../../reference/import.rst:833 msgid "" "If it is acceptable to only alter the behaviour of import statements without " "affecting other APIs that access the import system, then replacing the " @@ -1776,7 +1570,7 @@ msgstr "" "るだけで十分です。この手法は、ある 1 つのモジュール内だけで import 文の動作を" "変更するのにも用いられます。" -#: ../../reference/import.rst:956 +#: ../../reference/import.rst:839 msgid "" "To selectively prevent the import of some modules from a hook early on the " "meta path (rather than disabling the standard import system entirely), it is " @@ -1792,11 +1586,11 @@ msgstr "" "の走査を続けるべきであることを意味しますが、例外を送出するとすぐに走査を打ち" "切ります。" -#: ../../reference/import.rst:966 +#: ../../reference/import.rst:849 msgid "Package Relative Imports" msgstr "" -#: ../../reference/import.rst:968 +#: ../../reference/import.rst:851 msgid "" "Relative imports use leading dots. A single leading dot indicates a relative " "import, starting with the current package. Two or more leading dots indicate " @@ -1804,7 +1598,7 @@ msgid "" "after the first. For example, given the following package layout::" msgstr "" -#: ../../reference/import.rst:973 +#: ../../reference/import.rst:856 msgid "" "package/\n" " __init__.py\n" @@ -1818,13 +1612,13 @@ msgid "" " moduleA.py" msgstr "" -#: ../../reference/import.rst:984 +#: ../../reference/import.rst:867 msgid "" "In either ``subpackage1/moduleX.py`` or ``subpackage1/__init__.py``, the " "following are valid relative imports::" msgstr "" -#: ../../reference/import.rst:987 +#: ../../reference/import.rst:870 msgid "" "from .moduleY import spam\n" "from .moduleY import spam as ham\n" @@ -1834,28 +1628,28 @@ msgid "" "from ..moduleA import foo" msgstr "" -#: ../../reference/import.rst:994 +#: ../../reference/import.rst:877 msgid "" "Absolute imports may use either the ``import <>`` or ``from <> import <>`` " "syntax, but relative imports may only use the second form; the reason for " "this is that::" msgstr "" -#: ../../reference/import.rst:998 +#: ../../reference/import.rst:881 msgid "import XXX.YYY.ZZZ" msgstr "" -#: ../../reference/import.rst:1000 +#: ../../reference/import.rst:883 msgid "" "should expose ``XXX.YYY.ZZZ`` as a usable expression, but .moduleY is not a " "valid expression." msgstr "" -#: ../../reference/import.rst:1007 +#: ../../reference/import.rst:890 msgid "Special considerations for __main__" msgstr "__main__ に対する特別な考慮" -#: ../../reference/import.rst:1009 +#: ../../reference/import.rst:892 msgid "" "The :mod:`__main__` module is a special case relative to Python's import " "system. As noted :ref:`elsewhere `, the ``__main__`` module is " @@ -1873,11 +1667,11 @@ msgstr "" "ん。これは、 ``__main__`` が初期化される方法がインタプリタが起動されるときの" "フラグやその他のオプションに依存するためです。" -#: ../../reference/import.rst:1020 +#: ../../reference/import.rst:903 msgid "__main__.__spec__" msgstr "__main__.__spec__" -#: ../../reference/import.rst:1022 +#: ../../reference/import.rst:905 msgid "" "Depending on how :mod:`__main__` is initialized, ``__main__.__spec__`` gets " "set appropriately or to ``None``." @@ -1885,7 +1679,7 @@ msgstr "" ":mod:`__main__` がどのように初期化されるかに依存して、 ``__main__.__spec__`` " "は適切に設定されることもあれば ``None`` になることもあります。" -#: ../../reference/import.rst:1025 +#: ../../reference/import.rst:908 msgid "" "When Python is started with the :option:`-m` option, ``__spec__`` is set to " "the module spec of the corresponding module or package. ``__spec__`` is also " @@ -1898,7 +1692,7 @@ msgstr "" "一部として ``__main__`` モジュールがロードされる場合にも ``__spec__`` が生成 " "(populate) されます。" -#: ../../reference/import.rst:1030 +#: ../../reference/import.rst:913 msgid "" "In :ref:`the remaining cases ` ``__main__." "__spec__`` is set to ``None``, as the code used to populate the :mod:" @@ -1909,23 +1703,23 @@ msgstr "" "(populate) するために使われたコードがインポート可能なモジュールと直接一致して" "いないためです:" -#: ../../reference/import.rst:1034 +#: ../../reference/import.rst:917 msgid "interactive prompt" msgstr "対話プロンプト" -#: ../../reference/import.rst:1035 +#: ../../reference/import.rst:918 msgid ":option:`-c` option" msgstr ":option:`-c` オプション" -#: ../../reference/import.rst:1036 +#: ../../reference/import.rst:919 msgid "running from stdin" msgstr "stdin から起動された場合" -#: ../../reference/import.rst:1037 +#: ../../reference/import.rst:920 msgid "running directly from a source or bytecode file" msgstr "ソースファイルやバイトコードファイルから直接起動された場合" -#: ../../reference/import.rst:1039 +#: ../../reference/import.rst:922 msgid "" "Note that ``__main__.__spec__`` is always ``None`` in the last case, *even " "if* the file could technically be imported directly as a module instead. Use " @@ -1937,7 +1731,7 @@ msgstr "" "ださい。もし :mod:`__main__` において有効なモジュールメタデータが必要なら :" "option:`-m` スイッチを使ってください。" -#: ../../reference/import.rst:1044 +#: ../../reference/import.rst:927 msgid "" "Note also that even when ``__main__`` corresponds with an importable module " "and ``__main__.__spec__`` is set accordingly, they're still considered " @@ -1952,11 +1746,11 @@ msgstr "" "(populate) するためにモジュールが使用される時にだけ実行され、通常のインポート" "時には実行されない、という事実に起因しています。" -#: ../../reference/import.rst:1052 +#: ../../reference/import.rst:935 msgid "References" msgstr "参考資料" -#: ../../reference/import.rst:1054 +#: ../../reference/import.rst:937 msgid "" "The import machinery has evolved considerably since Python's early days. " "The original `specification for packages `_ はまだ読む" "ことができます。" -#: ../../reference/import.rst:1059 +#: ../../reference/import.rst:942 msgid "" "The original specification for :data:`sys.meta_path` was :pep:`302`, with " "subsequent extension in :pep:`420`." @@ -1976,14 +1770,14 @@ msgstr "" "オリジナルの :data:`sys.meta_path` の仕様は :pep:`302` で、その後継となる拡張" "が :pep:`420` です。" -#: ../../reference/import.rst:1062 +#: ../../reference/import.rst:945 msgid "" ":pep:`420` introduced :term:`namespace packages ` for " "Python 3.3. :pep:`420` also introduced the :meth:`!find_loader` protocol as " "an alternative to :meth:`!find_module`." msgstr "" -#: ../../reference/import.rst:1066 +#: ../../reference/import.rst:949 msgid "" ":pep:`366` describes the addition of the ``__package__`` attribute for " "explicit relative imports in main modules." @@ -1991,7 +1785,7 @@ msgstr "" ":pep:`366` は、メインモジュールでの明示的な相対インポートのために追加した " "``__package__`` 属性の解説をしています。" -#: ../../reference/import.rst:1069 +#: ../../reference/import.rst:952 msgid "" ":pep:`328` introduced absolute and explicit relative imports and initially " "proposed ``__name__`` for semantics :pep:`366` would eventually specify for " @@ -2001,12 +1795,12 @@ msgstr "" "``__name__`` で提案し、後に :pep:`366` が ``__package__`` で定めた仕様を導入" "しました。" -#: ../../reference/import.rst:1073 +#: ../../reference/import.rst:956 msgid ":pep:`338` defines executing modules as scripts." msgstr "" ":pep:`338` はモジュールをスクリプトとして実行するときの仕様を定めています。" -#: ../../reference/import.rst:1075 +#: ../../reference/import.rst:958 msgid "" ":pep:`451` adds the encapsulation of per-module import state in spec " "objects. It also off-loads most of the boilerplate responsibilities of " @@ -2020,15 +1814,15 @@ msgstr "" "くつかの API が deprecate され、またファインダーとローダーには新しいメソッド" "が追加されました。" -#: ../../reference/import.rst:1082 +#: ../../reference/import.rst:965 msgid "Footnotes" msgstr "脚注" -#: ../../reference/import.rst:1083 +#: ../../reference/import.rst:966 msgid "See :class:`types.ModuleType`." msgstr ":class:`types.ModuleType` を参照してください。" -#: ../../reference/import.rst:1085 +#: ../../reference/import.rst:968 msgid "" "The importlib implementation avoids using the return value directly. " "Instead, it gets the module object by looking the module name up in :data:" @@ -2115,22 +1909,22 @@ msgstr "sys.meta_path" msgid "find_spec" msgstr "" -#: ../../reference/import.rst:753 +#: ../../reference/import.rst:636 msgid "path based finder" msgstr "path based finder" -#: ../../reference/import.rst:802 +#: ../../reference/import.rst:685 msgid "sys.path" msgstr "sys.path" -#: ../../reference/import.rst:802 +#: ../../reference/import.rst:685 msgid "sys.path_hooks" msgstr "sys.path_hooks" -#: ../../reference/import.rst:802 +#: ../../reference/import.rst:685 msgid "sys.path_importer_cache" msgstr "sys.path_importer_cache" -#: ../../reference/import.rst:802 +#: ../../reference/import.rst:685 msgid "PYTHONPATH" msgstr "PYTHONPATH" diff --git a/tutorial/introduction.po b/tutorial/introduction.po index 7eac9f202..2845b1ba8 100644 --- a/tutorial/introduction.po +++ b/tutorial/introduction.po @@ -18,7 +18,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:50+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -372,38 +372,25 @@ msgid "" "String literals can span multiple lines. One way is using triple-quotes: " "``\"\"\"...\"\"\"`` or ``'''...'''``. End of lines are automatically " "included in the string, but it's possible to prevent this by adding a ``\\`` " -"at the end of the line. The following example::" +"at the end of the line. In the following example, the initial newline is " +"not included::" msgstr "" -"文字列リテラルは複数行にまたがって書けます。1 つの方法は三連引用符 " -"(``\"\"\"...\"\"\"`` や ``'''...'''``) を使うことです。改行文字は自動的に文字" -"列に含まれますが、行末に ``\\`` を付けることで含めないようにすることもできま" -"す。次の例::" -#: ../../tutorial/introduction.rst:202 +#: ../../tutorial/introduction.rst:203 msgid "" -"print(\"\"\"\\\n" +">>> print(\"\"\"\\\n" +"... Usage: thingy [OPTIONS]\n" +"... -h Display this usage message\n" +"... -H hostname Hostname to connect to\n" +"... \"\"\")\n" "Usage: thingy [OPTIONS]\n" " -h Display this usage message\n" " -H hostname Hostname to connect to\n" -"\"\"\")" -msgstr "" - -#: ../../tutorial/introduction.rst:208 -msgid "" -"produces the following output (note that the initial newline is not " -"included):" -msgstr "" -"は次のような出力になります (最初の改行文字は含まれていないことに注意してくだ" -"さい):" - -#: ../../tutorial/introduction.rst:210 -msgid "" -"Usage: thingy [OPTIONS]\n" -" -h Display this usage message\n" -" -H hostname Hostname to connect to" +"\n" +">>>" msgstr "" -#: ../../tutorial/introduction.rst:216 +#: ../../tutorial/introduction.rst:214 msgid "" "Strings can be concatenated (glued together) with the ``+`` operator, and " "repeated with ``*``::" @@ -411,14 +398,14 @@ msgstr "" "文字列は ``+`` 演算子で連結させる (くっつけて一つにする) ことができ、``*`` 演" "算子で反復させることができます::" -#: ../../tutorial/introduction.rst:219 +#: ../../tutorial/introduction.rst:217 msgid "" ">>> # 3 times 'un', followed by 'ium'\n" ">>> 3 * 'un' + 'ium'\n" "'unununium'" msgstr "" -#: ../../tutorial/introduction.rst:223 +#: ../../tutorial/introduction.rst:221 msgid "" "Two or more *string literals* (i.e. the ones enclosed between quotes) next " "to each other are automatically concatenated. ::" @@ -426,18 +413,18 @@ msgstr "" "連続して並んでいる複数の *文字列リテラル* (つまり、引用符に囲われた文字列) " "は、自動的に連結されます。 ::" -#: ../../tutorial/introduction.rst:226 +#: ../../tutorial/introduction.rst:224 msgid "" ">>> 'Py' 'thon'\n" "'Python'" msgstr "" -#: ../../tutorial/introduction.rst:229 +#: ../../tutorial/introduction.rst:227 msgid "" "This feature is particularly useful when you want to break long strings::" msgstr "この機能は、長い文字列を改行したいときにとても役に立ちます::" -#: ../../tutorial/introduction.rst:231 +#: ../../tutorial/introduction.rst:229 msgid "" ">>> text = ('Put several strings within parentheses '\n" "... 'to have them joined together.')\n" @@ -445,12 +432,12 @@ msgid "" "'Put several strings within parentheses to have them joined together.'" msgstr "" -#: ../../tutorial/introduction.rst:236 +#: ../../tutorial/introduction.rst:234 msgid "" "This only works with two literals though, not with variables or expressions::" msgstr "これは 2 つのリテラルどうしに対してのみ働き、変数や式には働きません::" -#: ../../tutorial/introduction.rst:238 +#: ../../tutorial/introduction.rst:236 msgid "" ">>> prefix = 'Py'\n" ">>> prefix 'thon' # can't concatenate a variable and a string literal\n" @@ -465,18 +452,18 @@ msgid "" "SyntaxError: invalid syntax" msgstr "" -#: ../../tutorial/introduction.rst:250 +#: ../../tutorial/introduction.rst:248 msgid "" "If you want to concatenate variables or a variable and a literal, use ``+``::" msgstr "変数どうしや変数とリテラルを連結したい場合は、``+`` を使ってください::" -#: ../../tutorial/introduction.rst:252 +#: ../../tutorial/introduction.rst:250 msgid "" ">>> prefix + 'thon'\n" "'Python'" msgstr "" -#: ../../tutorial/introduction.rst:255 +#: ../../tutorial/introduction.rst:253 msgid "" "Strings can be *indexed* (subscripted), with the first character having " "index 0. There is no separate character type; a character is simply a string " @@ -486,7 +473,7 @@ msgstr "" "デックスは 0 になります。文字を表す、専用のデータ型は用意されていません; 文字" "とは、単に長さが 1 の文字列です::" -#: ../../tutorial/introduction.rst:259 +#: ../../tutorial/introduction.rst:257 msgid "" ">>> word = 'Python'\n" ">>> word[0] # character in position 0\n" @@ -495,13 +482,13 @@ msgid "" "'n'" msgstr "" -#: ../../tutorial/introduction.rst:265 +#: ../../tutorial/introduction.rst:263 msgid "" "Indices may also be negative numbers, to start counting from the right::" msgstr "" "インデックスには、負の値も指定できまます。この場合、右から数えていきます::" -#: ../../tutorial/introduction.rst:267 +#: ../../tutorial/introduction.rst:265 msgid "" ">>> word[-1] # last character\n" "'n'\n" @@ -511,11 +498,11 @@ msgid "" "'P'" msgstr "" -#: ../../tutorial/introduction.rst:274 +#: ../../tutorial/introduction.rst:272 msgid "Note that since -0 is the same as 0, negative indices start from -1." msgstr "-0 は 0 と区別できないので、負のインデックスは -1 から始まります。" -#: ../../tutorial/introduction.rst:276 +#: ../../tutorial/introduction.rst:274 msgid "" "In addition to indexing, *slicing* is also supported. While indexing is " "used to obtain individual characters, *slicing* allows you to obtain a " @@ -525,7 +512,7 @@ msgstr "" "個々の文字を取得するのに使いますが、 *スライス* を使うと部分文字列を取得する" "ことができます::" -#: ../../tutorial/introduction.rst:279 +#: ../../tutorial/introduction.rst:277 msgid "" ">>> word[0:2] # characters from position 0 (included) to 2 (excluded)\n" "'Py'\n" @@ -533,7 +520,7 @@ msgid "" "'tho'" msgstr "" -#: ../../tutorial/introduction.rst:284 +#: ../../tutorial/introduction.rst:282 msgid "" "Slice indices have useful defaults; an omitted first index defaults to zero, " "an omitted second index defaults to the size of the string being sliced. ::" @@ -542,7 +529,7 @@ msgstr "" "を省略すると、0 と見なされます。二番め のインデックスを省略すると、スライスす" "る文字列のサイズとみなされます。 ::" -#: ../../tutorial/introduction.rst:287 +#: ../../tutorial/introduction.rst:285 msgid "" ">>> word[:2] # character from the beginning to position 2 (excluded)\n" "'Py'\n" @@ -552,7 +539,7 @@ msgid "" "'on'" msgstr "" -#: ../../tutorial/introduction.rst:294 +#: ../../tutorial/introduction.rst:292 msgid "" "Note how the start is always included, and the end always excluded. This " "makes sure that ``s[:i] + s[i:]`` is always equal to ``s``::" @@ -560,7 +547,7 @@ msgstr "" "開始値は常に含まれ、終了値は常に含まれないことに注意してください。なので " "``s[:i] + s[i:]`` は常に ``s`` と等しくなります::" -#: ../../tutorial/introduction.rst:297 +#: ../../tutorial/introduction.rst:295 msgid "" ">>> word[:2] + word[2:]\n" "'Python'\n" @@ -568,7 +555,7 @@ msgid "" "'Python'" msgstr "" -#: ../../tutorial/introduction.rst:302 +#: ../../tutorial/introduction.rst:300 msgid "" "One way to remember how slices work is to think of the indices as pointing " "*between* characters, with the left edge of the first character numbered 0. " @@ -580,7 +567,7 @@ msgstr "" "そうすると、 *n* 文字からなる文字列中の最後の文字の右端はインデックス *n* と" "なります。例えばこうです::" -#: ../../tutorial/introduction.rst:307 +#: ../../tutorial/introduction.rst:305 msgid "" " +---+---+---+---+---+---+\n" " | P | y | t | h | o | n |\n" @@ -589,7 +576,7 @@ msgid "" "-6 -5 -4 -3 -2 -1" msgstr "" -#: ../../tutorial/introduction.rst:313 +#: ../../tutorial/introduction.rst:311 msgid "" "The first row of numbers gives the position of the indices 0...6 in the " "string; the second row gives the corresponding negative indices. The slice " @@ -600,7 +587,7 @@ msgstr "" "は対応する負のインデックスを示しています。*i* から *j* までのスライスは、それ" "ぞれ *i* と付いた境界から *j* と付いた境界までの全ての文字から成っています。" -#: ../../tutorial/introduction.rst:318 +#: ../../tutorial/introduction.rst:316 msgid "" "For non-negative indices, the length of a slice is the difference of the " "indices, if both are within bounds. For example, the length of " @@ -610,11 +597,11 @@ msgstr "" "ンデックスが範囲内にあるかぎり、インデックス間の差になります。例えば、 " "``word[1:3]`` の長さは 2 になります。" -#: ../../tutorial/introduction.rst:322 +#: ../../tutorial/introduction.rst:320 msgid "Attempting to use an index that is too large will result in an error::" msgstr "大き過ぎるインデックスを使おうとするとエラーが発生します::" -#: ../../tutorial/introduction.rst:324 +#: ../../tutorial/introduction.rst:322 msgid "" ">>> word[42] # the word only has 6 characters\n" "Traceback (most recent call last):\n" @@ -622,7 +609,7 @@ msgid "" "IndexError: string index out of range" msgstr "" -#: ../../tutorial/introduction.rst:329 +#: ../../tutorial/introduction.rst:327 msgid "" "However, out of range slice indexes are handled gracefully when used for " "slicing::" @@ -630,7 +617,7 @@ msgstr "" "しかし、スライスで範囲外のインデックスを使ったときは、上手く対応して扱ってく" "れます::" -#: ../../tutorial/introduction.rst:332 +#: ../../tutorial/introduction.rst:330 msgid "" ">>> word[4:42]\n" "'on'\n" @@ -638,7 +625,7 @@ msgid "" "''" msgstr "" -#: ../../tutorial/introduction.rst:337 +#: ../../tutorial/introduction.rst:335 msgid "" "Python strings cannot be changed --- they are :term:`immutable`. Therefore, " "assigning to an indexed position in the string results in an error::" @@ -646,7 +633,7 @@ msgstr "" "Python の文字列は変更できません -- つまり :term:`不変 ` です。従っ" "て、文字列のインデックスで指定したある場所に代入を行うとエラーが発生します::" -#: ../../tutorial/introduction.rst:340 +#: ../../tutorial/introduction.rst:338 msgid "" ">>> word[0] = 'J'\n" "Traceback (most recent call last):\n" @@ -658,11 +645,11 @@ msgid "" "TypeError: 'str' object does not support item assignment" msgstr "" -#: ../../tutorial/introduction.rst:349 +#: ../../tutorial/introduction.rst:347 msgid "If you need a different string, you should create a new one::" msgstr "元の文字列と別の文字列が必要な場合は、新しく文字列を作成してください::" -#: ../../tutorial/introduction.rst:351 +#: ../../tutorial/introduction.rst:349 msgid "" ">>> 'J' + word[1:]\n" "'Jython'\n" @@ -670,22 +657,22 @@ msgid "" "'Pypy'" msgstr "" -#: ../../tutorial/introduction.rst:356 +#: ../../tutorial/introduction.rst:354 msgid "The built-in function :func:`len` returns the length of a string::" msgstr "組込み関数 :func:`len` は文字列の長さ (length) を返します::" -#: ../../tutorial/introduction.rst:358 +#: ../../tutorial/introduction.rst:356 msgid "" ">>> s = 'supercalifragilisticexpialidocious'\n" ">>> len(s)\n" "34" msgstr "" -#: ../../tutorial/introduction.rst:365 +#: ../../tutorial/introduction.rst:363 msgid ":ref:`textseq`" msgstr ":ref:`textseq`" -#: ../../tutorial/introduction.rst:366 +#: ../../tutorial/introduction.rst:364 msgid "" "Strings are examples of *sequence types*, and support the common operations " "supported by such types." @@ -693,11 +680,11 @@ msgstr "" "文字列は代表的な *シーケンス型* で、シーケンス型でサポートされている共通の操" "作をサポートしています。" -#: ../../tutorial/introduction.rst:369 +#: ../../tutorial/introduction.rst:367 msgid ":ref:`string-methods`" msgstr ":ref:`string-methods`" -#: ../../tutorial/introduction.rst:370 +#: ../../tutorial/introduction.rst:368 msgid "" "Strings support a large number of methods for basic transformations and " "searching." @@ -705,28 +692,28 @@ msgstr "" "文字列は、基本的な変換や検索を行うための数多くのメソッドをサポートしていま" "す。" -#: ../../tutorial/introduction.rst:373 +#: ../../tutorial/introduction.rst:371 msgid ":ref:`f-strings`" msgstr ":ref:`f-strings`" -#: ../../tutorial/introduction.rst:374 +#: ../../tutorial/introduction.rst:372 msgid "String literals that have embedded expressions." msgstr "式の埋め込みをサポートした文字列リテラル" -#: ../../tutorial/introduction.rst:376 +#: ../../tutorial/introduction.rst:374 msgid ":ref:`formatstrings`" msgstr ":ref:`formatstrings`" -#: ../../tutorial/introduction.rst:377 +#: ../../tutorial/introduction.rst:375 msgid "Information about string formatting with :meth:`str.format`." msgstr "" ":meth:`str.format` を使った文字列のフォーマットについての情報があります。" -#: ../../tutorial/introduction.rst:379 +#: ../../tutorial/introduction.rst:377 msgid ":ref:`old-string-formatting`" msgstr ":ref:`old-string-formatting`" -#: ../../tutorial/introduction.rst:380 +#: ../../tutorial/introduction.rst:378 msgid "" "The old formatting operations invoked when strings are the left operand of " "the ``%`` operator are described in more detail here." @@ -734,11 +721,11 @@ msgstr "" "文字列が ``%`` 演算子の左オペランドである場合に呼び出される古いフォーマット操" "作について、詳しく記述されています。" -#: ../../tutorial/introduction.rst:387 +#: ../../tutorial/introduction.rst:385 msgid "Lists" msgstr "リスト型 (list)" -#: ../../tutorial/introduction.rst:389 +#: ../../tutorial/introduction.rst:387 msgid "" "Python knows a number of *compound* data types, used to group together other " "values. The most versatile is the *list*, which can be written as a list of " @@ -750,14 +737,14 @@ msgstr "" "の並びを角括弧で囲んだものとして書き表されます。リストは異なる型の要素を含む" "こともありますが、通常は同じ型の要素のみを持ちます。 ::" -#: ../../tutorial/introduction.rst:394 +#: ../../tutorial/introduction.rst:392 msgid "" ">>> squares = [1, 4, 9, 16, 25]\n" ">>> squares\n" "[1, 4, 9, 16, 25]" msgstr "" -#: ../../tutorial/introduction.rst:398 +#: ../../tutorial/introduction.rst:396 msgid "" "Like strings (and all other built-in :term:`sequence` types), lists can be " "indexed and sliced::" @@ -765,7 +752,7 @@ msgstr "" "文字列 (や他の全ての組み込みの :term:`シーケンス ` 型) のように、リ" "ストはインデックスやスライスができます::" -#: ../../tutorial/introduction.rst:401 +#: ../../tutorial/introduction.rst:399 msgid "" ">>> squares[0] # indexing returns the item\n" "1\n" @@ -775,17 +762,17 @@ msgid "" "[9, 16, 25]" msgstr "" -#: ../../tutorial/introduction.rst:408 +#: ../../tutorial/introduction.rst:406 msgid "Lists also support operations like concatenation::" msgstr "リストは、リストの連結などもサポートしています::" -#: ../../tutorial/introduction.rst:410 +#: ../../tutorial/introduction.rst:408 msgid "" ">>> squares + [36, 49, 64, 81, 100]\n" "[1, 4, 9, 16, 25, 36, 49, 64, 81, 100]" msgstr "" -#: ../../tutorial/introduction.rst:413 +#: ../../tutorial/introduction.rst:411 msgid "" "Unlike strings, which are :term:`immutable`, lists are a :term:`mutable` " "type, i.e. it is possible to change their content::" @@ -793,7 +780,7 @@ msgstr "" ":term:`不変 ` な文字列とは違って、リストは :term:`可変 ` " "型ですので、要素を入れ替えられます::" -#: ../../tutorial/introduction.rst:416 +#: ../../tutorial/introduction.rst:414 msgid "" ">>> cubes = [1, 8, 27, 65, 125] # something's wrong here\n" ">>> 4 ** 3 # the cube of 4 is 64, not 65!\n" @@ -803,7 +790,7 @@ msgid "" "[1, 8, 27, 64, 125]" msgstr "" -#: ../../tutorial/introduction.rst:423 +#: ../../tutorial/introduction.rst:421 msgid "" "You can also add new items at the end of the list, by using the :meth:`!list." "append` *method* (we will see more about methods later)::" @@ -811,7 +798,7 @@ msgstr "" ":meth:`!list.append` を使って、リストの末尾に新しい要素を追加できます (このメ" "ソッドについては後で詳しく見ていきます)::" -#: ../../tutorial/introduction.rst:426 +#: ../../tutorial/introduction.rst:424 msgid "" ">>> cubes.append(216) # add the cube of 6\n" ">>> cubes.append(7 ** 3) # and the cube of 7\n" @@ -819,7 +806,7 @@ msgid "" "[1, 8, 27, 64, 125, 216, 343]" msgstr "" -#: ../../tutorial/introduction.rst:431 +#: ../../tutorial/introduction.rst:429 msgid "" "Simple assignment in Python never copies data. When you assign a list to a " "variable, the variable refers to the *existing list*. Any changes you make " @@ -830,7 +817,7 @@ msgstr "" "と、その変数は *既存のリスト* を参照します。ある変数を通してリストに任意の変" "更を行うと、そのリストを参照したすべての他の変数を通して確認できます。::" -#: ../../tutorial/introduction.rst:436 +#: ../../tutorial/introduction.rst:434 msgid "" ">>> rgb = [\"Red\", \"Green\", \"Blue\"]\n" ">>> rgba = rgb\n" @@ -841,7 +828,7 @@ msgid "" "[\"Red\", \"Green\", \"Blue\", \"Alph\"]" msgstr "" -#: ../../tutorial/introduction.rst:444 +#: ../../tutorial/introduction.rst:442 msgid "" "All slice operations return a new list containing the requested elements. " "This means that the following slice returns a :ref:`shallow copy " @@ -851,7 +838,7 @@ msgstr "" "のスライスは、リストの :ref:`浅いコピー ` を返しま" "す。::" -#: ../../tutorial/introduction.rst:448 +#: ../../tutorial/introduction.rst:446 msgid "" ">>> correct_rgba = rgba[:]\n" ">>> correct_rgba[-1] = \"Alpha\"\n" @@ -861,7 +848,7 @@ msgid "" "[\"Red\", \"Green\", \"Blue\", \"Alph\"]" msgstr "" -#: ../../tutorial/introduction.rst:455 +#: ../../tutorial/introduction.rst:453 msgid "" "Assignment to slices is also possible, and this can even change the size of " "the list or clear it entirely::" @@ -869,7 +856,7 @@ msgstr "" "スライスには、代入もできます。スライスの代入で、リストのサイズを変更したり、" "全てを削除したりもできます::" -#: ../../tutorial/introduction.rst:458 +#: ../../tutorial/introduction.rst:456 msgid "" ">>> letters = ['a', 'b', 'c', 'd', 'e', 'f', 'g']\n" ">>> letters\n" @@ -888,24 +875,24 @@ msgid "" "[]" msgstr "" -#: ../../tutorial/introduction.rst:474 +#: ../../tutorial/introduction.rst:472 msgid "The built-in function :func:`len` also applies to lists::" msgstr "組込み関数 :func:`len` はリストにも使えます::" -#: ../../tutorial/introduction.rst:476 +#: ../../tutorial/introduction.rst:474 msgid "" ">>> letters = ['a', 'b', 'c', 'd']\n" ">>> len(letters)\n" "4" msgstr "" -#: ../../tutorial/introduction.rst:480 +#: ../../tutorial/introduction.rst:478 msgid "" "It is possible to nest lists (create lists containing other lists), for " "example::" msgstr "リストを入れ子 (ほかのリストを含むリストを造る) にできます。例えば::" -#: ../../tutorial/introduction.rst:483 +#: ../../tutorial/introduction.rst:481 msgid "" ">>> a = ['a', 'b', 'c']\n" ">>> n = [1, 2, 3]\n" @@ -918,11 +905,11 @@ msgid "" "'b'" msgstr "" -#: ../../tutorial/introduction.rst:496 +#: ../../tutorial/introduction.rst:494 msgid "First Steps Towards Programming" msgstr "プログラミングへの第一歩" -#: ../../tutorial/introduction.rst:498 +#: ../../tutorial/introduction.rst:496 msgid "" "Of course, we can use Python for more complicated tasks than adding two and " "two together. For instance, we can write an initial sub-sequence of the " @@ -933,7 +920,7 @@ msgstr "" "例えば、`Fibonacci series `_ の先頭の部分列は次のように書けます::" -#: ../../tutorial/introduction.rst:503 +#: ../../tutorial/introduction.rst:501 msgid "" ">>> # Fibonacci series:\n" ">>> # the sum of two elements defines the next\n" @@ -951,11 +938,11 @@ msgid "" "8" msgstr "" -#: ../../tutorial/introduction.rst:518 +#: ../../tutorial/introduction.rst:516 msgid "This example introduces several new features." msgstr "上の例では、いくつか新しい機能を使用しています。" -#: ../../tutorial/introduction.rst:520 +#: ../../tutorial/introduction.rst:518 msgid "" "The first line contains a *multiple assignment*: the variables ``a`` and " "``b`` simultaneously get the new values 0 and 1. On the last line this is " @@ -968,7 +955,7 @@ msgstr "" "最後の行でも使われています。代入文では、まず右辺の式がすべて評価され、次に代" "入が行われます。右辺の式は、左から右へと順番に評価されます。" -#: ../../tutorial/introduction.rst:526 +#: ../../tutorial/introduction.rst:524 msgid "" "The :keyword:`while` loop executes as long as the condition (here: ``a < " "10``) remains true. In Python, like in C, any non-zero integer value is " @@ -988,7 +975,7 @@ msgstr "" "(より大きい)、 ``==`` (等しい)、 ``<=`` (より小さいか等しい)、 ``>=`` (より大" "きいか等しい)、および ``!=`` (等しくない)、です。" -#: ../../tutorial/introduction.rst:535 +#: ../../tutorial/introduction.rst:533 msgid "" "The *body* of the loop is *indented*: indentation is Python's way of " "grouping statements. At the interactive prompt, you have to type a tab or " @@ -1009,7 +996,7 @@ msgstr "" "ためです。基本的なブロック内では、全ての行は同じだけインデントされていなけれ" "ばならないので注意してください。" -#: ../../tutorial/introduction.rst:544 +#: ../../tutorial/introduction.rst:542 msgid "" "The :func:`print` function writes the value of the argument(s) it is given. " "It differs from just writing the expression you want to write (as we did " @@ -1023,14 +1010,14 @@ msgstr "" "列に対する扱い方が違います。:func:`print` 関数では、文字列は引用符無しで出力" "され、要素の間に空白が挿入されて、このように出力の書式が整えられます::" -#: ../../tutorial/introduction.rst:551 +#: ../../tutorial/introduction.rst:549 msgid "" ">>> i = 256*256\n" ">>> print('The value of i is', i)\n" "The value of i is 65536" msgstr "" -#: ../../tutorial/introduction.rst:555 +#: ../../tutorial/introduction.rst:553 msgid "" "The keyword argument *end* can be used to avoid the newline after the " "output, or end the output with a different string::" @@ -1038,7 +1025,7 @@ msgstr "" "キーワード引数 *end* を使うと、出力の末尾に改行文字を出力しないようにしたり、" "別の文字列を末尾に出力したりできます::" -#: ../../tutorial/introduction.rst:558 +#: ../../tutorial/introduction.rst:556 msgid "" ">>> a, b = 0, 1\n" ">>> while a < 1000:\n" @@ -1048,11 +1035,11 @@ msgid "" "0,1,1,2,3,5,8,13,21,34,55,89,144,233,377,610,987," msgstr "" -#: ../../tutorial/introduction.rst:567 +#: ../../tutorial/introduction.rst:565 msgid "Footnotes" msgstr "脚注" -#: ../../tutorial/introduction.rst:568 +#: ../../tutorial/introduction.rst:566 msgid "" "Since ``**`` has higher precedence than ``-``, ``-3**2`` will be interpreted " "as ``-(3**2)`` and thus result in ``-9``. To avoid this and get ``9``, you " @@ -1062,7 +1049,7 @@ msgstr "" "計算結果は ``-9`` になります。これを避けて ``9`` を得たければ、``(-3)**2`` と" "書きます。" -#: ../../tutorial/introduction.rst:572 +#: ../../tutorial/introduction.rst:570 msgid "" "Unlike other languages, special characters such as ``\\n`` have the same " "meaning with both single (``'...'``) and double (``\"...\"``) quotes. The " diff --git a/tutorial/modules.po b/tutorial/modules.po index d3a0c5d3a..0e0c0f75c 100644 --- a/tutorial/modules.po +++ b/tutorial/modules.po @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:50+0000\n" "Last-Translator: TENMYO Masakazu, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -1119,19 +1119,14 @@ msgstr "複数ディレクトリ中のパッケージ" #: ../../tutorial/modules.rst:588 msgid "" -"Packages support one more special attribute, :attr:`__path__`. This is " -"initialized to be a list containing the name of the directory holding the " -"package's :file:`__init__.py` before the code in that file is executed. " -"This variable can be modified; doing so affects future searches for modules " -"and subpackages contained in the package." +"Packages support one more special attribute, :attr:`~module.__path__`. This " +"is initialized to be a :term:`sequence` of strings containing the name of " +"the directory holding the package's :file:`__init__.py` before the code in " +"that file is executed. This variable can be modified; doing so affects " +"future searches for modules and subpackages contained in the package." msgstr "" -"パッケージはもう一つ特別な属性として :attr:`__path__` をサポートしています。" -"この属性は、パッケージの :file:`__init__.py` 中のコードが実行されるよりも前" -"に、 :file:`__init__.py` の収められているディレクトリ名の入ったリストになるよ" -"う初期化されます。この変数は変更することができます。変更を加えると、以降その" -"パッケージに入っているモジュールやサブパッケージの検索に影響します。" -#: ../../tutorial/modules.rst:594 +#: ../../tutorial/modules.rst:595 msgid "" "While this feature is not often needed, it can be used to extend the set of " "modules found in a package." @@ -1139,11 +1134,11 @@ msgstr "" "この機能はほとんど必要にはならないのですが、パッケージ内存在するモジュール群" "を拡張するために使うことができます。" -#: ../../tutorial/modules.rst:599 +#: ../../tutorial/modules.rst:600 msgid "Footnotes" msgstr "脚注" -#: ../../tutorial/modules.rst:600 +#: ../../tutorial/modules.rst:601 msgid "" "In fact function definitions are also 'statements' that are 'executed'; the " "execution of a module-level function definition adds the function name to " diff --git a/using/cmdline.po b/using/cmdline.po index c457c4bf2..7b60292a2 100644 --- a/using/cmdline.po +++ b/using/cmdline.po @@ -4,8 +4,8 @@ # FIRST AUTHOR , YEAR. # # Translators: +# tomo, 2021 # Osamu NAKAMURA, 2021 -# tomo, 2022 # Arihiro TAKASE, 2023 # 石井明久, 2024 # Takanori Suzuki , 2024 @@ -15,7 +15,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:50+0000\n" "Last-Translator: Takanori Suzuki , 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -1489,8 +1489,9 @@ msgid "" msgstr "" #: ../../using/cmdline.rst:1030 ../../using/cmdline.rst:1044 -msgid ":ref:`Availability `: Windows." -msgstr ":ref:`利用可能な環境 `: Windows 。" +#: ../../using/cmdline.rst:1095 +msgid "Availability" +msgstr "" #: ../../using/cmdline.rst:1032 msgid "See :pep:`529` for more details." @@ -1579,10 +1580,6 @@ msgid "" "system interfaces." msgstr "" -#: ../../using/cmdline.rst:1095 -msgid ":ref:`Availability `: Unix." -msgstr ":ref:`利用可能な環境 `: Unix。" - #: ../../using/cmdline.rst:1097 msgid "See :pep:`538` for more details." msgstr "より詳しくは :pep:`538` を参照をしてください。" diff --git a/whatsnew/2.6.po b/whatsnew/2.6.po index ffba54b92..cf0d8cd39 100644 --- a/whatsnew/2.6.po +++ b/whatsnew/2.6.po @@ -11,7 +11,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-20 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-28 01:51+0000\n" "Last-Translator: tomo, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -838,32 +838,18 @@ msgstr "" #: ../../whatsnew/2.6.rst:505 msgid "" -"The fix for Python 2.6 adds a :attr:`__package__` attribute to modules. " -"When this attribute is present, relative imports will be relative to the " -"value of this attribute instead of the :attr:`__name__` attribute." +"The fix for Python 2.6 adds a :attr:`module.__package__` attribute. When " +"this attribute is present, relative imports will be relative to the value of " +"this attribute instead of the :attr:`~module.__name__` attribute." msgstr "" -"Python 2.6 でのそれについてのフィックスは、モジュールに :attr:`__package__` " -"属性を追加するというものです。この属性がある場合は相対インポートは :attr:" -"`__name__` 属性の代わりにこの属性の値からの相対でインポートします。" #: ../../whatsnew/2.6.rst:510 msgid "" -"PEP 302-style importers can then set :attr:`__package__` as necessary. The :" -"mod:`runpy` module that implements the :option:`-m` switch now does this, so " -"relative imports will now work correctly in scripts running from inside a " -"package." -msgstr "" -"PEP 302 スタイルのインポーターはその結果 :attr:`__package__` を必要に応じて設" -"定出来ます。 :option:`-m` スイッチを実装している :mod:`runpy` モジュールは今" -"はこれをするので、パッケージ内のモジュール実行内の相対インポートは、今では正" -"しく動作します。(--- 訳注: このセクションの言いたいことの結論がわからない方は" -"いないと思いますが、細かいところでこの翻訳を行っている 2015 年ではわからなく" -"なっているところがあるので補足しておきます。 :attr:`__package__` 属性のくだり" -"ですが、現在となっては「2.5 ではこれを設定していなかった」のかどうか簡単には" -"確認は出来ないですが、言語リファレンスによればローダが :attr:`__package__` を" -"セットするのはオプションだがセットすべき、と書かれています。2.6 で行われたの" -"は、おそらく :attr:`__package__` の用法が :mod:`runpy` きっかけで整理された、" -"ということではないかと思います。---)" +"PEP 302-style importers can then set :attr:`~module.__package__` as " +"necessary. The :mod:`runpy` module that implements the :option:`-m` switch " +"now does this, so relative imports will now work correctly in scripts " +"running from inside a package." +msgstr "" #: ../../whatsnew/2.6.rst:520 msgid "PEP 370: Per-user ``site-packages`` Directory" diff --git a/whatsnew/3.0.po b/whatsnew/3.0.po index c1e03da54..ccd9fdc11 100644 --- a/whatsnew/3.0.po +++ b/whatsnew/3.0.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-10-04 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-29 13:04+0000\n" "Last-Translator: Taichi Haradaguchi, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -629,16 +629,10 @@ msgid "" ":pep:`3107`: Function argument and return value annotations. This provides " "a standardized way of annotating a function's parameters and return value. " "There are no semantics attached to such annotations except that they can be " -"introspected at runtime using the :attr:`__annotations__` attribute. The " -"intent is to encourage experimentation through metaclasses, decorators or " -"frameworks." -msgstr "" -":pep:`3107`: 関数引数と戻り値のアノテーション。これは関数のパラメータと戻り値" -"へのアノテーションを付ける標準的な手段を提供します (訳注: annotation を強いて" -"訳せば「注釈」)。そのようなアノテーションには、実行時に :attr:" -"`__annotations__` 属性を調べること以外には何の意味付けもされていません。メタ" -"クラスやデコレータ、フレームワークを通じた実験を促進することが意図されていま" -"す。" +"introspected at runtime using the :attr:`~object.__annotations__` " +"attribute. The intent is to encourage experimentation through metaclasses, " +"decorators or frameworks." +msgstr "" #: ../../whatsnew/3.0.rst:363 msgid "" diff --git a/whatsnew/3.2.po b/whatsnew/3.2.po index 51f811b13..1d65905c4 100644 --- a/whatsnew/3.2.po +++ b/whatsnew/3.2.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-29 13:04+0000\n" "Last-Translator: Tetsuo Koyama , 2021\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -510,11 +510,9 @@ msgstr "" #: ../../whatsnew/3.2.rst:315 msgid "" -"Imported modules now have a :attr:`__cached__` attribute which stores the " -"name of the actual file that was imported:" +"Imported modules now have a :attr:`~module.__cached__` attribute which " +"stores the name of the actual file that was imported:" msgstr "" -"インポートされたモジュールには属性 :attr:`__cached__` が追加されて、これには" -"インポートされたファイルの実際のファイル名を記憶しています:" #: ../../whatsnew/3.2.rst:322 msgid "" diff --git a/whatsnew/3.4.po b/whatsnew/3.4.po index 6edf0fcba..576bc1551 100644 --- a/whatsnew/3.4.po +++ b/whatsnew/3.4.po @@ -12,7 +12,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-29 13:04+0000\n" "Last-Translator: Takanori Suzuki , 2021\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -4397,17 +4397,13 @@ msgstr "" #: ../../whatsnew/3.4.rst:2274 msgid "" -"The module type now initializes the :attr:`__package__` and :attr:" -"`__loader__` attributes to ``None`` by default. To determine if these " -"attributes were set in a backwards-compatible fashion, use e.g. " +"The module type now initializes the :attr:`~module.__package__` and :attr:" +"`~module.__loader__` attributes to ``None`` by default. To determine if " +"these attributes were set in a backwards-compatible fashion, use e.g. " "``getattr(module, '__loader__', None) is not None``. (:issue:`17115`.)" msgstr "" -"モジュール型が :attr:`__package__` 属性と :attr:`__loader__` 属性をデフォルト" -"で ``None`` で初期化するようになりました。これら属性がセットされたかどうかを" -"後方互換性のある方法で調べるには、たとえば ``getattr(module, '__loader__', " -"None) is not None`` のようにしてください。 (:issue:`17115`.)" -#: ../../whatsnew/3.4.rst:2279 +#: ../../whatsnew/3.4.rst:2280 msgid "" ":meth:`!importlib.util.module_for_loader` now sets ``__loader__`` and " "``__package__`` unconditionally to properly support reloading. If this is " @@ -4415,7 +4411,7 @@ msgid "" "use :func:`importlib.util.module_to_load` for module management." msgstr "" -#: ../../whatsnew/3.4.rst:2284 +#: ../../whatsnew/3.4.rst:2285 msgid "" "Import now resets relevant attributes (e.g. ``__name__``, ``__loader__``, " "``__package__``, ``__file__``, ``__cached__``) unconditionally when " @@ -4428,7 +4424,7 @@ msgstr "" "舞いと同じものを復元するものであるということを注記しておきます。 (:issue:" "`19413`)" -#: ../../whatsnew/3.4.rst:2289 +#: ../../whatsnew/3.4.rst:2290 msgid "" "Frozen packages no longer set ``__path__`` to a list containing the package " "name, they now set it to an empty list. The previous behavior could cause " @@ -4444,7 +4440,7 @@ msgstr "" "ジなのかそうでないのかを決める正しい方法は、 ``hasattr(module, '__path__')`` " "を使うことです。 (:issue:`18065`)" -#: ../../whatsnew/3.4.rst:2296 +#: ../../whatsnew/3.4.rst:2297 msgid "" "Frozen modules no longer define a ``__file__`` attribute. It's semantically " "incorrect for frozen modules to set the attribute as they are not loaded " @@ -4455,7 +4451,7 @@ msgid "" "use :func:`!imp.is_frozen`." msgstr "" -#: ../../whatsnew/3.4.rst:2304 +#: ../../whatsnew/3.4.rst:2305 msgid "" ":func:`py_compile.compile` now raises :exc:`FileExistsError` if the file " "path it would write to is a symlink or a non-regular file. This is to act as " @@ -4467,7 +4463,7 @@ msgstr "" "れは、警告の役割を果たすためです、インポートがファイルパスの元のファイルタイ" "プが何かによらずに、それらファイルをレギュラーファイルで上書きすることの。" -#: ../../whatsnew/3.4.rst:2309 +#: ../../whatsnew/3.4.rst:2310 msgid "" ":meth:`importlib.abc.SourceLoader.get_source` no longer raises :exc:" "`ImportError` when the source code being loaded triggers a :exc:" @@ -4488,7 +4484,7 @@ msgstr "" "ば、これら 3 つ全ての例外を捕捉するようにしてください。 (訳注: `changeset " "84172:e353f64dfd95 `_ )" -#: ../../whatsnew/3.4.rst:2318 +#: ../../whatsnew/3.4.rst:2319 msgid "" ":func:`functools.update_wrapper` and :func:`functools.wraps` now correctly " "set the ``__wrapped__`` attribute to the function being wrapped, even if " @@ -4513,7 +4509,7 @@ msgstr "" "AttributeError になります。今回のこの修正で ``my_func.__wrapped__." "__wrapped__`` は期待通りに振舞います。 ---)" -#: ../../whatsnew/3.4.rst:2328 +#: ../../whatsnew/3.4.rst:2329 msgid "" ":func:`inspect.getfullargspec` has been reimplemented on top of :func:" "`inspect.signature` and hence handles a much wider variety of callable " @@ -4530,7 +4526,7 @@ msgstr "" "ます。 :func:`inspect.getfullargspec` が非 Python callable で失敗することを前" "提としたコードは、適宜調整の必要があるかもしれません。" -#: ../../whatsnew/3.4.rst:2336 +#: ../../whatsnew/3.4.rst:2337 msgid "" ":class:`importlib.machinery.PathFinder` now passes on the current working " "directory to objects in :data:`sys.path_hooks` for the empty string. This " @@ -4553,7 +4549,7 @@ msgstr "" "直接実行された際の ``__main__.__file__`` を除きます (Contributed by Brett " "Cannon in :issue:`18416`))。 (:issue:`18416`)" -#: ../../whatsnew/3.4.rst:2347 +#: ../../whatsnew/3.4.rst:2348 msgid "" "The removal of the *strict* argument to :class:`~http.client.HTTPConnection` " "and :class:`~http.client.HTTPSConnection` changes the meaning of the " @@ -4567,7 +4563,7 @@ msgstr "" "奨警告に注意を払ってきたのであれば、あなたのコードは既に全てのオプショナル引" "数をキーワードで渡しているはずです。" -#: ../../whatsnew/3.4.rst:2353 +#: ../../whatsnew/3.4.rst:2354 msgid "" "Strings between ``from __future__ import ...`` statements now *always* raise " "a :exc:`SyntaxError`. Previously if there was no leading docstring, an " @@ -4581,7 +4577,7 @@ msgstr "" "せず無視される場合がありました。この修正は CPython を言語仕様に準拠させるもの" "です。Jython と PyPy では既にこれが行われています。 (:issue:`17434`)" -#: ../../whatsnew/3.4.rst:2359 +#: ../../whatsnew/3.4.rst:2360 msgid "" ":meth:`ssl.SSLSocket.getpeercert` and :meth:`ssl.SSLSocket.do_handshake` now " "raise an :exc:`OSError` with ``ENOTCONN`` when the ``SSLSocket`` is not " @@ -4595,7 +4591,7 @@ msgstr "" "meth:`~ssl.SSLSocket.getpeercert` はハンドシェイクが未実施の場合に :exc:" "`ValueError` を投げるようになりました。" -#: ../../whatsnew/3.4.rst:2365 +#: ../../whatsnew/3.4.rst:2366 msgid "" ":func:`base64.b32decode` now raises a :exc:`binascii.Error` when the input " "string contains non-b32-alphabet characters, instead of a :exc:`TypeError`. " @@ -4611,7 +4607,7 @@ msgstr "" "性を保てないので本来メンテナンスリリースの Python 3.3 には入るべきではなかっ" "たのですが、不注意で Python 3.3.3 にも行われてしまいました。" -#: ../../whatsnew/3.4.rst:2372 +#: ../../whatsnew/3.4.rst:2373 msgid "" "The :attr:`!file` attribute is now automatically closed when the creating :" "class:`!cgi.FieldStorage` instance is garbage collected. If you were pulling " @@ -4621,7 +4617,7 @@ msgid "" "the :class:`!cgi.FieldStorage` instance is garbage collected." msgstr "" -#: ../../whatsnew/3.4.rst:2379 +#: ../../whatsnew/3.4.rst:2380 msgid "" "Calling ``read`` or ``write`` on a closed SSL socket now raises an " "informative :exc:`ValueError` rather than the previous more mysterious :exc:" @@ -4631,7 +4627,7 @@ msgstr "" "ようなミステリアスな :exc:`AttributeError` ではなく、役に立つ :exc:" "`ValueError` を投げるようになりました。 (:issue:`9177`)" -#: ../../whatsnew/3.4.rst:2383 +#: ../../whatsnew/3.4.rst:2384 msgid "" ":meth:`slice.indices` no longer produces an :exc:`OverflowError` for huge " "values. As a consequence of this fix, :meth:`slice.indices` now raises a :" @@ -4643,7 +4639,7 @@ msgstr "" "`ValueError` を投げるようになっています。以前はこれは馬鹿げた値を返していまし" "た。 (:issue:`14794`)" -#: ../../whatsnew/3.4.rst:2388 +#: ../../whatsnew/3.4.rst:2389 msgid "" "The :class:`complex` constructor, unlike the :mod:`cmath` functions, was " "incorrectly accepting :class:`float` values if an object's ``__complex__`` " @@ -4655,7 +4651,7 @@ msgstr "" "`complex` コンストラクタでは受け容れられていましたが、これはいずれも :exc:" "`TypeError` となるように改められました。(:issue:`16290`.)" -#: ../../whatsnew/3.4.rst:2393 +#: ../../whatsnew/3.4.rst:2394 msgid "" "The :class:`int` constructor in 3.2 and 3.3 erroneously accepts :class:" "`float` values for the *base* parameter. It is unlikely anyone was doing " @@ -4666,7 +4662,7 @@ msgstr "" "いですが、そうしていたなら今後は :exc:`TypeError` になります。 (:issue:" "`16772`)" -#: ../../whatsnew/3.4.rst:2397 +#: ../../whatsnew/3.4.rst:2398 msgid "" "Defaults for keyword-only arguments are now evaluated *after* defaults for " "regular keyword arguments, instead of before. Hopefully no one wrote any " @@ -4677,7 +4673,7 @@ msgstr "" "バギーな振る舞いに頼っちゃうおバカなコードを書いていませんように。願います。 " "(:issue:`16967`)" -#: ../../whatsnew/3.4.rst:2401 +#: ../../whatsnew/3.4.rst:2402 msgid "" "Stale thread states are now cleared after :func:`~os.fork`. This may cause " "some system resources to be released that previously were incorrectly kept " @@ -4689,14 +4685,14 @@ msgstr "" "(たとえば、スレッドローカル記憶内に維持されたデータベース接続) が解放されるよ" "うになります。 (:issue:`17094`.)" -#: ../../whatsnew/3.4.rst:2406 +#: ../../whatsnew/3.4.rst:2407 msgid "" "Parameter names in ``__annotations__`` dicts are now mangled properly, " "similarly to :attr:`~function.__kwdefaults__`. (Contributed by Yury " "Selivanov in :issue:`20625`.)" msgstr "" -#: ../../whatsnew/3.4.rst:2410 +#: ../../whatsnew/3.4.rst:2411 msgid "" ":attr:`hashlib.hash.name` now always returns the identifier in lower case. " "Previously some builtin hashes had uppercase names, but now that it is a " @@ -4706,7 +4702,7 @@ msgstr "" "いくつかの組み込みハッシュが大文字名を持っていましたが、公式インターフェイス" "であることから、命名に一貫性を持たせるようにしました。 (:issue:`18532`)" -#: ../../whatsnew/3.4.rst:2414 +#: ../../whatsnew/3.4.rst:2415 msgid "" "Because :mod:`unittest.TestSuite` now drops references to tests after they " "are run, test harnesses that reuse a :class:`~unittest.TestSuite` to re-run " @@ -4719,7 +4715,7 @@ msgid "" "__iter__`) (:issue:`11798`)." msgstr "" -#: ../../whatsnew/3.4.rst:2424 +#: ../../whatsnew/3.4.rst:2425 msgid "" ":mod:`unittest` now uses :mod:`argparse` for command line parsing. There " "are certain invalid command forms that used to work that are no longer " @@ -4733,7 +4729,7 @@ msgstr "" "なったコマンド形式は意味をなしていなかったものですから、使われていたとは思え" "ません。" -#: ../../whatsnew/3.4.rst:2429 +#: ../../whatsnew/3.4.rst:2430 msgid "" "The :func:`re.split`, :func:`re.findall`, and :func:`re.sub` functions, and " "the :meth:`~re.match.group` and :meth:`~re.match.groups` methods of " @@ -4749,13 +4745,13 @@ msgstr "" "たとえば ``bytearray`` になることに依存していたのであれば、コードを修正する必" "要があります。" -#: ../../whatsnew/3.4.rst:2436 +#: ../../whatsnew/3.4.rst:2437 msgid "" ":mod:`!audioop` functions now raise an error immediately if passed string " "input, instead of failing randomly later on (:issue:`16685`)." msgstr "" -#: ../../whatsnew/3.4.rst:2439 +#: ../../whatsnew/3.4.rst:2440 msgid "" "The new *convert_charrefs* argument to :class:`~html.parser.HTMLParser` " "currently defaults to ``False`` for backward compatibility, but will " @@ -4769,7 +4765,7 @@ msgstr "" "全ての呼び出しでこれをキーワード引数として明示することをお勧めします。 (:" "issue:`13633`)" -#: ../../whatsnew/3.4.rst:2445 +#: ../../whatsnew/3.4.rst:2446 msgid "" "Since the *digestmod* argument to the :func:`hmac.new` function will in the " "future have no default, all calls to :func:`hmac.new` should be changed to " @@ -4779,7 +4775,7 @@ msgstr "" "で、 :func:`hmac.new` 呼び出しは常に *digestmod* を明示するように修正すべきで" "す。 (:issue:`17276`)" -#: ../../whatsnew/3.4.rst:2449 +#: ../../whatsnew/3.4.rst:2450 msgid "" "Calling :func:`sysconfig.get_config_var` with the ``SO`` key, or looking " "``SO`` up in the results of a call to :func:`sysconfig.get_config_vars` is " @@ -4791,7 +4787,7 @@ msgstr "" "キーは文脈依存の ``EXT_SUFFIX`` または ``SHLIB_SUFFIX`` で置き換えられるべき" "です。 (:issue:`19555`)" -#: ../../whatsnew/3.4.rst:2454 +#: ../../whatsnew/3.4.rst:2455 msgid "" "Any calls to ``open`` functions that specify ``U`` should be modified. ``U`` " "is ineffective in Python3 and will eventually raise an error if used. " @@ -4806,7 +4802,7 @@ msgstr "" "ムを :mod:`~io.TextIOWrapper` でラップしてその *newline* 引数を使うことで、そ" "の古い Python 2 の振る舞いと同等なものを実現出来ます。 (:issue:`15204`)" -#: ../../whatsnew/3.4.rst:2461 +#: ../../whatsnew/3.4.rst:2462 msgid "" "If you use ``pyvenv`` in a script and desire that pip *not* be installed, " "you must add ``--without-pip`` to your command invocation." @@ -4815,7 +4811,7 @@ msgstr "" "を望むならば、コマンド呼び出しに ``--without-pip`` を追加しなければなりませ" "ん。" -#: ../../whatsnew/3.4.rst:2465 +#: ../../whatsnew/3.4.rst:2466 msgid "" "The default behavior of :func:`json.dump` and :func:`json.dumps` when an " "indent is specified has changed: it no longer produces trailing spaces after " @@ -4828,7 +4824,7 @@ msgstr "" "を追加しなくなりました。これはその出力のテストを空白に繊細な比較をすることで" "行っている場合にだけ問題になります。 (:issue:`16333`)" -#: ../../whatsnew/3.4.rst:2471 +#: ../../whatsnew/3.4.rst:2472 msgid "" ":mod:`doctest` now looks for doctests in extension module ``__doc__`` " "strings, so if your doctest test discovery includes extension modules that " @@ -4840,7 +4836,7 @@ msgstr "" "中で doctest のようにみえるものが含まれていると、テスト実行時にこれまで見かけ" "たことのないテスト失敗を目にするかもしれません。 (:issue:`3158`)" -#: ../../whatsnew/3.4.rst:2476 +#: ../../whatsnew/3.4.rst:2477 msgid "" "The :mod:`collections.abc` module has been slightly refactored as part of " "the Python startup improvements. As a consequence of this, it is no longer " @@ -4856,11 +4852,11 @@ msgstr "" "collections.abc`` として明示的にインポートを追加する必要があります。 (:issue:" "`20784`)" -#: ../../whatsnew/3.4.rst:2485 +#: ../../whatsnew/3.4.rst:2486 msgid "Changes in the C API" msgstr "C API の変更" -#: ../../whatsnew/3.4.rst:2487 +#: ../../whatsnew/3.4.rst:2488 msgid "" ":c:func:`PyEval_EvalFrameEx`, :c:func:`PyObject_Repr`, and :c:func:" "`PyObject_Str`, along with some other internal C APIs, now include a " @@ -4883,7 +4879,7 @@ msgstr "" "ンを発行するのを、明示的に :c:func:`PyErr_Clear` 呼び出しをすることで潰してく" "ださい。" -#: ../../whatsnew/3.4.rst:2499 +#: ../../whatsnew/3.4.rst:2500 msgid "" ":c:func:`PyErr_SetImportError` now sets :exc:`TypeError` when its **msg** " "argument is not set. Previously only ``NULL`` was returned with no exception " @@ -4893,7 +4889,7 @@ msgstr "" "`TypeError` をセットするようになりました。以前は例外をセットすることなく " "``NULL`` を返すだけでした。" -#: ../../whatsnew/3.4.rst:2503 +#: ../../whatsnew/3.4.rst:2504 msgid "" "The result of the :c:data:`PyOS_ReadlineFunctionPointer` callback must now " "be a string allocated by :c:func:`PyMem_RawMalloc` or :c:func:" @@ -4906,7 +4902,7 @@ msgstr "" "トした文字列を返さなければなりません。 :c:func:`PyMem_Malloc` や :c:func:" "`PyMem_Realloc` でアロケートした文字列はダメです。 (:issue:`16742`)" -#: ../../whatsnew/3.4.rst:2509 +#: ../../whatsnew/3.4.rst:2510 msgid "" ":c:func:`PyThread_set_key_value` now always set the value. In Python 3.3, " "the function did nothing if the key already exists (if the current value is " @@ -4916,7 +4912,7 @@ msgstr "" "Python 3.3 ではこの関数はキーが既存 (で現在値が ``NULL`` ポインタでない) の場" "合には何もしませんでした。" -#: ../../whatsnew/3.4.rst:2513 +#: ../../whatsnew/3.4.rst:2514 msgid "" "The ``f_tstate`` (thread state) field of the :c:type:`PyFrameObject` " "structure has been removed to fix a bug: see :issue:`14432` for the " @@ -4926,17 +4922,17 @@ msgstr "" "グをフィックスするために削除されました: 論拠については :issue:`14432` を参照" "してください。" -#: ../../whatsnew/3.4.rst:2518 +#: ../../whatsnew/3.4.rst:2519 msgid "Changed in 3.4.3" msgstr "3.4.3 の変更" -#: ../../whatsnew/3.4.rst:2523 +#: ../../whatsnew/3.4.rst:2524 msgid "" "PEP 476: Enabling certificate verification by default for stdlib http clients" msgstr "" "PEP 476: stdlib http クライアントが証明書の検証を行うのをデフォルトで有効化" -#: ../../whatsnew/3.4.rst:2525 +#: ../../whatsnew/3.4.rst:2526 msgid "" ":mod:`http.client` and modules which use it, such as :mod:`urllib.request` " "and :mod:`xmlrpc.client`, will now verify that the server presents a " @@ -4950,7 +4946,7 @@ msgstr "" "うかのチェックをデフォルトで行うようになりました。これは多くのアプリケーショ" "ンにとって大幅なセキュリティ改善になります。" -#: ../../whatsnew/3.4.rst:2531 +#: ../../whatsnew/3.4.rst:2532 msgid "" "For applications which require the old previous behavior, they can pass an " "alternate context::" @@ -4958,7 +4954,7 @@ msgstr "" "以前の古い振る舞いが必要なアプリケーションでは、代わりとなるコンテキストを渡" "せます::" -#: ../../whatsnew/3.4.rst:2534 +#: ../../whatsnew/3.4.rst:2535 msgid "" "import urllib.request\n" "import ssl\n" diff --git a/whatsnew/3.5.po b/whatsnew/3.5.po index 9da6d9ddb..c88d09aee 100644 --- a/whatsnew/3.5.po +++ b/whatsnew/3.5.po @@ -14,7 +14,7 @@ msgid "" msgstr "" "Project-Id-Version: Python 3.13\n" "Report-Msgid-Bugs-To: \n" -"POT-Creation-Date: 2024-09-27 14:17+0000\n" +"POT-Creation-Date: 2024-10-11 14:17+0000\n" "PO-Revision-Date: 2021-06-29 13:04+0000\n" "Last-Translator: Arihiro TAKASE, 2024\n" "Language-Team: Japanese (https://app.transifex.com/python-doc/teams/5390/" @@ -710,7 +710,7 @@ msgstr "" #: ../../whatsnew/3.5.rst:425 msgid "" "While these annotations are available at runtime through the usual :attr:" -"`__annotations__` attribute, *no automatic type checking happens at " +"`~object.__annotations__` attribute, *no automatic type checking happens at " "runtime*. Instead, it is assumed that a separate off-line type checker (e." "g. `mypy `_) will be used for on-demand source code " "analysis."