(n *chast.LikeExpr)
| 634 | } |
| 635 | |
| 636 | func (c *cc) convertLikeExpr(n *chast.LikeExpr) *ast.A_Expr { |
| 637 | kind := ast.A_Expr_Kind(0) |
| 638 | opName := "~~" |
| 639 | if n.CaseInsensitive { |
| 640 | opName = "~~*" |
| 641 | } |
| 642 | if n.Not { |
| 643 | opName = "!~~" |
| 644 | if n.CaseInsensitive { |
| 645 | opName = "!~~*" |
| 646 | } |
| 647 | } |
| 648 | |
| 649 | return &ast.A_Expr{ |
| 650 | Kind: kind, |
| 651 | Name: &ast.List{ |
| 652 | Items: []ast.Node{&ast.String{Str: opName}}, |
| 653 | }, |
| 654 | Lexpr: c.convertExpr(n.Expr), |
| 655 | Rexpr: c.convertExpr(n.Pattern), |
| 656 | Location: n.Pos().Offset, |
| 657 | } |
| 658 | } |
| 659 | |
| 660 | func (c *cc) convertSubquery(n *chast.Subquery) *ast.SubLink { |
| 661 | return &ast.SubLink{ |
no test coverage detected