Changeset View
Changeset View
Standalone View
Standalone View
autotests/input/highlight.pony
Show First 20 Lines • Show All 143 Lines • ▼ Show 20 Line(s) | 135 | fun foo(n:U32): {ref(U32): U32} => | |||
---|---|---|---|---|---|
144 | } | 144 | } | ||
145 | 145 | | |||
146 | new create(env:Env) => | 146 | new create(env:Env) => | ||
147 | var f = foo(5) | 147 | var f = foo(5) | ||
148 | env.out.print(f(10).string()) | 148 | env.out.print(f(10).string()) | ||
149 | env.out.print(f(20).string()) | 149 | env.out.print(f(20).string()) | ||
150 | 150 | | |||
151 | /* nested /* commentary */ */ | 151 | /* nested /* commentary */ */ | ||
152 | // simgle comment | 152 | // single comment | ||
153 | 153 | | |||
154 | class A | ||||
155 | class _A | ||||
156 | x' | ||||
157 | x'' | ||||
158 | x'.string() | ||||
154 | '\uaaaa' | 159 | '\uaaaa' | ||
155 | '\Ubbbbbb' | 160 | '\Ubbbbbb' | ||
156 | '\xcc' | 161 | '\xcc' | ||
157 | "\uaaaaa" | 162 | "\uaaaaa" | ||
158 | "\Ubbbbbbb" | 163 | "\Ubbbbbbb" | ||
159 | "\xccc" | 164 | "\xccc" | ||
160 | 34.4 | 165 | 34.4 | ||
161 | 34.4e43 | 166 | 34.4e43 | ||
162 | 43e4 | 167 | 43e4 | ||
163 | 0x3040 | 168 | 0x3040 | ||
164 | 0xaF | 169 | 0xaF | ||
165 | 0b01 | 170 | 0b01 | ||
166 | 3_43_4 | 171 | 3_43_4 | ||
167 | 0x0_4 | 172 | 0x0_4 | ||
168 | 173 | | |||
169 | fun create(): U32 => 0 | 174 | fun create(): U32 => 0 | ||
170 | fun iso create(): U32 => 0 | 175 | fun iso create(): U32 => 0 | ||
171 | fun \\ abc \\ iso create(): U32 => 0 | 176 | fun \\ abc \\ iso create(): U32 => 0 | ||
172 | class \\ packet, blah \\ iso Xyz | 177 | class \\ packet, blah \\ iso Xyz | ||
173 | if \\ likely \\ a then | 178 | if \\ likely \\ a then | ||
174 | end | 179 | end | ||
175 | 180 | | |||
176 | a.endnormal | 181 | a.endnormal | ||
177 | 182 | | |||
183 | print();print() | ||||
184 | | ||||
178 | /* syntactically false: */ | 185 | /* syntactically false: */ | ||
179 | 186 | | |||
187 | class _aA | ||||
188 | class _a | ||||
189 | class a | ||||
180 | 0b2332 | 190 | 0b2332 | ||
181 | 0b | 191 | 0b | ||
182 | 0x | 192 | 0x | ||
183 | 0xgf | 193 | 0xgf | ||
184 | 0f00 | 194 | 0f00 | ||
185 | 3. | 195 | 3. | ||
186 | .3 | 196 | .3 | ||
187 | 3.e3 | 197 | 3.e3 | ||
188 | 3_ | 198 | 3_ | ||
189 | 3__43_4 | 199 | 3__43_4 | ||
190 | '' | 200 | '' | ||
191 | '\u' | 201 | '\u' | ||
192 | '\ua' | 202 | '\ua' | ||
193 | '\uaaa' | 203 | '\uaaa' | ||
194 | '\uaaaaa' | 204 | '\uaaaaa' | ||
195 | '\uyyyy' | 205 | '\uyyyy' | ||
196 | "\u" | 206 | "\u" | ||
197 | "\ua" | 207 | "\ua" | ||
198 | "\uaaa" | 208 | "\uaaa" | ||
199 | "\uyyyy" | 209 | "\uyyyy" | ||
210 | a'a | ||||
200 | 211 | | |||
201 | class badType | 212 | class badType | ||
213 | print(); |