Debian Codegraph @

test/symtab11.awk

raw
1 BEGIN {
2 PROCINFO["sorted_in"] = "@val_type_asc" # okay with PROCINFO commented out, kaboom if not
3 IGNORECASE = 1 # yes
4
5 printf("BEGIN -- Symtab is next\n") > "/dev/stdout"
6 for (i in SYMTAB) {
7 printf "[%s] = %s\n", i, isarray(SYMTAB[i]) ? "<array>" : SYMTAB[i] # else {printf("[%s]\t(%s)\n",i,SYMTAB[i]);}
8 }
9 printf("BEGIN-- after Symtab loop\n") > "/dev/stdout" # never got here
10
11 printf("BEGIN -- Functab is next\n") > "/dev/stdout"
12 for (i in FUNCTAB) {
13 printf "[%s] = %s\n", i, FUNCTAB[i] # else {printf("[%s]\t(%s)\n",i,FUNCTAB[i]);}
14 }
15 printf("BEGIN-- after Functab loop\n") > "/dev/stdout" # never got here
16 exit
17 }
18
19 function foo()
20 {
21 print "foo called"
22 }
23
24 function bar()
25 {
26 print "bar called"
27 }
28
29 # e-o-begin
30 # --- No END, No Main ... ---