()
| 492 | return r |
| 493 | } |
| 494 | function parse_if(){ |
| 495 | var n = input.next(); |
| 496 | var r={ |
| 497 | type:"IfStatement", |
| 498 | poi:{line:n.poi.line,start:n.poi.start}, |
| 499 | value:n.value, |
| 500 | } |
| 501 | if(is_sp(':')){r.body=parse_block().body}//else |
| 502 | else{ |
| 503 | r.condition=parse_condition() |
| 504 | if(is_sp(':')){ |
| 505 | r.body=parse_block().body |
| 506 | } |
| 507 | return r |
| 508 | } |
| 509 | // console.log('parse if',r) |
| 510 | return r |
| 511 | } |
| 512 | |
| 513 | function parse_try(){ |
| 514 | var n = input.next(); |
no test coverage detected