Mercurial > repos > rhope
comparison backendutils_c.rhope @ 135:18a4403fe576
Javascript backend can now produce broken output. Needs fixes plus port of standard lib
author | Mike Pavone <pavone@retrodev.com> |
---|---|
date | Sun, 14 Nov 2010 03:09:49 -0500 |
parents | b7df624895b2 |
children | fc3815b7462f |
comparison
equal
deleted
inserted
replaced
134:386f4a874821 | 135:18a4403fe576 |
---|---|
42 Strip Addref@String[op:out] | 42 Strip Addref@String[op:out] |
43 { | 43 { |
44 out <- op | 44 out <- op |
45 } | 45 } |
46 | 46 |
47 Get Type@String[op,func:out] | |
48 { | |
49 out <- [func]Get Var Type[op] | |
50 } | |
51 | |
47 Make Op@String Cat[string,func:out] | 52 Make Op@String Cat[string,func:out] |
48 { | 53 { |
49 out <- [func]Resolve[string] | 54 out <- [func]Resolve[string] |
50 } | 55 } |
51 | 56 |
52 Strip Addref@String Cat[op:out] | 57 Strip Addref@String Cat[op:out] |
53 { | 58 { |
54 out <- op | 59 out <- op |
55 } | 60 } |
56 | 61 |
62 Get Type@String Cat[op,func:out] | |
63 { | |
64 out <- [func]Get Var Type[op] | |
65 } | |
66 | |
57 Make Op@String Slice[string,func:out] | 67 Make Op@String Slice[string,func:out] |
58 { | 68 { |
59 out <- [func]Resolve[string] | 69 out <- [func]Resolve[string] |
60 } | 70 } |
61 | 71 |
62 Strip Addref@String Slice[op:out] | 72 Strip Addref@String Slice[op:out] |
63 { | 73 { |
64 out <- op | 74 out <- op |
75 } | |
76 | |
77 Get Type@String Slice[op,func:out] | |
78 { | |
79 out <- [func]Get Var Type[op] | |
65 } | 80 } |
66 | 81 |
67 Make Op@Whole Number[num,func:out] | 82 Make Op@Whole Number[num,func:out] |
68 { | 83 { |
69 out <- num | 84 out <- num |
118 Make Op@Constant[const,func:out] | 133 Make Op@Constant[const,func:out] |
119 { | 134 { |
120 out <- [func]Lookup Constant[[const]Value >>, [const]Need Addref >>] | 135 out <- [func]Lookup Constant[[const]Value >>, [const]Need Addref >>] |
121 } | 136 } |
122 | 137 |
138 Get Type@Constant[const,func:out] | |
139 { | |
140 out <- [func]Get Constant Type[const] | |
141 } | |
142 | |
123 Strip Addref@Constant[op:out] | 143 Strip Addref@Constant[op:out] |
124 { | 144 { |
125 out <- [op]Need Addref <<[No] | 145 out <- [op]Need Addref <<[No] |
126 } | 146 } |
127 | 147 |
265 } | 285 } |
266 | 286 |
267 Field Ref[var,field:out] | 287 Field Ref[var,field:out] |
268 { | 288 { |
269 out <- [[Build[Field Ref()]]Variable <<[var]]Field <<[field] | 289 out <- [[Build[Field Ref()]]Variable <<[var]]Field <<[field] |
290 } | |
291 | |
292 Get Type@Field Ref[ref,func:out] | |
293 { | |
294 out <- [func]Get Field Type[[[ref]Variable >>]Get Type[func], [ref]Field >>] | |
270 } | 295 } |
271 | 296 |
272 Make Op@Field Ref[ref,func:out] | 297 Make Op@Field Ref[ref,func:out] |
273 { | 298 { |
274 out <- [func]Field Result[[ref]Variable >>,[ref]Field >>] | 299 out <- [func]Field Result[[ref]Variable >>,[ref]Field >>] |