Skip to content

Commit f04b1cf

Browse files
geooo109georgesittas
authored andcommitted
refactor impl
1 parent 2e1686b commit f04b1cf

File tree

2 files changed

+993
-971
lines changed

2 files changed

+993
-971
lines changed

sqlglot/optimizer/annotate_types.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -213,6 +213,11 @@ def __init__(
213213
# When set to False, this enables partial annotation by skipping already-annotated nodes
214214
self._overwrite_types = overwrite_types
215215

216+
def clean(self) -> None:
217+
self._visited.clear()
218+
self._null_expressions.clear()
219+
self._setop_column_types.clear()
220+
216221
def _set_type(
217222
self, expression: exp.Expression, target_type: t.Optional[exp.DataType | exp.DataType.Type]
218223
) -> None:

0 commit comments

Comments
 (0)