-
-
Notifications
You must be signed in to change notification settings - Fork 98
Expand file tree
/
Copy pathveryhigh.po
More file actions
578 lines (508 loc) · 27.8 KB
/
veryhigh.po
File metadata and controls
578 lines (508 loc) · 27.8 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
# SOME DESCRIPTIVE TITLE.
# Copyright (C) 2001 Python Software Foundation
# This file is distributed under the same license as the Python package.
# FIRST AUTHOR <EMAIL@ADDRESS>, YEAR.
#
# Translators:
# Rafael Fontenelle <rffontenelle@gmail.com>, 2026
#
#, fuzzy
msgid ""
msgstr ""
"Project-Id-Version: Python 3.14\n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2026-05-08 19:31+0000\n"
"PO-Revision-Date: 2026-05-08 17:16+0000\n"
"Last-Translator: Rafael Fontenelle <rffontenelle@gmail.com>, 2026\n"
"Language-Team: Chinese (China) (https://app.transifex.com/python-doc/teams/5390/zh_CN/)\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Language: zh_CN\n"
"Plural-Forms: nplurals=1; plural=0;\n"
#: ../../c-api/veryhigh.rst:8
msgid "The Very High Level Layer"
msgstr "极高层级 API"
#: ../../c-api/veryhigh.rst:10
msgid ""
"The functions in this chapter will let you execute Python source code given "
"in a file or a buffer, but they will not let you interact in a more detailed"
" way with the interpreter."
msgstr "本章节的函数将允许你执行在文件或缓冲区中提供的 Python 源代码,但它们将不允许你以更细节化的方式与解释器进行交互。"
#: ../../c-api/veryhigh.rst:14
msgid ""
"Several of these functions accept a start symbol from the grammar as a "
"parameter. The available start symbols are :c:data:`Py_eval_input`, "
":c:data:`Py_file_input`, :c:data:`Py_single_input`, and "
":c:data:`Py_func_type_input`. These are described following the functions "
"which accept them as parameters."
msgstr ""
"这些函数中有几个可以接受特定的语法起始符号作为形参。可用的起始符号有 :c:data:`Py_eval_input`, "
":c:data:`Py_file_input`, :c:data:`Py_single_input` 和 "
":c:data:`Py_func_type_input`。这些符号会在接受它们作为形参的函数中加以说明。"
#: ../../c-api/veryhigh.rst:20
msgid ""
"Note also that several of these functions take :c:expr:`FILE*` parameters. "
"One particular issue which needs to be handled carefully is that the "
":c:type:`FILE` structure for different C libraries can be different and "
"incompatible. Under Windows (at least), it is possible for dynamically "
"linked extensions to actually use different libraries, so care should be "
"taken that :c:expr:`FILE*` parameters are only passed to these functions if "
"it is certain that they were created by the same library that the Python "
"runtime is using."
msgstr ""
"还要注意这些函数中有几个可以接受 :c:expr:`FILE*` 形参。有一个需要小心处理的特别问题是针对不同 C 库的 :c:type:`FILE` "
"结构体可能是不相同且不兼容的。 (至少是)在 Windows 中,动态链接的扩展实际上有可能会使用不同的库,所以应当特别注意只有在确定这些函数是由 "
"Python 运行时所使用的相同的库创建的情况下才将 :c:expr:`FILE*` 形参传给它们。"
#: ../../c-api/veryhigh.rst:31
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:37
msgid ""
"This is a simplified interface to :c:func:`PyRun_AnyFileExFlags` below, "
"leaving the *closeit* argument set to ``0``."
msgstr "这是针对下面 :c:func:`PyRun_AnyFileExFlags` 的简化版接口,将 *closeit* 参数设为 ``0``。"
#: ../../c-api/veryhigh.rst:43
msgid ""
"This is a simplified interface to :c:func:`PyRun_AnyFileExFlags` below, "
"leaving the *flags* argument set to ``NULL``."
msgstr "这是针对下面 :c:func:`PyRun_AnyFileExFlags` 的简化版接口,将 *flags* 参数设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:49
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:`PyRun_InteractiveLoop`, otherwise return the result of "
":c:func:`PyRun_SimpleFile`. *filename* is decoded from the filesystem "
"encoding (:func:`sys.getfilesystemencoding`). If *filename* is ``NULL``, "
"this function uses ``\"???\"`` as the filename. If *closeit* is true, the "
"file is closed before ``PyRun_SimpleFileExFlags()`` returns."
msgstr ""
"如果 *fp* 指向一个关联到交互设备(控制台或终端输入或 Unix 伪终端)的文件,则返回 "
":c:func:`PyRun_InteractiveLoop` 的值,否则返回 :c:func:`PyRun_SimpleFile` 的结果。 "
"*filename* 会使用文件系统的编码格式 (:func:`sys.getfilesystemencoding`) 来解码。如果 "
"*filename* 为 ``NULL``,此函数会使用 ``\"???\"`` 作为文件名。如果 *closeit* 为真值,文件会在 "
"``PyRun_SimpleFileExFlags()`` 返回之前被关闭。"
#: ../../c-api/veryhigh.rst:61
msgid ""
"This is a simplified interface to :c:func:`PyRun_SimpleStringFlags` below, "
"leaving the :c:struct:`PyCompilerFlags`\\* argument set to ``NULL``."
msgstr ""
"这是针对下面 :c:func:`PyRun_SimpleStringFlags` 的简化版接口,将 "
":c:struct:`PyCompilerFlags`\\* 参数设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:67
msgid ""
"Executes the Python source code from *command* in the :mod:`__main__` module"
" according to the *flags* argument. If :mod:`__main__` does not already "
"exist, it is created. Returns ``0`` on success or ``-1`` if an exception "
"was raised. If there was an error, there is no way to get the exception "
"information. For the meaning of *flags*, see below."
msgstr ""
"根据 *flags* 参数,在 :mod:`__main__` 模块中执行 Python 源代码。如果 :mod:`__main__` "
"尚不存在,它将被创建。成功时返回 ``0``,如果引发异常则返回 ``-1``。如果发生错误,则将无法获得异常信息。对于 *flags* "
"的含义,请参阅下文。"
#: ../../c-api/veryhigh.rst:73
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 ""
"请注意如果引发了一个在其他场合下未处理的 :exc:`SystemExit`,此函数将不会返回 ``-1``,而是退出进程,只要 "
":c:member:`PyConfig.inspect` 为零就会这样。"
#: ../../c-api/veryhigh.rst:80
msgid ""
"This is a simplified interface to :c:func:`PyRun_SimpleFileExFlags` below, "
"leaving *closeit* set to ``0`` and *flags* set to ``NULL``."
msgstr ""
"这是针对下面 :c:func:`PyRun_SimpleFileExFlags` 的简化版接口,将 *closeit* 设为 ``0`` 而将 "
"*flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:86
msgid ""
"This is a simplified interface to :c:func:`PyRun_SimpleFileExFlags` below, "
"leaving *flags* set to ``NULL``."
msgstr ""
"这是针对下面 :c:func:`PyRun_SimpleFileExFlags` 的简化版接口,将 *flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:92
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"
" of the file, it is decoded from :term:`filesystem encoding and error "
"handler`. If *closeit* is true, the file is closed before "
"``PyRun_SimpleFileExFlags()`` returns."
msgstr ""
"类似于 :c:func:`PyRun_SimpleStringFlags`,但 Python 源代码是从 *fp* 读取而不是一个内存中的字符串。 "
"*filename* 应为文件名,它将使用 :term:`filesystem encoding and error handler` 来解码。如果 "
"*closeit* 为真值,则文件将在 ``PyRun_SimpleFileExFlags()`` 返回之前被关闭。"
#: ../../c-api/veryhigh.rst:99
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"
" correctly."
msgstr ""
"在 Windows 上,*fp* 应当以二进制模式打开 (即 ``fopen(filename, \"rb\")``)。否则,Python "
"可能无法正确地处理使用 LF 行结束符的脚本文件。"
#: ../../c-api/veryhigh.rst:105
msgid ""
"Read and execute a single statement from a file associated with an "
"interactive device according to the *flags* argument. The user will be "
"prompted using ``sys.ps1`` and ``sys.ps2``. *filename* must be a Python "
":class:`str` object."
msgstr ""
"根据 *flags* 参数读取并执行来自与交互设备相关联的文件的一条语句。用户将得到使用 ``sys.ps1`` 和 ``sys.ps2`` 的提示。 "
"*filename* 必须是一个 Python :class:`str` 对象。"
#: ../../c-api/veryhigh.rst:110
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 "
"distributed as part of Python if there was a parse error. (Note that "
":file:`errcode.h` is not included by :file:`Python.h`, so must be included "
"specifically if needed.)"
msgstr ""
"当输入被成功执行时返回 ``0``,如果引发异常则返回 ``-1``,或者如果存在解析错误则返回来自作为 Python 的组成部分发布的 "
":file:`errcode.h` 包含文件的错误代码。 (请注意 :file:`errcode.h` 并未被 :file:`Python.h` "
"所包含,因此如果需要则必须专门地包含。)"
#: ../../c-api/veryhigh.rst:119
msgid ""
"This is a simplified interface to :c:func:`PyRun_InteractiveOneFlags` below,"
" leaving *flags* set to ``NULL``."
msgstr ""
"这是针对下面 :c:func:`PyRun_InteractiveOneFlags` 的简化版接口,将 *flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:125
msgid ""
"Similar to :c:func:`PyRun_InteractiveOneObject`, but *filename* is a "
":c:expr:`const char*`, which is decoded from the :term:`filesystem encoding "
"and error handler`."
msgstr ""
"类似于 :c:func:`PyRun_InteractiveOneObject`,但 *filename* 是一个 :c:expr:`const "
"char*`,它使用 :term:`filesystem encoding and error handler` 来解码。"
#: ../../c-api/veryhigh.rst:132
msgid ""
"This is a simplified interface to :c:func:`PyRun_InteractiveLoopFlags` "
"below, leaving *flags* set to ``NULL``."
msgstr ""
"这是针对下面 :c:func:`PyRun_InteractiveLoopFlags` 的简化版接口,将 *flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:138
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`` "
"and ``sys.ps2``. *filename* is decoded from the :term:`filesystem encoding "
"and error handler`. Returns ``0`` at EOF or a negative number upon failure."
msgstr ""
"读取并执行来自与交互设备相关联的语句直至到达 EOF。用户将得到使用 ``sys.ps1`` 和 ``sys.ps2`` 的提示。 *filename*"
" 将使用 :term:`filesystem encoding and error handler` 来解码。当位于 EOF 时将返回 "
"``0``,或者当失败时将返回一个负数。"
#: ../../c-api/veryhigh.rst:146
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 "
"become idle and wait for user input from the terminal. The return value is "
"ignored. Overriding this hook can be used to integrate the interpreter's "
"prompt with other event loops, as done in :file:`Modules/_tkinter.c` in the "
"Python source code."
msgstr ""
"可以设为指向一个原型为 ``int func(void)`` 的函数。该函数将在 Python 的解释器提示符即将空闲并等待用户从终端输入时被调用。 "
"返回值会被忽略。重写这个钩子可被用来将解释器的提示符集成到其他事件循环中,就像 Python 源代码中 "
":file:`Modules/_tkinter.c` 所做的那样。"
#: ../../c-api/veryhigh.rst:154 ../../c-api/veryhigh.rst:178
msgid ""
"This function is only called from the :ref:`main interpreter <sub-"
"interpreter-support>`."
msgstr "此函数只能被 :ref:`主解释器 <sub-interpreter-support>` 调用。"
#: ../../c-api/veryhigh.rst:161
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 "
"to read a single line of input at the interpreter's prompt. The function is"
" expected to output the string *prompt* if it's not ``NULL``, and then read "
"a line of input from the provided standard input file, returning the "
"resulting string. For example, The :mod:`readline` module sets this hook to"
" provide line-editing and tab-completion features."
msgstr ""
"可以被设为指向一个原型为 ``char *func(FILE *stdin, FILE *stdout, char *prompt)`` "
"的函数,重写被用来读取解释器提示符的一行输入的默认函数。该函数被预期为如果字符串 *prompt* 不为 ``NULL`` "
"就输出它,然后从所提供的标准输入文件读取一行输入,并返回结果字符串。例如,:mod:`readline` 模块将这个钩子设置为提供行编辑和 tab "
"键补全等功能。"
#: ../../c-api/veryhigh.rst:170
msgid ""
"The result must be a string allocated by :c:func:`PyMem_RawMalloc` or "
":c:func:`PyMem_RawRealloc`, or ``NULL`` if an error occurred."
msgstr ""
"结果必须是一个由 :c:func:`PyMem_RawMalloc` 或 :c:func:`PyMem_RawRealloc` "
"分配的字符串,或者如果发生错误则为 ``NULL``。"
#: ../../c-api/veryhigh.rst:173
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 :c:func:`PyMem_Realloc`."
msgstr ""
"结果必须由 :c:func:`PyMem_RawMalloc` 或 :c:func:`PyMem_RawRealloc` 分配,而不是由 "
":c:func:`PyMem_Malloc` 或 :c:func:`PyMem_Realloc` 分配。"
#: ../../c-api/veryhigh.rst:184
msgid ""
"This is a simplified interface to :c:func:`PyRun_StringFlags` below, leaving"
" *flags* set to ``NULL``."
msgstr "这是针对下面 :c:func:`PyRun_StringFlags` 的简化版接口,将 *flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:190
msgid ""
"Execute Python source code from *str* in the context specified by the "
"objects *globals* and *locals* with the compiler flags specified by *flags*."
" *globals* must be a dictionary; *locals* can be any object that implements"
" the mapping protocol. The parameter *start* specifies the start symbol and"
" must be one of the :ref:`available start symbols <start-symbols>`."
msgstr ""
"在由 *globals* 和 *locals* 对象指定的上下文中执行 *str* 中的 Python 源代码并使用由 *flags* "
"指定的编译器旗标。 *globals* 必须是一个字典;*locals* 可以是任何实现了映射协议的对象。 形参 *start* 指定起始符号并且必须是"
" :ref:`可用的起始符号 <start-symbols>` 之一。"
#: ../../c-api/veryhigh.rst:196
msgid ""
"Returns the result of executing the code as a Python object, or ``NULL`` if "
"an exception was raised."
msgstr "返回将代码作为 Python 对象执行的结果,或者如果引发了异常则返回 ``NULL``。"
#: ../../c-api/veryhigh.rst:202
msgid ""
"This is a simplified interface to :c:func:`PyRun_FileExFlags` below, leaving"
" *closeit* set to ``0`` and *flags* set to ``NULL``."
msgstr ""
"这是针对下面 :c:func:`PyRun_FileExFlags` 的简化版接口,将 *closeit* 设为 ``0`` 并将 *flags* 设为"
" ``NULL``."
#: ../../c-api/veryhigh.rst:208
msgid ""
"This is a simplified interface to :c:func:`PyRun_FileExFlags` below, leaving"
" *flags* set to ``NULL``."
msgstr "这是针对下面 :c:func:`PyRun_FileExFlags` 的简化版接口,将 *flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:214
msgid ""
"This is a simplified interface to :c:func:`PyRun_FileExFlags` below, leaving"
" *closeit* set to ``0``."
msgstr "这是针对下面 :c:func:`PyRun_FileExFlags` 的简化版接口,将 *closeit* 设为 ``0``。"
#: ../../c-api/veryhigh.rst:220
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 "
"the file, it is decoded from the :term:`filesystem encoding and error "
"handler`. If *closeit* is true, the file is closed before "
":c:func:`PyRun_FileExFlags` returns."
msgstr ""
"类似于 :c:func:`PyRun_StringFlags`,但 Python 源代码是从 *fp* 读取而不是一个内存中的字符串。 "
"*filename* 应为文件名,它将使用 :term:`filesystem encoding and error handler` 来解码。如果 "
"*closeit* 为真值,则文件将在 :c:func:`PyRun_FileExFlags` 返回之前被关闭。"
#: ../../c-api/veryhigh.rst:229
msgid ""
"This is a simplified interface to :c:func:`Py_CompileStringFlags` below, "
"leaving *flags* set to ``NULL``."
msgstr "这是针对下面 :c:func:`Py_CompileStringFlags` 的简化版接口,将 *flags* 设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:235
msgid ""
"This is a simplified interface to :c:func:`Py_CompileStringExFlags` below, "
"with *optimize* set to ``-1``."
msgstr ""
"这是针对下面 :c:func:`Py_CompileStringExFlags` 的简化版接口,将 *optimize* 设为 ``-1``。"
#: ../../c-api/veryhigh.rst:241
msgid ""
"Parse and compile the Python source code in *str*, returning the resulting "
"code object. The start symbol is given by *start*; this can be used to "
"constrain the code which can be compiled and should be :ref:`available start"
" symbols <start-symbols>`. The filename specified by *filename* is used to "
"construct the code object and may appear in tracebacks or :exc:`SyntaxError`"
" exception messages. This returns ``NULL`` if the code cannot be parsed or "
"compiled."
msgstr ""
"解析并编译 *str* 中的 Python 源代码,返回结果代码对象。起始符号由 *start* 给出;这可用于约束可编译的代码并且应当是 "
":ref:`可用的起始符号 <start-symbols>`。由 *filename* 指定的文件名将被用来构建代码对象并可能出现在回溯或 "
":exc:`SyntaxError` 异常消息中。如果代码无法被解析或编译则返回 ``NULL``。"
#: ../../c-api/veryhigh.rst:249
msgid ""
"The integer *optimize* specifies the optimization level of the compiler; a "
"value of ``-1`` selects the optimization level of the interpreter as given "
"by :option:`-O` options. Explicit levels are ``0`` (no optimization; "
"``__debug__`` is true), ``1`` (asserts are removed, ``__debug__`` is false) "
"or ``2`` (docstrings are removed too)."
msgstr ""
"整数 *optimize* 指定编译器的优化级别;值 ``-1`` 将选择与 :option:`-O` 选项相同的解释器优化级别。显式级别为 ``0``"
" (无优化;``__debug__`` 为真值)、``1`` (断言被移除,``__debug__`` 为假值) 或 ``2`` "
"(文档字符串也被移除)。"
#: ../../c-api/veryhigh.rst:260
msgid ""
"Like :c:func:`Py_CompileStringObject`, but *filename* is a byte string "
"decoded from the :term:`filesystem encoding and error handler`."
msgstr ""
"与 :c:func:`Py_CompileStringObject` 类似,但 *filename* 是一个字节串,使用 "
":term:`filesystem encoding and error handler` 来解码。"
#: ../../c-api/veryhigh.rst:267
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 ``NULL``."
msgstr ""
"这是针对 :c:func:`PyEval_EvalCodeEx` 的简化版接口,只附带代码对象,以及全局和局部变量。其他参数均设为 ``NULL``。"
#: ../../c-api/veryhigh.rst:274
msgid ""
"Evaluate a precompiled code object, given a particular environment for its "
"evaluation. This environment consists of a dictionary of global variables, "
"a mapping object of local variables, arrays of arguments, keywords and "
"defaults, a dictionary of default values for :ref:`keyword-only <keyword-"
"only_parameter>` arguments and a closure tuple of cells."
msgstr ""
"对一个预编译的代码对象求值,为其求值给出特定的环境。此环境由全局变量的字典,局部变量映射对象,参数、关键字和默认值的数组,:ref:`仅限关键字 "
"<keyword-only_parameter>` 参数的默认值的字典和单元的封闭元组构成。"
#: ../../c-api/veryhigh.rst:283
msgid ""
"Evaluate an execution frame. This is a simplified interface to "
":c:func:`PyEval_EvalFrameEx`, for backward compatibility."
msgstr "对一个执行帧求值。这是针对 :c:func:`PyEval_EvalFrameEx` 的简化版接口,用于保持向下兼容性。"
#: ../../c-api/veryhigh.rst:289
msgid ""
"This is the main, unvarnished function of Python interpretation. The code "
"object associated with the execution frame *f* is executed, interpreting "
"bytecode and executing calls as needed. The additional *throwflag* "
"parameter can mostly be ignored - if true, then it causes an exception to "
"immediately be thrown; this is used for the :meth:`~generator.throw` methods"
" of generator objects."
msgstr ""
"这是 Python 解释运行不带修饰的主函数。与执行帧 *f* 相关联的代码对象将被执行,解释字节码并根据需要执行调用。额外的 *throwflag* "
"形参基本可以被忽略 —— 如果为真值,则会导致立即抛出一个异常;这会被用于生成器对象的 :meth:`~generator.throw` 方法。"
#: ../../c-api/veryhigh.rst:296
msgid ""
"This function now includes a debug assertion to help ensure that it does not"
" silently discard an active exception."
msgstr "该函数现在包含一个调试断言,用以确保不会静默地丢弃活动的异常。"
#: ../../c-api/veryhigh.rst:303
msgid ""
"This function changes the flags of the current evaluation frame, and returns"
" true on success, false on failure."
msgstr "此函数会修改当前求值帧的旗标,并在成功时返回真值,失败时返回假值。"
#: ../../c-api/veryhigh.rst:309
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 "
"is being executed, it is passed as ``PyCompilerFlags *flags``. In this "
"case, ``from __future__ import`` can modify *flags*."
msgstr ""
"这是用来存放编译器旗标的结构体。对于代码仅被编译的情况,它将作为 ``int flags`` 传入,而对于代码要被执行的情况,它将作为 "
"``PyCompilerFlags *flags`` 传入。在这种情况下,``from __future__ import`` 可以修改 "
"*flags*."
#: ../../c-api/veryhigh.rst:314
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 ""
"只要 ``PyCompilerFlags *flags`` 是 "
"``NULL``,:c:member:`~PyCompilerFlags.cf_flags` 就会被视为等同于 ``0``,而由于 ``from "
"__future__ import`` 而产生的任何修改都会被丢弃。"
#: ../../c-api/veryhigh.rst:320
msgid "Compiler flags."
msgstr "编译器旗标。"
#: ../../c-api/veryhigh.rst:324
msgid ""
"*cf_feature_version* is the minor Python version. It should be initialized "
"to ``PY_MINOR_VERSION``."
msgstr "*cf_feature_version* 是 Python 的小版本号。它应当被初始化为 ``PY_MINOR_VERSION``。"
#: ../../c-api/veryhigh.rst:327
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:member:`~PyCompilerFlags.cf_flags` 中设置了 ``PyCF_ONLY_AST``"
" 旗标时它才会被使用。"
#: ../../c-api/veryhigh.rst:330
msgid "Added *cf_feature_version* field."
msgstr "增加了 *cf_feature_version* 字段。"
#: ../../c-api/veryhigh.rst:333
msgid "The available compiler flags are accessible as macros:"
msgstr "现有的编译器旗标可作为宏来使用:"
#: ../../c-api/veryhigh.rst:342
msgid ""
"See :ref:`compiler flags <ast-compiler-flags>` in documentation of the "
":py:mod:`!ast` Python module, which exports these constants under the same "
"names."
msgstr ""
"请参阅 :py:mod:`!ast` Python 模块文档中的 :ref:`编译器旗标 <ast-compiler-"
"flags>`,它们会将这些常量以相同的名称导出。"
#: ../../c-api/veryhigh.rst:346
msgid ""
"The \"``PyCF``\" flags above can be combined with \"``CO_FUTURE``\" flags "
"such as :c:macro:`CO_FUTURE_ANNOTATIONS` to enable features normally "
"selectable using :ref:`future statements <future>`. See "
":ref:`c_codeobject_flags` for a complete list."
msgstr ""
"上述 \"``PyCF``\" 旗标可与 \"``CO_FUTURE``\" 类旗标如 :c:macro:`CO_FUTURE_ANNOTATIONS`"
" 组合使用,以启用通常通过 :ref:`future 语句 <future>` 选择的功能特性。完整旗标列表请参见 "
":ref:`c_codeobject_flags`."
#: ../../c-api/veryhigh.rst:355
msgid "Available start symbols"
msgstr "可用的起始符号"
#: ../../c-api/veryhigh.rst:362
msgid ""
"The start symbol from the Python grammar for isolated expressions; for use "
"with :c:func:`Py_CompileString`."
msgstr "Python 语法中用于孤立表达式的起始符号;配合 :c:func:`Py_CompileString` 使用。"
#: ../../c-api/veryhigh.rst:370
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"
" is the symbol to use when compiling arbitrarily long Python source code."
msgstr ""
"Python 语法中用于从文件或其他源读取语句序列的起始符号;配合 :c:func:`Py_CompileString` 使用。这是在编译任意长的 "
"Python 源代码时要使用的符号。"
#: ../../c-api/veryhigh.rst:379
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"
" interpreter loop."
msgstr ""
"Python 语法中用于单独语句的起始符号;配合 :c:func:`Py_CompileString` 使用。这是用于交互式解释器循环的符号。"
#: ../../c-api/veryhigh.rst:388
msgid ""
"The start symbol from the Python grammar for a function type; for use with "
":c:func:`Py_CompileString`. This is used to parse \"signature type "
"comments\" from :pep:`484`."
msgstr ""
"Python 语法中用于函数类型的起始符号;配合 :c:func:`Py_CompileString` 使用。这是用于解析来自 :pep:`484` 的"
" \"签名类型注释\"。"
#: ../../c-api/veryhigh.rst:392
msgid "This requires the :c:macro:`PyCF_ONLY_AST` flag to be set."
msgstr "这需要设置 :c:macro:`PyCF_ONLY_AST` 旗标。"
#: ../../c-api/veryhigh.rst:395
msgid ":py:class:`ast.FunctionType`"
msgstr ":py:class:`ast.FunctionType`"
#: ../../c-api/veryhigh.rst:396
msgid ":pep:`484`"
msgstr ":pep:`484`"
#: ../../c-api/veryhigh.rst:402
msgid "Stack Effects"
msgstr "栈影响"
#: ../../c-api/veryhigh.rst:405
msgid ":py:func:`dis.stack_effect`"
msgstr ":py:func:`dis.stack_effect`"
#: ../../c-api/veryhigh.rst:410
msgid "Sentinel value representing an invalid stack effect."
msgstr "代表无效栈影响的哨兵值。"
#: ../../c-api/veryhigh.rst:412
msgid "This is currently equivalent to ``INT_MAX``."
msgstr "目前这等价于 ``INT_MAX``。"
#: ../../c-api/veryhigh.rst:419
msgid "Compute the stack effect of *opcode* with argument *oparg*."
msgstr "使用参数 *oparg* 计算 *opcode* 的栈影响。"
#: ../../c-api/veryhigh.rst:421 ../../c-api/veryhigh.rst:435
msgid ""
"On success, this function returns the stack effect; on failure, this returns"
" :c:macro:`PY_INVALID_STACK_EFFECT`."
msgstr "成功时,此函数返回栈影响;失败时,则返回 :c:macro:`PY_INVALID_STACK_EFFECT`。"
#: ../../c-api/veryhigh.rst:429
msgid ""
"Similar to :c:func:`PyCompile_OpcodeStackEffect`, but don't include the "
"stack effect of jumping if *jump* is zero."
msgstr "类似于 :c:func:`PyCompile_OpcodeStackEffect`,但不包括当 *jump* 为零时的跳转的栈影响。"
#: ../../c-api/veryhigh.rst:432
msgid ""
"If *jump* is ``0``, this will not include the stack effect of jumping, but "
"if *jump* is ``1`` or ``-1``, this will include it."
msgstr "如果 *jump* 为 ``0``,这将不包括跳转的栈影响,但如果 *jump* 为 ``1`` 或 ``-1``,这将会包括它。"
#: ../../c-api/veryhigh.rst:360 ../../c-api/veryhigh.rst:368
#: ../../c-api/veryhigh.rst:377 ../../c-api/veryhigh.rst:386
msgid "Py_CompileString (C function)"
msgstr "Py_CompileString (C 函数)"