Today my main task is to study some source on the old project EV. From those sources, we have to build a new management program on public
line. The new program will need less men to manage or monitor a group of building. Under the circumstance of economic crisis, it will be
a good tool in order to cut down staff, especially, building manager or monitor.
However, I found that some strange logic is here and there. It is not easy to comprehend them.
#`(1)
(define-syntax n
(lambda (x)
(syntax-case x ()
((_ #(p1 p2 pe ... p4 p5))
(syntax (list
(list p1 p2)
(list pe ...)
(list p4 p5)))))))
> (n #(1 2 3 4 5 6 7 8))
((1 2) (3 4 5 6) (7 8))
(define-syntax m
(lambda (x)
(syntax-case x ()
((_ p1 p2 pe ... p4 p5 . pt)
(syntax (list
(list p1 p2)
(list pe ...)
(list p4 p5)
(list pt)))))))
> (m 1 2 3 4 5 6 7 . 8)
((1 2) (3 4 5) (6 7) (8))
(define-syntax v
(lambda (x)
(syntax-case x ()
((_ p1 p2 . pt)
(syntax (list
(list p1 p2)
(list pt)))))))
> (v 1 2 . 3)
((1 2) (3))
Every predicate has a alike following control flow.
+-----------+
call -->| |--> exit
| predicate |
fail <--| |<-- redo
+-----------+
|
exception <----+
repeat:
+-----------+
call -->| +->|--> exit
| repeat | |
fail <--| +--|<-- redo
+-----------+
|
exception <----+
fail:
+-----------+
call -->|--+ |--> exit
| | fail |
fail <--|<-+ |<-- redo
+-----------+
|
exception <----+
2009 March 27th Friday (三月 二十七日 金曜日)
最新推荐文章于 2026-01-08 21:46:27 发布
今日主要任务是对旧项目EV的源码进行研究,并计划基于这些资料开发一套新的公共线路管理系统。新系统将减少对建筑群管理的人力需求,在经济危机背景下有助于裁员,特别是减少对建筑管理员的需求。但在研究过程中发现了一些逻辑上的难点。
521

被折叠的 条评论
为什么被折叠?



