栏目分类:
子分类:
返回
名师互学网用户登录
快速导航关闭
当前搜索
当前分类
子分类
实用工具
热门搜索
名师互学网 > IT > 软件开发 > 后端开发 > Python

Python 3.7 正式发布, 大量新特性和优化

Python 更新时间: 发布时间: IT归档 最新发布 模块sitemap 名妆网 法律咨询 聚返吧 英语巴士网 伯小乐 网商动力

Python 3.7 正式发布, 大量新特性和优化

Python 3.7 已正式发布,同时发布的还有 3.6.6 , 具体详情可分别查阅更新说明:


3.7:https://www.python.org/downloads/release/python-370/


3.6.6:https://www.python.org/downloads/release/python-366/


Python 3.7 包含许多新特性和优化,亮点包括:


新语法特性:


PEP 563, 推迟评估类型注释


向后不兼容语法更改:


async 和 await 现在保留关键字


新的库模块:


contextvars: PEP 567 – Context Variables


dataclasses: PEP 557 – Data Classes


importlib.resources


新的内置功能:


PEP 553, 新的 breakpoint() 函数


数据模型改进:


PEP 562, customization of access to module attributes.


PEP 560, core support for typing module and generic types.


the insertion-order preservation nature of dict objects has been declared to be an official part of the Python language spec.


标准库重要改进:


asyncio模块性能和可用性改进


time 模块支持 nanosecond resolution


CPython 实现改进:


避免使用 ASCII 作为默认文本编码:


PEP 538, legacy C locale coercion


PEP 540, forced UTF-8 runtime mode


PEP 552, deterministic .pycs


新的 development runtime mode


PEP 565, 改进 DeprecationWarning 处理


C API 改进:


PEP 539, 用于 thread-local 存储的新的 C API


文档改进:


PEP 545,Python 文档翻译


新增文档翻译:日语、法语和韩语


各项更改详情请查阅:


https://docs.python.org/3.7/whatsnew/3.7.html

原文来源:https://m.pythontab.com/article/1313


转载请注明:文章转载自 www.mshxw.com
本文地址:https://www.mshxw.com/it/222290.html
我们一直用心在做
关于我们 文章归档 网站地图 联系我们

版权所有 (c)2021-2022 MSHXW.COM

ICP备案号:晋ICP备2021003244-6号