home *** CD-ROM | disk | FTP | other *** search
MacBinary | 1995-09-26 | 31.1 KB | [TEXT/CWIE] |
open in:
MacOS 8.1
|
Win98
|
DOS
view JSON data
|
view as text
This file was processed as: MacBinary
(archive/macBinary).
You can browse this item here: Assign.doc
Confidence | Program | Detection | Match Type | Support
|
---|
10%
| dexvert
| MacBinary (archive/macBinary)
| fallback
| Supported |
1%
| dexvert
| WANG Integrated Word Processor (document/wangIWP)
| ext
| Unsupported |
1%
| dexvert
| Dynamic Publisher Document (document/dynamicPublisherDocument)
| ext
| Unsupported |
1%
| dexvert
| Excellence! Document (document/excellenceDocument)
| ext
| Unsupported |
1%
| dexvert
| Norton Textra Writer (document/textraWriter)
| ext
| Unsupported |
1%
| dexvert
| IBM DisplayWrite Document (document/ibmDisplayWriteDocument)
| ext
| Unsupported |
1%
| dexvert
| Open Access Document (document/openAccessDocument)
| ext
| Unsupported |
1%
| dexvert
| Text File (text/txt)
| fallback
| Supported |
100%
| file
| MacBinary II, inited, Tue Sep 26 19:26:04 1995, modified Tue Sep 26 19:26:04 1995, creator 'CWIE', type ASCII, 31126 bytes "Assign.doc" , at 0x7a16 410 bytes resource
| default (weak)
| |
99%
| file
| data
| default
| |
74%
| TrID
| Macintosh plain text (MacBinary)
| default
| |
25%
| TrID
| MacBinary 2
| default (weak)
| |
100%
| siegfried
| fmt/1762 MacBinary (II)
| default
| |
100%
| lsar
| MacBinary
| default
|
|
id metadata |
---|
key | value |
---|
macFileType | [TEXT] |
macFileCreator | [CWIE] |
hex view+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 0a 41 73 73 69 67 6e | 2e 64 6f 63 00 00 00 00 |..Assign|.doc....|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 43 57 49 | 45 01 00 00 00 00 00 00 |.TEXTCWI|E.......|
|00000050| 00 00 00 00 00 79 96 00 | 00 01 9a ac 8e 3c 8c ac |.....y..|.....<..|
|00000060| 8e 3c 8c 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |.<......|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 55 f6 00 00 |........|....U...|
|00000080| 23 69 66 20 30 0d 41 73 | 73 69 67 6e 2e 64 6f 63 |#if 0.As|sign.doc|
|00000090| 0d 54 68 69 73 20 66 69 | 6c 65 20 64 6f 63 75 6d |.This fi|le docum|
|000000a0| 65 6e 74 73 20 41 73 73 | 69 67 6e 2e 63 2e 0d 0d |ents Ass|ign.c...|
|000000b0| 41 73 73 69 67 6e 20 69 | 73 20 61 20 70 6f 72 74 |Assign i|s a port|
|000000c0| 61 62 6c 65 20 72 75 6e | 74 69 6d 65 20 43 20 69 |able run|time C i|
|000000d0| 6e 74 65 72 70 72 65 74 | 65 72 20 74 68 61 74 20 |nterpret|er that |
|000000e0| 72 65 61 64 73 20 61 6e | 64 20 65 78 65 63 75 74 |reads an|d execut|
|000000f0| 65 73 20 61 6e 79 20 74 | 65 78 74 0d 22 61 73 73 |es any t|ext."ass|
|00000100| 69 67 6e 6d 65 6e 74 22 | 20 66 69 6c 65 20 74 68 |ignment"| file th|
|00000110| 61 74 20 63 6f 6e 74 61 | 69 6e 73 20 6f 6e 6c 79 |at conta|ins only|
|00000120| 20 43 20 61 73 73 69 67 | 6e 6d 65 6e 74 73 20 61 | C assig|nments a|
|00000130| 6e 64 20 63 6f 6d 6d 65 | 6e 74 73 2c 20 65 2e 67 |nd comme|nts, e.g|
|00000140| 2e 0d 09 76 69 65 77 69 | 6e 67 44 69 73 74 61 6e |...viewi|ngDistan|
|00000150| 63 65 3d 35 37 2e 30 3b | 09 2f 2a 20 69 6e 63 68 |ce=57.0;|./* inch|
|00000160| 65 73 20 2a 2f 0d 49 74 | 20 75 73 65 73 20 61 6e |es */.It| uses an|
|00000170| 20 61 72 72 61 79 20 6f | 66 20 22 44 65 73 63 72 | array o|f "Descr|
|00000180| 69 70 74 69 6f 6e 22 20 | 73 74 72 75 63 74 75 72 |iption" |structur|
|00000190| 65 73 20 74 6f 20 61 73 | 73 6f 63 69 61 74 65 20 |es to as|sociate |
|000001a0| 65 61 63 68 20 6e 61 6d | 65 20 69 6e 20 74 68 65 |each nam|e in the|
|000001b0| 0d 61 73 73 69 67 6e 6d | 65 6e 74 20 66 69 6c 65 |.assignm|ent file|
|000001c0| 20 77 69 74 68 20 61 20 | 63 6f 72 72 65 73 70 6f | with a |correspo|
|000001d0| 6e 64 69 6e 67 20 72 75 | 6e 74 69 6d 65 20 43 20 |nding ru|ntime C |
|000001e0| 76 61 72 69 61 62 6c 65 | 2e 20 49 74 20 63 61 6e |variable|. It can|
|000001f0| 20 61 6c 73 6f 20 77 72 | 69 74 65 20 61 6e 0d 61 | also wr|ite an.a|
|00000200| 73 73 69 67 6e 6d 65 6e | 74 20 66 69 6c 65 2c 20 |ssignmen|t file, |
|00000210| 6d 61 6b 69 6e 67 20 74 | 68 65 20 61 73 73 69 67 |making t|he assig|
|00000220| 6e 6d 65 6e 74 20 66 69 | 6c 65 20 61 20 70 6f 72 |nment fi|le a por|
|00000230| 74 61 62 6c 65 20 77 61 | 79 20 6f 66 20 77 72 69 |table wa|y of wri|
|00000240| 74 69 6e 67 20 61 6e 64 | 0d 72 65 61 64 69 6e 67 |ting and|.reading|
|00000250| 20 63 61 6c 69 62 72 61 | 74 69 6f 6e 73 20 61 6e | calibra|tions an|
|00000260| 64 20 65 78 70 65 72 69 | 6d 65 6e 74 61 6c 20 70 |d experi|mental p|
|00000270| 61 72 61 6d 65 74 65 72 | 73 2e 20 41 72 72 61 79 |arameter|s. Array|
|00000280| 73 20 63 61 6e 20 62 65 | 20 61 6c 6c 6f 63 61 74 |s can be| allocat|
|00000290| 65 64 0d 64 79 6e 61 6d | 69 63 61 6c 6c 79 2c 20 |ed.dynam|ically, |
|000002a0| 61 75 74 6f 6d 61 74 69 | 63 61 6c 6c 79 20 64 69 |automati|cally di|
|000002b0| 6d 65 6e 73 69 6f 6e 65 | 64 20 73 6f 20 61 73 20 |mensione|d so as |
|000002c0| 74 6f 20 68 6f 6c 64 20 | 61 6c 6c 20 74 68 65 20 |to hold |all the |
|000002d0| 61 73 73 69 67 6e 6d 65 | 6e 74 73 20 69 6e 20 61 |assignme|nts in a|
|000002e0| 6e 79 0d 70 61 72 74 20 | 6f 66 20 74 68 65 20 61 |ny.part |of the a|
|000002f0| 73 73 69 67 6e 6d 65 6e | 74 20 66 69 6c 65 2e 0d |ssignmen|t file..|
|00000300| 0d 50 72 6f 67 72 61 6d | 73 20 77 72 69 74 74 65 |.Program|s writte|
|00000310| 6e 20 62 65 66 6f 72 65 | 20 31 39 39 33 2c 20 75 |n before| 1993, u|
|00000320| 73 69 6e 67 20 74 68 65 | 20 6f 6c 64 20 52 65 61 |sing the| old Rea|
|00000330| 64 41 73 73 69 67 6e 6d | 65 6e 74 73 2e 63 20 28 |dAssignm|ents.c (|
|00000340| 6e 6f 77 20 73 75 70 65 | 72 63 65 64 65 64 20 62 |now supe|rceded b|
|00000350| 79 20 0d 41 73 73 69 67 | 6e 2e 63 29 2c 20 6d 61 |y .Assig|n.c), ma|
|00000360| 79 20 23 69 6e 63 6c 75 | 64 65 20 74 68 65 20 68 |y #inclu|de the h|
|00000370| 65 61 64 65 72 20 66 69 | 6c 65 20 41 73 73 69 67 |eader fi|le Assig|
|00000380| 6e 39 32 2e 68 20 74 6f | 20 6d 69 6e 69 6d 69 7a |n92.h to| minimiz|
|00000390| 65 20 74 68 65 20 65 66 | 66 6f 72 74 20 6f 66 20 |e the ef|fort of |
|000003a0| 0d 75 70 64 61 74 69 6e | 67 2e 0d 0d 50 4f 52 54 |.updatin|g...PORT|
|000003b0| 41 42 49 4c 49 54 59 3a | 20 53 74 61 6e 64 61 72 |ABILITY:| Standar|
|000003c0| 64 20 43 0d 0d 53 59 4e | 54 41 58 20 4f 46 20 54 |d C..SYN|TAX OF T|
|000003d0| 48 45 20 41 53 53 49 47 | 4e 4d 45 4e 54 20 46 49 |HE ASSIG|NMENT FI|
|000003e0| 4c 45 0d 0d 54 68 65 20 | 65 6e 74 69 72 65 20 22 |LE..The |entire "|
|000003f0| 61 73 73 69 67 6e 6d 65 | 6e 74 22 20 66 69 6c 65 |assignme|nt" file|
|00000400| 20 6d 61 79 20 63 6f 6e | 74 61 69 6e 20 6f 6e 6c | may con|tain onl|
|00000410| 79 20 73 69 6d 70 6c 65 | 20 61 73 73 69 67 6e 6d |y simple| assignm|
|00000420| 65 6e 74 73 2d 2d 77 68 | 69 63 68 20 61 72 65 0d |ents--wh|ich are.|
|00000430| 69 6e 74 65 72 70 72 65 | 74 65 64 2d 2d 61 6e 64 |interpre|ted--and|
|00000440| 20 77 68 69 74 65 73 70 | 61 63 65 20 61 6e 64 20 | whitesp|ace and |
|00000450| 63 6f 6d 6d 65 6e 74 73 | 2d 2d 77 68 69 63 68 20 |comments|--which |
|00000460| 61 72 65 20 69 67 6e 6f | 72 65 64 2e 20 42 6f 74 |are igno|red. Bot|
|00000470| 68 20 43 20 73 74 79 6c | 65 20 2f 2a 20 2a 2f 0d |h C styl|e /* */.|
|00000480| 61 6e 64 20 43 2b 2b 20 | 73 74 79 6c 65 20 2f 2f |and C++ |style //|
|00000490| 20 63 6f 6d 6d 65 6e 74 | 73 20 61 72 65 20 61 6c | comment|s are al|
|000004a0| 6c 6f 77 65 64 2e 20 49 | 67 6e 6f 72 69 6e 67 20 |lowed. I|gnoring |
|000004b0| 61 6e 79 20 69 6e 74 65 | 72 76 65 6e 69 6e 67 20 |any inte|rvening |
|000004c0| 77 68 69 74 65 73 70 61 | 63 65 20 61 6e 64 0d 63 |whitespa|ce and.c|
|000004d0| 6f 6d 6d 65 6e 74 73 2c | 20 65 61 63 68 20 61 73 |omments,| each as|
|000004e0| 73 69 67 6e 6d 65 6e 74 | 20 63 6f 6e 73 69 73 74 |signment| consist|
|000004f0| 73 20 6f 66 20 61 20 76 | 61 72 69 61 62 6c 65 20 |s of a v|ariable |
|00000500| 6e 61 6d 65 20 6f 66 20 | 61 6e 79 20 6c 65 6e 67 |name of |any leng|
|00000510| 74 68 2c 20 70 6f 73 73 | 69 62 6c 79 0d 77 69 74 |th, poss|ibly.wit|
|00000520| 68 20 61 20 63 6f 6e 73 | 74 61 6e 74 20 73 75 62 |h a cons|tant sub|
|00000530| 73 63 72 69 70 74 20 28 | 6f 66 20 75 70 20 74 6f |script (|of up to|
|00000540| 20 41 53 53 49 47 4e 5f | 44 49 4d 53 20 64 69 6d | ASSIGN_|DIMS dim|
|00000550| 65 6e 73 69 6f 6e 73 29 | 2c 20 61 6e 20 65 71 75 |ensions)|, an equ|
|00000560| 61 6c 20 73 69 67 6e 2c | 0d 65 69 74 68 65 72 20 |al sign,|.either |
|00000570| 61 20 63 6f 6e 73 74 61 | 6e 74 20 28 64 65 63 69 |a consta|nt (deci|
|00000580| 6d 61 6c 20 31 33 2c 20 | 31 2e 33 2c 20 31 2e 33 |mal 13, |1.3, 1.3|
|00000590| 65 39 2c 20 68 65 78 20 | 30 78 31 61 2c 20 63 68 |e9, hex |0x1a, ch|
|000005a0| 61 72 20 27 61 27 2c 20 | 74 72 61 6e 73 63 65 6e |ar 'a', |transcen|
|000005b0| 64 65 6e 74 61 6c 0d 49 | 6e 66 2c 20 6f 72 20 6e |dental.I|nf, or n|
|000005c0| 6f 74 2d 61 2d 6e 75 6d | 62 65 72 20 4e 61 4e 29 |ot-a-num|ber NaN)|
|000005d0| 20 6f 72 20 61 20 73 74 | 72 69 6e 67 20 6c 69 74 | or a st|ring lit|
|000005e0| 65 72 61 6c 20 28 65 2e | 67 2e 20 22 68 65 6c 6c |eral (e.|g. "hell|
|000005f0| 6f 22 29 2c 20 61 6e 64 | 20 61 20 73 65 6d 69 63 |o"), and| a semic|
|00000600| 6f 6c 6f 6e 2e 0d 09 69 | 3d 33 3b 20 61 3d 31 2e |olon...i|=3; a=1.|
|00000610| 30 3b 20 62 5b 31 5d 5b | 32 5d 3d 49 4e 46 3b 20 |0; b[1][|2]=INF; |
|00000620| 6d 73 67 3d 22 68 65 6c | 6c 6f 20 77 6f 72 6c 64 |msg="hel|lo world|
|00000630| 22 3b 20 2f 2a 20 65 78 | 61 6d 70 6c 65 73 20 2a |"; /* ex|amples *|
|00000640| 2f 0d 4e 61 4e 20 28 6f | 72 20 4e 41 4e 20 6f 72 |/.NaN (o|r NAN or|
|00000650| 20 6e 61 6e 29 2c 20 49 | 6e 66 20 28 6f 72 20 49 | nan), I|nf (or I|
|00000660| 4e 46 20 6f 72 20 69 6e | 66 29 2c 20 61 6e 64 20 |NF or in|f), and |
|00000670| 2d 49 6e 66 20 61 72 65 | 20 61 63 63 65 70 74 65 |-Inf are| accepte|
|00000680| 64 20 61 73 20 66 6c 6f | 61 74 69 6e 67 0d 76 61 |d as flo|ating.va|
|00000690| 6c 75 65 73 2e 20 28 54 | 68 65 20 4e 41 4e 20 73 |lues. (T|he NAN s|
|000006a0| 70 65 63 69 66 69 63 61 | 74 69 6f 6e 20 6d 61 79 |pecifica|tion may|
|000006b0| 20 69 6e 63 6c 75 64 65 | 20 61 20 4e 41 4e 2d 63 | include| a NAN-c|
|000006c0| 6f 64 65 2c 20 61 20 6c | 61 20 54 48 49 4e 4b 20 |ode, a l|a THINK |
|000006d0| 43 2c 20 65 2e 67 2e 20 | 4e 41 4e 46 46 2c 0d 6f |C, e.g. |NANFF,.o|
|000006e0| 72 20 61 6c 61 20 4d 50 | 57 20 43 2c 20 65 2e 67 |r ala MP|W C, e.g|
|000006f0| 2e 20 4e 41 4e 5b 32 35 | 35 5d 2e 29 20 42 61 63 |. NAN[25|5].) Bac|
|00000700| 6b 73 6c 61 73 68 20 65 | 73 63 61 70 65 73 2c 20 |kslash e|scapes, |
|00000710| 65 2e 67 2e 20 5c 30 30 | 37 20 61 6e 64 20 5c 6e |e.g. \00|7 and \n|
|00000720| 2c 20 77 69 74 68 69 6e | 20 73 69 6e 67 6c 65 0d |, within| single.|
|00000730| 6f 72 20 64 6f 75 62 6c | 65 20 71 75 6f 74 65 73 |or doubl|e quotes|
|00000740| 20 61 72 65 20 66 75 6c | 6c 79 20 73 75 70 70 6f | are ful|ly suppo|
|00000750| 72 74 65 64 20 28 65 78 | 63 65 70 74 20 74 68 61 |rted (ex|cept tha|
|00000760| 74 20 74 68 65 72 65 20 | 69 73 20 6e 6f 20 73 75 |t there |is no su|
|00000770| 70 70 6f 72 74 20 66 6f | 72 20 53 74 61 6e 64 61 |pport fo|r Standa|
|00000780| 72 64 20 43 27 73 0d 6e | 65 77 20 69 6e 74 65 72 |rd C's.n|ew inter|
|00000790| 6e 61 74 69 6f 6e 61 6c | 20 22 77 69 64 65 22 20 |national| "wide" |
|000007a0| 63 68 61 72 61 63 74 65 | 72 73 20 61 6e 64 20 74 |characte|rs and t|
|000007b0| 72 69 67 72 61 70 68 20 | 73 65 71 75 65 6e 63 65 |rigraph |sequence|
|000007c0| 73 29 2e 20 41 20 73 69 | 6d 70 6c 65 20 76 61 72 |s). A si|mple var|
|000007d0| 69 61 62 6c 65 0d 6e 61 | 6d 65 2c 20 61 73 20 69 |iable.na|me, as i|
|000007e0| 6e 20 43 2c 20 63 6f 6e | 73 69 73 74 73 20 6f 66 |n C, con|sists of|
|000007f0| 20 61 6e 20 61 6c 70 68 | 61 62 65 74 69 63 20 63 | an alph|abetic c|
|00000800| 68 61 72 61 63 74 65 72 | 20 28 6f 72 20 5f 29 20 |haracter| (or _) |
|00000810| 66 6f 6c 6c 6f 77 65 64 | 20 62 79 20 61 6e 79 20 |followed| by any |
|00000820| 6e 75 6d 62 65 72 0d 6f | 66 20 61 6c 70 68 61 6e |number.o|f alphan|
|00000830| 75 6d 65 72 69 63 20 63 | 68 61 72 61 63 74 65 72 |umeric c|haracter|
|00000840| 73 20 28 6f 72 20 5f 29 | 2e 20 54 6f 20 73 69 6d |s (or _)|. To sim|
|00000850| 75 6c 61 74 65 20 73 74 | 72 75 63 74 75 72 65 20 |ulate st|ructure |
|00000860| 72 65 66 65 72 65 6e 63 | 65 73 2c 20 63 6f 6d 70 |referenc|es, comp|
|00000870| 6f 73 69 74 65 0d 6e 61 | 6d 65 73 20 61 72 65 20 |osite.na|mes are |
|00000880| 61 6c 6c 6f 77 65 64 2c | 20 6d 61 64 65 20 75 70 |allowed,| made up|
|00000890| 20 6f 66 20 73 69 6d 70 | 6c 65 20 6e 61 6d 65 73 | of simp|le names|
|000008a0| 20 6a 6f 69 6e 65 64 20 | 62 79 20 22 2e 22 20 6f | joined |by "." o|
|000008b0| 72 20 22 2d 3e 22 2c 20 | 65 2e 67 2e 0d 09 61 2d |r "->", |e.g...a-|
|000008c0| 3e 62 2e 63 3d 30 2e 30 | 3b 20 6d 79 53 74 72 75 |>b.c=0.0|; myStru|
|000008d0| 63 74 2d 3e 62 3d 49 4e | 46 3b 0d 55 6e 6c 69 6b |ct->b=IN|F;.Unlik|
|000008e0| 65 20 53 74 61 6e 64 61 | 72 64 20 43 2c 20 65 61 |e Standa|rd C, ea|
|000008f0| 63 68 20 6c 69 6e 65 20 | 6d 75 73 74 20 62 65 20 |ch line |must be |
|00000900| 6c 65 73 73 20 74 68 61 | 6e 20 42 55 46 46 45 52 |less tha|n BUFFER|
|00000910| 5f 53 49 5a 45 20 63 68 | 61 72 61 63 74 65 72 73 |_SIZE ch|aracters|
|00000920| 20 6c 6f 6e 67 20 28 63 | 75 72 72 65 6e 74 6c 79 | long (c|urrently|
|00000930| 0d 35 31 32 29 2e 20 4c | 69 6e 65 73 20 74 68 61 |.512). L|ines tha|
|00000940| 74 20 65 6e 64 20 77 69 | 74 68 20 74 68 65 20 62 |t end wi|th the b|
|00000950| 61 63 6b 73 6c 61 73 68 | 20 63 68 61 72 61 63 74 |ackslash| charact|
|00000960| 65 72 20 5c 20 61 72 65 | 20 73 70 6c 69 63 65 64 |er \ are| spliced|
|00000970| 20 74 6f 20 74 68 65 20 | 6e 65 78 74 20 62 79 0d | to the |next by.|
|00000980| 64 65 6c 65 74 69 6e 67 | 20 74 68 65 20 62 61 63 |deleting| the bac|
|00000990| 6b 73 6c 61 73 68 20 61 | 6e 64 20 74 68 65 20 66 |kslash a|nd the f|
|000009a0| 6f 6c 6c 6f 77 69 6e 67 | 20 6e 65 77 6c 69 6e 65 |ollowing| newline|
|000009b0| 20 63 68 61 72 61 63 74 | 65 72 2e 20 54 68 65 20 | charact|er. The |
|000009c0| 73 70 6c 69 63 65 20 6d | 61 79 20 62 65 0d 62 65 |splice m|ay be.be|
|000009d0| 74 77 65 65 6e 20 74 6f | 6b 65 6e 73 20 6f 72 20 |tween to|kens or |
|000009e0| 69 6e 73 69 64 65 20 61 | 20 63 6f 6d 6d 65 6e 74 |inside a| comment|
|000009f0| 20 6f 72 20 73 74 72 69 | 6e 67 20 6c 69 74 65 72 | or stri|ng liter|
|00000a00| 61 6c 2c 20 62 75 74 2c | 20 75 6e 6c 69 6b 65 20 |al, but,| unlike |
|00000a10| 43 2c 20 74 68 65 20 73 | 70 6c 69 63 65 0d 6d 61 |C, the s|plice.ma|
|00000a20| 79 20 6e 6f 74 20 62 72 | 65 61 6b 20 61 20 74 6f |y not br|eak a to|
|00000a30| 6b 65 6e 2e 20 41 64 6a | 61 63 65 6e 74 20 73 74 |ken. Adj|acent st|
|00000a40| 72 69 6e 67 20 6c 69 74 | 65 72 61 6c 73 20 22 61 |ring lit|erals "a|
|00000a50| 22 20 22 62 22 20 61 72 | 65 20 63 6f 6e 63 61 74 |" "b" ar|e concat|
|00000a60| 65 6e 61 74 65 64 20 22 | 61 62 22 2c 0d 61 73 20 |enated "|ab",.as |
|00000a70| 73 70 65 63 69 66 69 65 | 64 20 62 79 20 53 74 61 |specifie|d by Sta|
|00000a80| 6e 64 61 72 64 20 43 2e | 20 28 54 68 65 20 6c 69 |ndard C.| (The li|
|00000a90| 6e 65 20 73 70 6c 69 63 | 69 6e 67 20 61 6e 64 20 |ne splic|ing and |
|00000aa0| 61 64 6a 61 63 65 6e 74 | 20 63 6f 6e 63 61 74 65 |adjacent| concate|
|00000ab0| 6e 61 74 69 6f 6e 20 61 | 6c 6c 6f 77 0d 63 72 65 |nation a|llow.cre|
|00000ac0| 61 74 69 6f 6e 20 6f 66 | 20 73 74 72 69 6e 67 73 |ation of| strings|
|00000ad0| 20 6f 66 20 61 72 62 69 | 74 72 61 72 79 20 6c 65 | of arbi|trary le|
|00000ae0| 6e 67 74 68 2c 20 6e 6f | 74 20 6c 69 6d 69 74 65 |ngth, no|t limite|
|00000af0| 64 20 62 79 20 42 55 46 | 46 45 52 5f 53 49 5a 45 |d by BUF|FER_SIZE|
|00000b00| 2e 29 20 4e 6f 20 66 75 | 72 74 68 65 72 0d 65 78 |.) No fu|rther.ex|
|00000b10| 70 72 65 73 73 69 6f 6e | 20 65 76 61 6c 75 61 74 |pression| evaluat|
|00000b20| 69 6f 6e 20 69 73 20 73 | 75 70 70 6f 72 74 65 64 |ion is s|upported|
|00000b30| 2e 20 4e 6f 20 6f 74 68 | 65 72 20 6f 70 65 72 61 |. No oth|er opera|
|00000b40| 74 6f 72 73 2c 20 65 2e | 67 2e 20 2b 2d 26 2a 2c |tors, e.|g. +-&*,|
|00000b50| 20 65 6e 75 6d 73 2c 20 | 63 61 73 74 73 2c 0d 65 | enums, |casts,.e|
|00000b60| 2e 67 2e 20 28 75 6e 73 | 69 67 6e 65 64 20 6c 6f |.g. (uns|igned lo|
|00000b70| 6e 67 29 2c 20 6f 72 20 | 6e 75 6d 62 65 72 20 73 |ng), or |number s|
|00000b80| 75 66 66 69 78 65 73 2c | 20 65 2e 67 2e 20 55 4c |uffixes,| e.g. UL|
|00000b90| 2c 20 61 72 65 20 61 6c | 6c 6f 77 65 64 2e 20 4e |, are al|lowed. N|
|00000ba0| 6f 20 6d 61 63 72 6f 73 | 20 6f 72 0d 70 72 65 70 |o macros| or.prep|
|00000bb0| 72 6f 63 65 73 73 6f 72 | 20 64 69 72 65 63 74 69 |rocessor| directi|
|00000bc0| 76 65 73 20 61 72 65 20 | 73 75 70 70 6f 72 74 65 |ves are |supporte|
|00000bd0| 64 20 28 65 2e 67 2e 20 | 23 69 66 2c 20 23 64 65 |d (e.g. |#if, #de|
|00000be0| 66 69 6e 65 29 2e 20 54 | 68 65 20 73 79 6e 74 61 |fine). T|he synta|
|00000bf0| 78 20 72 75 6c 65 73 20 | 61 72 65 0d 73 74 72 69 |x rules |are.stri|
|00000c00| 63 74 6c 79 20 65 6e 66 | 6f 72 63 65 64 2e 20 49 |ctly enf|orced. I|
|00000c10| 66 20 52 65 61 64 41 73 | 73 69 67 6e 6d 65 6e 74 |f ReadAs|signment|
|00000c20| 4c 69 6e 65 20 63 61 6e | 27 74 20 69 6e 74 65 72 |Line can|'t inter|
|00000c30| 70 72 65 74 20 79 6f 75 | 72 20 66 69 6c 65 20 69 |pret you|r file i|
|00000c40| 74 20 77 69 6c 6c 2c 20 | 61 74 0d 74 68 65 20 63 |t will, |at.the c|
|00000c50| 61 6c 6c 65 72 27 73 20 | 6f 70 74 69 6f 6e 2c 20 |aller's |option, |
|00000c60| 65 69 74 68 65 72 20 72 | 65 74 75 72 6e 20 61 6e |either r|eturn an|
|00000c70| 20 65 72 72 6f 72 20 63 | 6f 64 65 20 6f 72 20 63 | error c|ode or c|
|00000c80| 61 6c 6c 20 50 72 69 6e | 74 66 45 78 69 74 20 77 |all Prin|tfExit w|
|00000c90| 69 74 68 20 61 6e 0d 65 | 72 72 6f 72 20 6d 65 73 |ith an.e|rror mes|
|00000ca0| 73 61 67 65 20 70 69 6e | 70 6f 69 6e 74 69 6e 67 |sage pin|pointing|
|00000cb0| 20 74 68 65 20 65 72 72 | 6f 72 2e 0d 0d 41 73 73 | the err|or...Ass|
|00000cc0| 69 67 6e 2e 63 20 73 75 | 70 70 6f 72 74 73 20 6f |ign.c su|pports o|
|00000cd0| 6e 65 20 6f 70 74 69 6f | 6e 61 6c 20 65 78 74 65 |ne optio|nal exte|
|00000ce0| 6e 73 69 6f 6e 20 62 65 | 79 6f 6e 64 20 43 20 73 |nsion be|yond C s|
|00000cf0| 79 6e 74 61 78 20 74 68 | 61 74 20 6d 61 6b 65 73 |yntax th|at makes|
|00000d00| 20 69 74 20 70 72 61 63 | 74 69 63 61 6c 0d 74 6f | it prac|tical.to|
|00000d10| 20 73 61 76 65 20 69 6d | 61 67 65 73 20 77 69 74 | save im|ages wit|
|00000d20| 68 69 6e 20 61 73 73 69 | 67 6e 6d 65 6e 74 20 66 |hin assi|gnment f|
|00000d30| 69 6c 65 73 2e 20 49 66 | 20 61 20 6e 6f 6e 2d 73 |iles. If| a non-s|
|00000d40| 74 72 69 6e 67 20 76 61 | 72 69 61 62 6c 65 20 69 |tring va|riable i|
|00000d50| 73 20 61 73 73 69 67 6e | 65 64 20 61 0d 73 74 72 |s assign|ed a.str|
|00000d60| 69 6e 67 2c 20 0d 09 61 | 3d 22 31 31 31 31 61 61 |ing, ..a|="1111aa|
|00000d70| 61 61 31 31 31 31 22 3b | 0d 74 68 65 6e 20 52 65 |aa1111";|.then Re|
|00000d80| 61 64 41 73 73 69 67 6e | 6d 65 6e 74 4c 69 6e 65 |adAssign|mentLine|
|00000d90| 20 61 73 73 75 6d 65 73 | 20 74 68 61 74 20 74 68 | assumes| that th|
|00000da0| 65 20 73 74 72 69 6e 67 | 20 69 73 20 61 6e 20 65 |e string| is an e|
|00000db0| 6e 63 6f 64 69 6e 67 20 | 6f 66 20 74 68 65 20 64 |ncoding |of the d|
|00000dc0| 65 73 69 72 65 64 0d 62 | 69 6e 61 72 79 20 6f 62 |esired.b|inary ob|
|00000dd0| 6a 65 63 74 20 61 73 20 | 61 20 68 65 78 61 64 65 |ject as |a hexade|
|00000de0| 63 69 6d 61 6c 20 6e 75 | 6d 62 65 72 2c 20 61 6e |cimal nu|mber, an|
|00000df0| 64 20 61 73 73 69 67 6e | 73 20 74 68 65 20 64 65 |d assign|s the de|
|00000e00| 63 6f 64 65 64 20 62 69 | 6e 61 72 79 20 6f 62 6a |coded bi|nary obj|
|00000e10| 65 63 74 20 74 6f 0d 74 | 68 65 20 76 61 72 69 61 |ect to.t|he varia|
|00000e20| 62 6c 65 2c 20 6f 6e 65 | 20 62 79 74 65 20 66 6f |ble, one| byte fo|
|00000e30| 72 20 65 76 65 72 79 20 | 74 77 6f 20 68 65 78 20 |r every |two hex |
|00000e40| 64 69 67 69 74 73 2e 20 | 54 68 69 73 20 69 73 20 |digits. |This is |
|00000e50| 73 75 70 70 6f 72 74 65 | 64 20 66 6f 72 20 62 6f |supporte|d for bo|
|00000e60| 74 68 0d 73 63 61 6c 61 | 72 20 61 6e 64 20 61 72 |th.scala|r and ar|
|00000e70| 72 61 79 20 76 61 72 69 | 61 62 6c 65 73 2d 2d 74 |ray vari|ables--t|
|00000e80| 72 65 61 74 69 6e 67 20 | 65 69 74 68 65 72 20 61 |reating |either a|
|00000e90| 6e 20 65 6c 65 6d 65 6e | 74 20 6f 72 20 61 20 72 |n elemen|t or a r|
|00000ea0| 6f 77 20 28 6c 61 73 74 | 20 73 75 62 73 63 72 69 |ow (last| subscri|
|00000eb0| 70 74 2c 0d 66 61 73 74 | 65 73 74 20 63 68 61 6e |pt,.fast|est chan|
|00000ec0| 67 69 6e 67 29 20 6f 66 | 20 74 68 65 20 61 72 72 |ging) of| the arr|
|00000ed0| 61 79 20 61 73 20 61 20 | 73 69 6e 67 6c 65 20 62 |ay as a |single b|
|00000ee0| 69 6e 61 72 79 20 6f 62 | 6a 65 63 74 2d 2d 73 6f |inary ob|ject--so|
|00000ef0| 20 79 6f 75 20 63 61 6e | 20 6c 6f 61 64 20 6f 72 | you can| load or|
|00000f00| 0d 73 61 76 65 20 61 20 | 68 75 67 65 20 72 6f 77 |.save a |huge row|
|00000f10| 20 62 79 20 61 20 73 69 | 6e 67 6c 65 20 73 74 61 | by a si|ngle sta|
|00000f20| 74 65 6d 65 6e 74 20 74 | 68 61 74 20 61 73 73 69 |tement t|hat assi|
|00000f30| 67 6e 73 20 61 20 68 75 | 6d 75 6e 67 6f 75 73 20 |gns a hu|mungous |
|00000f40| 73 74 72 69 6e 67 20 6f | 66 20 68 65 78 0d 64 61 |string o|f hex.da|
|00000f50| 74 61 20 74 6f 20 74 68 | 65 20 61 72 72 61 79 2e |ta to th|e array.|
|00000f60| 20 45 2e 67 2e 20 69 66 | 20 6d 5b 5d 5b 5d 20 69 | E.g. if| m[][] i|
|00000f70| 73 20 6f 66 20 74 79 70 | 65 20 63 68 61 72 2c 20 |s of typ|e char, |
|00000f80| 74 68 65 6e 20 74 68 65 | 20 66 6f 6c 6c 6f 77 69 |then the| followi|
|00000f90| 6e 67 20 74 68 72 65 65 | 20 6c 69 6e 65 73 0d 61 |ng three| lines.a|
|00000fa0| 72 65 20 65 71 75 69 76 | 61 6c 65 6e 74 2e 0d 09 |re equiv|alent...|
|00000fb0| 6d 5b 33 5d 5b 30 5d 3d | 31 35 35 3b 6d 5b 33 5d |m[3][0]=|155;m[3]|
|00000fc0| 5b 31 5d 3d 39 35 3b 6d | 5b 33 5d 5b 32 5d 3d 32 |[1]=95;m|[3][2]=2|
|00000fd0| 35 35 3b 6d 5b 33 5d 5b | 33 5d 3d 31 32 37 3b 0d |55;m[3][|3]=127;.|
|00000fe0| 09 6d 5b 33 5d 5b 30 5d | 3d 22 39 62 22 3b 6d 5b |.m[3][0]|="9b";m[|
|00000ff0| 33 5d 5b 31 5d 3d 22 35 | 66 22 3b 6d 5b 33 5d 5b |3][1]="5|f";m[3][|
|00001000| 32 5d 3d 22 66 66 22 3b | 6d 5b 33 5d 5b 33 5d 3d |2]="ff";|m[3][3]=|
|00001010| 22 37 66 22 3b 0d 09 6d | 5b 33 5d 3d 22 39 62 35 |"7f";..m|[3]="9b5|
|00001020| 66 66 66 37 66 22 3b 0d | 54 68 69 73 20 66 6f 72 |fff7f";.|This for|
|00001030| 6d 61 74 20 69 73 20 73 | 75 70 70 6f 72 74 65 64 |mat is s|upported|
|00001040| 20 62 79 20 62 6f 74 68 | 20 52 65 61 64 41 73 73 | by both| ReadAss|
|00001050| 69 67 6e 6d 65 6e 74 4c | 69 6e 65 20 61 6e 64 20 |ignmentL|ine and |
|00001060| 50 72 69 6e 74 41 6e 41 | 73 73 69 67 6e 6d 65 6e |PrintAnA|ssignmen|
|00001070| 74 2e 20 57 68 65 6e 0d | 72 65 61 64 69 6e 67 20 |t. When.|reading |
|00001080| 61 6e 20 61 73 73 69 67 | 6e 6d 65 6e 74 20 66 69 |an assig|nment fi|
|00001090| 6c 65 2c 20 61 20 62 69 | 6e 61 72 79 20 6f 62 6a |le, a bi|nary obj|
|000010a0| 65 63 74 20 63 6f 6e 74 | 61 69 6e 69 6e 67 20 6f |ect cont|aining o|
|000010b0| 6e 6c 79 20 6f 6e 65 20 | 65 6c 65 6d 65 6e 74 2c |nly one |element,|
|000010c0| 20 61 73 20 69 6e 0d 6d | 5b 33 5d 5b 30 5d 3d 22 | as in.m|[3][0]="|
|000010d0| 39 62 22 2c 20 69 73 20 | 69 6e 74 65 72 70 72 65 |9b", is |interpre|
|000010e0| 74 65 64 20 61 73 20 61 | 20 73 63 61 6c 61 72 2c |ted as a| scalar,|
|000010f0| 20 72 61 74 68 65 72 20 | 74 68 61 6e 20 61 73 20 | rather |than as |
|00001100| 61 20 72 6f 77 20 6f 66 | 20 6c 65 6e 67 74 68 20 |a row of| length |
|00001110| 31 2e 20 57 68 65 6e 0d | 77 72 69 74 69 6e 67 20 |1. When.|writing |
|00001120| 61 6e 20 61 73 73 69 67 | 6e 6d 65 6e 74 20 66 69 |an assig|nment fi|
|00001130| 6c 65 20 61 20 77 68 6f | 6c 65 20 72 6f 77 20 6f |le a who|le row o|
|00001140| 66 20 65 61 63 68 20 61 | 72 72 61 79 20 69 73 20 |f each a|rray is |
|00001150| 61 73 73 69 67 6e 65 64 | 20 61 74 20 6f 6e 63 65 |assigned| at once|
|00001160| 0d 6d 5b 33 5d 3d 22 39 | 62 35 66 66 66 37 66 22 |.m[3]="9|b5fff7f"|
|00001170| 20 75 6e 6c 65 73 73 20 | 74 68 65 20 72 6f 77 20 | unless |the row |
|00001180| 69 73 20 6f 6e 6c 79 20 | 6f 6e 65 20 65 6c 65 6d |is only |one elem|
|00001190| 65 6e 74 20 6c 6f 6e 67 | 2c 20 69 6e 20 77 68 69 |ent long|, in whi|
|000011a0| 63 68 20 63 61 73 65 20 | 65 61 63 68 0d 65 6c 65 |ch case |each.ele|
|000011b0| 6d 65 6e 74 20 69 73 20 | 61 73 73 69 67 6e 65 64 |ment is |assigned|
|000011c0| 20 73 65 70 61 72 61 74 | 65 6c 79 2e 20 54 68 65 | separat|ely. The|
|000011d0| 20 64 65 66 61 75 6c 74 | 20 62 65 68 61 76 69 6f | default| behavio|
|000011e0| 72 20 6f 66 20 52 65 61 | 64 41 73 73 69 67 6e 6d |r of Rea|dAssignm|
|000011f0| 65 6e 74 4c 69 6e 65 20 | 61 6e 64 0d 50 72 69 6e |entLine |and.Prin|
|00001200| 74 41 6e 41 73 73 69 67 | 6e 6d 65 6e 74 20 69 73 |tAnAssig|nment is|
|00001210| 20 74 6f 20 75 73 65 20 | 74 68 65 20 62 69 6e 61 | to use |the bina|
|00001220| 72 79 20 6f 62 6a 65 63 | 74 20 61 73 73 69 67 6e |ry objec|t assign|
|00001230| 6d 65 6e 74 73 20 6f 6e | 6c 79 20 66 6f 72 20 69 |ments on|ly for i|
|00001240| 6e 74 65 67 65 72 73 0d | 28 69 6e 63 6c 75 64 69 |ntegers.|(includi|
|00001250| 6e 67 20 63 68 61 72 29 | 20 61 6e 64 20 74 6f 20 |ng char)| and to |
|00001260| 77 72 69 74 65 20 69 74 | 20 6f 6e 6c 79 20 77 68 |write it| only wh|
|00001270| 65 6e 20 69 74 20 77 6f | 75 6c 64 20 67 72 65 61 |en it wo|uld grea|
|00001280| 74 6c 79 20 72 65 64 75 | 63 65 20 74 68 65 20 66 |tly redu|ce the f|
|00001290| 69 6c 65 0d 73 69 7a 65 | 2e 20 54 68 65 20 6d 6f |ile.size|. The mo|
|000012a0| 74 69 76 61 74 69 6f 6e | 20 66 6f 72 20 74 68 69 |tivation| for thi|
|000012b0| 73 20 65 78 74 65 6e 73 | 69 6f 6e 20 69 73 20 74 |s extens|ion is t|
|000012c0| 6f 20 70 72 6f 76 69 64 | 65 20 61 20 63 6f 6d 70 |o provid|e a comp|
|000012d0| 61 63 74 20 77 61 79 20 | 74 6f 20 73 70 65 63 69 |act way |to speci|
|000012e0| 66 79 0d 74 68 65 20 63 | 6f 6e 74 65 6e 74 73 20 |fy.the c|ontents |
|000012f0| 6f 66 20 61 6e 20 69 6d | 61 67 65 2c 20 74 79 70 |of an im|age, typ|
|00001300| 69 63 61 6c 6c 79 20 61 | 6e 20 61 72 72 61 79 20 |ically a|n array |
|00001310| 6f 66 20 73 6d 61 6c 6c | 20 69 6e 74 65 67 65 72 |of small| integer|
|00001320| 73 2e 20 49 74 20 6d 61 | 79 20 61 6c 73 6f 20 62 |s. It ma|y also b|
|00001330| 65 0d 75 73 65 66 75 6c | 20 69 6e 20 73 69 74 75 |e.useful| in situ|
|00001340| 61 74 69 6f 6e 73 20 77 | 68 65 72 65 20 6f 6e 65 |ations w|here one|
|00001350| 20 77 61 6e 74 73 20 74 | 6f 20 73 61 76 65 20 61 | wants t|o save a|
|00001360| 6e 64 20 72 65 73 74 6f | 72 65 20 74 68 65 20 65 |nd resto|re the e|
|00001370| 78 61 63 74 20 76 61 6c | 75 65 20 6f 66 20 61 0d |xact val|ue of a.|
|00001380| 64 6f 75 62 6c 65 2c 20 | 73 69 6e 63 65 20 74 79 |double, |since ty|
|00001390| 70 69 63 61 6c 20 69 6d | 70 6c 65 6d 65 6e 74 61 |pical im|plementa|
|000013a0| 74 69 6f 6e 73 20 6f 66 | 20 74 68 65 20 43 20 73 |tions of| the C s|
|000013b0| 74 64 69 6f 20 6c 69 62 | 72 61 72 79 20 6c 6f 73 |tdio lib|rary los|
|000013c0| 65 20 61 20 66 65 77 20 | 62 69 74 73 20 6f 66 0d |e a few |bits of.|
|000013d0| 70 72 65 63 69 73 69 6f | 6e 20 74 72 61 6e 73 6c |precisio|n transl|
|000013e0| 61 74 69 6e 67 20 74 6f | 20 6f 72 20 66 72 6f 6d |ating to| or from|
|000013f0| 20 64 65 63 69 6d 61 6c | 20 72 65 70 72 65 73 65 | decimal| represe|
|00001400| 6e 74 61 74 69 6f 6e 73 | 20 6f 66 20 66 6c 6f 61 |ntations| of floa|
|00001410| 74 69 6e 67 20 6e 75 6d | 62 65 72 73 2e 0d 59 6f |ting num|bers..Yo|
|00001420| 75 20 67 72 61 6e 74 20 | 6f 72 20 64 65 6e 79 20 |u grant |or deny |
|00001430| 70 65 72 6d 69 73 73 69 | 6f 6e 20 74 6f 20 72 65 |permissi|on to re|
|00001440| 61 64 20 61 6e 64 20 77 | 72 69 74 65 20 68 65 78 |ad and w|rite hex|
|00001450| 2d 65 6e 63 6f 64 65 64 | 20 62 69 6e 61 72 79 20 |-encoded| binary |
|00001460| 6f 62 6a 65 63 74 73 20 | 62 79 0d 73 65 74 74 69 |objects |by.setti|
|00001470| 6e 67 20 6f 72 20 63 6c | 65 61 72 69 6e 67 20 74 |ng or cl|earing t|
|00001480| 77 6f 20 66 6c 61 67 20 | 62 69 74 73 2c 20 61 73 |wo flag |bits, as|
|00001490| 73 69 67 6e 4e 6f 48 65 | 78 49 6e 74 73 20 61 6e |signNoHe|xInts an|
|000014a0| 64 20 61 73 73 69 67 6e | 48 65 78 46 6c 6f 61 74 |d assign|HexFloat|
|000014b0| 73 2c 20 77 68 69 63 68 | 0d 61 72 65 20 65 78 70 |s, which|.are exp|
|000014c0| 6c 61 69 6e 65 64 20 62 | 65 6c 6f 77 2e 0d 0d 44 |lained b|elow...D|
|000014d0| 45 53 43 52 49 42 49 4e | 47 20 59 4f 55 52 20 56 |ESCRIBIN|G YOUR V|
|000014e0| 41 52 49 41 42 4c 45 53 | 20 54 4f 20 54 48 45 20 |ARIABLES| TO THE |
|000014f0| 41 53 53 49 47 4e 20 52 | 4f 55 54 49 4e 45 53 0d |ASSIGN R|OUTINES.|
|00001500| 0d 54 68 65 20 41 73 73 | 69 67 6e 20 72 6f 75 74 |.The Ass|ign rout|
|00001510| 69 6e 65 73 20 75 73 65 | 20 79 6f 75 72 20 70 72 |ines use| your pr|
|00001520| 65 2d 65 78 69 73 74 69 | 6e 67 20 43 20 76 61 72 |e-existi|ng C var|
|00001530| 69 61 62 6c 65 73 2e 20 | 45 61 63 68 20 43 20 76 |iables. |Each C v|
|00001540| 61 72 69 61 62 6c 65 20 | 74 68 61 74 0d 79 6f 75 |ariable |that.you|
|00001550| 20 77 61 6e 74 20 74 6f | 20 62 65 20 61 62 6c 65 | want to| be able|
|00001560| 20 74 6f 20 6c 6f 61 64 | 20 66 72 6f 6d 20 28 6f | to load| from (o|
|00001570| 72 20 70 72 69 6e 74 20 | 74 6f 29 20 61 6e 20 61 |r print |to) an a|
|00001580| 73 73 69 67 6e 6d 65 6e | 74 20 66 69 6c 65 20 6d |ssignmen|t file m|
|00001590| 75 73 74 20 62 65 0d 64 | 65 73 63 72 69 62 65 64 |ust be.d|escribed|
|000015a0| 20 62 79 20 61 20 22 44 | 65 73 63 72 69 70 74 69 | by a "D|escripti|
|000015b0| 6f 6e 22 20 73 74 72 75 | 63 74 75 72 65 2c 20 77 |on" stru|cture, w|
|000015c0| 68 69 63 68 20 68 61 73 | 20 66 69 65 6c 64 73 20 |hich has| fields |
|000015d0| 66 6f 72 20 74 68 65 20 | 74 79 70 65 2c 20 6e 61 |for the |type, na|
|000015e0| 6d 65 2c 0d 61 64 64 72 | 65 73 73 20 28 22 70 74 |me,.addr|ess ("pt|
|000015f0| 72 22 29 2c 20 61 6e 64 | 20 6f 74 68 65 72 20 63 |r"), and| other c|
|00001600| 68 61 72 61 63 74 65 72 | 69 73 74 69 63 73 20 6f |haracter|istics o|
|00001610| 66 20 79 6f 75 72 20 43 | 20 76 61 72 69 61 62 6c |f your C| variabl|
|00001620| 65 2e 0d 09 74 79 70 65 | 64 65 66 20 73 74 72 75 |e...type|def stru|
|00001630| 63 74 20 7b 0d 09 09 73 | 68 6f 72 74 20 74 79 70 |ct {...s|hort typ|
|00001640| 65 3b 0d 09 09 75 6e 73 | 69 67 6e 65 64 20 73 69 |e;...uns|igned si|
|00001650| 7a 65 64 4f 6e 63 65 3a | 31 3b 09 2f 2a 20 49 73 |zedOnce:|1;./* Is|
|00001660| 20 64 69 6d 5b 5d 20 6d | 65 61 6e 69 6e 67 66 75 | dim[] m|eaningfu|
|00001670| 6c 3f 20 2a 2f 0d 09 09 | 75 6e 73 69 67 6e 65 64 |l? */...|unsigned|
|00001680| 20 73 69 7a 65 64 3a 31 | 3b 09 09 2f 2a 20 49 73 | sized:1|;../* Is|
|00001690| 20 64 69 6d 5b 5d 20 66 | 69 6e 61 6c 3f 20 2a 2f | dim[] f|inal? */|
|000016a0| 0d 09 09 75 6e 73 69 67 | 6e 65 64 20 6d 61 6c 6c |...unsig|ned mall|
|000016b0| 6f 63 65 64 3a 31 3b 09 | 2f 2a 20 41 6c 6c 6f 63 |oced:1;.|/* Alloc|
|000016c0| 61 74 65 64 20 62 79 20 | 6d 61 6c 6c 6f 63 3f 20 |ated by |malloc? |
|000016d0| 2a 2f 0d 09 09 63 68 61 | 72 20 2a 6e 61 6d 65 3b |*/...cha|r *name;|
|000016e0| 0d 09 09 76 6f 69 64 20 | 2a 70 74 72 3b 09 09 09 |...void |*ptr;...|
|000016f0| 09 2f 2a 20 66 6f 72 20 | 61 72 72 61 79 2c 20 61 |./* for |array, a|
|00001700| 64 64 72 65 73 73 20 6f | 66 20 65 6c 65 6d 65 6e |ddress o|f elemen|
|00001710| 74 20 7a 65 72 6f 20 2a | 2f 0d 09 09 6c 6f 6e 67 |t zero *|/...long|
|00001720| 20 64 69 6d 5b 41 53 53 | 49 47 4e 5f 44 49 4d 53 | dim[ASS|IGN_DIMS|
|00001730| 5d 3b 09 2f 2a 20 7a 65 | 72 6f 20 69 6e 64 69 63 |];./* ze|ro indic|
|00001740| 61 74 65 73 20 61 20 73 | 63 61 6c 61 72 20 2a 2f |ates a s|calar */|
|00001750| 0d 09 09 6c 6f 6e 67 20 | 66 69 72 73 74 45 6c 65 |...long |firstEle|
|00001760| 6d 65 6e 74 3b 2f 2a 20 | 73 75 62 73 63 72 69 70 |ment;/* |subscrip|
|00001770| 74 20 6f 66 20 66 69 72 | 73 74 20 65 6c 65 6d 65 |t of fir|st eleme|
|00001780| 6e 74 20 6f 66 20 6c 61 | 73 74 20 64 69 6d 65 6e |nt of la|st dimen|
|00001790| 73 69 6f 6e 2e 20 55 73 | 75 61 6c 6c 79 20 30 20 |sion. Us|ually 0 |
|000017a0| 2a 2f 0d 09 09 63 6f 6e | 73 74 20 63 68 61 72 20 |*/...con|st char |
|000017b0| 2a 63 6f 6d 6d 65 6e 74 | 3b 09 2f 2a 20 74 65 78 |*comment|;./* tex|
|000017c0| 74 20 73 74 72 69 6e 67 | 2c 20 6f 72 20 4e 55 4c |t string|, or NUL|
|000017d0| 4c 20 2a 2f 0d 09 7d 20 | 44 65 73 63 72 69 70 74 |L */..} |Descript|
|000017e0| 69 6f 6e 3b 0d 54 68 65 | 20 72 6f 75 74 69 6e 65 |ion;.The| routine|
|000017f0| 73 20 44 65 73 63 72 69 | 62 65 2c 20 44 65 73 63 |s Descri|be, Desc|
|00001800| 72 69 62 65 41 72 72 61 | 79 2c 20 61 6e 64 20 44 |ribeArra|y, and D|
|00001810| 65 73 63 72 69 62 65 46 | 69 72 73 74 4c 61 73 74 |escribeF|irstLast|
|00001820| 20 61 72 65 20 63 6f 6e | 76 65 6e 69 65 6e 74 20 | are con|venient |
|00001830| 77 61 79 73 0d 74 6f 20 | 73 65 74 20 61 6c 6c 20 |ways.to |set all |
|00001840| 74 68 65 20 66 69 65 6c | 64 73 2e 20 55 73 65 20 |the fiel|ds. Use |
|00001850| 74 68 65 73 65 20 72 6f | 75 74 69 6e 65 73 20 28 |these ro|utines (|
|00001860| 69 6e 73 74 65 61 64 20 | 6f 66 20 65 78 70 6c 69 |instead |of expli|
|00001870| 63 69 74 6c 79 20 6c 6f | 61 64 69 6e 67 20 74 68 |citly lo|ading th|
|00001880| 65 0d 66 69 65 6c 64 73 | 20 79 6f 75 72 73 65 6c |e.fields| yoursel|
|00001890| 66 29 20 74 6f 20 65 6e | 68 61 6e 63 65 20 74 68 |f) to en|hance th|
|000018a0| 65 20 63 6f 6d 70 61 74 | 69 62 69 6c 69 74 79 20 |e compat|ibility |
|000018b0| 6f 66 20 79 6f 75 72 20 | 70 72 6f 67 72 61 6d 73 |of your |programs|
|000018c0| 20 77 69 74 68 20 66 75 | 74 75 72 65 0d 65 6e 68 | with fu|ture.enh|
|000018d0| 61 6e 63 65 6d 65 6e 74 | 73 20 74 6f 20 41 73 73 |ancement|s to Ass|
|000018e0| 69 67 6e 2e 63 2c 20 77 | 68 69 63 68 20 6d 69 67 |ign.c, w|hich mig|
|000018f0| 68 74 20 72 65 64 65 66 | 69 6e 65 20 74 68 65 20 |ht redef|ine the |
|00001900| 66 69 65 6c 64 73 20 6f | 66 20 74 68 65 20 44 65 |fields o|f the De|
|00001910| 73 63 72 69 70 74 69 6f | 6e 0d 73 74 72 75 63 74 |scriptio|n.struct|
|00001920| 75 72 65 2e 0d 09 44 65 | 73 63 72 69 70 74 69 6f |ure...De|scriptio|
|00001930| 6e 20 44 65 73 63 72 69 | 62 65 28 73 68 6f 72 74 |n Descri|be(short|
|00001940| 20 74 79 70 65 2c 76 6f | 69 64 20 2a 70 74 72 2c | type,vo|id *ptr,|
|00001950| 63 68 61 72 20 2a 6e 61 | 6d 65 2c 63 6f 6e 73 74 |char *na|me,const|
|00001960| 20 63 68 61 72 20 2a 63 | 6f 6d 6d 65 6e 74 29 3b | char *c|omment);|
|00001970| 0d 09 73 68 6f 72 74 20 | 6e 3b 0d 09 64 5b 69 2b |..short |n;..d[i+|
|00001980| 2b 5d 3d 44 65 73 63 72 | 69 62 65 28 73 68 6f 72 |+]=Descr|ibe(shor|
|00001990| 74 54 79 70 65 2c 26 6e | 2c 22 6e 22 2c 22 68 65 |tType,&n|,"n","he|
|000019a0| 6c 6c 6f 22 29 3b 0d 54 | 68 65 20 61 76 61 69 6c |llo");.T|he avail|
|000019b0| 61 62 6c 65 20 74 79 70 | 65 73 20 66 61 6c 6c 20 |able typ|es fall |
|000019c0| 69 6e 74 6f 20 74 68 72 | 65 65 20 67 72 6f 75 70 |into thr|ee group|
|000019d0| 73 2e 20 54 68 65 20 62 | 61 73 69 63 20 74 79 70 |s. The b|asic typ|
|000019e0| 65 73 20 63 6f 72 72 65 | 73 70 6f 6e 64 20 74 6f |es corre|spond to|
|000019f0| 20 74 68 65 0d 62 61 73 | 69 63 20 74 79 70 65 73 | the.bas|ic types|
|00001a00| 20 69 6e 20 43 3a 20 63 | 68 61 72 54 79 70 65 2c | in C: c|harType,|
|00001a10| 20 75 6e 73 69 67 6e 65 | 64 43 68 61 72 54 79 70 | unsigne|dCharTyp|
|00001a20| 65 2c 20 73 68 6f 72 74 | 54 79 70 65 2c 20 75 6e |e, short|Type, un|
|00001a30| 73 69 67 6e 65 64 53 68 | 6f 72 74 54 79 70 65 2c |signedSh|ortType,|
|00001a40| 0d 6c 6f 6e 67 54 79 70 | 65 2c 20 75 6e 73 69 67 |.longTyp|e, unsig|
|00001a50| 6e 65 64 4c 6f 6e 67 54 | 79 70 65 2c 20 66 6c 6f |nedLongT|ype, flo|
|00001a60| 61 74 54 79 70 65 2c 20 | 73 68 6f 72 74 44 6f 75 |atType, |shortDou|
|00001a70| 62 6c 65 54 79 70 65 2c | 20 61 6e 64 20 64 6f 75 |bleType,| and dou|
|00001a80| 62 6c 65 54 79 70 65 2e | 20 41 0d 73 65 63 6f 6e |bleType.| A.secon|
|00001a90| 64 2c 20 63 6f 72 72 65 | 73 70 6f 6e 64 69 6e 67 |d, corre|sponding|
|00001aa0| 2c 20 67 72 6f 75 70 20 | 6f 66 20 74 79 70 65 73 |, group |of types|
|00001ab0| 2c 20 61 64 64 69 6e 67 | 20 74 68 65 20 77 6f 72 |, adding| the wor|
|00001ac0| 64 20 22 50 74 72 22 2c | 20 72 65 71 75 65 73 74 |d "Ptr",| request|
|00001ad0| 73 20 64 79 6e 61 6d 69 | 63 0d 61 72 72 61 79 20 |s dynami|c.array |
|00001ae0| 61 6c 6c 6f 63 61 74 69 | 6f 6e 3a 20 63 68 61 72 |allocati|on: char|
|00001af0| 50 74 72 54 79 70 65 2c | 20 75 6e 73 69 67 6e 65 |PtrType,| unsigne|
|00001b00| 64 43 68 61 72 50 74 72 | 54 79 70 65 2c 20 73 68 |dCharPtr|Type, sh|
|00001b10| 6f 72 74 50 74 72 54 79 | 70 65 2c 0d 75 6e 73 69 |ortPtrTy|pe,.unsi|
|00001b20| 67 6e 65 64 53 68 6f 72 | 74 50 74 72 54 79 70 65 |gnedShor|tPtrType|
|00001b30| 2c 20 6c 6f 6e 67 50 74 | 72 54 79 70 65 2c 20 75 |, longPt|rType, u|
|00001b40| 6e 73 69 67 6e 65 64 4c | 6f 6e 67 50 74 72 54 79 |nsignedL|ongPtrTy|
|00001b50| 70 65 2c 20 66 6c 6f 61 | 74 50 74 72 54 79 70 65 |pe, floa|tPtrType|
|00001b60| 2c 0d 73 68 6f 72 74 44 | 6f 75 62 6c 65 50 74 72 |,.shortD|oublePtr|
|00001b70| 54 79 70 65 2c 20 61 6e | 64 20 64 6f 75 62 6c 65 |Type, an|d double|
|00001b80| 50 74 72 54 79 70 65 2e | 20 54 68 65 20 74 68 69 |PtrType.| The thi|
|00001b90| 72 64 20 67 72 6f 75 70 | 20 63 6f 6e 73 69 73 74 |rd group| consist|
|00001ba0| 73 20 73 6f 6c 65 6c 79 | 20 6f 66 20 74 68 65 0d |s solely| of the.|
|00001bb0| 22 73 74 72 69 6e 67 54 | 79 70 65 22 2c 20 77 68 |"stringT|ype", wh|
|00001bc0| 69 63 68 20 69 73 20 68 | 61 6e 64 6c 65 64 20 73 |ich is h|andled s|
|00001bd0| 6f 6d 65 77 68 61 74 20 | 64 69 66 66 65 72 65 6e |omewhat |differen|
|00001be0| 74 6c 79 20 66 72 6f 6d | 20 74 68 65 20 63 68 61 |tly from| the cha|
|00001bf0| 72 50 74 72 54 79 70 65 | 2e 20 28 4e 6f 74 65 3a |rPtrType|. (Note:|
|00001c00| 0d 73 69 6e 63 65 20 53 | 74 61 6e 64 61 72 64 20 |.since S|tandard |
|00001c10| 43 20 64 6f 65 73 6e 27 | 74 20 61 6c 6c 6f 77 20 |C doesn'|t allow |
|00001c20| 74 68 65 20 22 73 68 6f | 72 74 20 64 6f 75 62 6c |the "sho|rt doubl|
|00001c30| 65 22 20 74 79 70 65 2c | 20 74 68 65 20 73 68 6f |e" type,| the sho|
|00001c40| 72 74 44 6f 75 62 6c 65 | 54 79 70 65 20 61 6e 64 |rtDouble|Type and|
|00001c50| 0d 73 68 6f 72 74 44 6f | 75 62 6c 65 50 74 72 54 |.shortDo|ublePtrT|
|00001c60| 79 70 65 20 61 72 65 20 | 63 6f 6e 64 69 74 69 6f |ype are |conditio|
|00001c70| 6e 61 6c 6c 79 20 63 6f | 6d 70 69 6c 65 64 2c 20 |nally co|mpiled, |
|00001c80| 63 6f 6e 74 72 6f 6c 6c | 65 64 20 62 79 20 53 48 |controll|ed by SH|
|00001c90| 4f 52 54 5f 44 4f 55 42 | 4c 45 5f 4f 4b 2c 0d 77 |ORT_DOUB|LE_OK,.w|
|00001ca0| 68 69 63 68 20 69 73 20 | 64 65 66 69 6e 65 64 20 |hich is |defined |
|00001cb0| 69 6e 20 56 69 64 65 6f | 54 6f 6f 6c 62 6f 78 2e |in Video|Toolbox.|
|00001cc0| 68 2e 29 20 54 68 65 20 | 6e 61 6d 65 20 61 72 67 |h.) The |name arg|
|00001cd0| 75 6d 65 6e 74 20 73 74 | 72 69 6e 67 20 69 73 20 |ument st|ring is |
|00001ce0| 75 73 65 64 20 69 6e 20 | 72 65 61 64 69 6e 67 20 |used in |reading |
|00001cf0| 74 68 65 0d 61 73 73 69 | 67 6e 6d 65 6e 74 20 66 |the.assi|gnment f|
|00001d00| 69 6c 65 2e 20 54 68 65 | 20 70 74 72 20 61 72 67 |ile. The| ptr arg|
|00001d10| 75 6d 65 6e 74 20 73 68 | 6f 75 6c 64 20 62 65 20 |ument sh|ould be |
|00001d20| 74 68 65 20 61 64 64 72 | 65 73 73 20 6f 66 20 61 |the addr|ess of a|
|00001d30| 20 43 20 76 61 72 69 61 | 62 6c 65 20 6f 66 20 74 | C varia|ble of t|
|00001d40| 68 65 0d 74 79 70 65 20 | 73 70 65 63 69 66 69 65 |he.type |specifie|
|00001d50| 64 20 62 79 20 74 68 65 | 20 74 79 70 65 20 61 72 |d by the| type ar|
|00001d60| 67 75 6d 65 6e 74 20 28 | 65 2e 67 2e 20 66 6c 6f |gument (|e.g. flo|
|00001d70| 61 74 29 2e 20 57 68 65 | 6e 20 74 68 65 20 74 79 |at). Whe|n the ty|
|00001d80| 70 65 20 69 73 20 6f 6e | 65 20 6f 66 20 74 68 65 |pe is on|e of the|
|00001d90| 0d 50 74 72 20 74 79 70 | 65 73 2c 20 6f 72 20 73 |.Ptr typ|es, or s|
|00001da0| 74 72 69 6e 67 54 79 70 | 65 2c 20 74 68 65 6e 20 |tringTyp|e, then |
|00001db0| 74 68 65 20 43 20 76 61 | 72 69 61 62 6c 65 20 73 |the C va|riable s|
|00001dc0| 68 6f 75 6c 64 20 62 65 | 20 61 20 70 6f 69 6e 74 |hould be| a point|
|00001dd0| 65 72 20 6f 66 20 74 68 | 65 0d 61 70 70 72 6f 70 |er of th|e.approp|
|00001de0| 72 69 61 74 65 20 6b 69 | 6e 64 2c 20 73 6f 20 74 |riate ki|nd, so t|
|00001df0| 68 65 20 22 70 74 72 22 | 20 61 72 67 75 6d 65 6e |he "ptr"| argumen|
|00001e00| 74 20 79 6f 75 20 73 75 | 70 70 6c 79 20 77 69 6c |t you su|pply wil|
|00001e10| 6c 20 62 65 20 74 68 65 | 20 61 64 64 72 65 73 73 |l be the| address|
|00001e20| 20 6f 66 20 74 68 61 74 | 0d 70 6f 69 6e 74 65 72 | of that|.pointer|
|00001e30| 2e 20 54 68 65 20 6c 61 | 73 74 20 61 72 67 75 6d |. The la|st argum|
|00001e40| 65 6e 74 20 74 6f 20 44 | 65 73 63 72 69 62 65 28 |ent to D|escribe(|
|00001e50| 29 20 69 73 20 63 6f 6d | 6d 65 6e 74 2c 20 77 68 |) is com|ment, wh|
|00001e60| 69 63 68 20 6d 75 73 74 | 20 62 65 20 61 20 73 74 |ich must| be a st|
|00001e70| 72 69 6e 67 20 6f 72 0d | 4e 55 4c 4c 2e 20 41 6e |ring or.|NULL. An|
|00001e80| 79 20 63 61 6c 6c 20 74 | 6f 20 50 72 69 6e 74 41 |y call t|o PrintA|
|00001e90| 6e 41 73 73 69 67 6e 6d | 65 6e 74 28 29 20 77 69 |nAssignm|ent() wi|
|00001ea0| 6c 6c 20 70 72 69 6e 74 | 20 74 68 65 20 63 6f 6d |ll print| the com|
|00001eb0| 6d 65 6e 74 20 28 69 66 | 20 6e 6f 74 20 4e 55 4c |ment (if| not NUL|
|00001ec0| 4c 29 20 61 66 74 65 72 | 0d 74 68 65 20 61 73 73 |L) after|.the ass|
|00001ed0| 69 67 6e 6d 65 6e 74 20 | 73 74 61 74 65 6d 65 6e |ignment |statemen|
|00001ee0| 74 2c 20 73 75 72 72 6f | 75 6e 64 69 6e 67 20 69 |t, surro|unding i|
|00001ef0| 74 20 62 79 20 2f 2a 20 | 2a 2f 2e 0d 09 44 65 73 |t by /* |*/...Des|
|00001f00| 63 72 69 70 74 69 6f 6e | 20 44 65 73 63 72 69 62 |cription| Describ|
|00001f10| 65 41 72 72 61 79 28 73 | 68 6f 72 74 20 74 79 70 |eArray(s|hort typ|
|00001f20| 65 2c 76 6f 69 64 20 2a | 70 74 72 2c 63 68 61 72 |e,void *|ptr,char|
|00001f30| 20 2a 6e 61 6d 65 2c 63 | 6f 6e 73 74 20 63 68 61 | *name,c|onst cha|
|00001f40| 72 20 2a 63 6f 6d 6d 65 | 6e 74 2c 2e 2e 2e 29 3b |r *comme|nt,...);|
|00001f50| 0d 09 64 6f 75 62 6c 65 | 20 62 5b 33 5d 5b 34 5d |..double| b[3][4]|
|00001f60| 3b 0d 09 64 5b 69 2b 2b | 5d 3d 44 65 73 63 72 69 |;..d[i++|]=Descri|
|00001f70| 62 65 41 72 72 61 79 28 | 64 6f 75 62 6c 65 54 79 |beArray(|doubleTy|
|00001f80| 70 65 2c 26 62 2c 22 62 | 22 2c 22 63 6f 65 66 66 |pe,&b,"b|","coeff|
|00001f90| 69 63 69 65 6e 74 73 22 | 2c 33 4c 2c 34 4c 2c 30 |icients"|,3L,4L,0|
|00001fa0| 4c 29 3b 0d 46 6f 72 20 | 74 68 65 20 62 61 73 69 |L);.For |the basi|
|00001fb0| 63 20 61 6e 64 20 73 74 | 72 69 6e 67 20 74 79 70 |c and st|ring typ|
|00001fc0| 65 73 2c 20 74 68 65 20 | 73 75 70 70 6c 69 65 64 |es, the |supplied|
|00001fd0| 20 43 20 76 61 72 69 61 | 62 6c 65 20 63 61 6e 20 | C varia|ble can |
|00001fe0| 62 65 20 61 6e 20 61 72 | 72 61 79 2c 20 77 68 6f |be an ar|ray, who|
|00001ff0| 73 65 0d 64 69 6d 65 6e | 73 69 6f 6e 73 20 61 72 |se.dimen|sions ar|
|00002000| 65 20 73 70 65 63 69 66 | 69 65 64 20 61 73 20 61 |e specif|ied as a|
|00002010| 64 64 69 74 69 6f 6e 61 | 6c 20 61 72 67 75 6d 65 |dditiona|l argume|
|00002020| 6e 74 73 20 74 6f 20 44 | 65 73 63 72 69 62 65 41 |nts to D|escribeA|
|00002030| 72 72 61 79 2e 20 54 68 | 65 72 65 20 6d 61 79 0d |rray. Th|ere may.|
|00002040| 62 65 20 75 70 20 74 6f | 20 41 53 53 49 47 4e 5f |be up to| ASSIGN_|
|00002050| 44 49 4d 53 20 64 69 6d | 65 6e 73 69 6f 6e 73 2e |DIMS dim|ensions.|
|00002060| 20 45 61 63 68 20 64 69 | 6d 65 6e 73 69 6f 6e 20 | Each di|mension |
|00002070| 6d 75 73 74 20 62 65 20 | 61 20 6c 6f 6e 67 2c 20 |must be |a long, |
|00002080| 61 6e 64 20 74 68 65 20 | 61 72 67 75 6d 65 6e 74 |and the |argument|
|00002090| 0d 6c 69 73 74 20 6d 75 | 73 74 20 62 65 20 74 65 |.list mu|st be te|
|000020a0| 72 6d 69 6e 61 74 65 64 | 20 62 79 20 30 4c 2c 20 |rminated| by 0L, |
|000020b0| 69 2e 65 2e 20 61 20 7a | 65 72 6f 20 6f 66 20 74 |i.e. a z|ero of t|
|000020c0| 79 70 65 20 6c 6f 6e 67 | 2e 0d 0d 41 72 72 61 79 |ype long|...Array|
|000020d0| 73 20 6f 66 20 73 74 72 | 69 6e 67 54 79 70 65 20 |s of str|ingType |
|000020e0| 61 72 65 20 61 6c 6c 6f | 77 65 64 2c 20 65 2e 67 |are allo|wed, e.g|
|000020f0| 2e 20 0d 09 63 68 61 72 | 20 2a 6e 69 63 6b 6e 61 |. ..char| *nickna|
|00002100| 6d 65 73 5b 31 30 5d 3b | 0d 09 44 65 73 63 72 69 |mes[10];|..Descri|
|00002110| 62 65 41 72 72 61 79 28 | 73 74 72 69 6e 67 54 79 |beArray(|stringTy|
|00002120| 70 65 2c 26 6e 69 63 6b | 6e 61 6d 65 73 2c 22 6e |pe,&nick|names,"n|
|00002130| 69 63 6b 6e 61 6d 65 73 | 22 2c 4e 55 4c 4c 2c 31 |icknames|",NULL,1|
|00002140| 30 4c 2c 30 4c 29 3b 0d | 42 75 74 2c 20 69 6e 20 |0L,0L);.|But, in |
|00002150| 74 68 61 74 20 63 61 73 | 65 2c 20 6d 61 6c 6c 6f |that cas|e, mallo|
|00002160| 63 65 64 20 73 70 61 63 | 65 20 66 6f 72 20 61 20 |ced spac|e for a |
|00002170| 73 74 72 69 6e 67 20 69 | 73 20 6e 6f 74 20 66 72 |string i|s not fr|
|00002180| 65 65 64 20 77 68 65 6e | 20 61 20 6e 65 77 20 73 |eed when| a new s|
|00002190| 74 72 69 6e 67 20 0d 69 | 73 20 61 73 73 69 67 6e |tring .i|s assign|
|000021a0| 65 64 2e 0d 0d 52 45 41 | 44 49 4e 47 20 41 4e 20 |ed...REA|DING AN |
|000021b0| 41 53 53 49 47 4e 4d 45 | 4e 54 20 46 49 4c 45 0d |ASSIGNME|NT FILE.|
|000021c0| 0d 52 65 61 64 41 73 73 | 69 67 6e 6d 65 6e 74 4c |.ReadAss|ignmentL|
|000021d0| 69 6e 65 20 64 6f 65 73 | 20 61 6c 6c 20 74 68 65 |ine does| all the|
|000021e0| 20 72 65 61 64 69 6e 67 | 2e 20 52 65 61 64 41 73 | reading|. ReadAs|
|000021f0| 73 69 67 6e 6d 65 6e 74 | 42 6c 6f 63 6b 20 61 6e |signment|Block an|
|00002200| 64 0d 52 65 61 64 41 73 | 73 69 67 6e 6d 65 6e 74 |d.ReadAs|signment|
|00002210| 46 69 6c 65 20 6a 75 73 | 74 20 63 61 6c 6c 20 52 |File jus|t call R|
|00002220| 65 61 64 41 73 73 69 67 | 6e 6d 65 6e 74 4c 69 6e |eadAssig|nmentLin|
|00002230| 65 20 72 65 70 65 61 74 | 65 64 6c 79 2e 20 4f 6e |e repeat|edly. On|
|00002240| 65 20 62 79 20 6f 6e 65 | 2c 0d 52 65 61 64 41 73 |e by one|,.ReadAs|
|00002250| 73 69 67 6e 6d 65 6e 74 | 4c 69 6e 65 20 72 65 61 |signment|Line rea|
|00002260| 64 73 20 61 73 73 69 67 | 6e 6d 65 6e 74 73 20 66 |ds assig|nments f|
|00002270| 72 6f 6d 20 74 68 65 20 | 61 73 73 69 67 6e 6d 65 |rom the |assignme|
|00002280| 6e 74 20 66 69 6c 65 20 | 28 75 6e 74 69 6c 20 69 |nt file |(until i|
|00002290| 74 20 72 65 61 63 68 65 | 73 0d 74 68 65 20 65 6e |t reache|s.the en|
|000022a0| 64 20 6f 66 20 74 68 65 | 20 6c 69 6e 65 2c 20 6f |d of the| line, o|
|000022b0| 72 20 64 65 74 65 63 74 | 73 20 61 6e 20 65 72 72 |r detect|s an err|
|000022c0| 6f 72 29 2e 20 53 79 6e | 74 61 78 20 65 72 72 6f |or). Syn|tax erro|
|000022d0| 72 73 20 61 72 65 20 72 | 65 70 6f 72 74 65 64 2e |rs are r|eported.|
|000022e0| 0d 52 65 61 64 41 73 73 | 69 67 6e 6d 65 6e 74 4c |.ReadAss|ignmentL|
|000022f0| 69 6e 65 20 67 65 74 73 | 20 61 20 76 61 72 69 61 |ine gets| a varia|
|00002300| 62 6c 65 20 6e 61 6d 65 | 20 66 72 6f 6d 20 74 68 |ble name| from th|
|00002310| 65 20 61 73 73 69 67 6e | 6d 65 6e 74 20 66 69 6c |e assign|ment fil|
|00002320| 65 20 61 6e 64 20 6c 6f | 6f 6b 73 20 66 6f 72 20 |e and lo|oks for |
|00002330| 61 0d 6d 61 74 63 68 69 | 6e 67 20 6e 61 6d 65 20 |a.matchi|ng name |
|00002340| 69 6e 20 74 68 65 20 75 | 73 65 72 2d 73 75 70 70 |in the u|ser-supp|
|00002350| 6c 69 65 64 20 44 65 73 | 63 72 69 70 74 69 6f 6e |lied Des|cription|
|00002360| 20 61 72 72 61 79 2e 20 | 41 6e 79 20 69 6e 63 6f | array. |Any inco|
|00002370| 6e 73 69 73 74 65 6e 63 | 79 20 6f 66 20 74 68 65 |nsistenc|y of the|
|00002380| 0d 61 73 73 69 67 6e 6d | 65 6e 74 20 73 74 61 74 |.assignm|ent stat|
|00002390| 65 6d 65 6e 74 20 77 69 | 74 68 20 74 68 65 20 76 |ement wi|th the v|
|000023a0| 61 72 69 61 62 6c 65 27 | 73 20 64 65 63 6c 61 72 |ariable'|s declar|
|000023b0| 65 64 20 74 79 70 65 20 | 61 6e 64 20 64 69 6d 65 |ed type |and dime|
|000023c0| 6e 73 69 6f 6e 73 20 69 | 73 0d 72 65 70 6f 72 74 |nsions i|s.report|
|000023d0| 65 64 2e 20 54 68 65 6e | 20 74 68 65 20 61 73 73 |ed. Then| the ass|
|000023e0| 69 67 6e 6d 65 6e 74 20 | 69 73 20 6d 61 64 65 2e |ignment |is made.|
|000023f0| 0d 0d 41 73 73 69 67 6e | 6d 65 6e 74 20 74 6f 20 |..Assign|ment to |
|00002400| 62 61 73 69 63 20 76 61 | 72 69 61 62 6c 65 73 20 |basic va|riables |
|00002410| 69 73 20 73 74 72 61 69 | 67 68 74 66 6f 72 77 61 |is strai|ghtforwa|
|00002420| 72 64 2c 20 65 71 75 69 | 76 61 6c 65 6e 74 20 74 |rd, equi|valent t|
|00002430| 6f 20 61 73 73 69 67 6e | 6d 65 6e 74 20 69 6e 0d |o assign|ment in.|
|00002440| 61 20 43 20 70 72 6f 67 | 72 61 6d 2c 20 65 2e 67 |a C prog|ram, e.g|
|00002450| 2e 0d 09 61 5b 32 5d 5b | 31 5d 3d 33 2e 30 3b 0d |...a[2][|1]=3.0;.|
|00002460| 57 68 65 6e 20 52 65 61 | 64 41 73 73 69 67 6e 6d |When Rea|dAssignm|
|00002470| 65 6e 74 4c 69 6e 65 20 | 61 73 73 69 67 6e 73 20 |entLine |assigns |
|00002480| 61 20 73 74 72 69 6e 67 | 20 74 6f 20 61 20 73 74 |a string| to a st|
|00002490| 72 69 6e 67 54 79 70 65 | 20 76 61 72 69 61 62 6c |ringType| variabl|
|000024a0| 65 2c 0d 09 73 3d 22 68 | 65 6c 6c 6f 20 77 6f 72 |e,..s="h|ello wor|
|000024b0| 6c 64 22 3b 0d 74 68 65 | 20 73 74 72 69 6e 67 20 |ld";.the| string |
|000024c0| 69 73 20 61 6c 6c 6f 63 | 61 74 65 64 20 62 79 20 |is alloc|ated by |
|000024d0| 6d 61 6c 6c 6f 63 28 29 | 20 61 6e 64 20 74 68 65 |malloc()| and the|
|000024e0| 20 73 74 72 69 6e 67 27 | 73 20 61 64 64 72 65 73 | string'|s addres|
|000024f0| 73 20 69 73 20 70 6f 6b | 65 64 20 69 6e 74 6f 20 |s is pok|ed into |
|00002500| 79 6f 75 72 0d 63 68 61 | 72 20 2a 20 76 61 72 69 |your.cha|r * vari|
|00002510| 61 62 6c 65 2e 20 50 72 | 69 6f 72 20 74 6f 20 61 |able. Pr|ior to a|
|00002520| 73 73 69 67 6e 6d 65 6e | 74 20 6f 66 20 61 20 73 |ssignmen|t of a s|
|00002530| 74 72 69 6e 67 2c 20 46 | 72 65 65 41 44 65 73 63 |tring, F|reeADesc|
|00002540| 72 69 62 65 64 56 61 72 | 20 77 69 6c 6c 20 62 65 |ribedVar| will be|
|00002550| 0d 63 61 6c 6c 65 64 2c | 20 77 68 69 63 68 2c 20 |.called,| which, |
|00002560| 69 66 20 61 6e 79 20 70 | 72 65 2d 65 78 69 73 74 |if any p|re-exist|
|00002570| 69 6e 67 20 73 74 72 69 | 6e 67 20 77 61 73 20 61 |ing stri|ng was a|
|00002580| 6c 6c 6f 63 61 74 65 64 | 20 62 79 20 6d 61 6c 6c |llocated| by mall|
|00002590| 6f 63 2d 2d 61 73 20 69 | 6e 64 69 63 61 74 65 64 |oc--as i|ndicated|
|000025a0| 0d 62 79 20 74 68 65 20 | 64 2d 3e 6d 61 6c 6c 6f |.by the |d->mallo|
|000025b0| 63 65 64 20 66 6c 61 67 | 2d 2d 77 69 6c 6c 20 66 |ced flag|--will f|
|000025c0| 72 65 65 20 69 74 2e 20 | 59 6f 75 20 63 61 6e 20 |ree it. |You can |
|000025d0| 66 72 65 65 20 61 6c 6c | 20 79 6f 75 72 20 73 74 |free all| your st|
|000025e0| 72 69 6e 67 73 20 28 61 | 6e 64 0d 50 74 72 54 79 |rings (a|nd.PtrTy|
|000025f0| 70 65 20 76 61 72 69 61 | 62 6c 65 73 29 20 62 79 |pe varia|bles) by|
|00002600| 20 63 61 6c 6c 69 6e 67 | 20 46 72 65 65 44 65 73 | calling| FreeDes|
|00002610| 63 72 69 62 65 64 56 61 | 72 73 2e 0d 0d 54 68 65 |cribedVa|rs...The|
|00002620| 20 50 74 72 54 79 70 65 | 20 76 61 72 69 61 62 6c | PtrType| variabl|
|00002630| 65 73 20 69 6e 69 74 69 | 61 6c 6c 79 20 68 61 76 |es initi|ally hav|
|00002640| 65 20 6e 6f 20 73 70 61 | 63 65 20 61 6c 6c 6f 63 |e no spa|ce alloc|
|00002650| 61 74 69 6f 6e 20 66 6f | 72 20 73 74 6f 72 61 67 |ation fo|r storag|
|00002660| 65 20 6f 66 20 64 61 74 | 61 2e 20 45 61 63 68 0d |e of dat|a. Each.|
|00002670| 75 6e 61 6c 6c 6f 63 61 | 74 65 64 20 50 74 72 20 |unalloca|ted Ptr |
|00002680| 76 61 72 69 61 62 6c 65 | 20 69 73 20 61 75 74 6f |variable| is auto|
|00002690| 6d 61 74 69 63 61 6c 6c | 79 20 61 6c 6c 6f 63 61 |maticall|y alloca|
|000026a0| 74 65 64 20 73 70 61 63 | 65 20 66 6f 72 20 61 20 |ted spac|e for a |
|000026b0| 73 63 61 6c 61 72 20 6f | 72 20 61 72 72 61 79 0d |scalar o|r array.|
|000026c0| 64 69 6d 65 6e 73 69 6f | 6e 65 64 20 6a 75 73 74 |dimensio|ned just|
|000026d0| 20 62 69 67 20 65 6e 6f | 75 67 68 20 74 6f 20 63 | big eno|ugh to c|
|000026e0| 6f 6e 74 61 69 6e 20 61 | 6c 6c 20 74 68 65 20 61 |ontain a|ll the a|
|000026f0| 73 73 69 67 6e 6d 65 6e | 74 73 20 69 6e 20 74 68 |ssignmen|ts in th|
|00002700| 65 20 70 61 72 74 20 28 | 6f 72 0d 22 67 75 6c 70 |e part (|or."gulp|
|00002710| 22 29 20 6f 66 20 74 68 | 65 20 61 73 73 69 67 6e |") of th|e assign|
|00002720| 6d 65 6e 74 20 66 69 6c | 65 20 74 68 61 74 20 74 |ment fil|e that t|
|00002730| 68 65 20 75 73 65 72 20 | 68 61 73 20 6a 75 73 74 |he user |has just|
|00002740| 20 61 73 6b 65 64 20 74 | 6f 20 72 65 61 64 3a 20 | asked t|o read: |
|00002750| 61 20 6c 69 6e 65 2c 20 | 61 0d 62 6c 6f 63 6b 2c |a line, |a.block,|
|00002760| 20 6f 72 20 74 68 65 20 | 77 68 6f 6c 65 20 66 69 | or the |whole fi|
|00002770| 6c 65 2e 20 28 49 66 20 | 74 68 65 20 50 74 72 20 |le. (If |the Ptr |
|00002780| 76 61 72 69 61 62 6c 65 | 20 69 73 20 64 69 6d 65 |variable| is dime|
|00002790| 6e 73 69 6f 6e 65 64 2c | 20 66 72 6f 6d 20 61 20 |nsioned,| from a |
|000027a0| 63 61 6c 6c 20 74 6f 0d | 44 65 73 63 72 69 62 65 |call to.|Describe|
|000027b0| 41 72 72 61 79 2c 20 62 | 75 74 20 6e 6f 74 20 61 |Array, b|ut not a|
|000027c0| 6c 6c 6f 63 61 74 65 64 | 2c 20 74 68 65 6e 20 69 |llocated|, then i|
|000027d0| 74 20 77 69 6c 6c 20 62 | 65 20 61 6c 6c 6f 63 61 |t will b|e alloca|
|000027e0| 74 65 64 20 61 74 20 74 | 68 65 20 64 65 63 6c 61 |ted at t|he decla|
|000027f0| 72 65 64 0d 73 69 7a 65 | 2e 29 20 4f 6e 63 65 20 |red.size|.) Once |
|00002800| 61 6c 6c 6f 63 61 74 65 | 64 2c 20 74 68 65 20 61 |allocate|d, the a|
|00002810| 72 72 61 79 20 64 69 6d | 65 6e 73 69 6f 6e 73 20 |rray dim|ensions |
|00002820| 61 72 65 20 66 69 78 65 | 64 2c 20 75 6e 6c 65 73 |are fixe|d, unles|
|00002830| 73 20 74 68 65 20 75 73 | 65 72 20 66 72 65 65 73 |s the us|er frees|
|00002840| 20 74 68 65 0d 61 6c 6c | 6f 63 61 74 69 6f 6e 73 | the.all|ocations|
|00002850| 20 62 79 20 63 61 6c 6c | 69 6e 67 20 46 72 65 65 | by call|ing Free|
|00002860| 44 65 73 63 72 69 62 65 | 64 50 74 72 56 61 72 73 |Describe|dPtrVars|
|00002870| 28 29 20 6f 72 20 46 72 | 65 65 44 65 73 63 72 69 |() or Fr|eeDescri|
|00002880| 62 65 64 56 61 72 73 28 | 29 2c 20 77 68 69 63 68 |bedVars(|), which|
|00002890| 20 61 6c 73 6f 0d 63 6c | 65 61 72 20 74 68 65 20 | also.cl|ear the |
|000028a0| 61 72 72 61 79 27 73 20 | 64 69 6d 65 6e 73 69 6f |array's |dimensio|
|000028b0| 6e 73 20 28 77 68 65 74 | 68 65 72 20 73 65 74 20 |ns (whet|her set |
|000028c0| 64 79 6e 61 6d 69 63 61 | 6c 6c 79 20 6f 72 20 62 |dynamica|lly or b|
|000028d0| 79 20 61 6e 20 69 6e 69 | 74 69 61 6c 20 63 61 6c |y an ini|tial cal|
|000028e0| 6c 20 74 6f 0d 44 65 73 | 63 72 69 62 65 41 72 72 |l to.Des|cribeArr|
|000028f0| 61 79 29 2e 20 52 65 73 | 74 72 69 63 74 69 6e 67 |ay). Res|tricting|
|00002900| 20 74 68 65 20 73 63 61 | 6e 20 74 6f 20 74 68 65 | the sca|n to the|
|00002910| 20 63 75 72 72 65 6e 74 | 20 67 75 6c 70 20 6d 61 | current| gulp ma|
|00002920| 6b 65 73 20 69 74 20 70 | 6f 73 73 69 62 6c 65 20 |kes it p|ossible |
|00002930| 74 6f 0d 72 65 61 64 20 | 61 73 73 69 67 6e 6d 65 |to.read |assignme|
|00002940| 6e 74 20 66 69 6c 65 73 | 20 69 6e 20 77 68 69 63 |nt files| in whic|
|00002950| 68 20 74 68 65 20 61 72 | 72 61 79 20 73 69 7a 65 |h the ar|ray size|
|00002960| 73 20 63 68 61 6e 67 65 | 20 66 72 6f 6d 20 67 75 |s change| from gu|
|00002970| 6c 70 20 74 6f 20 67 75 | 6c 70 2c 0d 70 72 6f 76 |lp to gu|lp,.prov|
|00002980| 69 64 65 64 20 6f 6e 6c | 79 20 74 68 61 74 20 62 |ided onl|y that b|
|00002990| 65 74 77 65 65 6e 20 67 | 75 6c 70 73 20 74 68 65 |etween g|ulps the|
|000029a0| 20 75 73 65 72 20 63 61 | 6c 6c 73 20 46 72 65 65 | user ca|lls Free|
|000029b0| 44 65 73 63 72 69 62 65 | 64 50 74 72 56 61 72 73 |Describe|dPtrVars|
|000029c0| 28 29 20 6f 72 0d 46 72 | 65 65 44 65 73 63 72 69 |() or.Fr|eeDescri|
|000029d0| 62 65 64 56 61 72 73 28 | 29 2e 20 41 6e 20 69 6e |bedVars(|). An in|
|000029e0| 63 6f 6e 73 69 73 74 65 | 6e 74 20 6e 75 6d 62 65 |consiste|nt numbe|
|000029f0| 72 20 6f 66 20 61 72 72 | 61 79 20 64 69 6d 65 6e |r of arr|ay dimen|
|00002a00| 73 69 6f 6e 73 0d 09 61 | 5b 30 5d 3d 31 3b 20 61 |sions..a|[0]=1; a|
|00002a10| 5b 30 5d 5b 30 5d 3d 31 | 3b 0d 77 69 74 68 69 6e |[0][0]=1|;.within|
|00002a20| 20 61 20 67 75 6c 70 20 | 69 73 20 66 6c 61 67 67 | a gulp |is flagg|
|00002a30| 65 64 20 61 73 20 61 6e | 20 65 72 72 6f 72 2e 20 |ed as an| error. |
|00002a40| 0d 0d 52 4f 55 54 49 4e | 45 53 0d 0d 09 73 74 72 |..ROUTIN|ES...str|
|00002a50| 65 61 6d 3d 4f 70 65 6e | 43 61 6c 46 69 6c 65 57 |eam=Open|CalFileW|
|00002a60| 72 69 74 65 28 66 69 6c | 65 6e 61 6d 65 29 3b 0d |rite(fil|ename);.|
|00002a70| 4f 70 65 6e 20 75 70 20 | 61 20 63 61 6c 69 62 72 |Open up |a calibr|
|00002a80| 61 74 69 6f 6e 20 66 69 | 6c 65 20 66 6f 72 20 61 |ation fi|le for a|
|00002a90| 70 70 65 6e 64 69 6e 67 | 2e 20 49 66 20 74 68 65 |ppending|. If the|
|00002aa0| 20 66 69 6c 65 20 65 78 | 69 73 74 73 20 69 6e 20 | file ex|ists in |
|00002ab0| 74 68 65 20 63 75 72 72 | 65 6e 74 0d 64 69 72 65 |the curr|ent.dire|
|00002ac0| 63 74 6f 72 79 2c 20 69 | 74 20 69 73 20 75 73 65 |ctory, i|t is use|
|00002ad0| 64 2e 20 49 66 20 6e 6f | 74 2c 20 74 68 65 6e 20 |d. If no|t, then |
|00002ae0| 69 66 20 69 74 20 65 78 | 69 73 74 73 20 69 6e 20 |if it ex|ists in |
|00002af0| 74 68 65 20 50 72 65 66 | 65 72 65 6e 63 65 73 20 |the Pref|erences |
|00002b00| 66 6f 6c 64 65 72 2c 20 | 69 74 0d 75 73 65 64 2e |folder, |it.used.|
|00002b10| 20 49 66 20 6e 6f 74 2c | 20 74 68 65 20 66 69 6c | If not,| the fil|
|00002b20| 65 20 69 73 20 63 72 65 | 61 74 65 64 20 69 6e 20 |e is cre|ated in |
|00002b30| 74 68 65 20 50 72 65 66 | 65 72 65 6e 63 65 73 20 |the Pref|erences |
|00002b40| 66 6f 6c 64 65 72 2e 0d | 0d 09 73 74 72 65 61 6d |folder..|..stream|
|00002b50| 3d 4f 70 65 6e 43 61 6c | 46 69 6c 65 52 65 61 64 |=OpenCal|FileRead|
|00002b60| 28 66 69 6c 65 6e 61 6d | 65 29 3b 0d 4f 70 65 6e |(filenam|e);.Open|
|00002b70| 20 75 70 20 61 20 63 61 | 6c 69 62 72 61 74 69 6f | up a ca|libratio|
|00002b80| 6e 20 66 69 6c 65 20 66 | 6f 72 20 72 65 61 64 69 |n file f|or readi|
|00002b90| 6e 67 2e 20 46 69 72 73 | 74 20 6c 6f 6f 6b 73 20 |ng. Firs|t looks |
|00002ba0| 69 6e 20 74 68 65 20 63 | 75 72 72 65 6e 74 20 64 |in the c|urrent d|
|00002bb0| 69 72 65 63 74 6f 72 79 | 2c 0d 74 68 65 6e 20 69 |irectory|,.then i|
|00002bc0| 6e 20 74 68 65 20 70 72 | 65 66 65 72 65 6e 63 65 |n the pr|eference|
|00002bd0| 73 20 66 6f 6c 64 65 72 | 2e 20 4f 6e 20 73 75 63 |s folder|. On suc|
|00002be0| 63 65 73 73 20 72 65 74 | 75 72 6e 73 20 74 68 65 |cess ret|urns the|
|00002bf0| 20 6f 70 65 6e 65 64 20 | 66 69 6c 65 27 73 20 73 | opened |file's s|
|00002c00| 74 72 65 61 6d 2e 20 4f | 6e 0d 66 61 69 6c 75 72 |tream. O|n.failur|
|00002c10| 65 20 72 65 74 75 72 6e | 73 20 4e 55 4c 4c 2e 0d |e return|s NULL..|
|00002c20| 0d 09 73 74 72 65 61 6d | 3d 4f 70 65 6e 43 61 6c |..stream|=OpenCal|
|00002c30| 46 69 6c 65 52 65 61 64 | 41 6e 64 43 68 65 63 6b |FileRead|AndCheck|
|00002c40| 28 66 69 6c 65 6e 61 6d | 65 29 3b 0d 4f 70 65 6e |(filenam|e);.Open|
|00002c50| 20 75 70 20 61 20 63 61 | 6c 69 62 72 61 74 69 6f | up a ca|libratio|
|00002c60| 6e 20 66 69 6c 65 20 66 | 6f 72 20 72 65 61 64 69 |n file f|or readi|
|00002c70| 6e 67 2e 20 49 66 20 74 | 68 65 20 66 69 6c 65 20 |ng. If t|he file |
|00002c80| 65 78 69 73 74 73 20 69 | 6e 20 74 68 65 20 63 75 |exists i|n the cu|
|00002c90| 72 72 65 6e 74 0d 64 69 | 72 65 63 74 6f 72 79 2c |rrent.di|rectory,|
|00002ca0| 20 69 74 20 69 73 20 75 | 73 65 64 2e 20 49 66 20 | it is u|sed. If |
|00002cb0| 6e 6f 74 2c 20 74 68 65 | 6e 20 69 66 20 69 74 20 |not, the|n if it |
|00002cc0| 65 78 69 73 74 73 20 69 | 6e 20 74 68 65 20 70 72 |exists i|n the pr|
|00002cd0| 65 66 65 72 65 6e 63 65 | 73 20 66 6f 6c 64 65 72 |eference|s folder|
|00002ce0| 2c 20 69 74 0d 75 73 65 | 64 2e 20 49 66 20 6e 6f |, it.use|d. If no|
|00002cf0| 20 66 69 6c 65 20 69 73 | 20 66 6f 75 6e 64 20 74 | file is| found t|
|00002d00| 68 65 6e 20 70 72 69 6e | 74 73 20 61 6e 20 65 72 |hen prin|ts an er|
|00002d10| 72 6f 72 20 6d 65 73 73 | 61 67 65 20 61 6e 64 20 |ror mess|age and |
|00002d20| 65 78 69 74 73 2e 0d 0d | 09 41 70 70 65 6e 64 44 |exits...|.AppendD|
|00002d30| 65 73 63 72 69 70 74 69 | 6f 6e 73 28 26 64 2c 73 |escripti|ons(&d,s|
|00002d40| 29 3b 0d 41 70 70 65 6e | 64 73 20 74 68 65 20 73 |);.Appen|ds the s|
|00002d50| 65 63 6f 6e 64 20 64 65 | 73 63 72 69 70 74 69 6f |econd de|scriptio|
|00002d60| 6e 73 20 61 72 72 61 79 | 20 6f 6e 74 6f 20 74 68 |ns array| onto th|
|00002d70| 65 20 65 6e 64 20 6f 66 | 20 74 68 65 20 66 69 72 |e end of| the fir|
|00002d80| 73 74 2c 20 77 68 69 63 | 68 20 69 73 0d 72 65 61 |st, whic|h is.rea|
|00002d90| 6c 6c 6f 63 61 74 65 64 | 20 77 69 74 68 20 6d 6f |llocated| with mo|
|00002da0| 72 65 20 73 70 61 63 65 | 2e 20 54 68 65 20 73 6f |re space|. The so|
|00002db0| 75 72 63 65 20 61 72 72 | 61 79 20 69 73 20 6e 6f |urce arr|ay is no|
|00002dc0| 74 20 66 72 65 65 64 3b | 20 74 68 65 20 63 61 6c |t freed;| the cal|
|00002dd0| 6c 65 72 20 73 68 6f 75 | 6c 64 20 64 6f 0d 74 68 |ler shou|ld do.th|
|00002de0| 61 74 2e 20 42 6f 74 68 | 20 61 72 72 61 79 73 20 |at. Both| arrays |
|00002df0| 6d 75 73 74 20 62 65 20 | 6e 75 6c 6c 2d 74 65 72 |must be |null-ter|
|00002e00| 6d 69 6e 61 74 65 64 2e | 0d 0d 09 43 6f 70 79 44 |minated.|...CopyD|
|00002e10| 65 73 63 72 69 70 74 69 | 6f 6e 73 28 64 2c 73 29 |escripti|ons(d,s)|
|00002e20| 3b 0d 43 6f 70 79 20 6f | 6e 65 20 6e 75 6c 6c 2d |;.Copy o|ne null-|
|00002e30| 74 65 72 6d 69 6e 61 74 | 65 64 20 61 72 72 61 79 |terminat|ed array|
|00002e40| 20 6f 66 20 64 65 73 63 | 72 69 70 74 69 6f 6e 73 | of desc|riptions|
|00002e50| 20 74 6f 20 61 6e 6f 74 | 68 65 72 2c 20 77 68 69 | to anot|her, whi|
|00002e60| 63 68 20 69 73 20 61 73 | 73 75 6d 65 64 20 74 6f |ch is as|sumed to|
|00002e70| 0d 62 65 20 62 69 67 20 | 65 6e 6f 75 67 68 2e 0d |.be big |enough..|
|00002e80| 0d 09 64 3d 41 6c 6c 6f | 63 61 74 65 44 65 73 63 |..d=Allo|cateDesc|
|00002e90| 72 69 70 74 69 6f 6e 73 | 28 6e 29 3b 0d 41 6c 6c |riptions|(n);.All|
|00002ea0| 6f 63 61 74 65 20 73 70 | 61 63 65 20 66 6f 72 20 |ocate sp|ace for |
|00002eb0| 76 61 72 69 61 62 6c 65 | 20 64 65 73 63 72 69 70 |variable| descrip|
|00002ec0| 74 69 6f 6e 73 2e 20 41 | 64 64 73 20 6f 6e 65 20 |tions. A|dds one |
|00002ed0| 74 6f 20 74 68 65 20 70 | 61 73 73 65 64 20 73 69 |to the p|assed si|
|00002ee0| 7a 65 20 74 6f 20 68 6f | 6c 64 0d 74 68 65 20 6e |ze to ho|ld.the n|
|00002ef0| 75 6c 6c 20 64 65 73 63 | 72 69 70 74 6f 72 2e 20 |ull desc|riptor. |
|00002f00| 4e 75 6c 6c 73 20 74 68 | 65 20 66 69 72 73 74 20 |Nulls th|e first |
|00002f10| 65 6c 65 6d 65 6e 74 2e | 0d 0d 09 46 72 65 65 44 |element.|...FreeD|
|00002f20| 65 73 63 72 69 70 74 69 | 6f 6e 73 28 64 29 3b 0d |escripti|ons(d);.|
|00002f30| 46 72 65 65 20 74 68 65 | 20 64 65 73 63 72 69 70 |Free the| descrip|
|00002f40| 74 69 6f 6e 73 20 61 72 | 72 61 79 2e 20 44 6f 65 |tions ar|ray. Doe|
|00002f50| 73 6e 27 74 20 61 66 66 | 65 63 74 20 74 68 65 20 |sn't aff|ect the |
|00002f60| 64 65 73 63 72 69 62 65 | 64 20 76 61 72 69 61 62 |describe|d variab|
|00002f70| 6c 65 73 2e 0d 0d 09 6e | 3d 4e 75 6d 62 65 72 4f |les....n|=NumberO|
|00002f80| 66 44 65 73 63 72 69 70 | 74 69 6f 6e 73 28 64 29 |fDescrip|tions(d)|
|00002f90| 3b 0d 46 69 6e 64 20 74 | 68 65 20 73 69 7a 65 20 |;.Find t|he size |
|00002fa0| 6f 66 20 61 6e 20 61 72 | 72 61 79 20 6f 66 20 64 |of an ar|ray of d|
|00002fb0| 65 73 63 72 69 70 74 69 | 6f 6e 73 2e 20 44 6f 65 |escripti|ons. Doe|
|00002fc0| 73 20 6e 6f 74 20 63 6f | 75 6e 74 20 74 68 65 20 |s not co|unt the |
|00002fd0| 74 72 61 69 6c 69 6e 67 | 20 6e 75 6c 6c 0d 64 65 |trailing| null.de|
|00002fe0| 73 63 72 69 70 74 69 6f | 6e 2e 0d 0d 09 64 5b 69 |scriptio|n....d[i|
|00002ff0| 5d 3d 4e 75 6c 6c 44 65 | 73 63 72 69 70 74 69 6f |]=NullDe|scriptio|
|00003000| 6e 28 29 3b 0d 52 65 74 | 75 72 6e 73 20 61 20 6e |n();.Ret|urns a n|
|00003010| 75 6c 6c 20 64 65 73 63 | 72 69 70 74 69 6f 6e 2c |ull desc|ription,|
|00003020| 20 74 6f 20 74 65 72 6d | 69 6e 61 74 65 20 61 20 | to term|inate a |
|00003030| 64 65 73 63 72 69 70 74 | 69 6f 6e 73 20 61 72 72 |descript|ions arr|
|00003040| 61 79 2e 0d 0d 09 69 66 | 28 20 49 73 4e 75 6c 6c |ay....if|( IsNull|
|00003050| 44 65 73 63 72 69 70 74 | 69 6f 6e 28 64 5b 69 5d |Descript|ion(d[i]|
|00003060| 29 20 29 2e 2e 2e 3b 0d | 44 65 74 65 72 6d 69 6e |) )...;.|Determin|
|00003070| 65 20 77 68 65 74 68 65 | 72 20 77 65 20 61 72 65 |e whethe|r we are|
|00003080| 20 6c 6f 6f 6b 69 6e 67 | 20 61 74 20 61 20 6e 75 | looking| at a nu|
|00003090| 6c 6c 20 64 65 73 63 72 | 69 70 74 69 6f 6e 2e 20 |ll descr|iption. |
|000030a0| 49 6d 70 6c 65 6d 65 6e | 74 65 64 20 61 73 20 61 |Implemen|ted as a|
|000030b0| 20 6d 61 63 72 6f 2e 0d | 0d 44 65 73 63 72 69 70 | macro..|.Descrip|
|000030c0| 74 69 6f 6e 20 44 65 73 | 63 72 69 62 65 28 73 68 |tion Des|cribe(sh|
|000030d0| 6f 72 74 20 74 79 70 65 | 2c 76 6f 69 64 20 2a 70 |ort type|,void *p|
|000030e0| 74 72 2c 63 68 61 72 20 | 2a 6e 61 6d 65 2c 63 6f |tr,char |*name,co|
|000030f0| 6e 73 74 20 63 68 61 72 | 20 2a 63 6f 6d 6d 65 6e |nst char| *commen|
|00003100| 74 29 3b 0d 44 65 73 63 | 72 69 70 74 69 6f 6e 20 |t);.Desc|ription |
|00003110| 44 65 73 63 72 69 62 65 | 41 72 72 61 79 28 73 68 |Describe|Array(sh|
|00003120| 6f 72 74 20 74 79 70 65 | 2c 76 6f 69 64 20 2a 70 |ort type|,void *p|
|00003130| 74 72 2c 63 68 61 72 20 | 2a 6e 61 6d 65 2c 63 6f |tr,char |*name,co|
|00003140| 6e 73 74 20 63 68 61 72 | 20 2a 63 6f 6d 6d 65 6e |nst char| *commen|
|00003150| 74 2c 2e 2e 2e 29 3b 0d | 09 64 6f 75 62 6c 65 20 |t,...);.|.double |
|00003160| 61 2c 2a 70 2c 78 5b 33 | 5d 3b 0d 09 64 5b 69 2b |a,*p,x[3|];..d[i+|
|00003170| 2b 5d 3d 44 65 73 63 72 | 69 62 65 28 64 6f 75 62 |+]=Descr|ibe(doub|
|00003180| 6c 65 54 79 70 65 2c 26 | 61 2c 22 61 22 2c 22 68 |leType,&|a,"a","h|
|00003190| 65 6c 6c 6f 22 29 3b 0d | 09 64 5b 69 2b 2b 5d 3d |ello");.|.d[i++]=|
|000031a0| 44 65 73 63 72 69 62 65 | 28 64 6f 75 62 6c 65 50 |Describe|(doubleP|
|000031b0| 74 72 54 79 70 65 2c 26 | 70 2c 22 70 22 2c 4e 55 |trType,&|p,"p",NU|
|000031c0| 4c 4c 29 3b 0d 09 64 5b | 69 2b 2b 5d 3d 44 65 73 |LL);..d[|i++]=Des|
|000031d0| 63 72 69 62 65 41 72 72 | 61 79 28 64 6f 75 62 6c |cribeArr|ay(doubl|
|000031e0| 65 54 79 70 65 2c 26 78 | 2c 22 78 22 2c 4e 55 4c |eType,&x|,"x",NUL|
|000031f0| 4c 2c 33 4c 2c 30 4c 29 | 3b 0d 44 65 73 63 72 69 |L,3L,0L)|;.Descri|
|00003200| 62 65 20 61 6e 64 20 44 | 65 73 63 72 69 62 65 41 |be and D|escribeA|
|00003210| 72 72 61 79 20 6d 65 72 | 65 6c 79 20 72 65 74 75 |rray mer|ely retu|
|00003220| 72 6e 20 61 20 44 65 73 | 63 72 69 70 74 69 6f 6e |rn a Des|cription|
|00003230| 20 77 69 74 68 20 74 68 | 65 20 66 69 65 6c 64 20 | with th|e field |
|00003240| 76 61 6c 75 65 73 0d 74 | 68 61 74 20 79 6f 75 20 |values.t|hat you |
|00003250| 73 75 70 70 6c 79 2e 20 | 55 73 65 20 74 68 65 6d |supply. |Use them|
|00003260| 20 74 6f 20 6d 61 6b 65 | 20 79 6f 75 72 20 70 72 | to make| your pr|
|00003270| 6f 67 72 61 6d 73 20 6d | 6f 72 65 20 72 65 61 64 |ograms m|ore read|
|00003280| 61 62 6c 65 2c 20 61 6e | 64 20 74 6f 20 65 6e 68 |able, an|d to enh|
|00003290| 61 6e 63 65 0d 74 68 65 | 20 63 6f 6d 70 61 74 69 |ance.the| compati|
|000032a0| 62 69 6c 69 74 79 20 6f | 66 20 79 6f 75 72 20 70 |bility o|f your p|
|000032b0| 72 6f 67 72 61 6d 73 20 | 77 69 74 68 20 66 75 74 |rograms |with fut|
|000032c0| 75 72 65 20 65 6e 68 61 | 6e 63 65 6d 65 6e 74 73 |ure enha|ncements|
|000032d0| 20 74 6f 20 41 73 73 69 | 67 6e 2e 63 2c 20 77 68 | to Assi|gn.c, wh|
|000032e0| 69 63 68 0d 6d 69 67 68 | 74 20 72 65 64 65 66 69 |ich.migh|t redefi|
|000032f0| 6e 65 20 74 68 65 20 66 | 69 65 6c 64 73 20 6f 66 |ne the f|ields of|
|00003300| 20 74 68 65 20 44 65 73 | 63 72 69 70 74 69 6f 6e | the Des|cription|
|00003310| 20 73 74 72 75 63 74 75 | 72 65 2e 20 44 65 73 63 | structu|re. Desc|
|00003320| 72 69 62 65 41 72 72 61 | 79 28 29 20 61 63 63 65 |ribeArra|y() acce|
|00003330| 70 74 73 0d 61 20 76 61 | 72 69 61 62 6c 65 20 6e |pts.a va|riable n|
|00003340| 75 6d 62 65 72 20 6f 66 | 20 61 72 67 75 6d 65 6e |umber of| argumen|
|00003350| 74 73 20 73 70 65 63 69 | 66 79 69 6e 67 20 74 68 |ts speci|fying th|
|00003360| 65 20 61 72 72 61 79 20 | 64 69 6d 65 6e 73 69 6f |e array |dimensio|
|00003370| 6e 73 2e 20 59 6f 75 20 | 6d 61 79 20 73 75 70 70 |ns. You |may supp|
|00003380| 6c 79 0d 61 6e 79 20 6e | 75 6d 62 65 72 20 6f 66 |ly.any n|umber of|
|00003390| 20 61 72 72 61 79 20 64 | 69 6d 65 6e 73 69 6f 6e | array d|imension|
|000033a0| 73 20 28 75 70 20 74 6f | 20 41 53 53 49 47 4e 5f |s (up to| ASSIGN_|
|000033b0| 44 49 4d 53 29 2c 20 62 | 75 74 20 74 68 65 79 20 |DIMS), b|ut they |
|000033c0| 4d 55 53 54 20 62 65 20 | 6c 6f 6e 67 2c 20 61 6e |MUST be |long, an|
|000033d0| 64 0d 74 68 65 20 61 72 | 67 75 6d 65 6e 74 20 6c |d.the ar|gument l|
|000033e0| 69 73 74 20 4d 55 53 54 | 20 62 65 20 74 65 72 6d |ist MUST| be term|
|000033f0| 69 6e 61 74 65 64 20 62 | 79 20 61 20 30 4c 20 66 |inated b|y a 0L f|
|00003400| 6f 6c 6c 6f 77 69 6e 67 | 20 74 68 65 20 6c 69 73 |ollowing| the lis|
|00003410| 74 20 6f 66 20 64 69 6d | 65 6e 73 69 6f 6e 73 2e |t of dim|ensions.|
|00003420| 0d 41 6e 79 20 61 64 64 | 69 74 69 6f 6e 61 6c 20 |.Any add|itional |
|00003430| 61 72 67 75 6d 65 6e 74 | 73 20 66 6f 6c 6c 6f 77 |argument|s follow|
|00003440| 69 6e 67 20 74 68 65 20 | 30 4c 20 61 72 65 20 69 |ing the |0L are i|
|00003450| 67 6e 6f 72 65 64 2e 20 | 41 20 50 74 72 54 79 70 |gnored. |A PtrTyp|
|00003460| 65 20 76 61 72 69 61 62 | 6c 65 20 6d 61 79 20 62 |e variab|le may b|
|00003470| 65 0d 64 65 73 63 72 69 | 62 65 64 20 62 79 20 44 |e.descri|bed by D|
|00003480| 65 73 63 72 69 62 65 41 | 72 72 61 79 28 29 2c 20 |escribeA|rray(), |
|00003490| 73 70 65 63 69 66 79 69 | 6e 67 20 74 68 65 20 64 |specifyi|ng the d|
|000034a0| 69 6d 65 6e 73 69 6f 6e | 73 20 6f 66 20 74 68 65 |imension|s of the|
|000034b0| 20 73 74 6f 72 61 67 65 | 20 61 72 65 61 20 74 6f | storage| area to|
|000034c0| 0d 62 65 20 61 6c 6c 6f | 63 61 74 65 64 2c 20 6f |.be allo|cated, o|
|000034d0| 72 20 6d 61 79 20 62 65 | 20 64 65 73 63 72 69 62 |r may be| describ|
|000034e0| 65 64 20 62 79 20 44 65 | 73 63 72 69 62 65 28 29 |ed by De|scribe()|
|000034f0| 20 69 6e 20 77 68 69 63 | 68 20 63 61 73 65 20 74 | in whic|h case t|
|00003500| 68 65 20 64 69 6d 65 6e | 73 69 6f 6e 73 0d 28 6e |he dimen|sions.(n|
|00003510| 6f 6e 65 20 75 70 20 74 | 6f 20 41 53 53 49 47 4e |one up t|o ASSIGN|
|00003520| 5f 44 49 4d 53 29 20 77 | 69 6c 6c 20 62 65 20 64 |_DIMS) w|ill be d|
|00003530| 65 74 65 72 6d 69 6e 65 | 64 20 66 72 6f 6d 20 74 |etermine|d from t|
|00003540| 68 65 20 66 69 72 73 74 | 20 67 75 6c 70 20 6f 66 |he first| gulp of|
|00003550| 20 74 68 65 0d 61 73 73 | 69 67 6e 6d 65 6e 74 20 | the.ass|ignment |
|00003560| 66 69 6c 65 2e 20 49 6e | 20 65 69 74 68 65 72 20 |file. In| either |
|00003570| 63 61 73 65 2c 20 73 74 | 6f 72 61 67 65 20 66 6f |case, st|orage fo|
|00003580| 72 20 74 68 65 20 50 74 | 72 54 79 70 65 20 76 61 |r the Pt|rType va|
|00003590| 72 69 61 62 6c 65 20 69 | 73 20 61 6c 6c 6f 63 61 |riable i|s alloca|
|000035a0| 74 65 64 0d 6f 6e 6c 79 | 20 77 68 65 6e 20 69 74 |ted.only| when it|
|000035b0| 20 69 73 20 65 6e 63 6f | 75 6e 74 65 72 65 64 20 | is enco|untered |
|000035c0| 69 6e 20 74 68 65 20 61 | 73 73 69 67 6e 6d 65 6e |in the a|ssignmen|
|000035d0| 74 20 66 69 6c 65 2e 20 | 54 68 65 20 61 72 72 61 |t file. |The arra|
|000035e0| 79 20 64 69 6d 65 6e 73 | 69 6f 6e 73 20 6f 66 20 |y dimens|ions of |
|000035f0| 61 0d 50 74 72 54 79 70 | 65 20 76 61 72 69 61 62 |a.PtrTyp|e variab|
|00003600| 6c 65 20 73 70 65 63 69 | 66 69 65 64 20 77 68 65 |le speci|fied whe|
|00003610| 6e 20 63 61 6c 6c 69 6e | 67 20 44 65 73 63 72 69 |n callin|g Descri|
|00003620| 62 65 41 72 72 61 79 28 | 29 20 61 72 65 20 77 69 |beArray(|) are wi|
|00003630| 70 65 64 20 6f 75 74 20 | 69 66 20 79 6f 75 0d 6c |ped out |if you.l|
|00003640| 61 74 65 72 20 63 61 6c | 6c 20 46 72 65 65 50 74 |ater cal|l FreePt|
|00003650| 72 56 61 72 69 61 62 6c | 65 73 28 29 2c 20 77 69 |rVariabl|es(), wi|
|00003660| 74 68 20 74 68 65 20 73 | 61 6d 65 20 72 65 73 75 |th the s|ame resu|
|00003670| 6c 74 20 61 73 20 6a 75 | 73 74 20 63 61 6c 6c 69 |lt as ju|st calli|
|00003680| 6e 67 20 44 65 73 63 72 | 69 62 65 28 29 2e 0d 0d |ng Descr|ibe()...|
|00003690| 54 59 50 45 53 3a 20 63 | 68 61 72 54 79 70 65 2c |TYPES: c|harType,|
|000036a0| 20 75 6e 73 69 67 6e 65 | 64 43 68 61 72 54 79 70 | unsigne|dCharTyp|
|000036b0| 65 2c 20 73 68 6f 72 74 | 54 79 70 65 2c 20 75 6e |e, short|Type, un|
|000036c0| 73 69 67 6e 65 64 53 68 | 6f 72 74 54 79 70 65 2c |signedSh|ortType,|
|000036d0| 20 6c 6f 6e 67 54 79 70 | 65 2c 0d 75 6e 73 69 67 | longTyp|e,.unsig|
|000036e0| 6e 65 64 4c 6f 6e 67 54 | 79 70 65 2c 20 66 6c 6f |nedLongT|ype, flo|
|000036f0| 61 74 54 79 70 65 2c 20 | 73 68 6f 72 74 44 6f 75 |atType, |shortDou|
|00003700| 62 6c 65 54 79 70 65 2c | 20 64 6f 75 62 6c 65 54 |bleType,| doubleT|
|00003710| 79 70 65 2c 20 63 68 61 | 72 50 74 72 54 79 70 65 |ype, cha|rPtrType|
|00003720| 2c 0d 75 6e 73 69 67 6e | 65 64 43 68 61 72 50 74 |,.unsign|edCharPt|
|00003730| 72 54 79 70 65 2c 20 73 | 68 6f 72 74 50 74 72 54 |rType, s|hortPtrT|
|00003740| 79 70 65 2c 20 75 6e 73 | 69 67 6e 65 64 53 68 6f |ype, uns|ignedSho|
|00003750| 72 74 50 74 72 54 79 70 | 65 2c 20 6c 6f 6e 67 50 |rtPtrTyp|e, longP|
|00003760| 74 72 54 79 70 65 2c 0d | 75 6e 73 69 67 6e 65 64 |trType,.|unsigned|
|00003770| 4c 6f 6e 67 50 74 72 54 | 79 70 65 2c 20 66 6c 6f |LongPtrT|ype, flo|
|00003780| 61 74 50 74 72 54 79 70 | 65 2c 20 73 68 6f 72 74 |atPtrTyp|e, short|
|00003790| 44 6f 75 62 6c 65 50 74 | 72 54 79 70 65 2c 20 64 |DoublePt|rType, d|
|000037a0| 6f 75 62 6c 65 50 74 72 | 54 79 70 65 2c 0d 73 74 |oublePtr|Type,.st|
|000037b0| 72 69 6e 67 54 79 70 65 | 2e 0d 0d 44 65 73 63 72 |ringType|...Descr|
|000037c0| 69 70 74 69 6f 6e 20 44 | 65 73 63 72 69 62 65 46 |iption D|escribeF|
|000037d0| 69 72 73 74 4c 61 73 74 | 28 73 68 6f 72 74 20 74 |irstLast|(short t|
|000037e0| 79 70 65 2c 76 6f 69 64 | 20 2a 70 74 72 2c 63 68 |ype,void| *ptr,ch|
|000037f0| 61 72 20 2a 6e 61 6d 65 | 0d 09 2c 63 6f 6e 73 74 |ar *name|..,const|
|00003800| 20 63 68 61 72 20 2a 63 | 6f 6d 6d 65 6e 74 2c 6c | char *c|omment,l|
|00003810| 6f 6e 67 20 66 69 72 73 | 74 45 6c 65 6d 65 6e 74 |ong firs|tElement|
|00003820| 2c 6c 6f 6e 67 20 6c 61 | 73 74 45 6c 65 6d 65 6e |,long la|stElemen|
|00003830| 74 29 3b 0d 09 66 6c 6f | 61 74 20 2a 61 3b 0d 09 |t);..flo|at *a;..|
|00003840| 61 3d 76 65 63 74 6f 72 | 28 31 2c 31 30 29 3b 09 |a=vector|(1,10);.|
|00003850| 2f 2a 20 61 20 4e 75 6d | 65 72 69 63 61 6c 20 52 |/* a Num|erical R|
|00003860| 65 63 69 70 65 73 20 69 | 6e 20 43 20 61 6c 6c 6f |ecipes i|n C allo|
|00003870| 63 61 74 69 6f 6e 20 72 | 6f 75 74 69 6e 65 20 2a |cation r|outine *|
|00003880| 2f 0d 09 64 5b 69 2b 2b | 5d 3d 44 65 73 63 72 69 |/..d[i++|]=Descri|
|00003890| 62 65 46 69 72 73 74 4c | 61 73 74 28 66 6c 6f 61 |beFirstL|ast(floa|
|000038a0| 74 54 79 70 65 2c 61 2c | 22 61 22 2c 4e 55 4c 4c |tType,a,|"a",NULL|
|000038b0| 2c 31 4c 2c 31 30 4c 2c | 30 4c 29 3b 0d 54 68 69 |,1L,10L,|0L);.Thi|
|000038c0| 73 20 61 6c 6c 6f 77 73 | 20 79 6f 75 20 74 6f 20 |s allows| you to |
|000038d0| 73 70 65 63 69 66 79 20 | 61 20 31 2d 64 69 6d 65 |specify |a 1-dime|
|000038e0| 6e 73 69 6f 6e 61 6c 20 | 61 72 72 61 79 20 77 69 |nsional |array wi|
|000038f0| 74 68 20 61 20 6e 6f 6e | 73 74 61 6e 64 61 72 64 |th a non|standard|
|00003900| 20 73 75 62 73 63 72 69 | 70 74 0d 72 61 6e 67 65 | subscri|pt.range|
|00003910| 2c 20 65 2e 67 2e 20 73 | 74 61 72 74 69 6e 67 20 |, e.g. s|tarting |
|00003920| 77 69 74 68 20 73 75 62 | 73 63 72 69 70 74 20 31 |with sub|script 1|
|00003930| 2c 20 61 73 20 69 6e 20 | 4e 75 6d 65 72 69 63 61 |, as in |Numerica|
|00003940| 6c 20 52 65 63 69 70 65 | 73 20 69 6e 20 43 2e 20 |l Recipe|s in C. |
|00003950| 54 68 65 20 22 70 74 72 | 22 0d 61 72 67 75 6d 65 |The "ptr|".argume|
|00003960| 6e 74 20 73 68 6f 75 6c | 64 20 61 6c 77 61 79 73 |nt shoul|d always|
|00003970| 20 70 6f 69 6e 74 20 74 | 6f 20 65 6c 65 6d 65 6e | point t|o elemen|
|00003980| 74 20 7a 65 72 6f 2c 20 | 65 76 65 6e 20 69 66 20 |t zero, |even if |
|00003990| 74 68 61 74 20 65 6c 65 | 6d 65 6e 74 20 69 73 20 |that ele|ment is |
|000039a0| 6e 6f 74 20 70 61 72 74 | 20 6f 66 0d 74 68 65 20 |not part| of.the |
|000039b0| 61 72 72 61 79 27 73 20 | 61 6c 6c 6f 63 61 74 65 |array's |allocate|
|000039c0| 64 20 73 74 6f 72 61 67 | 65 2e 20 0d 0d 09 65 72 |d storag|e. ...er|
|000039d0| 72 6f 72 3d 55 6e 65 71 | 75 61 6c 44 65 73 63 72 |ror=Uneq|ualDescr|
|000039e0| 69 62 65 64 56 61 72 73 | 28 64 65 73 63 72 69 70 |ibedVars|(descrip|
|000039f0| 74 69 6f 6e 73 31 2c 64 | 65 73 63 72 69 70 74 69 |tions1,d|escripti|
|00003a00| 6f 6e 73 32 2c 66 6c 61 | 67 73 29 3b 0d 09 65 72 |ons2,fla|gs);..er|
|00003a10| 72 6f 72 3d 55 6e 65 71 | 75 61 6c 44 65 73 63 72 |ror=Uneq|ualDescr|
|00003a20| 69 62 65 64 56 61 72 50 | 61 69 72 28 64 31 2c 64 |ibedVarP|air(d1,d|
|00003a30| 32 2c 66 6c 61 67 73 29 | 3b 0d 54 68 65 73 65 20 |2,flags)|;.These |
|00003a40| 72 6f 75 74 69 6e 65 73 | 20 63 6f 6d 70 61 72 65 |routines| compare|
|00003a50| 20 74 68 65 20 64 61 74 | 61 20 70 6f 69 6e 74 65 | the dat|a pointe|
|00003a60| 64 20 74 6f 20 62 79 20 | 74 68 65 20 74 77 6f 20 |d to by |the two |
|00003a70| 44 65 73 63 72 69 70 74 | 69 6f 6e 20 61 72 72 61 |Descript|ion arra|
|00003a80| 79 73 20 6f 72 0d 73 74 | 72 75 63 74 73 2e 20 54 |ys or.st|ructs. T|
|00003a90| 68 65 79 20 72 65 74 75 | 72 6e 20 30 20 69 66 20 |hey retu|rn 0 if |
|00003aa0| 74 68 65 20 44 65 73 63 | 72 69 70 74 69 6f 6e 73 |the Desc|riptions|
|00003ab0| 20 61 72 65 20 6c 65 67 | 61 6c 20 61 6e 64 20 74 | are leg|al and t|
|00003ac0| 68 65 20 64 61 74 61 20 | 61 72 65 0d 65 71 75 61 |he data |are.equa|
|00003ad0| 6c 2c 20 61 6e 64 20 61 | 20 6e 6f 6e 7a 65 72 6f |l, and a| nonzero|
|00003ae0| 20 65 72 72 6f 72 20 63 | 6f 64 65 20 28 6f 72 20 | error c|ode (or |
|00003af0| 50 72 69 6e 74 66 45 78 | 69 74 2c 20 64 65 70 65 |PrintfEx|it, depe|
|00003b00| 6e 64 69 6e 67 20 6f 6e | 20 66 6c 61 67 73 29 20 |nding on| flags) |
|00003b10| 6f 74 68 65 72 77 69 73 | 65 2e 0d 28 43 6f 6d 70 |otherwis|e..(Comp|
|00003b20| 61 72 69 73 6f 6e 20 6f | 66 20 66 6c 6f 61 74 69 |arison o|f floati|
|00003b30| 6e 67 20 6e 75 6d 62 65 | 72 73 20 61 6c 6c 6f 77 |ng numbe|rs allow|
|00003b40| 73 20 61 20 74 6f 6c 65 | 72 61 6e 63 65 20 6f 66 |s a tole|rance of|
|00003b50| 20 2b 2f 2d 20 6f 6e 65 | 20 70 61 72 74 20 69 6e | +/- one| part in|
|00003b60| 20 61 20 6d 69 6c 6c 69 | 6f 6e 2c 0d 62 65 63 61 | a milli|on,.beca|
|00003b70| 75 73 65 20 63 6f 6e 76 | 65 72 74 69 6e 67 20 74 |use conv|erting t|
|00003b80| 6f 20 61 6e 64 20 66 72 | 6f 6d 20 64 65 63 69 6d |o and fr|om decim|
|00003b90| 61 6c 20 6d 61 79 20 6c | 6f 73 65 20 73 6f 6d 65 |al may l|ose some|
|00003ba0| 20 70 72 65 63 69 73 69 | 6f 6e 2c 20 61 6e 64 20 | precisi|on, and |
|00003bb0| 63 6f 6e 73 69 64 65 72 | 73 0d 61 6c 6c 20 4e 41 |consider|s.all NA|
|00003bc0| 4e 73 20 65 71 75 61 6c | 20 62 65 63 61 75 73 65 |Ns equal| because|
|00003bd0| 20 4e 41 4e 20 69 6e 64 | 69 63 65 73 20 28 4e 41 | NAN ind|ices (NA|
|00003be0| 4e 30 34 20 76 73 20 4e | 41 4e 46 46 29 20 61 72 |N04 vs N|ANFF) ar|
|00003bf0| 65 20 6e 6f 74 20 70 72 | 65 73 65 72 76 65 64 20 |e not pr|eserved |
|00003c00| 62 79 20 6d 6f 73 74 0d | 6f 70 65 72 61 74 69 6f |by most.|operatio|
|00003c10| 6e 73 2e 29 20 54 68 69 | 73 20 6d 61 6b 65 73 20 |ns.) Thi|s makes |
|00003c20| 69 74 20 65 61 73 79 20 | 74 6f 20 76 65 72 69 66 |it easy |to verif|
|00003c30| 79 20 77 68 61 74 20 77 | 61 73 20 77 72 69 74 74 |y what w|as writt|
|00003c40| 65 6e 20 74 6f 20 61 6e | 20 61 73 73 69 67 6e 6d |en to an| assignm|
|00003c50| 65 6e 74 0d 66 69 6c 65 | 2e 20 4a 75 73 74 20 63 |ent.file|. Just c|
|00003c60| 72 65 61 74 65 20 61 20 | 6e 65 77 20 64 61 74 61 |reate a |new data|
|00003c70| 20 73 74 72 75 63 74 75 | 72 65 20 61 6e 64 20 61 | structu|re and a|
|00003c80| 20 44 65 73 63 72 69 70 | 74 69 6f 6e 20 61 72 72 | Descrip|tion arr|
|00003c90| 61 79 20 64 65 73 63 72 | 69 62 69 6e 67 20 69 74 |ay descr|ibing it|
|00003ca0| 2c 0d 63 61 6c 6c 20 52 | 65 61 64 41 73 73 69 67 |,.call R|eadAssig|
|00003cb0| 6e 6d 65 6e 74 46 69 6c | 65 2c 20 61 6e 64 20 75 |nmentFil|e, and u|
|00003cc0| 73 65 20 55 6e 65 71 75 | 61 6c 44 65 73 63 72 69 |se Unequ|alDescri|
|00003cd0| 62 65 64 56 61 72 73 20 | 74 6f 20 76 65 72 69 66 |bedVars |to verif|
|00003ce0| 79 20 74 68 61 74 20 79 | 6f 75 20 72 65 61 64 0d |y that y|ou read.|
|00003cf0| 62 61 63 6b 20 65 78 61 | 63 74 6c 79 20 77 68 61 |back exa|ctly wha|
|00003d00| 74 20 79 6f 75 20 77 72 | 6f 74 65 2e 0d 0d 09 6e |t you wr|ote....n|
|00003d10| 3d 43 6f 70 79 44 65 73 | 63 72 69 62 65 64 56 61 |=CopyDes|cribedVa|
|00003d20| 72 73 28 64 65 73 63 72 | 69 70 74 69 6f 6e 73 31 |rs(descr|iptions1|
|00003d30| 2c 64 65 73 63 72 69 70 | 74 69 6f 6e 73 32 2c 66 |,descrip|tions2,f|
|00003d40| 6c 61 67 73 29 3b 0d 09 | 6e 3d 43 6f 70 79 41 44 |lags);..|n=CopyAD|
|00003d50| 65 73 63 72 69 62 65 64 | 56 61 72 28 64 31 2c 64 |escribed|Var(d1,d|
|00003d60| 32 2c 66 6c 61 67 73 29 | 3b 0d 54 68 65 73 65 20 |2,flags)|;.These |
|00003d70| 72 6f 75 74 69 6e 65 73 | 20 63 6f 70 79 20 74 68 |routines| copy th|
|00003d80| 65 20 64 61 74 61 20 70 | 6f 69 6e 74 65 64 20 74 |e data p|ointed t|
|00003d90| 6f 20 62 79 20 74 68 65 | 20 66 69 72 73 74 20 44 |o by the| first D|
|00003da0| 65 73 63 72 69 70 74 69 | 6f 6e 20 61 72 72 61 79 |escripti|on array|
|00003db0| 20 6f 72 0d 73 74 72 75 | 63 74 2c 20 6f 76 65 72 | or.stru|ct, over|
|00003dc0| 77 72 69 74 69 6e 67 20 | 74 68 65 20 64 61 74 61 |writing |the data|
|00003dd0| 20 70 6f 69 6e 74 65 64 | 20 74 6f 20 62 79 20 74 | pointed| to by t|
|00003de0| 68 65 20 73 65 63 6f 6e | 64 2e 20 54 68 65 79 20 |he secon|d. They |
|00003df0| 72 65 74 75 72 6e 20 30 | 20 6f 6e 20 73 75 63 63 |return 0| on succ|
|00003e00| 65 73 73 2c 0d 69 2e 65 | 2e 20 69 66 20 74 68 65 |ess,.i.e|. if the|
|00003e10| 20 44 65 73 63 72 69 70 | 74 69 6f 6e 73 20 61 72 | Descrip|tions ar|
|00003e20| 65 20 6c 65 67 61 6c 20 | 61 6e 64 20 74 68 65 20 |e legal |and the |
|00003e30| 64 61 74 61 20 74 79 70 | 65 73 20 61 6e 64 20 6e |data typ|es and n|
|00003e40| 61 6d 65 73 20 61 72 65 | 20 63 6f 6e 73 69 73 74 |ames are| consist|
|00003e50| 65 6e 74 2c 0d 61 6e 64 | 20 61 20 6e 6f 6e 7a 65 |ent,.and| a nonze|
|00003e60| 72 6f 20 65 72 72 6f 72 | 20 63 6f 64 65 20 28 6f |ro error| code (o|
|00003e70| 72 20 50 72 69 6e 74 66 | 45 78 69 74 2c 20 64 65 |r Printf|Exit, de|
|00003e80| 70 65 6e 64 69 6e 67 20 | 6f 6e 20 66 6c 61 67 73 |pending |on flags|
|00003e90| 29 20 6f 74 68 65 72 77 | 69 73 65 2e 20 54 68 69 |) otherw|ise. Thi|
|00003ea0| 73 0d 6d 61 6b 65 73 20 | 69 74 20 65 61 73 69 65 |s.makes |it easie|
|00003eb0| 72 20 74 6f 20 72 65 61 | 64 20 64 61 74 61 20 69 |r to rea|d data i|
|00003ec0| 6e 74 6f 20 61 20 74 65 | 6d 70 6f 72 61 72 79 20 |nto a te|mporary |
|00003ed0| 61 72 65 61 2c 20 61 6e | 64 20 74 68 65 6e 2c 20 |area, an|d then, |
|00003ee0| 69 66 20 74 68 65 73 65 | 20 61 72 65 20 74 68 65 |if these| are the|
|00003ef0| 0d 64 61 74 61 20 77 65 | 20 77 61 6e 74 2c 20 74 |.data we| want, t|
|00003f00| 6f 20 74 68 65 6e 20 63 | 6f 70 79 20 74 68 65 6d |o then c|opy them|
|00003f10| 20 69 6e 74 6f 20 74 68 | 65 20 72 65 61 6c 20 76 | into th|e real v|
|00003f20| 61 72 69 61 62 6c 65 73 | 2e 0d 0d 09 6e 3d 49 6e |ariables|....n=In|
|00003f30| 69 74 69 61 6c 69 7a 65 | 44 65 73 63 72 69 62 65 |itialize|Describe|
|00003f40| 64 56 61 72 73 28 64 65 | 73 63 72 69 70 74 69 6f |dVars(de|scriptio|
|00003f50| 6e 73 2c 66 6c 61 67 73 | 29 3b 0d 09 6e 3d 49 6e |ns,flags|);..n=In|
|00003f60| 69 74 69 61 6c 69 7a 65 | 41 44 65 73 63 72 69 62 |itialize|ADescrib|
|00003f70| 65 64 56 61 72 28 64 2c | 66 6c 61 67 73 29 3b 0d |edVar(d,|flags);.|
|00003f80| 49 6e 69 74 69 61 6c 69 | 7a 65 20 74 68 65 20 64 |Initiali|ze the d|
|00003f90| 65 73 63 72 69 62 65 64 | 20 76 61 72 69 61 62 6c |escribed| variabl|
|00003fa0| 65 73 2e 20 41 6c 6c 20 | 69 6e 74 65 67 65 72 20 |es. All |integer |
|00003fb0| 76 61 72 69 61 62 6c 65 | 73 0d 61 72 65 20 73 65 |variable|s.are se|
|00003fc0| 74 20 74 6f 20 7a 65 72 | 6f 2c 20 61 6c 6c 20 66 |t to zer|o, all f|
|00003fd0| 6c 6f 61 74 69 6e 67 20 | 76 61 72 69 61 62 6c 65 |loating |variable|
|00003fe0| 73 20 61 72 65 20 73 65 | 74 20 74 6f 20 4e 41 4e |s are se|t to NAN|
|00003ff0| 2c 20 61 6e 64 20 61 6c | 6c 20 74 68 65 20 73 74 |, and al|l the st|
|00004000| 72 69 6e 67 73 20 61 72 | 65 0d 73 65 74 20 74 6f |rings ar|e.set to|
|00004010| 20 70 6f 69 6e 74 20 74 | 6f 20 61 20 70 61 72 74 | point t|o a part|
|00004020| 69 63 75 6c 61 72 20 65 | 6d 70 74 79 20 73 74 72 |icular e|mpty str|
|00004030| 69 6e 67 20 22 22 2e 20 | 41 6e 79 20 50 74 72 54 |ing "". |Any PtrT|
|00004040| 79 70 65 20 73 63 61 6c | 61 72 73 20 61 6e 64 20 |ype scal|ars and |
|00004050| 61 72 72 61 79 73 0d 74 | 68 61 74 20 68 61 76 65 |arrays.t|hat have|
|00004060| 20 61 6c 72 65 61 64 79 | 20 62 65 65 6e 20 61 6c | already| been al|
|00004070| 6c 6f 63 61 74 65 64 20 | 77 69 6c 6c 20 62 65 20 |located |will be |
|00004080| 69 6e 69 74 69 61 6c 69 | 7a 65 64 3b 20 75 6e 61 |initiali|zed; una|
|00004090| 6c 6c 6f 63 61 74 65 64 | 20 50 74 72 54 79 70 65 |llocated| PtrType|
|000040a0| 0d 76 61 72 69 61 62 6c | 65 73 20 61 72 65 20 4e |.variabl|es are N|
|000040b0| 55 4c 4c 65 64 2e 0d 0d | 09 6e 3d 52 65 61 64 41 |ULLed...|.n=ReadA|
|000040c0| 73 73 69 67 6e 6d 65 6e | 74 4c 69 6e 65 28 73 74 |ssignmen|tLine(st|
|000040d0| 72 65 61 6d 2c 64 65 73 | 63 72 69 70 74 69 6f 6e |ream,des|cription|
|000040e0| 73 2c 66 6c 61 67 73 29 | 3b 0d 49 6e 74 65 72 70 |s,flags)|;.Interp|
|000040f0| 72 65 74 73 20 6f 6e 65 | 20 6c 69 6e 65 20 66 72 |rets one| line fr|
|00004100| 6f 6d 20 74 68 65 20 73 | 74 72 65 61 6d 20 28 73 |om the s|tream (s|
|00004110| 70 6c 69 63 69 6e 67 20 | 63 6f 6e 74 69 6e 75 61 |plicing |continua|
|00004120| 74 69 6f 6e 20 6c 69 6e | 65 73 29 2c 20 61 6e 64 |tion lin|es), and|
|00004130| 20 63 6f 6e 74 69 6e 75 | 65 73 0d 74 6f 20 72 65 | continu|es.to re|
|00004140| 61 64 20 66 75 72 74 68 | 65 72 20 6c 69 6e 65 73 |ad furth|er lines|
|00004150| 2c 20 69 66 20 6e 65 63 | 65 73 73 61 72 79 2c 20 |, if nec|essary, |
|00004160| 74 6f 20 72 65 61 63 68 | 20 74 68 65 20 65 6e 64 |to reach| the end|
|00004170| 20 6f 66 20 61 6e 79 20 | 69 6e 63 6f 6d 70 6c 65 | of any |incomple|
|00004180| 74 65 20 63 6f 6d 6d 65 | 6e 74 0d 6f 72 20 61 73 |te comme|nt.or as|
|00004190| 73 69 67 6e 6d 65 6e 74 | 2e 20 52 65 61 64 41 73 |signment|. ReadAs|
|000041a0| 73 69 67 6e 6d 65 6e 74 | 42 6c 6f 63 6b 28 29 20 |signment|Block() |
|000041b0| 61 6e 64 20 52 65 61 64 | 41 73 73 69 67 6e 6d 65 |and Read|Assignme|
|000041c0| 6e 74 46 69 6c 65 28 29 | 2c 20 62 65 6c 6f 77 2c |ntFile()|, below,|
|000041d0| 20 64 6f 20 61 6c 6c 0d | 74 68 65 69 72 20 72 65 | do all.|their re|
|000041e0| 61 64 69 6e 67 20 62 79 | 20 72 65 70 65 61 74 65 |ading by| repeate|
|000041f0| 64 6c 79 20 63 61 6c 6c | 69 6e 67 20 52 65 61 64 |dly call|ing Read|
|00004200| 41 73 73 69 67 6e 6d 65 | 6e 74 4c 69 6e 65 28 29 |Assignme|ntLine()|
|00004210| 2e 0d 0d 09 62 6c 61 6e | 6b 3d 41 73 73 69 67 6e |....blan|k=Assign|
|00004220| 6d 65 6e 74 4c 69 6e 65 | 57 61 73 42 6c 61 6e 6b |mentLine|WasBlank|
|00004230| 28 29 3b 0d 52 65 74 75 | 72 6e 73 20 74 72 75 65 |();.Retu|rns true|
|00004240| 20 28 69 2e 65 2e 20 31 | 29 20 75 6e 6c 65 73 73 | (i.e. 1|) unless|
|00004250| 20 74 68 65 20 6d 6f 73 | 74 20 72 65 63 65 6e 74 | the mos|t recent|
|00004260| 20 63 61 6c 6c 20 74 6f | 20 52 65 61 64 41 73 73 | call to| ReadAss|
|00004270| 69 67 6e 6d 65 6e 74 4c | 69 6e 65 28 29 20 72 65 |ignmentL|ine() re|
|00004280| 61 64 0d 73 6f 6d 65 20 | 6e 6f 6e 2d 62 6c 61 6e |ad.some |non-blan|
|00004290| 6b 20 74 65 78 74 2c 20 | 69 6e 20 77 68 69 63 68 |k text, |in which|
|000042a0| 20 63 61 73 65 20 69 74 | 20 72 65 74 75 72 6e 73 | case it| returns|
|000042b0| 20 66 61 6c 73 65 20 28 | 69 2e 65 2e 20 30 29 2e | false (|i.e. 0).|
|000042c0| 0d 0d 09 6e 3d 52 65 61 | 64 41 73 73 69 67 6e 6d |...n=Rea|dAssignm|
|000042d0| 65 6e 74 42 6c 6f 63 6b | 28 73 74 72 65 61 6d 2c |entBlock|(stream,|
|000042e0| 64 65 73 63 72 69 70 74 | 69 6f 6e 73 2c 66 6c 61 |descript|ions,fla|
|000042f0| 67 73 29 3b 0d 49 6e 74 | 65 72 70 72 65 74 73 20 |gs);.Int|erprets |
|00004300| 6c 69 6e 65 73 20 66 72 | 6f 6d 20 74 68 65 20 73 |lines fr|om the s|
|00004310| 74 72 65 61 6d 20 75 6e | 74 69 6c 20 69 74 20 72 |tream un|til it r|
|00004320| 65 61 64 73 20 61 20 62 | 6c 61 6e 6b 20 6c 69 6e |eads a b|lank lin|
|00004330| 65 2e 20 28 42 6c 61 6e | 6b 20 6c 69 6e 65 73 20 |e. (Blan|k lines |
|00004340| 77 69 74 68 69 6e 0d 61 | 6e 20 61 73 73 69 67 6e |within.a|n assign|
|00004350| 6d 65 6e 74 20 6f 72 20 | 63 6f 6d 6d 65 6e 74 20 |ment or |comment |
|00004360| 2f 2a 20 2a 2f 20 61 72 | 65 20 69 67 6e 6f 72 65 |/* */ ar|e ignore|
|00004370| 64 2e 29 20 49 6d 70 6c | 65 6d 65 6e 74 65 64 20 |d.) Impl|emented |
|00004380| 62 79 20 72 65 70 65 61 | 74 65 64 6c 79 20 63 61 |by repea|tedly ca|
|00004390| 6c 6c 69 6e 67 0d 52 65 | 61 64 41 73 73 69 67 6e |lling.Re|adAssign|
|000043a0| 6d 65 6e 74 4c 69 6e 65 | 28 29 20 75 6e 74 69 6c |mentLine|() until|
|000043b0| 20 41 73 73 69 67 6e 6d | 65 6e 74 4c 69 6e 65 57 | Assignm|entLineW|
|000043c0| 61 73 42 6c 61 6e 6b 28 | 29 20 69 73 20 74 72 75 |asBlank(|) is tru|
|000043d0| 65 2e 20 0d 0d 09 6e 3d | 52 65 61 64 41 73 73 69 |e. ...n=|ReadAssi|
|000043e0| 67 6e 6d 65 6e 74 46 69 | 6c 65 28 66 69 6c 65 6e |gnmentFi|le(filen|
|000043f0| 61 6d 65 2c 64 65 73 63 | 72 69 70 74 69 6f 6e 73 |ame,desc|riptions|
|00004400| 2c 66 6c 61 67 73 29 3b | 0d 49 6e 74 65 72 70 72 |,flags);|.Interpr|
|00004410| 65 74 20 61 20 77 68 6f | 6c 65 20 66 69 6c 65 2e |et a who|le file.|
|00004420| 20 49 6d 70 6c 65 6d 65 | 6e 74 65 64 20 62 79 20 | Impleme|nted by |
|00004430| 72 65 70 65 61 74 65 64 | 6c 79 20 63 61 6c 6c 69 |repeated|ly calli|
|00004440| 6e 67 20 52 65 61 64 41 | 73 73 69 67 6e 6d 65 6e |ng ReadA|ssignmen|
|00004450| 74 4c 69 6e 65 28 29 2e | 0d 0d 09 46 72 65 65 44 |tLine().|...FreeD|
|00004460| 65 73 63 72 69 62 65 64 | 50 74 72 56 61 72 73 28 |escribed|PtrVars(|
|00004470| 64 65 73 63 72 69 70 74 | 69 6f 6e 73 2c 66 6c 61 |descript|ions,fla|
|00004480| 67 73 29 3b 0d 46 72 65 | 65 73 20 61 6e 79 20 61 |gs);.Fre|es any a|
|00004490| 6c 6c 6f 63 61 74 65 64 | 20 73 74 6f 72 61 67 65 |llocated| storage|
|000044a0| 20 28 61 6e 64 20 77 69 | 70 65 73 20 6f 75 74 20 | (and wi|pes out |
|000044b0| 74 68 65 20 61 72 72 61 | 79 20 64 69 6d 65 6e 73 |the arra|y dimens|
|000044c0| 69 6f 6e 73 29 20 66 6f | 72 20 61 6e 79 0d 64 65 |ions) fo|r any.de|
|000044d0| 73 63 72 69 62 65 64 20 | 50 74 72 54 79 70 65 20 |scribed |PtrType |
|000044e0| 76 61 72 69 61 62 6c 65 | 73 3b 20 74 68 65 79 20 |variable|s; they |
|000044f0| 77 69 6c 6c 20 62 65 20 | 61 70 70 72 6f 70 72 69 |will be |appropri|
|00004500| 61 74 65 6c 79 20 64 69 | 6d 65 6e 73 69 6f 6e 65 |ately di|mensione|
|00004510| 64 20 61 6e 64 0d 61 6c | 6c 6f 63 61 74 65 64 20 |d and.al|located |
|00004520| 77 68 65 6e 20 74 68 65 | 79 20 61 72 65 20 6e 65 |when the|y are ne|
|00004530| 78 74 20 72 65 61 64 20 | 66 72 6f 6d 20 61 6e 20 |xt read |from an |
|00004540| 61 73 73 69 67 6e 6d 65 | 6e 74 20 66 69 6c 65 2e |assignme|nt file.|
|00004550| 20 54 68 69 73 20 61 6c | 6c 6f 77 73 20 72 65 61 | This al|lows rea|
|00004560| 64 69 6e 67 0d 6f 66 20 | 61 73 73 69 67 6e 6d 65 |ding.of |assignme|
|00004570| 6e 74 20 66 69 6c 65 73 | 20 69 6e 20 77 68 69 63 |nt files| in whic|
|00004580| 68 20 61 72 72 61 79 20 | 64 69 6d 65 6e 73 69 6f |h array |dimensio|
|00004590| 6e 73 20 6d 61 79 20 63 | 68 61 6e 67 65 20 66 72 |ns may c|hange fr|
|000045a0| 6f 6d 20 67 75 6c 70 20 | 74 6f 20 67 75 6c 70 2e |om gulp |to gulp.|
|000045b0| 0d 0d 09 46 72 65 65 44 | 65 73 63 72 69 62 65 64 |...FreeD|escribed|
|000045c0| 56 61 72 73 28 64 65 73 | 63 72 69 70 74 69 6f 6e |Vars(des|cription|
|000045d0| 73 2c 66 6c 61 67 73 29 | 3b 0d 46 72 65 65 73 20 |s,flags)|;.Frees |
|000045e0| 61 6e 79 20 61 6c 6c 6f | 63 61 74 65 64 20 73 74 |any allo|cated st|
|000045f0| 6f 72 61 67 65 20 28 61 | 6e 64 20 77 69 70 65 73 |orage (a|nd wipes|
|00004600| 20 6f 75 74 20 74 68 65 | 20 61 72 72 61 79 20 64 | out the| array d|
|00004610| 69 6d 65 6e 73 69 6f 6e | 73 29 20 66 6f 72 20 61 |imension|s) for a|
|00004620| 6e 79 0d 64 65 73 63 72 | 69 62 65 64 20 50 74 72 |ny.descr|ibed Ptr|
|00004630| 54 79 70 65 20 61 6e 64 | 20 73 74 72 69 6e 67 54 |Type and| stringT|
|00004640| 79 70 65 20 76 61 72 69 | 61 62 6c 65 73 2e 0d 0d |ype vari|ables...|
|00004650| 09 46 72 65 65 41 44 65 | 73 63 72 69 62 65 64 56 |.FreeADe|scribedV|
|00004660| 61 72 28 64 65 73 63 72 | 69 70 74 69 6f 6e 2c 66 |ar(descr|iption,f|
|00004670| 6c 61 67 73 29 3b 0d 46 | 72 65 65 73 20 61 6e 79 |lags);.F|rees any|
|00004680| 20 61 6c 6c 6f 63 61 74 | 65 64 20 73 74 6f 72 61 | allocat|ed stora|
|00004690| 67 65 20 28 61 6e 64 20 | 77 69 70 65 73 20 6f 75 |ge (and |wipes ou|
|000046a0| 74 20 74 68 65 20 61 72 | 72 61 79 20 64 69 6d 65 |t the ar|ray dime|
|000046b0| 6e 73 69 6f 6e 73 29 20 | 66 6f 72 20 61 20 64 65 |nsions) |for a de|
|000046c0| 73 63 72 69 62 65 64 0d | 76 61 72 69 61 62 6c 65 |scribed.|variable|
|000046d0| 2e 20 54 68 69 73 20 6f | 6e 6c 79 20 61 66 66 65 |. This o|nly affe|
|000046e0| 63 74 73 20 50 74 72 54 | 79 70 65 20 61 6e 64 20 |cts PtrT|ype and |
|000046f0| 73 74 72 69 6e 67 54 79 | 70 65 20 76 61 72 69 61 |stringTy|pe varia|
|00004700| 62 6c 65 73 2e 0d 0d 09 | 4b 65 65 70 44 65 73 63 |bles....|KeepDesc|
|00004710| 72 69 62 65 64 56 61 72 | 73 28 64 65 73 63 72 69 |ribedVar|s(descri|
|00004720| 70 74 69 6f 6e 73 2c 66 | 6c 61 67 73 29 3b 0d 50 |ptions,f|lags);.P|
|00004730| 72 65 76 65 6e 74 73 20 | 74 68 65 20 66 72 65 65 |revents |the free|
|00004740| 69 6e 67 20 6f 66 20 61 | 6c 6c 20 74 68 65 20 61 |ing of a|ll the a|
|00004750| 6c 6c 6f 63 61 74 65 64 | 20 73 74 6f 72 61 67 65 |llocated| storage|
|00004760| 20 66 6f 72 20 61 6c 6c | 20 74 68 65 20 64 65 73 | for all| the des|
|00004770| 63 72 69 62 65 64 20 50 | 74 72 54 79 70 65 0d 61 |cribed P|trType.a|
|00004780| 6e 64 20 73 74 72 69 6e | 67 54 79 70 65 20 76 61 |nd strin|gType va|
|00004790| 72 69 61 62 6c 65 73 2e | 20 43 61 6c 6c 20 74 68 |riables.| Call th|
|000047a0| 69 73 20 77 68 65 6e 20 | 79 6f 75 20 77 61 6e 74 |is when |you want|
|000047b0| 20 74 6f 20 63 6f 70 79 | 20 74 68 65 20 70 6f 69 | to copy| the poi|
|000047c0| 6e 74 65 72 20 65 6c 73 | 65 77 68 65 72 65 0d 61 |nter els|ewhere.a|
|000047d0| 6e 64 20 79 6f 75 20 64 | 6f 6e 27 74 20 77 61 6e |nd you d|on't wan|
|000047e0| 74 20 41 73 73 69 67 6e | 20 74 6f 20 64 69 73 70 |t Assign| to disp|
|000047f0| 6f 73 65 20 6f 66 20 74 | 68 65 20 73 74 6f 72 61 |ose of t|he stora|
|00004800| 67 65 20 70 6f 69 6e 74 | 65 64 20 74 6f 2e 20 28 |ge point|ed to. (|
|00004810| 54 68 69 73 20 72 6f 75 | 74 69 6e 65 0d 73 69 6d |This rou|tine.sim|
|00004820| 70 6c 79 20 63 6c 65 61 | 72 73 20 61 6c 6c 20 74 |ply clea|rs all t|
|00004830| 68 65 20 22 6d 61 6c 6c | 6f 63 65 64 22 20 66 69 |he "mall|oced" fi|
|00004840| 65 6c 64 73 20 69 6e 20 | 74 68 65 20 64 65 73 63 |elds in |the desc|
|00004850| 72 69 70 74 69 6f 6e 73 | 2e 29 0d 0d 09 69 3d 46 |riptions|.)...i=F|
|00004860| 69 6e 64 44 65 73 63 72 | 69 70 74 69 6f 6e 28 64 |indDescr|iption(d|
|00004870| 2c 70 74 72 2c 66 6c 61 | 67 73 29 3b 0d 46 69 6e |,ptr,fla|gs);.Fin|
|00004880| 64 73 20 79 6f 75 72 20 | 43 20 76 61 72 69 61 62 |ds your |C variab|
|00004890| 6c 65 27 73 20 64 65 73 | 63 72 69 70 74 69 6f 6e |le's des|cription|
|000048a0| 20 69 6e 20 74 68 65 20 | 73 75 70 70 6c 69 65 64 | in the |supplied|
|000048b0| 20 61 72 72 61 79 2e 20 | 52 65 74 75 72 6e 73 20 | array. |Returns |
|000048c0| 74 68 65 20 73 75 62 73 | 63 72 69 70 74 0d 28 b3 |the subs|cript.(.|
|000048d0| 30 29 20 6f 66 20 74 68 | 65 20 6d 61 74 63 68 69 |0) of th|e matchi|
|000048e0| 6e 67 20 44 65 73 63 72 | 69 70 74 69 6f 6e 2c 20 |ng Descr|iption, |
|000048f0| 6f 72 2c 20 69 66 20 74 | 68 65 20 73 65 61 72 63 |or, if t|he searc|
|00004900| 68 20 66 61 69 6c 73 2c | 20 74 68 65 6e 20 65 69 |h fails,| then ei|
|00004910| 74 68 65 72 20 50 72 69 | 6e 74 66 45 78 69 74 73 |ther Pri|ntfExits|
|00004920| 0d 77 69 74 68 20 61 6e | 20 65 72 72 6f 72 20 6f |.with an| error o|
|00004930| 72 20 72 65 74 75 72 6e | 73 20 61 20 6e 65 67 61 |r return|s a nega|
|00004940| 74 69 76 65 20 65 72 72 | 6f 72 20 63 6f 64 65 2c |tive err|or code,|
|00004950| 20 61 73 20 64 65 74 65 | 72 6d 69 6e 65 64 20 62 | as dete|rmined b|
|00004960| 79 20 74 68 65 20 73 65 | 74 74 69 6e 67 20 6f 66 |y the se|tting of|
|00004970| 0d 74 68 65 20 61 73 73 | 69 67 6e 4e 6f 50 72 69 |.the ass|ignNoPri|
|00004980| 6e 74 66 45 78 69 74 20 | 62 69 74 20 69 6e 20 66 |ntfExit |bit in f|
|00004990| 6c 61 67 73 2e 20 59 6f | 75 72 20 43 20 76 61 72 |lags. Yo|ur C var|
|000049a0| 69 61 62 6c 65 27 73 20 | 64 69 6d 65 6e 73 69 6f |iable's |dimensio|
|000049b0| 6e 73 20 61 72 65 20 69 | 6e 20 74 68 65 0d 64 5b |ns are i|n the.d[|
|000049c0| 69 5d 2e 64 69 6d 5b 5d | 20 66 69 65 6c 64 2c 20 |i].dim[]| field, |
|000049d0| 77 68 69 63 68 20 69 73 | 20 64 69 6d 65 6e 73 69 |which is| dimensi|
|000049e0| 6f 6e 65 64 20 41 53 53 | 49 47 4e 5f 44 49 4d 53 |oned ASS|IGN_DIMS|
|000049f0| 2e 0d 0d 09 64 69 6d 3d | 46 69 6e 64 44 65 73 63 |....dim=|FindDesc|
|00004a00| 72 69 62 65 64 44 69 6d | 28 64 2c 70 74 72 2c 6e |ribedDim|(d,ptr,n|
|00004a10| 2c 66 6c 61 67 73 29 3b | 0d 43 61 6c 6c 73 20 46 |,flags);|.Calls F|
|00004a20| 69 6e 64 44 65 73 63 72 | 69 70 74 69 6f 6e 20 74 |indDescr|iption t|
|00004a30| 6f 20 66 69 6e 64 20 79 | 6f 75 72 20 43 20 76 61 |o find y|our C va|
|00004a40| 72 69 61 62 6c 65 27 73 | 20 64 65 73 63 72 69 70 |riable's| descrip|
|00004a50| 74 69 6f 6e 20 61 6e 64 | 20 72 65 74 75 72 6e 73 |tion and| returns|
|00004a60| 20 74 68 65 0d 73 69 7a | 65 20 6f 66 20 79 6f 75 | the.siz|e of you|
|00004a70| 72 20 76 61 72 69 61 62 | 6c 65 27 73 20 6e 2d 74 |r variab|le's n-t|
|00004a80| 68 20 64 69 6d 65 6e 73 | 69 6f 6e 2e 20 28 41 6c |h dimens|ion. (Al|
|00004a90| 6c 20 64 69 6d 65 6e 73 | 69 6f 6e 73 20 61 66 74 |l dimens|ions aft|
|00004aa0| 65 72 20 74 68 65 20 66 | 69 72 73 74 0d 41 53 53 |er the f|irst.ASS|
|00004ab0| 49 47 4e 5f 44 49 4d 53 | 20 72 65 74 75 72 6e 20 |IGN_DIMS| return |
|00004ac0| 7a 65 72 6f 2e 29 20 48 | 61 6e 64 6c 69 6e 67 20 |zero.) H|andling |
|00004ad0| 6f 66 20 73 65 61 72 63 | 68 20 66 61 69 6c 75 72 |of searc|h failur|
|00004ae0| 65 20 61 73 20 69 6e 20 | 46 69 6e 64 44 65 73 63 |e as in |FindDesc|
|00004af0| 72 69 70 74 69 6f 6e 28 | 29 2e 0d 0d 09 6e 3d 50 |ription(|)....n=P|
|00004b00| 72 69 6e 74 41 6e 41 73 | 73 69 67 6e 6d 65 6e 74 |rintAnAs|signment|
|00004b10| 28 73 74 72 65 61 6d 2c | 64 2c 66 6c 61 67 73 29 |(stream,|d,flags)|
|00004b20| 3b 0d 50 72 69 6e 74 73 | 20 6f 75 74 20 74 68 65 |;.Prints| out the|
|00004b30| 20 6e 61 6d 65 20 61 6e | 64 20 76 61 6c 75 65 20 | name an|d value |
|00004b40| 6f 66 20 74 68 65 20 64 | 65 73 63 72 69 62 65 64 |of the d|escribed|
|00004b50| 20 76 61 72 69 61 62 6c | 65 20 61 73 20 61 6e 20 | variabl|e as an |
|00004b60| 61 73 73 69 67 6e 6d 65 | 6e 74 0d 73 74 61 74 65 |assignme|nt.state|
|00004b70| 6d 65 6e 74 20 22 69 3d | 32 3b 22 20 73 75 69 74 |ment "i=|2;" suit|
|00004b80| 61 62 6c 65 20 66 6f 72 | 20 72 65 61 64 69 6e 67 |able for| reading|
|00004b90| 20 62 79 20 52 65 61 64 | 41 73 73 69 67 6e 6d 65 | by Read|Assignme|
|00004ba0| 6e 74 4c 69 6e 65 2e 0d | 0d 09 6e 3d 50 72 69 6e |ntLine..|..n=Prin|
|00004bb0| 74 41 73 73 69 67 6e 6d | 65 6e 74 73 28 73 74 72 |tAssignm|ents(str|
|00004bc0| 65 61 6d 2c 64 65 73 63 | 72 69 70 74 69 6f 6e 73 |eam,desc|riptions|
|00004bd0| 2c 66 6c 61 67 73 29 3b | 0d 43 61 6c 6c 73 20 50 |,flags);|.Calls P|
|00004be0| 72 69 6e 74 41 6e 41 73 | 73 69 67 6e 6d 65 6e 74 |rintAnAs|signment|
|00004bf0| 20 61 6e 64 20 66 70 72 | 69 6e 74 66 28 73 74 72 | and fpr|intf(str|
|00004c00| 65 61 6d 2c 22 5c 6e 22 | 29 3b 20 66 6f 72 20 65 |eam,"\n"|); for e|
|00004c10| 61 63 68 20 64 65 73 63 | 72 69 62 65 64 20 76 61 |ach desc|ribed va|
|00004c20| 72 69 61 62 6c 65 2e 0d | 0d 09 6e 3d 50 72 69 6e |riable..|..n=Prin|
|00004c30| 74 41 73 73 69 67 6e 6d | 65 6e 74 73 54 6f 46 69 |tAssignm|entsToFi|
|00004c40| 6c 65 28 66 69 6c 65 6e | 61 6d 65 2c 64 65 73 63 |le(filen|ame,desc|
|00004c50| 72 69 70 74 69 6f 6e 73 | 2c 66 6c 61 67 73 29 3b |riptions|,flags);|
|00004c60| 0d 4f 70 65 6e 73 20 74 | 68 65 20 66 69 6c 65 2c |.Opens t|he file,|
|00004c70| 20 63 61 6c 6c 73 20 50 | 72 69 6e 74 41 73 73 69 | calls P|rintAssi|
|00004c80| 67 6e 6d 65 6e 74 73 2c | 20 61 6e 64 20 63 6c 6f |gnments,| and clo|
|00004c90| 73 65 73 20 74 68 65 20 | 66 69 6c 65 2e 20 49 66 |ses the |file. If|
|00004ca0| 20 61 20 66 69 6c 65 20 | 6f 66 20 74 68 61 74 20 | a file |of that |
|00004cb0| 0d 6e 61 6d 65 20 61 6c | 72 65 61 64 79 20 65 78 |.name al|ready ex|
|00004cc0| 69 73 74 73 20 69 74 20 | 61 70 70 65 6e 64 73 20 |ists it |appends |
|00004cd0| 74 6f 20 74 68 65 20 65 | 78 69 73 74 69 6e 67 20 |to the e|xisting |
|00004ce0| 66 69 6c 65 2e 0d 0d 09 | 6e 3d 52 65 61 64 4c 75 |file....|n=ReadLu|
|00004cf0| 6d 69 6e 61 6e 63 65 52 | 65 63 6f 72 64 28 66 69 |minanceR|ecord(fi|
|00004d00| 6c 65 6e 61 6d 65 2c 4c | 50 2c 66 6c 61 67 73 29 |lename,L|P,flags)|
|00004d10| 0d 54 68 69 73 20 75 73 | 65 73 20 52 65 61 64 41 |.This us|es ReadA|
|00004d20| 73 73 69 67 6e 6d 65 6e | 74 46 69 6c 65 28 29 20 |ssignmen|tFile() |
|00004d30| 74 6f 20 69 6e 74 65 72 | 70 72 65 74 20 61 20 4c |to inter|pret a L|
|00004d40| 75 6d 69 6e 61 6e 63 65 | 52 65 63 6f 72 64 3f 2e |uminance|Record?.|
|00004d50| 68 20 66 69 6c 65 2e 20 | 54 68 69 73 0d 72 6f 75 |h file. |This.rou|
|00004d60| 74 69 6e 65 20 69 73 20 | 69 6e 20 52 65 61 64 4c |tine is |in ReadL|
|00004d70| 75 6d 69 6e 61 6e 63 65 | 52 65 63 6f 72 64 2e 63 |uminance|Record.c|
|00004d80| 2e 0d 0d 49 6e 20 61 6c | 6c 20 63 61 73 65 73 20 |...In al|l cases |
|00004d90| 74 68 65 20 72 65 74 75 | 72 6e 65 64 20 76 61 6c |the retu|rned val|
|00004da0| 75 65 2c 20 6e 2c 20 69 | 73 20 65 69 74 68 65 72 |ue, n, i|s either|
|00004db0| 20 70 6f 73 69 74 69 76 | 65 20 28 3e 3d 30 29 2c | positiv|e (>=0),|
|00004dc0| 20 69 6e 64 69 63 61 74 | 69 6e 67 20 74 68 65 0d | indicat|ing the.|
|00004dd0| 6e 75 6d 62 65 72 20 6f | 66 20 64 61 74 61 20 74 |number o|f data t|
|00004de0| 68 61 74 20 77 65 72 65 | 20 66 75 6c 6c 79 20 70 |hat were| fully p|
|00004df0| 72 6f 63 65 73 73 65 64 | 2c 20 6f 72 20 6e 65 67 |rocessed|, or neg|
|00004e00| 61 74 69 76 65 2c 20 69 | 6e 64 69 63 61 74 69 6e |ative, i|ndicatin|
|00004e10| 67 20 61 6e 20 65 72 72 | 6f 72 20 63 6f 64 65 0d |g an err|or code.|
|00004e20| 64 65 66 69 6e 65 64 20 | 69 6e 20 56 69 64 65 6f |defined |in Video|
|00004e30| 54 6f 6f 6c 62 6f 78 2e | 68 2e 20 45 61 63 68 20 |Toolbox.|h. Each |
|00004e40| 61 72 72 61 79 20 65 6c | 65 6d 65 6e 74 2c 20 73 |array el|ement, s|
|00004e50| 63 61 6c 61 72 2c 20 6f | 72 20 73 74 72 69 6e 67 |calar, o|r string|
|00004e60| 20 69 73 20 63 6f 6e 73 | 69 64 65 72 65 64 20 61 | is cons|idered a|
|00004e70| 0d 64 61 74 75 6d 2e 20 | 41 6e 79 20 61 73 73 69 |.datum. |Any assi|
|00004e80| 67 6e 6d 65 6e 74 73 20 | 74 68 61 74 20 72 65 66 |gnments |that ref|
|00004e90| 65 72 72 65 64 20 74 6f | 20 6f 75 74 2d 6f 66 2d |erred to| out-of-|
|00004ea0| 72 61 6e 67 65 20 61 72 | 72 61 79 20 65 6c 65 6d |range ar|ray elem|
|00004eb0| 65 6e 74 73 20 6f 72 20 | 75 6e 6b 6e 6f 77 6e 0d |ents or |unknown.|
|00004ec0| 76 61 72 69 61 62 6c 65 | 73 20 61 72 65 20 73 6b |variable|s are sk|
|00004ed0| 69 70 70 65 64 20 61 6e | 64 20 61 72 65 20 6e 6f |ipped an|d are no|
|00004ee0| 74 20 63 6f 75 6e 74 65 | 64 2e 0d 0d 54 68 65 20 |t counte|d...The |
|00004ef0| 66 69 72 73 74 20 61 72 | 67 75 6d 65 6e 74 20 69 |first ar|gument i|
|00004f00| 73 20 65 69 74 68 65 72 | 20 61 20 66 69 6c 65 6e |s either| a filen|
|00004f10| 61 6d 65 20 28 63 20 73 | 74 72 69 6e 67 29 20 6f |ame (c s|tring) o|
|00004f20| 72 20 61 20 73 74 72 65 | 61 6d 20 28 46 49 4c 45 |r a stre|am (FILE|
|00004f30| 20 2a 29 0d 72 65 74 75 | 72 6e 65 64 20 62 79 20 | *).retu|rned by |
|00004f40| 66 6f 70 65 6e 28 29 2e | 20 4f 70 65 6e 20 74 68 |fopen().| Open th|
|00004f50| 65 20 66 69 6c 65 20 69 | 6e 20 74 65 78 74 2c 20 |e file i|n text, |
|00004f60| 6e 6f 74 20 62 69 6e 61 | 72 79 2c 20 6d 6f 64 65 |not bina|ry, mode|
|00004f70| 2c 20 73 6f 20 74 68 61 | 74 0d 27 5c 72 27 20 61 |, so tha|t.'\r' a|
|00004f80| 6e 64 20 27 5c 6e 27 20 | 63 68 61 72 61 63 74 65 |nd '\n' |characte|
|00004f90| 72 73 20 77 69 6c 6c 20 | 62 65 20 74 72 61 6e 73 |rs will |be trans|
|00004fa0| 6c 61 74 65 64 20 70 72 | 6f 70 65 72 6c 79 2e 0d |lated pr|operly..|
|00004fb0| 0d 54 68 65 20 73 65 63 | 6f 6e 64 20 61 72 67 75 |.The sec|ond argu|
|00004fc0| 6d 65 6e 74 2c 20 22 64 | 65 73 63 72 69 70 74 69 |ment, "d|escripti|
|00004fd0| 6f 6e 73 22 2c 20 69 73 | 20 61 6e 20 61 72 72 61 |ons", is| an arra|
|00004fe0| 79 20 6f 66 20 44 65 73 | 63 72 69 70 74 69 6f 6e |y of Des|cription|
|00004ff0| 73 20 6f 66 0d 79 6f 75 | 72 20 76 61 72 69 61 62 |s of.you|r variab|
|00005000| 6c 65 73 2e 20 54 68 65 | 20 6e 75 6d 62 65 72 20 |les. The| number |
|00005010| 6f 66 20 61 72 72 61 79 | 20 65 6c 65 6d 65 6e 74 |of array| element|
|00005020| 73 20 69 73 20 6e 6f 74 | 20 67 69 76 65 6e 2e 20 |s is not| given. |
|00005030| 49 6e 73 74 65 61 64 20 | 79 6f 75 20 6d 61 72 6b |Instead |you mark|
|00005040| 20 74 68 65 0d 65 6e 64 | 20 62 79 20 7a 65 72 6f | the.end| by zero|
|00005050| 69 6e 67 20 74 68 65 20 | 22 74 79 70 65 22 20 66 |ing the |"type" f|
|00005060| 69 65 6c 64 20 6f 66 20 | 74 68 65 20 6c 61 73 74 |ield of |the last|
|00005070| 20 44 65 73 63 72 69 70 | 74 69 6f 6e 2e 20 54 68 | Descrip|tion. Th|
|00005080| 65 20 22 44 65 73 63 72 | 69 70 74 69 6f 6e 22 20 |e "Descr|iption" |
|00005090| 64 61 74 61 0d 73 74 72 | 75 63 74 75 72 65 20 69 |data.str|ucture i|
|000050a0| 73 20 64 65 66 69 6e 65 | 64 20 69 6e 20 56 69 64 |s define|d in Vid|
|000050b0| 65 6f 54 6f 6f 6c 62 6f | 78 2e 68 2e 0d 0d 54 68 |eoToolbo|x.h...Th|
|000050c0| 65 20 74 68 69 72 64 20 | 61 72 67 75 6d 65 6e 74 |e third |argument|
|000050d0| 2c 20 22 66 6c 61 67 73 | 22 2c 20 61 6c 6c 6f 77 |, "flags|", allow|
|000050e0| 73 20 79 6f 75 20 74 6f | 20 73 70 65 63 69 66 79 |s you to| specify|
|000050f0| 20 76 61 72 69 6f 75 73 | 20 72 75 6e 74 69 6d 65 | various| runtime|
|00005100| 20 6f 70 74 69 6f 6e 73 | 2e 20 45 61 63 68 0d 6f | options|. Each.o|
|00005110| 70 74 69 6f 6e 20 69 73 | 20 63 6f 6e 74 72 6f 6c |ption is| control|
|00005120| 6c 65 64 20 62 79 20 61 | 20 64 69 66 66 65 72 65 |led by a| differe|
|00005130| 6e 74 20 62 69 74 3b 20 | 66 6c 61 67 73 20 69 73 |nt bit; |flags is|
|00005140| 20 74 68 65 20 73 75 6d | 20 6f 66 20 74 68 65 20 | the sum| of the |
|00005150| 64 65 73 69 72 65 64 0d | 6f 70 74 69 6f 6e 73 2e |desired.|options.|
|00005160| 20 4d 6f 73 74 20 75 73 | 65 72 73 20 77 69 6c 6c | Most us|ers will|
|00005170| 20 77 61 6e 74 20 74 68 | 65 20 64 65 66 61 75 6c | want th|e defaul|
|00005180| 74 20 62 65 68 61 76 69 | 6f 72 2c 20 69 2e 65 2e |t behavi|or, i.e.|
|00005190| 20 66 6c 61 67 73 3d 3d | 30 2e 20 54 68 65 20 64 | flags==|0. The d|
|000051a0| 65 66 61 75 6c 74 0d 62 | 65 68 61 76 69 6f 72 20 |efault.b|ehavior |
|000051b0| 6f 66 20 50 72 69 6e 74 | 41 6e 41 73 73 69 67 6e |of Print|AnAssign|
|000051c0| 6d 65 6e 74 20 69 73 20 | 74 6f 20 6e 65 76 65 72 |ment is |to never|
|000051d0| 20 68 65 78 2d 65 6e 63 | 6f 64 65 20 66 6c 6f 61 | hex-enc|ode floa|
|000051e0| 74 73 20 28 66 6c 6f 61 | 74 20 61 6e 64 20 64 6f |ts (floa|t and do|
|000051f0| 75 62 6c 65 29 0d 61 6e | 64 20 74 6f 20 6f 6e 6c |uble).an|d to onl|
|00005200| 79 20 68 65 78 20 65 6e | 63 6f 64 65 20 69 6e 74 |y hex en|code int|
|00005210| 65 67 65 72 73 20 28 69 | 2e 65 2e 20 63 68 61 72 |egers (i|.e. char|
|00005220| 2c 20 73 68 6f 72 74 2c | 20 61 6e 64 20 6c 6f 6e |, short,| and lon|
|00005230| 67 2c 20 73 69 67 6e 65 | 64 20 6f 72 20 75 6e 73 |g, signe|d or uns|
|00005240| 69 67 6e 65 64 29 0d 77 | 68 65 6e 20 74 68 69 73 |igned).w|hen this|
|00005250| 20 77 6f 75 6c 64 20 72 | 65 64 75 63 65 20 74 68 | would r|educe th|
|00005260| 65 20 6e 75 6d 62 65 72 | 20 6f 66 20 6c 69 6e 65 |e number| of line|
|00005270| 73 20 69 6e 20 74 68 65 | 20 61 73 73 69 67 6e 6d |s in the| assignm|
|00005280| 65 6e 74 20 66 69 6c 65 | 20 28 69 2e 65 2e 20 77 |ent file| (i.e. w|
|00005290| 68 65 6e 0d 74 68 65 20 | 6c 61 73 74 20 64 69 6d |hen.the |last dim|
|000052a0| 65 6e 73 69 6f 6e 20 65 | 78 63 65 65 64 73 20 74 |ension e|xceeds t|
|000052b0| 79 70 65 53 69 7a 65 2b | 32 29 2e 0d 0d 46 4c 41 |ypeSize+|2)...FLA|
|000052c0| 47 53 0d 0d 22 61 73 73 | 69 67 6e 4e 6f 50 72 69 |GS.."ass|ignNoPri|
|000052d0| 6e 74 66 45 78 69 74 22 | 20 69 73 20 61 20 66 6c |ntfExit"| is a fl|
|000052e0| 61 67 20 74 68 61 74 20 | 61 73 6b 73 20 61 6c 6c |ag that |asks all|
|000052f0| 20 74 68 65 20 72 6f 75 | 74 69 6e 65 73 20 74 6f | the rou|tines to|
|00005300| 20 72 65 74 75 72 6e 20 | 61 6e 20 65 72 72 6f 72 | return |an error|
|00005310| 0d 63 6f 64 65 20 69 66 | 20 74 68 65 79 20 63 61 |.code if| they ca|
|00005320| 6e 6e 6f 74 20 73 61 74 | 69 73 66 79 20 74 68 65 |nnot sat|isfy the|
|00005330| 20 72 65 71 75 65 73 74 | 2c 20 6f 74 68 65 72 77 | request|, otherw|
|00005340| 69 73 65 20 74 68 65 20 | 72 6f 75 74 69 6e 65 73 |ise the |routines|
|00005350| 20 63 61 6c 6c 20 50 72 | 69 6e 74 66 45 78 69 74 | call Pr|intfExit|
|00005360| 0d 77 69 74 68 20 61 20 | 64 69 61 67 6e 6f 73 74 |.with a |diagnost|
|00005370| 69 63 20 65 72 72 6f 72 | 20 6d 65 73 73 61 67 65 |ic error| message|
|00005380| 20 74 68 61 74 20 70 69 | 6e 70 6f 69 6e 74 73 20 | that pi|npoints |
|00005390| 74 68 65 20 6c 6f 63 61 | 74 69 6f 6e 20 6f 66 20 |the loca|tion of |
|000053a0| 74 68 65 20 65 72 72 6f | 72 2e 0d 0d 22 61 73 73 |the erro|r..."ass|
|000053b0| 69 67 6e 52 65 70 6f 72 | 74 55 6e 6b 6e 6f 77 6e |ignRepor|tUnknown|
|000053c0| 22 20 61 73 6b 73 20 52 | 65 61 64 41 73 73 69 67 |" asks R|eadAssig|
|000053d0| 6e 6d 65 6e 74 4c 69 6e | 65 20 74 6f 20 72 65 70 |nmentLin|e to rep|
|000053e0| 6f 72 74 20 61 6e 20 65 | 72 72 6f 72 20 69 66 20 |ort an e|rror if |
|000053f0| 61 6e 20 75 6e 6b 6e 6f | 77 6e 0d 76 61 72 69 61 |an unkno|wn.varia|
|00005400| 62 6c 65 20 61 70 70 65 | 61 72 73 20 69 6e 20 74 |ble appe|ars in t|
|00005410| 68 65 20 61 73 73 69 67 | 6e 6d 65 6e 74 20 66 69 |he assig|nment fi|
|00005420| 6c 65 2e 20 41 72 72 61 | 79 20 65 6c 65 6d 65 6e |le. Arra|y elemen|
|00005430| 74 73 20 77 69 74 68 20 | 6f 75 74 2d 6f 66 2d 72 |ts with |out-of-r|
|00005440| 61 6e 67 65 0d 73 75 62 | 73 63 72 69 70 74 73 20 |ange.sub|scripts |
|00005450| 61 72 65 20 63 6f 6e 73 | 69 64 65 72 65 64 20 75 |are cons|idered u|
|00005460| 6e 6b 6e 6f 77 6e 20 76 | 61 72 69 61 62 6c 65 73 |nknown v|ariables|
|00005470| 2e 20 49 6e 20 74 68 65 | 20 61 62 73 65 6e 63 65 |. In the| absence|
|00005480| 20 6f 66 20 74 68 69 73 | 20 66 6c 61 67 2c 0d 61 | of this| flag,.a|
|00005490| 74 74 65 6d 70 74 73 20 | 74 6f 20 61 73 73 69 67 |ttempts |to assig|
|000054a0| 6e 20 74 6f 20 75 6e 6b | 6e 6f 77 6e 20 76 61 72 |n to unk|nown var|
|000054b0| 69 61 62 6c 65 73 20 61 | 72 65 20 73 69 6c 65 6e |iables a|re silen|
|000054c0| 74 6c 79 20 73 6b 69 70 | 70 65 64 20 28 74 68 65 |tly skip|ped (the|
|000054d0| 20 64 61 74 61 20 61 72 | 65 0d 64 69 73 63 61 72 | data ar|e.discar|
|000054e0| 64 65 64 29 2e 0d 0d 22 | 61 73 73 69 67 6e 4e 6f |ded)..."|assignNo|
|000054f0| 48 65 78 49 6e 74 73 22 | 20 74 65 6c 6c 73 20 52 |HexInts"| tells R|
|00005500| 65 61 64 41 73 73 69 67 | 6e 6d 65 6e 74 4c 69 6e |eadAssig|nmentLin|
|00005510| 65 20 61 6e 64 20 50 72 | 69 6e 74 41 6e 41 73 73 |e and Pr|intAnAss|
|00005520| 69 67 6e 6d 65 6e 74 20 | 74 6f 20 6e 65 76 65 72 |ignment |to never|
|00005530| 20 72 65 61 64 0d 6f 72 | 20 73 61 76 65 20 63 68 | read.or| save ch|
|00005540| 61 72 2c 20 73 68 6f 72 | 74 2c 20 6f 72 20 6c 6f |ar, shor|t, or lo|
|00005550| 6e 67 20 61 73 20 68 65 | 78 20 73 74 72 69 6e 67 |ng as he|x string|
|00005560| 73 2e 20 54 68 69 73 20 | 73 61 63 72 69 66 69 63 |s. This |sacrific|
|00005570| 65 73 20 74 68 65 20 63 | 6f 6d 70 61 63 74 6e 65 |es the c|ompactne|
|00005580| 73 73 20 6f 66 0d 68 65 | 78 20 73 74 72 69 6e 67 |ss of.he|x string|
|00005590| 73 2c 20 62 75 74 20 65 | 6e 68 61 6e 63 65 73 20 |s, but e|nhances |
|000055a0| 68 75 6d 61 6e 20 72 65 | 61 64 61 62 69 6c 69 74 |human re|adabilit|
|000055b0| 79 20 6f 66 20 74 68 65 | 20 61 73 73 69 67 6e 6d |y of the| assignm|
|000055c0| 65 6e 74 20 66 69 6c 65 | 2e 20 28 49 74 20 61 6c |ent file|. (It al|
|000055d0| 73 6f 0d 70 72 65 73 65 | 72 76 65 73 20 63 6f 6d |so.prese|rves com|
|000055e0| 70 61 74 69 62 69 6c 69 | 74 79 20 77 69 74 68 20 |patibili|ty with |
|000055f0| 43 2c 20 6d 61 6b 69 6e | 67 20 69 74 20 70 6f 73 |C, makin|g it pos|
|00005600| 73 69 62 6c 65 20 74 6f | 20 23 69 6e 63 6c 75 64 |sible to| #includ|
|00005610| 65 20 74 68 65 20 61 73 | 73 69 67 6e 6d 65 6e 74 |e the as|signment|
|00005620| 0d 66 69 6c 65 20 69 6e | 73 69 64 65 20 61 20 43 |.file in|side a C|
|00005630| 20 70 72 6f 67 72 61 6d | 2c 20 61 6e 64 20 70 72 | program|, and pr|
|00005640| 65 73 65 72 76 65 73 20 | 70 6f 72 74 61 62 69 6c |eserves |portabil|
|00005650| 69 74 79 20 6f 66 20 74 | 68 65 20 61 73 73 69 67 |ity of t|he assig|
|00005660| 6e 6d 65 6e 74 20 66 69 | 6c 65 0d 62 65 74 77 65 |nment fi|le.betwe|
|00005670| 65 6e 20 63 6f 6d 70 75 | 74 65 72 73 20 74 68 61 |en compu|ters tha|
|00005680| 74 20 75 73 65 20 64 69 | 66 66 65 72 65 6e 74 20 |t use di|fferent |
|00005690| 62 79 74 65 20 6f 72 64 | 65 72 69 6e 67 73 2e 29 |byte ord|erings.)|
|000056a0| 0d 0d 22 61 73 73 69 67 | 6e 48 65 78 46 6c 6f 61 |.."assig|nHexFloa|
|000056b0| 74 73 22 20 74 65 6c 6c | 73 20 50 72 69 6e 74 41 |ts" tell|s PrintA|
|000056c0| 6e 41 73 73 69 67 6e 6d | 65 6e 74 20 74 6f 20 61 |nAssignm|ent to a|
|000056d0| 6c 77 61 79 73 20 73 61 | 76 65 20 66 6c 6f 61 74 |lways sa|ve float|
|000056e0| 73 20 28 66 6c 6f 61 74 | 20 61 6e 64 0d 64 6f 75 |s (float| and.dou|
|000056f0| 62 6c 65 29 20 61 73 20 | 68 65 78 20 73 74 72 69 |ble) as |hex stri|
|00005700| 6e 67 73 2c 20 61 6e 64 | 20 74 65 6c 6c 73 20 52 |ngs, and| tells R|
|00005710| 65 61 64 41 73 73 69 67 | 6e 6d 65 6e 74 4c 69 6e |eadAssig|nmentLin|
|00005720| 65 20 74 6f 20 61 6c 6c | 6f 77 20 68 65 78 20 73 |e to all|ow hex s|
|00005730| 74 72 69 6e 67 73 2e 20 | 54 68 69 73 0d 70 72 65 |trings. |This.pre|
|00005740| 73 65 72 76 65 73 20 74 | 68 65 20 65 78 61 63 74 |serves t|he exact|
|00005750| 20 76 61 6c 75 65 20 28 | 75 6e 6c 69 6b 65 20 64 | value (|unlike d|
|00005760| 65 63 69 6d 61 6c 20 72 | 65 70 72 65 73 65 6e 74 |ecimal r|epresent|
|00005770| 61 74 69 6f 6e 2c 20 77 | 68 69 63 68 20 6c 6f 73 |ation, w|hich los|
|00005780| 65 73 20 61 20 66 65 77 | 0d 6c 65 61 73 74 2d 73 |es a few|.least-s|
|00005790| 69 67 6e 69 66 69 63 61 | 6e 74 20 62 69 74 73 20 |ignifica|nt bits |
|000057a0| 69 6e 20 74 79 70 69 63 | 61 6c 20 69 6d 70 6c 65 |in typic|al imple|
|000057b0| 6d 65 6e 74 61 74 69 6f | 6e 73 20 6f 66 20 74 68 |mentatio|ns of th|
|000057c0| 65 20 43 20 73 74 64 69 | 6f 20 6c 69 62 72 61 72 |e C stdi|o librar|
|000057d0| 79 29 2c 20 62 75 74 0d | 73 61 63 72 69 66 69 63 |y), but.|sacrific|
|000057e0| 65 73 20 68 75 6d 61 6e | 20 72 65 61 64 61 62 69 |es human| readabi|
|000057f0| 6c 69 74 79 20 61 6e 64 | 20 70 6f 72 74 61 62 69 |lity and| portabi|
|00005800| 6c 69 74 79 20 6f 66 20 | 74 68 65 20 61 73 73 69 |lity of |the assi|
|00005810| 67 6e 6d 65 6e 74 20 66 | 69 6c 65 20 73 69 6e 63 |gnment f|ile sinc|
|00005820| 65 20 74 68 65 0d 62 69 | 6e 61 72 79 20 72 65 70 |e the.bi|nary rep|
|00005830| 72 65 73 65 6e 74 61 74 | 69 6f 6e 20 6f 66 20 66 |resentat|ion of f|
|00005840| 6c 6f 61 74 73 20 69 73 | 20 68 69 67 68 6c 79 20 |loats is| highly |
|00005850| 64 65 70 65 6e 64 65 6e | 74 20 6f 6e 20 74 68 65 |dependen|t on the|
|00005860| 20 63 6f 6d 70 69 6c 65 | 72 20 6f 70 74 69 6f 6e | compile|r option|
|00005870| 73 20 61 6e 64 0d 74 68 | 65 20 6b 69 6e 64 20 6f |s and.th|e kind o|
|00005880| 66 20 63 6f 6d 70 75 74 | 65 72 2e 20 28 49 74 20 |f comput|er. (It |
|00005890| 61 6c 73 6f 20 73 61 63 | 72 69 66 69 63 65 73 20 |also sac|rifices |
|000058a0| 63 6f 6d 70 61 74 69 62 | 69 6c 69 74 79 20 77 69 |compatib|ility wi|
|000058b0| 74 68 20 43 2c 20 6d 61 | 6b 69 6e 67 20 69 74 0d |th C, ma|king it.|
|000058c0| 69 6d 70 6f 73 73 69 62 | 6c 65 20 74 6f 20 23 69 |impossib|le to #i|
|000058d0| 6e 63 6c 75 64 65 20 74 | 68 65 20 61 73 73 69 67 |nclude t|he assig|
|000058e0| 6e 6d 65 6e 74 20 66 69 | 6c 65 2e 29 0d 0d 22 61 |nment fi|le.).."a|
|000058f0| 73 73 69 67 6e 4e 6f 43 | 6f 6d 6d 65 6e 74 22 20 |ssignNoC|omment" |
|00005900| 74 65 6c 6c 73 20 50 72 | 69 6e 74 41 6e 41 73 73 |tells Pr|intAnAss|
|00005910| 69 67 6e 6d 65 6e 74 20 | 6e 6f 74 20 74 6f 20 70 |ignment |not to p|
|00005920| 72 69 6e 74 20 74 68 65 | 20 63 6f 6d 6d 65 6e 74 |rint the| comment|
|00005930| 20 66 69 65 6c 64 2e 0d | 0d 22 61 73 73 69 67 6e | field..|."assign|
|00005940| 45 63 68 6f 46 69 6c 65 | 22 2c 20 70 72 69 6d 61 |EchoFile|", prima|
|00005950| 72 69 6c 79 20 61 6e 20 | 61 69 64 20 74 6f 20 64 |rily an |aid to d|
|00005960| 65 62 75 67 67 69 6e 67 | 2c 20 70 72 69 6e 74 73 |ebugging|, prints|
|00005970| 20 65 61 63 68 20 6c 69 | 6e 65 20 66 72 6f 6d 20 | each li|ne from |
|00005980| 74 68 65 20 73 74 72 65 | 61 6d 0d 61 73 20 69 74 |the stre|am.as it|
|00005990| 20 69 73 20 72 65 61 64 | 20 62 79 20 52 65 61 64 | is read| by Read|
|000059a0| 41 73 73 69 67 6e 6d 65 | 6e 74 4c 69 6e 65 2e 0d |Assignme|ntLine..|
|000059b0| 0d 22 61 73 73 69 67 6e | 45 63 68 6f 41 73 73 69 |."assign|EchoAssi|
|000059c0| 67 6e 6d 65 6e 74 73 22 | 2c 20 70 72 69 6d 61 72 |gnments"|, primar|
|000059d0| 69 6c 79 20 61 6e 20 61 | 69 64 20 74 6f 20 64 65 |ily an a|id to de|
|000059e0| 62 75 67 67 69 6e 67 2c | 20 63 61 6c 6c 73 20 50 |bugging,| calls P|
|000059f0| 72 69 6e 74 41 6e 41 73 | 73 69 67 6e 6d 65 6e 74 |rintAnAs|signment|
|00005a00| 0d 61 66 74 65 72 20 65 | 61 63 68 20 61 73 73 69 |.after e|ach assi|
|00005a10| 67 6e 6d 65 6e 74 20 69 | 73 20 70 65 72 66 6f 72 |gnment i|s perfor|
|00005a20| 6d 65 64 20 62 79 20 52 | 65 61 64 41 73 73 69 67 |med by R|eadAssig|
|00005a30| 6e 6d 65 6e 74 4c 69 6e | 65 2e 20 55 6e 63 6f 6d |nmentLin|e. Uncom|
|00005a40| 6d 65 6e 74 65 64 20 6e | 65 77 6c 69 6e 65 0d 63 |mented n|ewline.c|
|00005a50| 68 61 72 61 63 74 65 72 | 73 20 69 6e 20 74 68 65 |haracter|s in the|
|00005a60| 20 61 73 73 69 67 6e 6d | 65 6e 74 20 66 69 6c 65 | assignm|ent file|
|00005a70| 20 61 72 65 20 65 63 68 | 6f 65 64 20 61 73 20 77 | are ech|oed as w|
|00005a80| 65 6c 6c 2e 20 28 49 66 | 20 61 73 73 69 67 6e 52 |ell. (If| assignR|
|00005a90| 65 70 6f 72 74 55 6e 6b | 6e 6f 77 6e 20 69 73 0d |eportUnk|nown is.|
|00005aa0| 6f 66 66 20 74 68 65 6e | 20 61 73 73 69 67 6e 6d |off then| assignm|
|00005ab0| 65 6e 74 20 73 74 61 74 | 65 6d 65 6e 74 73 20 63 |ent stat|ements c|
|00005ac0| 6f 6e 74 61 69 6e 69 6e | 67 20 75 6e 6b 6e 6f 77 |ontainin|g unknow|
|00005ad0| 6e 20 76 61 72 69 61 62 | 6c 65 73 20 6f 72 20 6f |n variab|les or o|
|00005ae0| 75 74 2d 6f 66 2d 62 6f | 75 6e 64 73 0d 61 72 72 |ut-of-bo|unds.arr|
|00005af0| 61 79 20 72 65 66 65 72 | 65 6e 63 65 73 20 61 72 |ay refer|ences ar|
|00005b00| 65 20 65 63 68 6f 65 64 | 20 61 73 20 63 6f 6d 6d |e echoed| as comm|
|00005b10| 65 6e 74 73 3a 20 2f 2a | 55 4e 4b 4e 4f 57 4e 3a |ents: /*|UNKNOWN:|
|00005b20| 20 78 3d 33 3b 20 2a 2f | 2e 29 0d 0d 22 61 73 73 | x=3; */|.).."ass|
|00005b30| 69 67 6e 45 63 68 6f 43 | 6f 6d 6d 65 6e 74 73 22 |ignEchoC|omments"|
|00005b40| 2c 20 70 72 69 6d 61 72 | 69 6c 79 20 61 6e 20 61 |, primar|ily an a|
|00005b50| 69 64 20 74 6f 20 64 65 | 62 75 67 67 69 6e 67 2c |id to de|bugging,|
|00005b60| 20 70 72 69 6e 74 73 20 | 62 6f 74 68 20 2f 2a 2e | prints |both /*.|
|00005b70| 2e 2a 2f 20 61 6e 64 0d | 2f 2f 2d 73 74 79 6c 65 |.*/ and.|//-style|
|00005b80| 20 63 6f 6d 6d 65 6e 74 | 73 20 61 73 20 74 68 65 | comment|s as the|
|00005b90| 79 20 61 72 65 20 72 65 | 61 64 20 62 79 20 52 65 |y are re|ad by Re|
|00005ba0| 61 64 41 73 73 69 67 6e | 6d 65 6e 74 4c 69 6e 65 |adAssign|mentLine|
|00005bb0| 2e 20 55 6e 63 6f 6d 6d | 65 6e 74 65 64 20 6e 65 |. Uncomm|ented ne|
|00005bc0| 77 6c 69 6e 65 0d 63 68 | 61 72 61 63 74 65 72 73 |wline.ch|aracters|
|00005bd0| 20 69 6e 20 74 68 65 20 | 61 73 73 69 67 6e 6d 65 | in the |assignme|
|00005be0| 6e 74 20 66 69 6c 65 20 | 61 72 65 20 65 63 68 6f |nt file |are echo|
|00005bf0| 65 64 20 61 73 20 77 65 | 6c 6c 2e 0d 0d 45 52 52 |ed as we|ll...ERR|
|00005c00| 4f 52 53 0d 0d 41 6e 20 | 65 72 72 6f 72 20 63 6f |ORS..An |error co|
|00005c10| 64 65 20 69 73 20 72 65 | 74 75 72 6e 65 64 20 6f |de is re|turned o|
|00005c20| 6e 6c 79 20 69 66 20 74 | 68 65 20 61 73 73 69 67 |nly if t|he assig|
|00005c30| 6e 4e 6f 50 72 69 6e 74 | 66 45 78 69 74 20 66 6c |nNoPrint|fExit fl|
|00005c40| 61 67 20 69 73 20 73 65 | 74 2e 20 4f 74 68 65 72 |ag is se|t. Other|
|00005c50| 77 69 73 65 0d 50 72 69 | 6e 74 66 45 78 69 74 28 |wise.Pri|ntfExit(|
|00005c60| 29 20 69 73 20 63 61 6c | 6c 65 64 20 77 69 74 68 |) is cal|led with|
|00005c70| 20 61 20 64 69 61 67 6e | 6f 73 74 69 63 20 6d 65 | a diagn|ostic me|
|00005c80| 73 73 61 67 65 2e 0d 0d | 2d 31 20 61 73 73 69 67 |ssage...|-1 assig|
|00005c90| 6e 4d 65 6d 6f 72 79 45 | 72 72 6f 72 3a 20 63 6f |nMemoryE|rror: co|
|00005ca0| 75 6c 64 6e 27 74 20 61 | 6c 6c 6f 63 61 74 65 20 |uldn't a|llocate |
|00005cb0| 65 6e 6f 75 67 68 20 6d | 65 6d 6f 72 79 2e 0d 2d |enough m|emory..-|
|00005cc0| 32 20 61 73 73 69 67 6e | 54 79 70 65 45 72 72 6f |2 assign|TypeErro|
|00005cd0| 72 3a 20 75 6e 6b 6e 6f | 77 6e 20 74 79 70 65 2c |r: unkno|wn type,|
|00005ce0| 20 6f 72 20 61 72 72 61 | 79 20 6f 66 20 73 74 72 | or arra|y of str|
|00005cf0| 69 6e 67 2c 20 77 68 69 | 63 68 20 69 73 20 6e 6f |ing, whi|ch is no|
|00005d00| 74 20 61 6c 6c 6f 77 65 | 64 2e 0d 2d 33 20 61 73 |t allowe|d..-3 as|
|00005d10| 73 69 67 6e 56 61 72 69 | 61 62 6c 65 45 72 72 6f |signVari|ableErro|
|00005d20| 72 3a 20 63 6f 75 6c 64 | 6e 27 74 20 70 61 72 73 |r: could|n't pars|
|00005d30| 65 20 74 68 65 20 76 61 | 72 69 61 62 6c 65 20 6e |e the va|riable n|
|00005d40| 61 6d 65 2e 0d 2d 34 20 | 61 73 73 69 67 6e 55 6e |ame..-4 |assignUn|
|00005d50| 6b 6e 6f 77 6e 56 61 72 | 69 61 62 6c 65 45 72 72 |knownVar|iableErr|
|00005d60| 6f 72 3a 20 75 6e 6b 6e | 6f 77 6e 20 76 61 72 69 |or: unkn|own vari|
|00005d70| 61 62 6c 65 3b 20 63 61 | 6e 20 6f 6e 6c 79 20 6f |able; ca|n only o|
|00005d80| 63 63 75 72 20 69 66 20 | 74 68 65 20 0d 09 61 73 |ccur if |the ..as|
|00005d90| 73 69 67 6e 52 65 70 6f | 72 74 55 6e 6b 6e 6f 77 |signRepo|rtUnknow|
|00005da0| 6e 20 66 6c 61 67 20 69 | 73 20 73 65 74 2e 0d 2d |n flag i|s set..-|
|00005db0| 35 20 61 73 73 69 67 6e | 53 75 62 73 63 72 69 70 |5 assign|Subscrip|
|00005dc0| 74 45 72 72 6f 72 3a 20 | 63 6f 75 6c 64 6e 27 74 |tError: |couldn't|
|00005dd0| 20 70 61 72 73 65 20 74 | 68 65 20 73 75 62 73 63 | parse t|he subsc|
|00005de0| 72 69 70 74 2e 0d 2d 36 | 20 61 73 73 69 67 6e 53 |ript..-6| assignS|
|00005df0| 75 62 73 63 72 69 70 74 | 42 6f 75 6e 64 73 45 72 |ubscript|BoundsEr|
|00005e00| 72 6f 72 3a 20 6f 75 74 | 2d 6f 66 2d 62 6f 75 6e |ror: out|-of-boun|
|00005e10| 64 73 20 61 72 72 61 79 | 20 65 6c 65 6d 65 6e 74 |ds array| element|
|00005e20| 3b 20 74 68 69 73 20 65 | 72 72 6f 72 20 69 73 20 |; this e|rror is |
|00005e30| 66 6c 61 67 67 65 64 20 | 6f 6e 6c 79 20 0d 09 69 |flagged |only ..i|
|00005e40| 66 20 74 68 65 20 61 73 | 73 69 67 6e 52 65 70 6f |f the as|signRepo|
|00005e50| 72 74 55 6e 6b 6e 6f 77 | 6e 20 66 6c 61 67 20 69 |rtUnknow|n flag i|
|00005e60| 73 20 73 65 74 2e 0d 2d | 37 20 61 73 73 69 67 6e |s set..-|7 assign|
|00005e70| 45 71 75 61 6c 73 45 72 | 72 6f 72 3a 20 63 6f 75 |EqualsEr|ror: cou|
|00005e80| 6c 64 6e 27 74 20 66 69 | 6e 64 20 74 68 65 20 65 |ldn't fi|nd the e|
|00005e90| 71 75 61 6c 73 20 73 69 | 67 6e 2e 0d 2d 38 20 61 |quals si|gn..-8 a|
|00005ea0| 73 73 69 67 6e 43 6f 6e | 73 74 61 6e 74 45 72 72 |ssignCon|stantErr|
|00005eb0| 6f 72 3a 20 63 6f 75 6c | 64 6e 27 74 20 70 61 72 |or: coul|dn't par|
|00005ec0| 73 65 20 74 68 65 20 63 | 6f 6e 73 74 61 6e 74 2e |se the c|onstant.|
|00005ed0| 0d 2d 39 20 61 73 73 69 | 67 6e 48 65 78 45 72 72 |.-9 assi|gnHexErr|
|00005ee0| 6f 72 3a 20 63 6f 75 6c | 64 6e 27 74 20 70 61 72 |or: coul|dn't par|
|00005ef0| 73 65 20 61 20 68 65 78 | 2d 65 6e 63 6f 64 65 64 |se a hex|-encoded|
|00005f00| 20 62 69 6e 61 72 79 20 | 6f 62 6a 65 63 74 20 63 | binary |object c|
|00005f10| 6f 6e 73 74 61 6e 74 2e | 0d 2d 31 30 20 61 73 73 |onstant.|.-10 ass|
|00005f20| 69 67 6e 53 65 6d 69 63 | 6f 6c 6f 6e 45 72 72 6f |ignSemic|olonErro|
|00005f30| 72 3a 20 63 6f 75 6c 64 | 6e 27 74 20 66 69 6e 64 |r: could|n't find|
|00005f40| 20 74 68 65 20 73 65 6d | 69 63 6f 6c 6f 6e 2e 0d | the sem|icolon..|
|00005f50| 2d 31 31 20 61 73 73 69 | 67 6e 46 69 6c 65 45 72 |-11 assi|gnFileEr|
|00005f60| 72 6f 72 3a 20 63 6f 75 | 6c 64 6e 27 74 20 6f 70 |ror: cou|ldn't op|
|00005f70| 65 6e 20 74 68 65 20 66 | 69 6c 65 2e 0d 2d 31 32 |en the f|ile..-12|
|00005f80| 20 61 73 73 69 67 6e 49 | 6e 63 6f 6e 73 69 73 74 | assignI|nconsist|
|00005f90| 65 6e 74 44 65 73 63 72 | 69 70 74 69 6f 6e 73 45 |entDescr|iptionsE|
|00005fa0| 72 72 6f 72 3a 20 74 77 | 6f 20 64 65 73 63 72 69 |rror: tw|o descri|
|00005fb0| 70 74 69 6f 6e 73 20 61 | 72 65 20 69 6e 63 6f 6e |ptions a|re incon|
|00005fc0| 73 69 73 74 65 6e 74 2e | 0d 2d 31 33 20 61 73 73 |sistent.|.-13 ass|
|00005fd0| 69 67 6e 55 6e 65 71 75 | 61 6c 44 61 74 61 45 72 |ignUnequ|alDataEr|
|00005fe0| 72 6f 72 3a 20 74 77 6f | 20 64 65 73 63 72 69 62 |ror: two| describ|
|00005ff0| 65 64 20 76 61 72 69 61 | 62 6c 65 73 20 68 61 76 |ed varia|bles hav|
|00006000| 65 20 73 69 67 6e 69 66 | 69 63 61 6e 74 6c 79 20 |e signif|icantly |
|00006010| 64 69 66 66 65 72 65 6e | 74 20 64 61 74 61 2e 0d |differen|t data..|
|00006020| 0d 49 4d 50 4f 52 54 41 | 4e 54 3a 20 44 6f 20 6e |.IMPORTA|NT: Do n|
|00006030| 6f 74 20 66 6f 72 67 65 | 74 20 74 6f 20 6d 61 72 |ot forge|t to mar|
|00006040| 6b 20 74 68 65 20 65 6e | 64 20 6f 66 20 79 6f 75 |k the en|d of you|
|00006050| 72 20 44 65 73 63 72 69 | 70 74 69 6f 6e 20 61 72 |r Descri|ption ar|
|00006060| 72 61 79 20 62 79 20 61 | 20 44 65 73 63 72 69 70 |ray by a| Descrip|
|00006070| 74 69 6f 6e 20 0d 77 69 | 74 68 20 61 20 74 79 70 |tion .wi|th a typ|
|00006080| 65 20 6f 66 20 7a 65 72 | 6f 2e 0d 0d 55 53 49 4e |e of zer|o...USIN|
|00006090| 47 20 41 53 53 49 47 4e | 2e 43 0d 0d 49 74 20 69 |G ASSIGN|.C..It i|
|000060a0| 73 20 73 75 67 67 65 73 | 74 65 64 20 74 68 61 74 |s sugges|ted that|
|000060b0| 20 74 68 6f 73 65 20 77 | 68 6f 20 77 61 6e 74 20 | those w|ho want |
|000060c0| 74 6f 20 75 73 65 20 74 | 68 69 73 20 70 61 63 6b |to use t|his pack|
|000060d0| 61 67 65 20 63 72 65 61 | 74 65 20 61 20 68 65 61 |age crea|te a hea|
|000060e0| 64 65 72 20 66 69 6c 65 | 0d 77 69 74 68 20 61 20 |der file|.with a |
|000060f0| 74 79 70 65 64 65 66 20 | 66 6f 72 20 61 20 64 61 |typedef |for a da|
|00006100| 74 61 20 73 74 72 75 63 | 74 75 72 65 2c 20 61 6e |ta struc|ture, an|
|00006110| 64 20 77 72 69 74 65 20 | 61 20 73 75 62 72 6f 75 |d write |a subrou|
|00006120| 74 69 6e 65 20 74 68 61 | 74 20 61 6c 6c 6f 63 61 |tine tha|t alloca|
|00006130| 74 65 73 20 61 6e 64 0d | 66 69 6c 6c 73 20 61 20 |tes and.|fills a |
|00006140| 44 65 73 63 72 69 70 74 | 69 6f 6e 20 61 72 72 61 |Descript|ion arra|
|00006150| 79 20 64 65 73 63 72 69 | 62 69 6e 67 20 74 68 65 |y descri|bing the|
|00006160| 20 64 61 74 61 20 73 74 | 72 75 63 74 75 72 65 27 | data st|ructure'|
|00006170| 73 20 66 69 65 6c 64 73 | 2e 20 46 6f 72 20 65 78 |s fields|. For ex|
|00006180| 61 6d 70 6c 65 2c 0d 4c | 75 6d 69 6e 61 6e 63 65 |ample,.L|uminance|
|00006190| 2e 68 20 64 65 66 69 6e | 65 73 20 74 68 65 20 4c |.h defin|es the L|
|000061a0| 75 6d 69 6e 61 6e 63 65 | 52 65 63 6f 72 64 20 73 |uminance|Record s|
|000061b0| 74 72 75 63 74 75 72 65 | 20 61 6e 64 20 52 65 61 |tructure| and Rea|
|000061c0| 64 4c 75 6d 69 6e 61 6e | 63 65 52 65 63 6f 72 64 |dLuminan|ceRecord|
|000061d0| 2e 63 20 0d 63 6f 6e 74 | 61 69 6e 73 20 74 68 65 |.c .cont|ains the|
|000061e0| 20 66 75 6e 63 74 69 6f | 6e 2c 0d 09 44 65 73 63 | functio|n,..Desc|
|000061f0| 72 69 70 74 69 6f 6e 20 | 2a 44 65 73 63 72 69 62 |ription |*Describ|
|00006200| 65 4c 75 6d 69 6e 61 6e | 63 65 52 65 63 6f 72 64 |eLuminan|ceRecord|
|00006210| 28 4c 75 6d 69 6e 61 6e | 63 65 52 65 63 6f 72 64 |(Luminan|ceRecord|
|00006220| 20 2a 4c 50 29 3b 0d 74 | 68 61 74 20 63 72 65 61 | *LP);.t|hat crea|
|00006230| 74 65 73 20 61 20 44 65 | 73 63 72 69 70 74 69 6f |tes a De|scriptio|
|00006240| 6e 20 61 72 72 61 79 20 | 64 65 73 63 72 69 62 69 |n array |describi|
|00006250| 6e 67 20 74 68 65 20 70 | 61 72 74 69 63 75 6c 61 |ng the p|articula|
|00006260| 72 20 4c 75 6d 69 6e 61 | 6e 63 65 52 65 63 6f 72 |r Lumina|nceRecor|
|00006270| 64 20 73 74 72 75 63 74 | 75 72 65 2e 0d 0d 43 4f |d struct|ure...CO|
|00006280| 4e 54 52 4f 4c 4c 49 4e | 47 20 45 58 50 45 52 49 |NTROLLIN|G EXPERI|
|00006290| 4d 45 4e 54 53 0d 0d 41 | 73 73 69 67 6e 2e 63 20 |MENTS..A|ssign.c |
|000062a0| 77 61 73 20 6f 72 69 67 | 69 6e 61 6c 6c 79 20 77 |was orig|inally w|
|000062b0| 72 69 74 74 65 6e 20 74 | 6f 20 72 65 61 64 20 70 |ritten t|o read p|
|000062c0| 61 72 61 6d 65 74 65 72 | 20 66 69 6c 65 73 20 74 |arameter| files t|
|000062d0| 68 61 74 20 63 6f 6e 74 | 72 6f 6c 0d 65 78 70 65 |hat cont|rol.expe|
|000062e0| 72 69 6d 65 6e 74 73 2e | 20 54 79 70 69 63 61 6c |riments.| Typical|
|000062f0| 20 70 73 79 63 68 6f 70 | 68 79 73 69 63 61 6c 20 | psychop|hysical |
|00006300| 61 6e 64 20 70 68 79 73 | 69 6f 6c 6f 67 69 63 61 |and phys|iologica|
|00006310| 6c 20 65 78 70 65 72 69 | 6d 65 6e 74 73 20 61 72 |l experi|ments ar|
|00006320| 65 20 76 65 72 79 0d 63 | 6f 6d 70 6c 69 63 61 74 |e very.c|omplicat|
|00006330| 65 64 20 61 6e 64 20 72 | 65 71 75 69 72 65 20 6c |ed and r|equire l|
|00006340| 6f 74 73 20 6f 66 20 61 | 64 6a 75 73 74 61 62 6c |ots of a|djustabl|
|00006350| 65 20 70 61 72 61 6d 65 | 74 65 72 73 2e 20 4f 6e |e parame|ters. On|
|00006360| 65 20 6e 65 65 64 73 20 | 61 6e 20 65 61 73 79 20 |e needs |an easy |
|00006370| 77 61 79 20 74 6f 0d 63 | 68 61 6e 67 65 20 74 68 |way to.c|hange th|
|00006380| 65 6d 20 61 6c 6c 20 74 | 68 61 74 20 69 73 20 73 |em all t|hat is s|
|00006390| 65 6c 66 20 64 6f 63 75 | 6d 65 6e 74 69 6e 67 20 |elf docu|menting |
|000063a0| 61 6e 64 20 65 61 73 69 | 6c 79 20 72 65 70 72 6f |and easi|ly repro|
|000063b0| 64 75 63 65 64 2c 20 70 | 6f 73 73 69 62 6c 79 20 |duced, p|ossibly |
|000063c0| 6d 6f 6e 74 68 73 0d 6c | 61 74 65 72 2e 20 54 68 |months.l|ater. Th|
|000063d0| 65 20 72 6f 75 74 69 6e | 65 73 20 70 72 6f 76 69 |e routin|es provi|
|000063e0| 64 65 64 20 68 65 72 65 | 20 63 6f 6d 65 20 69 6e |ded here| come in|
|000063f0| 20 76 61 72 69 6f 75 73 | 20 66 6c 61 76 6f 72 73 | various| flavors|
+--------+-------------------------+-------------------------+--------+--------+
Only 25.0 KB of data is shown above.