()
| 306 | return r |
| 307 | } |
| 308 | function parse_arg(){//todo |
| 309 | if(is_sp(","))return skip_split(","); |
| 310 | if(is_punc('{'))return parse_block(); |
| 311 | let n=null; |
| 312 | let prevv=input.prev() |
| 313 | if(is_id()){ |
| 314 | n=input.next(); |
| 315 | if(is_punc('(')){ |
| 316 | return { |
| 317 | type:"CallExpression", |
| 318 | value:n.value, |
| 319 | poi:{line:n.poi.line,start:n.poi.start}, |
| 320 | body:[parse_arguments()], |
| 321 | callee:prevv |
| 322 | } |
| 323 | } |
| 324 | }else if(is_kw("function")){//Anonymous Function |
| 325 | n=input.next(); |
| 326 | if(is_punc('(')){ |
| 327 | return { |
| 328 | type:"CallExpression", |
| 329 | value:n.value, |
| 330 | poi:{line:n.poi.line,start:n.poi.start}, |
| 331 | body:[parse_arguments()], |
| 332 | callee:prevv |
| 333 | } |
| 334 | } |
| 335 | }else{ |
| 336 | n=input.next(); |
| 337 | } |
| 338 | return { |
| 339 | type:"Arg", |
| 340 | value:n.value, |
| 341 | node:n, |
| 342 | poi:n.poi |
| 343 | } |
| 344 | } |
| 345 | function is_define(ch){ |
| 346 | var tok = input.peek(); |
| 347 | var keywords=["public","private","protected","sealed","internal","static","class","interface","namespace"] |
no test coverage detected