Skip to content

Commit 99489f8

Browse files
committed
Update README.md
1 parent eee8dc7 commit 99489f8

File tree

1 file changed

+3
-5
lines changed

1 file changed

+3
-5
lines changed

README.md

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -112,14 +112,12 @@ times(4), times(,5); ;; 4, 5: optional, skipped arg
112112
dup(x) = (x,x); ;; return multiple
113113
(a,b) = dup(b); ;; destructure
114114
a=1,b=1; x()=(a=2;b=2); x(); ;; a==1, b==2: first statement declares locals
115-
116-
;; Static vars
117-
a() = ( *i=0; ++i ); ;; i keeps value between calls
115+
fn() = ( x; ^log(x) ); ;; defer: calls log after fn returns x
116+
f(a[], cb()) = cb(a[0]); ;; array, func args
117+
a() = ( *i=0; ++i ); ;; static var: i persists value
118118
a(), a(); ;; 1,2
119119
a1() = ( *copy=a; copy() ); ;; clone function
120120
a(), a(); a1(), a1(); ;; 3,4; 1,2;
121-
fn() = ( *t=0; t*2; ^t++ ); ;; defer: t++ called after fn returns `t*2`
122-
x(a[], f()) = f(a[0]); ;; array, func args
123121
124122
;; Export
125123
x, y, z; ;; exports last statement

0 commit comments

Comments
 (0)