智能化下的产物,无人棋牌室
编程语言 D 2.068 发布,此版本更新内容如下:
编译器改进
- Warning: Change in helper function generation might cause link error.
- The new -profile=gc switch enables profiling memory allocation.
- unittest blocks no longer parsed unless -unittest is specified.
- Compiler generated inclusive destructor and postblit functions for UDTs are now accessible as .__xdtor and .__xpostblit, see dmd#4650.
语言改进
- pragma(inline) was added.
- attribute inference for auto functions
- Indexed type tuples can now be followed by dot identifiers.
- Support template parameter deduction from function default arguments.
- Invalid reinterpret casts can be detected in the frontend.
库改进
- Many phobos functions were rangified.
- std.typetuple was renamed to std.meta but a backwards compatible forwarding module will remain.
- TypeTuple was renamed to AliasSeq but a backwards compatible alias will remain.
- hexString was added to replace core language hex strings.
- hasUDA was added to help check for the existence of user-defined attributes on symbols.
- GC API calls can now be profiled separately.
- The runtime implementations of synchronized and synchronized (obj) were rewritten to fix a race condition during mutex initialization, see druntime#1274.
- The handwritten object.di header was replaced by directly using the object.d source file, see druntime#1222 for more details.
- The AA implementation now uses open addressing.
- Merging code coverage reports was fixed, see Bugzilla 14464 and dmd_coverSetMerge.
- executeShell now ignores the SHELL environment variable and always uses sh, see Bugzilla 14282.
- byLine was improved to use getdelim where available and is now up to 3x faster, seeBugzilla 11810.
- The newly added ordered and strictlyOrdered can be used to test whether a few given values are ordered.
- RefCounted uses the new return attribute to enable escape checking for it’s payload.
更多内容请看发行说明。
D语言(Dlang)是由Digital Mars公司开发的编程语言,起因是为了改进C++。它与C二进制兼容(不完全),可编译为本地码,有GC也可手动管理内存,语法上借鉴多种语言,模板则 在C++的基础上做了相当大的扩充。D 语言既有 C 语言的强大威力,又有 Python 和 Ruby 的开发效率。它是一种集垃圾回收、手工内存操作、契约式设计、高级模板技术、内嵌汇编、内置单元测试、Mixin 风格多继承、类 Java 包管理机制、内置同步机制、内建基本运行时信息的系统级编程语言。
D语言是一种通用的系统和应用编程语言。它是比 C++ 更高级的语言,同时还保持了生成高效代码以及直接访问操作系统API和硬件的能力。D 很适合于编写从中等规模到那些由团队合作完成、数百万行代码规模的各种程序。D 易于学习,为编程者提供了很多便利,并且适用各种野心勃勃的编译器优化技术。
D 不是脚本语言,也不是一种解释型语言。它不需要虚拟机、宗教、或者高于一切的哲学。它是给实际的编程者使用的实际的语言,它帮助编程者快速、可靠的完成易于维护、易于理解的代码。