picolisp

Unnamed repository; edit this file to name it for gitweb.
git clone https://logand.com/git/picolisp.git/
Log | Files | Refs | README | LICENSE

db.l (654B)


      1 # 08oct09abu
      2 # (c) Software Lab. Alexander Burger
      3 
      4 ### id ###
      5 (test *DB (id 1))
      6 (test 1 (id *DB))
      7 (let I (id 3 4)
      8    (test (3 . 4) (id I T)) )
      9 
     10 
     11 ### lieu ###
     12 (rollback)
     13 (test NIL (lieu *DB))
     14 (test *DB (val *DB) (lieu *DB))
     15 
     16 
     17 ### commit rollback ###
     18 (let (X (new T)  Y (new T))
     19    (set X 1  Y 2)
     20    (commit)
     21    (test 1 (val X))
     22    (test 2 (val Y))
     23    (set X 111)
     24    (set Y 222)
     25    (test 111 (val X))
     26    (test 222 (val Y))
     27    (rollback)
     28    (test 1 (val X))
     29    (test 2 (val Y)) )
     30 
     31 
     32 ### mark ###
     33 (test NIL (mark *DB))
     34 (test NIL (mark *DB T))
     35 (test T (mark *DB))
     36 (test T (mark *DB 0))
     37 (test NIL (mark *DB))
     38 
     39 
     40 ### dbck ###
     41 (test NIL (dbck))
     42 
     43 # vi:et:ts=3:sw=3