@@ -399,12 +399,14 @@ msgid ""
399
399
"indexing or slicing non-BMP characters returns the expected value, so "
400
400
"``'\\ U0010FFFF'[0]`` now returns ``'\\ U0010FFFF'`` and not ``'\\ uDBFF'``;"
401
401
msgstr ""
402
+ "索引或切分非 BMP 字符会返回预期的值,因此 ``'\\ U0010FFFF'[0]`` 现在会返回 ``'\\ U0010FFFF'`` 而不是 "
403
+ "``'\\ uDBFF'``;"
402
404
403
405
#: ../../whatsnew/3.3.rst:248
404
406
msgid ""
405
407
"all other functions in the standard library now correctly handle non-BMP "
406
408
"code points."
407
- msgstr ""
409
+ msgstr "标准库中的所有其他函数现在都能正确处理非 BMP 代码点。 "
408
410
409
411
#: ../../whatsnew/3.3.rst:251
410
412
msgid ""
@@ -416,22 +418,22 @@ msgstr ""
416
418
417
419
#: ../../whatsnew/3.3.rst:256
418
420
msgid "The :file:`./configure` flag ``--with-wide-unicode`` has been removed."
419
- msgstr ""
421
+ msgstr ":file:`./configure` 标志 ``--with-wide-unicode`` 已被移除。 "
420
422
421
423
#: ../../whatsnew/3.3.rst:259
422
424
msgid "Performance and resource usage"
423
- msgstr ""
425
+ msgstr "性能和资源使用情况 "
424
426
425
427
#: ../../whatsnew/3.3.rst:261
426
428
msgid ""
427
429
"The storage of Unicode strings now depends on the highest code point in the "
428
430
"string:"
429
- msgstr ""
431
+ msgstr "现在,Unicode 字符串的存储取决于字符串中的最高码位: "
430
432
431
433
#: ../../whatsnew/3.3.rst:263
432
434
msgid ""
433
435
"pure ASCII and Latin1 strings (``U+0000-U+00FF``) use 1 byte per code point;"
434
- msgstr ""
436
+ msgstr "纯 ASCII 和 Latin1 字符串 (``U+0000-U+00FF``) 每个码位使用 1 个字节; "
435
437
436
438
#: ../../whatsnew/3.3.rst:265
437
439
msgid "BMP strings (``U+0000-U+FFFF``) use 2 bytes per code point;"
@@ -453,6 +455,10 @@ msgid ""
453
455
"than Python 3.2, and a little bit better than Python 2.7, on a Django "
454
456
"benchmark (see the PEP for details)."
455
457
msgstr ""
458
+ "这样做的效果是,对于大多数应用而言,字符串存储的内存使用量应该会大幅减少 —— 尤其是与以前的宽 unicode 版本相比 —— "
459
+ "因为在许多情况下,即使在国际环境中,字符串也将是纯 ASCII 格式(因为许多字符串存储的是非人类语言数据,如 XML 片段、HTTP 标头、JSON "
460
+ "编码数据等)。 出于同样的原因,我们还希望它能提高非小应用程序的 CPU 缓存效率。 在 Django 基准测试中,Python 3.3 的内存使用量比"
461
+ " Python 3.2 少两到三倍,比 Python 2.7 略好一些(详情请参见 PEP)。"
456
462
457
463
#: ../../whatsnew/3.3.rst:283
458
464
msgid ":pep:`393` - Flexible String Representation"
@@ -474,6 +480,7 @@ msgid ""
474
480
"that can be used to launch Python applications in a version independent "
475
481
"fashion."
476
482
msgstr ""
483
+ "Python 3.3 的 Windows 安装程序现在包含一个 ``py`` 启动程序,可用于以版本无关的方式启动 Python 应用程序。"
477
484
478
485
#: ../../whatsnew/3.3.rst:296
479
486
msgid ""
@@ -483,6 +490,8 @@ msgid ""
483
490
" version is used by default, but this can be overridden by including a Unix-"
484
491
"style \" shebang line\" in the Python script."
485
492
msgstr ""
493
+ "双击 ``*.py`` 文件时会隐式调用该启动器。 如果系统中只安装了一个 Python 版本,则将使用该版本运行文件。 "
494
+ "如果安装了多个版本,则默认使用最新版本,但也可以通过在 Python 脚本中加入 Unix 风格的“shebang 行”来覆盖该版本。"
486
495
487
496
#: ../../whatsnew/3.3.rst:302
488
497
msgid ""
@@ -493,13 +502,18 @@ msgid ""
493
502
"Python 2 is also installed, or ``-2.6`` to specifically request an earlier "
494
503
"Python version when a more recent version is installed)."
495
504
msgstr ""
505
+ "启动器也可以作为 ``py`` 应用程序在命令行中显式使用。运行 ``py`` "
506
+ "遵循与隐式启动脚本相同的版本选择规则,但可以通过传递适当的参数来选择更具体的版本(例如,当 Python 2 也已安装时,使用 ``-3`` 来请求 "
507
+ "Python 3;当安装了较新的 Python 版本时,使用 ``-2.6`` 来特别请求较早的 Python 版本)。"
496
508
497
509
#: ../../whatsnew/3.3.rst:309
498
510
msgid ""
499
511
"In addition to the launcher, the Windows installer now includes an option to"
500
512
" add the newly installed Python to the system PATH. (Contributed by Brian "
501
513
"Curtin in :issue:`3561`.)"
502
514
msgstr ""
515
+ "除了启动器之外,Windows 安装程序现在还包含一个选项,可将新安装的 Python 添加到系统 PATH 中。 (由 Brian Curtin 在 "
516
+ ":issue:`3561` 中贡献)。"
503
517
504
518
#: ../../whatsnew/3.3.rst:317
505
519
msgid ":pep:`397` - Python Launcher for Windows"
@@ -527,7 +541,7 @@ msgstr "PEP 3151: 重写 OS 和 IO 异常的层次结构"
527
541
msgid ""
528
542
"The hierarchy of exceptions raised by operating system errors is now both "
529
543
"simplified and finer-grained."
530
- msgstr ""
544
+ msgstr "现在,由操作系统错误引发的异常层次结构既得到了简化,又更加精细。 "
531
545
532
546
#: ../../whatsnew/3.3.rst:332
533
547
msgid ""
@@ -538,6 +552,10 @@ msgid ""
538
552
":exc:`OSError`. The other names are kept as aliases for compatibility "
539
553
"reasons."
540
554
msgstr ""
555
+ "您不必再为在 "
556
+ ":exc:`OSError`、:exc:`IOError`、:exc:`EnvironmentError`、:exc:`WindowsError`、:exc:`mmap.error`、:exc:`socket.error`"
557
+ " 或 :exc:`select.error` 之间选择合适的异常类型而烦恼。 所有这些异常类型现在都只有一个: :exc:`OSError`。 "
558
+ "出于兼容性考虑,其他名称将作为别名保留。"
541
559
542
560
#: ../../whatsnew/3.3.rst:339
543
561
msgid ""
@@ -546,6 +564,8 @@ msgid ""
546
564
"constant from the :mod:`errno` module, you can catch the adequate "
547
565
":exc:`OSError` subclass. The available subclasses are the following:"
548
566
msgstr ""
567
+ "此外,现在捕捉特定错误条件也更容易了。无需从 :mod:`errno` 模块中检查 ``errno`` 属性(或 ``args[0]`` "
568
+ ")中的特定常量,您可以捕捉适当的 :exc:`OSError` 子类。可用的子类如下:"
549
569
550
570
#: ../../whatsnew/3.3.rst:344
551
571
msgid ":exc:`BlockingIOError`"
@@ -615,13 +635,13 @@ msgstr ":exc:`ConnectionResetError`"
615
635
msgid ""
616
636
"Thanks to the new exceptions, common usages of the :mod:`errno` can now be "
617
637
"avoided. For example, the following code written for Python 3.2::"
618
- msgstr ""
638
+ msgstr "有了新的异常,现在就可以避免 :mod:`errno` 的常见用法了。 例如,下面是为 Python 3.2 编写的代码: "
619
639
620
640
#: ../../whatsnew/3.3.rst:379
621
641
msgid ""
622
642
"can now be written without the :mod:`errno` import and without manual "
623
643
"inspection of exception attributes::"
624
- msgstr ""
644
+ msgstr "现在无需导入 :mod:`errno`,也无需手动检查异常属性: "
625
645
626
646
#: ../../whatsnew/3.3.rst:392
627
647
msgid ":pep:`3151` - Reworking the OS and IO Exception Hierarchy"
@@ -643,19 +663,23 @@ msgid ""
643
663
" generator. Additionally, the subgenerator is allowed to return with a "
644
664
"value, and the value is made available to the delegating generator."
645
665
msgstr ""
666
+ "PEP 380 增加了 ``yield from`` 表达式,允许 :term:`generator` 将其部分操作委托给另一个生成器。 这样,包含 "
667
+ ":keyword:`yield` 的代码部分就可以被分解出来,放在另一个生成器中。 此外,还允许子生成器返回一个值,并将该值提供给委托生成器。"
646
668
647
669
#: ../../whatsnew/3.3.rst:411
648
670
msgid ""
649
671
"While designed primarily for use in delegating to a subgenerator, the "
650
672
"``yield from`` expression actually allows delegation to arbitrary "
651
673
"subiterators."
652
- msgstr ""
674
+ msgstr "虽然 ``yield from`` 表达式主要用于委托给子生成器,但它实际上允许委托给任意子生成器。 "
653
675
654
676
#: ../../whatsnew/3.3.rst:414
655
677
msgid ""
656
678
"For simple iterators, ``yield from iterable`` is essentially just a "
657
679
"shortened form of ``for item in iterable: yield item``::"
658
680
msgstr ""
681
+ "对于简单的迭代器而言,``yield from iterable`` 本质上只是 ``for item in iterable: yield "
682
+ "item`` 的简写形式:"
659
683
660
684
#: ../../whatsnew/3.3.rst:424
661
685
msgid ""
0 commit comments