设为首页收藏本站

LUPA开源社区

 找回密码
 注册
文章 帖子 博客
LUPA开源社区 首页 业界资讯 软件追踪 查看内容

脚本语言newLISP 10.6.1开发版发布了!

2014-9-17 16:15| 发布者: joejoe0332| 查看: 1903| 评论: 0|原作者: oschina|来自: oschina

摘要:   newLISP 10.6.1 开发版发布了,此版本现已提供下载,主要就是 Bug 修复,同时还添加几个小方法,兼容 newLISP 10.6.0 版本。新功能和改进A new function(collectexp)reapeatedly evaluatesexpand collects resul ...

  newLISP 10.6.1 开发版发布了,此版本现已提供下载,主要就是 Bug 修复,同时还添加几个小方法,兼容 newLISP  10.6.0 版本。


新功能和改进

  • A new function (collect exp) reapeatedly evaluates exp and collects results in a list until evaluation yields nil.

  • Some PCRE regular expression options can now be given as either numbers or letters. Multiple letter optiosn can be combined in a string. This affects all functions using regular expressions. See the regexfunction for details.

  • The regex function now gives offset and length in number of UTF-8 characters when PCRE UTF8 option2048 or "u" is specified.

  • A second syntax pattern for copy allows copying a newLISP cell from a memory address. This is useful when interfacing with C-language code.

  • The get-string function now takes one or two additional optional parameters for two new syntax patterns. The new patterns allow creating string buffers from memory address locations limited by size or a limit string. Using special limit strings, UTF16 and UTF32 strings of unknown size can be copied. This is useful when interfacing with C-language code.

  • The macro? predicate now also can be used on symbols to test if a symbol was created using the macrofunction.

  • A wrong UDP option in net-connect or net-listen will now throw an error message. Previously wrong UDP options were ignored.


Bug 修复

  • rotate on a (copy str) expression corrupted memory.

  • The flt function now returns an unsigned integer on all platforms. Previusly on 32-bit versions a signed integer was returned.

  • The crc32 function will not sign-extend on 32-bit newLISP.

  • The protected? function did not recognize macro symbols as protected.


  newLISP是一个类似Lisp语言的、用于一般用途的脚本语言。它具有 LISP 语言所有的魔力,但更容易学习和使用。 newLISP是友好的,快速和简小的。大部分您需要的功能都将已经内置。


  下面是一段示例代码:

(command-event (fn (s)
    (local (request)
        (if (find "?" s) ; is this a query
            (begin
                (set 'request (first (parse s "?")))
                ; discover illegal extension in queries
                (if (ends-with request ".exe") 
                    (set 'request "GET /errorpage.html")
                    (set 'request s)))
            (set 'request s))
        request)
))

酷毙

雷人

鲜花

鸡蛋

漂亮
  • 快毕业了,没工作经验,
    找份工作好难啊?
    赶紧去人才芯片公司磨练吧!!

最新评论

关于LUPA|人才芯片工程|人才招聘|LUPA认证|LUPA教育|LUPA开源社区 ( 浙B2-20090187 浙公网安备 33010602006705号   

返回顶部