|
|
|
|
 道语言最新版本0.9.6beta发布! - phunyx [ 2005-11-28 19:13 | 5,156 byte(s)]
 Re: 道语言最新版本0.9.6beta发布! - limodou [ 2005-11-28 20:43 | 6 byte(s)]
|
|
|
|
[Original]
[Print]
[Top]
|
大家好!
从上次发布道语言到现在已经快半年了。这半年的时间里,道语言有了很大的进步。
不过还是有不少地方不够完善,但考虑到已经新增了不少重要的特性,我决定还是
发布它。这次发布终于附带上了中文文档。
这个新版本的道语言最重要的新特性就是对多线程编程的支持,现在在道语言里使用
线程变得极其简单。为了实现对多线程的支持,还增加了一个新的同步垃圾回收器。
此版也增加了对字符串操作和正则表达式匹配的UNICODE支持。正则表达式匹配的算法
也有了改进,并修正了几处错误;也增加了反向匹配。道语言的C++插件与嵌入的接口
更加简单完善。
另外,我还同时发布一个带图形用户界面的道语言的互动开发终端:DaoConsole.
详情请访问:http://www.xdao.org
下面是此次发布的更改日志(很抱歉只有英文的):
+ : added
! : changed
* : fixed
- : removed
多线程:
+ Multi-threaded programming is supported as a kernel feature of
Dao language. Posix thread library is used in the implementation.
And the thread API in Dao is similar to that in Posix thread.
Parts of the Dao interpreter is re-structured for multithreading.
+ A novel concurrent garbage collector based on reference counting
is implemented to support multithreading.
+ A upper bound for GC amount is applied to prevent memory "avalanche",
where mutators generate garbage faster than GC can collect them.
gcmin(), gcmax().
UNICODE:
+ UNICODE is supported. String quotated with double quotation symbol
is internally represented as Wide Character String(WCS), while string
quotated with single quotation symbol is internally represented
Multi Bytes String(MBS). Corresponding operations on WCS is also
supported.
正则表达式:
+ Regex reverse matching is supported.
+ Now internal representation of Regex uses both MBS and WCS for both
efficiency and proper matching character class for unicode. When a
regex is applied to MBS or WCS, the corresponding representation is
used.
+ Regex datatype is added, a regex pattern can be compiled and stored
for later use, by using: define regex: rgx = /d+w/;
or, rgx = regex( "\d+\w" );
+ New character class abbreviations u and U are added for unicode.
+ Customized character class abbreviations are support. Users can define
their own character class abbreviations by:
define regex: 2 = [WhateverChars];
! Algorithm for regex matching is modified to extend matching when
possible, and is also modified to match regex group correctly.
数值数组:
+ Specification of precision in numeric array enumeration is supported:
num=[@{numtype} array];
! Transpose operator(right operator) is changed from ' to ~.
- Function convolute() for numeric arrays is removed.
扩展与嵌入:
+ Some abstract classes are added for supporting easy embedding
of Dao interpreter ( the daoMain.cpp source file is an example
for embedding ).
+ Some wrapper classes for Dao data objects are provide in daoType.h
to faciliate the using of Dao data objects in plugins or other
programs in which Dao is embedded.
! A new technique is implemented to allow more tranparent passing
data between Dao interpreter and C++ modules. Creation of shadow
classes is also supported by the way.
文件读写:
+ Instead of using STL stream classes, new DaoStream classes are
added mainly for handling unicode in many places.
+ For file IO, more open modes such as "rwat" are supported, and
more methods such as eof(), seek(), tell() ... are implemented.
read() is enhanced such that it can read until meeting EOF.
其他:
+ Multi inheritance is supported for OOP. And the passing parameters
and calling to parent constructor is simplified.
+ Negative subindex is supported for string.
+ Added a feature that allows using Alternate KeyWord (*.akw) to
write Dao scripts in non-english languages. The only requirement
is the character encoding for the .akw file must be the same as the
script files.
! Variable scope specification keyword "global" is added; keyword
"extern" is remove; keyword "share" is changed to "shared"
! Data states are added for constant and frozen data. Now a const
data is a really const, and can not be modified anymore. Function
freeze() is added to freeze some data structures as well as those
are reachable from them, to prevent them from being modified;
And defreeze() is added to defreeze them.
! The using namespace is simplified(compile(),eval(),source()).
|
|
|
[Original]
[Print]
[Top]
|
|
|