(e ast.Expr)
| 668 | } |
| 669 | |
| 670 | func isCollectionEmpty(e ast.Expr) bool { |
| 671 | switch e.Kind() { |
| 672 | case ast.ListKind: |
| 673 | return e.AsList().Size() == 0 |
| 674 | case ast.MapKind: |
| 675 | return e.AsMap().Size() == 0 |
| 676 | default: |
| 677 | return false |
| 678 | } |
| 679 | } |
| 680 | |
| 681 | func exprEqualsNeedle(needle, target ast.Expr) bool { |
| 682 | if needle.Kind() == ast.LiteralKind && target.Kind() == ast.LiteralKind { |
no test coverage detected