(node pcast.Node)
| 15 | } |
| 16 | |
| 17 | func toList(node pcast.Node) *ast.List { |
| 18 | var items []ast.Node |
| 19 | switch n := node.(type) { |
| 20 | case *pcast.TableName: |
| 21 | if schema := n.Schema.String(); schema != "" { |
| 22 | items = append(items, NewIdentifier(schema)) |
| 23 | } |
| 24 | items = append(items, NewIdentifier(n.Name.String())) |
| 25 | default: |
| 26 | return nil |
| 27 | } |
| 28 | return &ast.List{Items: items} |
| 29 | } |
| 30 | |
| 31 | func isNotNull(n *pcast.ColumnDef) bool { |
| 32 | for i := range n.Options { |
no test coverage detected